Enable memory transfer in enqueueMigrateMemObjects

Related-To: NEO-4589
Signed-off-by: Krzysztof Gibala <krzysztof.gibala@intel.com>
This commit is contained in:
Krzysztof Gibala
2020-12-28 12:10:10 +01:00
committed by Compute-Runtime-Automation
parent bbb0e9d095
commit 2e346b58cd
5 changed files with 92 additions and 19 deletions

View File

@ -26,6 +26,13 @@ cl_int CommandQueueHw<GfxFamily>::enqueueMigrateMemObjects(cl_uint numMemObjects
NullSurface s;
Surface *surfaces[] = {&s};
auto rootDeviceIndex = getDevice().getRootDeviceIndex();
for (unsigned int object = 0; object < numMemObjects; object++) {
auto memObject = castToObject<MemObj>(memObjects[object]);
memObject->getMigrateableMultiGraphicsAllocation().ensureMemoryOnDevice(*getDevice().getMemoryManager(), rootDeviceIndex);
}
enqueueHandler<CL_COMMAND_MIGRATE_MEM_OBJECTS>(surfaces,
false,
MultiDispatchInfo(),