From db3a5251664ae77f5e67dba571a11d208e448a86 Mon Sep 17 00:00:00 2001 From: Subv Date: Mon, 8 Jan 2018 14:14:30 -0500 Subject: Kernel: Actually wake up the requested number of threads in Semaphore::Release. Also properly keep track of data in guest memory, this fixes managing the semaphore from userland. It was found that Semaphores are actually Condition Variables, with Release(1) and Release(-1) being equivalent to notify_one and notify_all. We should change the name of the class to reflect this. --- src/citra_qt/debugger/wait_tree.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/citra_qt') diff --git a/src/citra_qt/debugger/wait_tree.cpp b/src/citra_qt/debugger/wait_tree.cpp index ebcc02894..6d15e43aa 100644 --- a/src/citra_qt/debugger/wait_tree.cpp +++ b/src/citra_qt/debugger/wait_tree.cpp @@ -273,9 +273,8 @@ std::vector> WaitTreeSemaphore::GetChildren() cons std::vector> list(WaitTreeWaitObject::GetChildren()); const auto& semaphore = static_cast(object); - list.push_back( - std::make_unique(tr("available count = %1").arg(semaphore.available_count))); - list.push_back(std::make_unique(tr("max count = %1").arg(semaphore.max_count))); + list.push_back(std::make_unique( + tr("available count = %1").arg(semaphore.GetAvailableCount()))); return list; } -- cgit v1.2.3