Enable zero copy for enqueueWriteBufferRect with hint

Change-Id: I411f00b98056307906c02d34e793cefe460735ba
This commit is contained in:
mplewka
2018-01-24 09:57:20 +01:00
committed by sys_ocldev
parent f3f53ed14b
commit 251de14ee6
13 changed files with 390 additions and 10 deletions

View File

@@ -45,7 +45,7 @@ cl_int CommandQueueHw<GfxFamily>::enqueueWriteBuffer(
cl_event *event) {
cl_int retVal = CL_SUCCESS;
auto isMemTransferNeeded = buffer->checkIfMemoryTransferIsRequired(offset, ptr, CL_COMMAND_WRITE_BUFFER);
auto isMemTransferNeeded = buffer->checkIfMemoryTransferIsRequired(offset, 0, ptr, CL_COMMAND_WRITE_BUFFER);
if ((DebugManager.flags.DoCpuCopyOnWriteBuffer.get() ||
buffer->isReadWriteOnCpuAllowed(blockingWrite, numEventsInWaitList, const_cast<void *>(ptr), size)) &&
context->getDevice(0)->getDeviceInfo().cpuCopyAllowed) {