SWDEV-405329 - Fix cuMask issue for WGP mode

- Enable CUs adjacent pairwise for WGP mode
- In HostQueue::terminate() do not segfault if virtual device hasn't been created

Change-Id: I94402ff333308af5824878086cc238b3993d534d


[ROCm/clr commit: 8c1232124e]
This commit is contained in:
Rakesh Roy
2023-06-27 20:57:49 +05:30
committed by Rakesh Roy
parent 47894de700
commit f887f2fc6f
2 changed files with 33 additions and 6 deletions
@@ -60,11 +60,13 @@ HostQueue::HostQueue(Context& context, Device& device, cl_command_queue_properti
bool HostQueue::terminate() {
if (AMD_DIRECT_DISPATCH) {
Command* marker = new Marker(*this, true);
if (marker != nullptr) {
marker->enqueue();
marker->awaitCompletion();
marker->release();
if (vdev() != nullptr) {
Command* marker = new Marker(*this, true);
if (marker != nullptr) {
marker->enqueue();
marker->awaitCompletion();
marker->release();
}
}
thread_.Release();
thread_.acceptingCommands_ = false;