fix: add L3 flush after post sync for zero copy mem objects
Related-To: NEO-13163 Signed-off-by: Kamil Kopryk <kamil.kopryk@intel.com>
This commit is contained in:
parent
90da066972
commit
caf1781e73
|
@ -104,7 +104,7 @@ inline void HardwareInterface<GfxFamily>::programWalker(
|
|||
|
||||
if constexpr (heaplessModeEnabled) {
|
||||
auto &productHelper = rootDeviceEnvironment.getHelper<ProductHelper>();
|
||||
bool flushL3AfterPostSyncForHostUsm = kernelSystemAllocation;
|
||||
bool flushL3AfterPostSyncForHostUsm = kernelSystemAllocation || kernel.isAnyKernelArgumentUsingZeroCopyMemory();
|
||||
bool flushL3AfterPostSyncForExternalAllocation = kernel.isUsingSharedObjArgs();
|
||||
|
||||
if (debugManager.flags.DisableFlushL3ForHostUsm.get() && flushL3AfterPostSyncForHostUsm) {
|
||||
|
|
|
@ -1469,6 +1469,8 @@ cl_int Kernel::setArgBuffer(uint32_t argIndex,
|
|||
this->anyKernelArgumentUsingSystemMemory |= Kernel::graphicsAllocationTypeUseSystemMemory(gfxAllocationType);
|
||||
}
|
||||
|
||||
this->anyKernelArgumentUsingZeroCopyMemory |= buffer->isMemObjZeroCopy();
|
||||
|
||||
if (buffer->peekSharingHandler()) {
|
||||
usingSharedObjArgs = true;
|
||||
}
|
||||
|
|
|
@ -375,6 +375,10 @@ class Kernel : public ReferenceTrackedObject<Kernel>, NEO::NonCopyableAndNonMova
|
|||
return anyKernelArgumentUsingSystemMemory;
|
||||
}
|
||||
|
||||
bool isAnyKernelArgumentUsingZeroCopyMemory() const {
|
||||
return anyKernelArgumentUsingZeroCopyMemory;
|
||||
}
|
||||
|
||||
static bool graphicsAllocationTypeUseSystemMemory(AllocationType type);
|
||||
void setDestinationAllocationInSystemMemory(bool value) {
|
||||
isDestinationAllocationInSystemMemory = value;
|
||||
|
@ -471,6 +475,7 @@ class Kernel : public ReferenceTrackedObject<Kernel>, NEO::NonCopyableAndNonMova
|
|||
bool isUnifiedMemorySyncRequired = true;
|
||||
bool kernelHasIndirectAccess = true;
|
||||
bool anyKernelArgumentUsingSystemMemory = false;
|
||||
bool anyKernelArgumentUsingZeroCopyMemory = false;
|
||||
bool isDestinationAllocationInSystemMemory = false;
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue