fix(ocl): Use GPU address of SVM alloc. when using builtins

Use GPU address of SVM allocation instead of CPU one. It fixes a bug
visible on platforms, where potentially GPU VA does not have to match
CPU VA.

Related-To: NEO-7970
Signed-off-by: Kacper Nowak <kacper.nowak@intel.com>
This commit is contained in:
Kacper Nowak
2023-05-19 00:43:16 +00:00
committed by Compute-Runtime-Automation
parent 3c35ca5f20
commit d05fee8087
2 changed files with 89 additions and 15 deletions

View File

@@ -340,7 +340,7 @@ class BuiltInOp<EBuiltInOps::FillBuffer> : public BuiltinDispatchInfoBuilder {
// Set-up srcMemObj with pattern
auto graphicsAllocation = operationParams.srcMemObj->getMultiGraphicsAllocation().getDefaultGraphicsAllocation();
kernelSplit1DBuilder.setArgSvm(2, operationParams.srcMemObj->getSize(), graphicsAllocation->getUnderlyingBuffer(), graphicsAllocation, CL_MEM_READ_ONLY);
kernelSplit1DBuilder.setArgSvm(2, operationParams.srcMemObj->getSize(), reinterpret_cast<void *>(graphicsAllocation->getGpuAddress()), graphicsAllocation, CL_MEM_READ_ONLY);
// Set-up patternSizeInEls
kernelSplit1DBuilder.setArg(SplitDispatch::RegionCoordX::Left, 3, static_cast<OffsetType>(operationParams.srcMemObj->getSize()));