aboutsummaryrefslogtreecommitdiff
path: root/lib/std/debug.zig
diff options
context:
space:
mode:
authormlugg <mlugg@mlugg.co.uk>2025-09-13 19:57:03 +0100
committerMatthew Lugg <mlugg@mlugg.co.uk>2025-10-18 09:28:43 +0100
commitb866c14328f0779b38f073b2ee3a8a3e437d129c (patch)
tree4174d7f1b185acda2a1d04f387715e77af7a920c /lib/std/debug.zig
parent7a5d2a196f2d78eb55f8ef294b4c899e0378f71e (diff)
downloadzig-b866c14328f0779b38f073b2ee3a8a3e437d129c.tar.gz
zig-b866c14328f0779b38f073b2ee3a8a3e437d129c.zip
std: make RwLock test less intensive
This test called `yield` 80,000 times, which is nothing on a system with little load, but murder on a CI system. macOS' scheduler in particular doesn't seem to deal with this very well. The `yield` calls also weren't even necessarily doing what they were meant to: if the optimizer could figure out that it doesn't clobber some memory, then it could happily reorder around the `yield`s anyway! The test has been simplified and made to work better, and the number of yields have been reduced. The number of overall iterations has also been reduced, because with the `yield` calls making races very likely, we don't really need to run too many iterations to be confident that the implementation is race-free.
Diffstat (limited to 'lib/std/debug.zig')
0 files changed, 0 insertions, 0 deletions