P4 to Git Change 1991259 by gandryey@gera-win10 on 2019/08/29 18:45:50

SWDEV-200614 - [Schneider] Crash in Agisoft when run in mGPU environment
	-  Add a workaround for memory pinning path. It will perform 2-step copy to make sure memory pinning doesn't occur on the first unaligned page, because in Windows memory manager can have CPU access to the allocation header in another thread and a race condition is possible
	- change some default setting for staging and pinned paths, because PCIE gen3 performance.

Affected files ...

... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palsettings.cpp#96 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palvirtual.cpp#150 edit
... //depot/stg/opencl/drivers/opencl/runtime/utils/flags.hpp#317 edit
This commit is contained in:
foreman
2019-08-29 18:58:53 -04:00
parent b6f298d3f0
commit daa0e96062
3 changed files with 54 additions and 8 deletions
+7 -2
View File
@@ -61,9 +61,14 @@ Settings::Settings() {
// By default use host blit
blitEngine_ = BlitEngineHost;
const static size_t MaxPinnedXferSize = 32;
constexpr size_t MaxPinnedXferSize = 64;
pinnedXferSize_ = std::min(GPU_PINNED_XFER_SIZE, MaxPinnedXferSize) * Mi;
pinnedMinXferSize_ = std::min(GPU_PINNED_MIN_XFER_SIZE * Ki, pinnedXferSize_);
constexpr size_t PinnedMinXferSize = 4 * Mi;
pinnedMinXferSize_ = flagIsDefault(GPU_PINNED_MIN_XFER_SIZE)
? PinnedMinXferSize
: GPU_PINNED_MIN_XFER_SIZE * Ki;
pinnedMinXferSize_ = std::min(pinnedMinXferSize_, pinnedXferSize_);
// Disable FP_FAST_FMA defines by default
reportFMAF_ = false;