Dont use Device from Kernel 2/n

make getDevice method protected

Related-To: NEO-5001
Signed-off-by: Mateusz Jablonski <mateusz.jablonski@intel.com>
This commit is contained in:
Mateusz Jablonski
2020-11-17 11:08:06 +01:00
committed by Compute-Runtime-Automation
parent 59b74a8ea3
commit 9d7807709d
6 changed files with 20 additions and 19 deletions

View File

@@ -4611,7 +4611,7 @@ cl_int CL_API_CALL clSetKernelArgSVMPointer(cl_kernel kernel,
}
}
} else {
pSvmAlloc = svmData->gpuAllocations.getGraphicsAllocation(pKernel->getDevice().getRootDeviceIndex());
pSvmAlloc = svmData->gpuAllocations.getGraphicsAllocation(pKernel->getDevices()[0]->getRootDeviceIndex());
}
}
@@ -4680,7 +4680,7 @@ cl_int CL_API_CALL clSetKernelExecInfo(cl_kernel kernel,
TRACING_EXIT(clSetKernelExecInfo, &retVal);
return retVal;
}
GraphicsAllocation *svmAlloc = svmData->gpuAllocations.getGraphicsAllocation(pKernel->getDevice().getRootDeviceIndex());
GraphicsAllocation *svmAlloc = svmData->gpuAllocations.getGraphicsAllocation(pKernel->getDevices()[0]->getRootDeviceIndex());
if (paramName == CL_KERNEL_EXEC_INFO_SVM_PTRS) {
pKernel->setSvmKernelExecInfo(svmAlloc);