Rollup merge of #154967 - PaulDance:patches/fix-x86-win7-rwlock-max-test, r=Mark-Simulacrum
Test(lib/sync): Fix `test_rwlock_max_readers` for x86 Win7 The test recently added in rust-lang/rust#153555 currently systematically deadlocks when running it under i686 Windows 7, but not x86_64 that passes it fine. This therefore fixes the test for the target. Empirically, the correct value for `MAX_READERS` seems to be `2^28 - 1`: removing the `- 1` re-introduces the deadlock, at least under our testing environment. This fix thus uses this value. However, I have no real justification to support that, because I find myself a bit at a loss when comparing the implementation details, the comment added above the test and what the current value is; some help would therefore be nice in this aspect. Also, the value change is restricted to 32-bit Win7 as there is no evidence to support it should be done for other targets. cc @roblabla @rustbot label O-windows-msvc O-windows-7 O-x86_32 A-atomic T-libs
J
Jonathan Brouwer committed
197eb8c6c0a495f52d71c8e7bda98818010dee55
Committed by GitHub <noreply@github.com>
on 4/11/2026, 6:58:35 PM