mirror of
https://codeberg.org/ziglang/zig.git
synced 2025-12-06 13:54:21 +00:00
fixes #12877 Current implementation (before this fix) observes number of waiters when broadcast occurs and then makes that number of wakeups. If we have multiple threads waiting for wakeup which immediately go into wait if wakeup is not for that thread (as described in the issue). The same thread can get multiple wakeups while some got none. That is not consistent with documented behavior for condition variable broadcast: `Unblocks all threads currently blocked in a call to wait() or timedWait() with a given Mutex.`. This fix ensures that the thread waiting on futext is woken up on futex wake. |
||
|---|---|---|
| .. | ||
| Condition.zig | ||
| Futex.zig | ||
| Mutex.zig | ||
| ResetEvent.zig | ||
| RwLock.zig | ||
| Semaphore.zig | ||