Revert "performance: Use lock pointer copy for dc flush mitigation"

This reverts commit b8be102455.

Signed-off-by: Compute-Runtime-Validation <compute-runtime-validation@intel.com>
This commit is contained in:
Compute-Runtime-Validation
2024-10-31 04:46:45 +01:00
committed by Compute-Runtime-Automation
parent aca7875dfd
commit 3fcb9b18ee
5 changed files with 15 additions and 34 deletions

View File

@@ -24,7 +24,6 @@
#include "shared/source/memory_manager/memory_operations_handler.h"
#include "shared/source/memory_manager/migration_sync_data.h"
#include "shared/source/os_interface/os_interface.h"
#include "shared/source/utilities/cpuintrinsics.h"
#include "opencl/source/cl_device/cl_device.h"
#include "opencl/source/command_queue/command_queue.h"
@@ -213,7 +212,8 @@ bool inline copyHostPointer(Buffer *buffer,
size <= Buffer::maxBufferSizeForCopyOnCpu &&
isCompressionEnabled == false &&
productHelper.getLocalMemoryAccessMode(hwInfo) != LocalMemoryAccessMode::cpuAccessDisallowed &&
isLockable;
isLockable &&
!isGpuCopyRequiredForDcFlushMitigation;
if (debugManager.flags.CopyHostPtrOnCpu.get() != -1) {
copyOnCpuAllowed = debugManager.flags.CopyHostPtrOnCpu.get() == 1;
@@ -222,9 +222,6 @@ bool inline copyHostPointer(Buffer *buffer,
memory->setAubWritable(true, GraphicsAllocation::defaultBank);
memory->setTbxWritable(true, GraphicsAllocation::defaultBank);
memcpy_s(ptrOffset(lockedPointer, buffer->getOffset()), size, hostPtr, size);
if (isGpuCopyRequiredForDcFlushMitigation) {
CpuIntrinsics::sfence();
}
return true;
} else {
auto blitMemoryToAllocationResult = BlitOperationResult::unsupported;