Add Blitter support for WriteBufferRect

Related-To: NEO-4013
Change-Id: I8506e2ba1437399d888cc2c7cbc724c52fe2aa9f
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
This commit is contained in:
Krzysztof Gibala
2020-03-30 15:20:55 +02:00
committed by sys_ocldev
parent f599773c27
commit d2508fb501
7 changed files with 144 additions and 37 deletions

View File

@@ -61,7 +61,12 @@ struct ClBlitProperties {
gpuAllocation = builtinOpParams.dstMemObj->getGraphicsAllocation();
memObjGpuVa = (gpuAllocation->getGpuAddress() + builtinOpParams.dstMemObj->getOffset());
}
copySize.x = builtinOpParams.size.x;
hostRowPitch = builtinOpParams.srcRowPitch;
hostSlicePitch = builtinOpParams.srcSlicePitch;
gpuRowPitch = builtinOpParams.dstRowPitch;
gpuSlicePitch = builtinOpParams.dstSlicePitch;
copySize = builtinOpParams.size;
}
if (BlitterConstants::BlitDirection::BufferToHostPtr == blitDirection) {
@@ -100,7 +105,7 @@ struct ClBlitProperties {
}
static BlitterConstants::BlitDirection obtainBlitDirection(uint32_t commandType) {
if (CL_COMMAND_WRITE_BUFFER == commandType) {
if (CL_COMMAND_WRITE_BUFFER == commandType || CL_COMMAND_WRITE_BUFFER_RECT == commandType) {
return BlitterConstants::BlitDirection::HostPtrToBuffer;
} else if (CL_COMMAND_READ_BUFFER == commandType || CL_COMMAND_READ_BUFFER_RECT == commandType) {
return BlitterConstants::BlitDirection::BufferToHostPtr;