[libc-commits] [libc] [llvm] [libc][CndVar] reimplmement conditional variable with FIFO ordering (PR #192748)

Michael Jones via libc-commits libc-commits at lists.llvm.org
Mon Apr 20 13:52:53 PDT 2026


================
@@ -30,6 +30,12 @@ class Mutex final : private RawMutex {
   pid_t owner;
   unsigned long long lock_count;
 
+  friend class PrivateCndVar;
+
+  LIBC_INLINE bool can_be_requeued() const {
+    return !this->pshared && !this->robust;
+  }
----------------
michaelrj-google wrote:

Why does this need to be private? If we made it public we wouldn't need to make `PrivateCndVar` a friend.

https://github.com/llvm/llvm-project/pull/192748


More information about the libc-commits mailing list