User space AUBs capable of memory re-dumps on CPU-side memory modifications.

Any CPU related updates such as clEnqueueMapBuffer or similar
need to trigger a re-dump of memory prior to the next clEnqueue call.

Change-Id: I7b31e559278e92ff55b6ebab8ef4190caef1ebc0
This commit is contained in:
Milczarek, Slawomir
2018-04-01 18:42:42 +02:00
committed by sys_ocldev
parent e1697d7002
commit b56289a507
8 changed files with 142 additions and 13 deletions

View File

@@ -135,6 +135,10 @@ void *CommandQueue::cpuDataTransferHandler(TransferProperties &transferPropertie
}
eventCompleted = true;
}
if (!unmapInfo.readOnly) {
auto graphicsAllocation = transferProperties.memObj->getGraphicsAllocation();
graphicsAllocation->clearTypeAubNonWritable();
}
break;
case CL_COMMAND_READ_BUFFER:
memcpy_s(transferProperties.ptr, transferProperties.size[0], ptrOffset(transferProperties.memObj->getCpuAddressForMemoryTransfer(), transferProperties.offset[0]), transferProperties.size[0]);