P4 to Git Change 1295077 by gandryey@gera-w8 on 2016/07/25 15:54:39

SWDEV-95007 - OpenCL on PAL (Windows)
	- Fix buffer rect copy when bytesPerElement>1
	- Report the number of banks to avoid OCLtst failure

Affected files ...

... //depot/stg/opencl/drivers/opencl/runtime/device/pal/paldevice.cpp#15 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palresource.cpp#8 edit


[ROCm/clr commit: 594dcef8a4]
This commit is contained in:
foreman
2016-07-25 16:08:09 -04:00
parent 32fbc0aa47
commit 884cf38d01
2 changed files with 2 additions and 2 deletions
@@ -463,7 +463,7 @@ void NullDevice::fillDeviceInfo(
info_.simdInstructionWidth_ = hwInfo()->simdInstructionWidth_;
info_.wavefrontWidth_ = palProp.gfxipProperties.shaderCore.wavefrontSize;
info_.globalMemChannels_ = palProp.gpuMemoryProperties.performance.vramBusBitWidth / 32;
//info_.globalMemChannelBanks_ = calAttr.numMemBanks;
info_.globalMemChannelBanks_ = 4;
info_.globalMemChannelBankWidth_ = hwInfo()->memChannelBankWidth_;
info_.localMemSizePerCU_ = hwInfo()->localMemSizePerCU_;
info_.localMemBanks_ = hwInfo()->localMemBanks_;
@@ -1238,7 +1238,7 @@ Resource::partialMemCopyTo(
copyRegion.srcBuffer.offset = calSrcOrigin[0] + offset();
copyRegion.srcBuffer.rowPitch = calSrcOrigin[1];
copyRegion.srcBuffer.depthPitch = calSrcOrigin[2];
copyRegion.extent.width = calSize[0];
copyRegion.extent.width = calSize[0] / bytesPerElement;
copyRegion.extent.height = calSize[1];
copyRegion.extent.depth = calSize[2];
copyRegion.dstBuffer.format.chFmt = ChannelFmt(bytesPerElement);