fix: Add explicit nullptr checks

Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
This commit is contained in:
Filip Hazubski
2024-12-09 20:44:06 +00:00
committed by Compute-Runtime-Automation
parent 2c37db194e
commit 43c199185a
2 changed files with 4 additions and 1 deletions

View File

@@ -340,9 +340,11 @@ cl_int CommandQueueHw<GfxFamily>::enqueueSVMMemcpy(cl_bool blockingCopy,
auto pageFaultManager = context->getMemoryManager()->getPageFaultManager();
if (dstSvmData && pageFaultManager) {
UNRECOVERABLE_IF(dstAllocation == nullptr);
pageFaultManager->moveAllocationToGpuDomain(reinterpret_cast<void *>(dstAllocation->getGpuAddress()));
}
if (srcSvmData && pageFaultManager) {
UNRECOVERABLE_IF(srcAllocation == nullptr);
pageFaultManager->moveAllocationToGpuDomain(reinterpret_cast<void *>(srcAllocation->getGpuAddress()));
}