From 692f05e62860c7af2abcf3fc14f307f48b64074a Mon Sep 17 00:00:00 2001
From: foreman
Date: Tue, 27 Sep 2016 11:15:47 -0400
Subject: [PATCH] P4 to Git Change 1319330 by gandryey@gera-w8 on 2016/09/27
11:03:51
SWDEV-86035 - Add PAL backend to OpenCL
- Use wait() for now to match GSL path.
Affected files ...
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palmemory.cpp#7 edit
... //depot/stg/opencl/drivers/opencl/runtime/device/pal/palvirtual.cpp#25 edit
---
rocclr/runtime/device/pal/palmemory.cpp | 4 ++++
rocclr/runtime/device/pal/palvirtual.cpp | 3 ---
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/rocclr/runtime/device/pal/palmemory.cpp b/rocclr/runtime/device/pal/palmemory.cpp
index eb7f8cc2b3..eae90ef2c0 100644
--- a/rocclr/runtime/device/pal/palmemory.cpp
+++ b/rocclr/runtime/device/pal/palmemory.cpp
@@ -572,6 +572,10 @@ Memory::syncCacheFromHost(VirtualGPU& gpu, device::Memory::SyncFlags syncFlags)
}
}
+ //!@todo A wait isn't really necessary. However processMemObjects()
+ // may lose the track of dependencies with a compute transfer(if sdma failed).
+ wait(gpu);
+
// Should never fail
assert(result && "Memory synchronization failed!");
}
diff --git a/rocclr/runtime/device/pal/palvirtual.cpp b/rocclr/runtime/device/pal/palvirtual.cpp
index 4a9060d58d..40e2ed043e 100644
--- a/rocclr/runtime/device/pal/palvirtual.cpp
+++ b/rocclr/runtime/device/pal/palvirtual.cpp
@@ -3208,9 +3208,6 @@ VirtualGPU::processMemObjectsHSA(
memoryDependency().validate(*this, mem, IsReadOnly);
}
- // Mark the tracker with the processed kernel
- memoryDependency().newKernel();
-
return true;
}