SWDEV-528808 - Release all HW queues even if only one is idle (#240)

Pytorch may not explicitly idle each queue. Thus, some queues can be considered as busy,
but have idle state in reality


[ROCm/clr commit: 65a0181a7c]
This commit is contained in:
Andryeyev, German
2025-05-05 19:09:01 -04:00
committed by GitHub
parent ee91a1e94a
commit 3ea758a2d4
5 changed files with 68 additions and 3 deletions
@@ -195,10 +195,13 @@ void HostQueue::finish(bool cpu_wait) {
device_.removeFromActiveQueues(this);
lastEnqueueCommand_->release();
lastEnqueueCommand_ = nullptr;
vdev()->ReleaseHwQueue(); // we can only release HwQueue when no commmand in quque.
}
}
}
// Release all HW queues, which are idle or nearly idle
vdev()->ReleaseAllHwQueues();
command->release();
ClPrint(LOG_DEBUG, LOG_CMD, "All commands finished for host queue : %p", this);
}