Use a dedicated lock for last queued command set/get

Change-Id: If3d2144841c7863cf7afe2ca85aea62e0a3a33c7


[ROCm/clr commit: 0782acabb5]
이 커밋은 다음에 포함됨:
Christophe Paquot가 2020-05-28 12:49:39 -07:00를 커밋했습니다
1 부모 75e59b010a
커밋 992fbe8215
2 파일이 변경됨
+6 -6

검색과 일치하는 파일 없음

+2
파일 보기
@@ -126,6 +126,7 @@ class CommandQueue : public RuntimeObject {
rtCUs_(rtCUs),
priority_(priority),
queueLock_("CommandQueue::queueLock"),
lastCmdLock_("LastQueuedCommand"),
device_(device),
context_(context),
cuMask_(cuMask){}
@@ -134,6 +135,7 @@ class CommandQueue : public RuntimeObject {
uint rtCUs_; //!< The number of used RT compute units
Priority priority_; //!< Queue priority
Monitor queueLock_; //!< Lock protecting the queue
Monitor lastCmdLock_; //!< Lock protecting the last queued command
Device& device_; //!< The device
SharedReference<Context> context_; //!< The context of this command queue
const std::vector<uint32_t>& cuMask_; //!< The CU mask