mirror of
https://github.com/intel/compute-runtime.git
synced 2026-01-08 22:12:59 +08:00
performance: enable staging read for images
Related-To: NEO-12968 Signed-off-by: Szymon Morek <szymon.morek@intel.com>
This commit is contained in:
committed by
Compute-Runtime-Automation
parent
363f2becd4
commit
6aeb8dffa0
@@ -2892,19 +2892,22 @@ cl_int CL_API_CALL clEnqueueReadImage(cl_command_queue commandQueue,
|
||||
TRACING_EXIT(ClEnqueueReadImage, &retVal);
|
||||
return retVal;
|
||||
}
|
||||
|
||||
retVal = pCommandQueue->enqueueReadImage(
|
||||
pImage,
|
||||
blockingRead,
|
||||
origin,
|
||||
region,
|
||||
rowPitch,
|
||||
slicePitch,
|
||||
ptr,
|
||||
nullptr,
|
||||
numEventsInWaitList,
|
||||
eventWaitList,
|
||||
event);
|
||||
if (pCommandQueue->isValidForStagingTransferImage(pImage, ptr, numEventsInWaitList > 0)) {
|
||||
retVal = pCommandQueue->enqueueStagingReadImage(pImage, blockingRead, origin, region, rowPitch, slicePitch, ptr, event);
|
||||
} else {
|
||||
retVal = pCommandQueue->enqueueReadImage(
|
||||
pImage,
|
||||
blockingRead,
|
||||
origin,
|
||||
region,
|
||||
rowPitch,
|
||||
slicePitch,
|
||||
ptr,
|
||||
nullptr,
|
||||
numEventsInWaitList,
|
||||
eventWaitList,
|
||||
event);
|
||||
}
|
||||
}
|
||||
DBG_LOG_INPUTS("event", getClFileLogger().getEvents(reinterpret_cast<const uintptr_t *>(event), 1u));
|
||||
TRACING_EXIT(ClEnqueueReadImage, &retVal);
|
||||
|
||||
Reference in New Issue
Block a user