P4 to Git Change 1416530 by skudchad@skudchad_test_win_opencl2 on 2017/05/31 16:37:42

SWDEV-121555 - [Gfx10][SW Emulation] - Support for SW emulation path for Compute
	- Create a new envvar PAL_DISABLE_SDMA to disable SDMA in runtime.

	ReviewBoardURL = http://ocltc.amd.com/reviews/r/12850/diff/

Affected files ...

... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palvirtual.cpp#50 edit
... //depot/stg/opencl/drivers/opencl/runtime/utils/flags.hpp#273 edit
Этот коммит содержится в:
foreman
2017-05-31 16:46:02 -04:00
родитель 6b1b3219c8
Коммит 4d1e5728ab
2 изменённых файлов: 11 добавлений и 4 удалений
+9 -4
Просмотреть файл
@@ -759,12 +759,13 @@ bool VirtualGPU::create(bool profiling, uint deviceQueueSize, uint rtCUs,
return false;
}
const uint firstQueue = (dev().numComputeEngines() > 2) ? 1 : 0;
uint idx = index() % (dev().numComputeEngines() - firstQueue);
if (dev().numComputeEngines()) {
//! @todo There is a hang with a mix of user and non user queues.
//! Currently there is no simple way to detect which queue is what.
//! Disable first for now.
const uint firstQueue = (dev().numComputeEngines() > 2) ? 1 : 0;
uint idx = index() % (dev().numComputeEngines() - firstQueue);
// hwRing_ should be set 0 if forced to have single scratch buffer
hwRing_ = (dev().settings().useSingleScratch_) ? 0 : idx;
@@ -776,7 +777,7 @@ bool VirtualGPU::create(bool profiling, uint deviceQueueSize, uint rtCUs,
}
// Check if device has SDMA engines
if (dev().numDMAEngines() != 0) {
if (dev().numDMAEngines() != 0 && !PAL_DISABLE_SDMA) {
uint sdma;
// If only 1 DMA engine is available then use that one
if ((dev().numDMAEngines() < 2) || ((idx & 0x1) && !dev().settings().svmFineGrainSystem_)) {
@@ -792,7 +793,11 @@ bool VirtualGPU::create(bool profiling, uint deviceQueueSize, uint rtCUs,
return false;
}
} else {
Unimplemented();
queues_[SdmaEngine] = Queue::Create(dev().iDev(), Pal::QueueTypeCompute,
idx, cmdAllocator_, rtCUs, amd::CommandQueue::Priority::Normal);
if (nullptr == queues_[SdmaEngine]) {
return false;
}
}
} else {
Unimplemented();
+2
Просмотреть файл
@@ -209,6 +209,8 @@ release(bool, OCL_CODE_CACHE_RESET, false, \
"1 = Reset the compiler code cache storage") \
release(bool, GPU_VEGA10_ONLY, VEGA10_ONLY, \
"1 = Report vega10 only on OCL/ROCR") \
release_on_stg(bool, PAL_DISABLE_SDMA, false, \
"1 = Disable SDMA for PAL") \
namespace amd {