-
Type: Improvement
-
Resolution: Duplicate
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Concurrency
-
None
sleepmicros() is misleading as the resolution can be very low on most operating systems. a quick test on linux yielded the results below. on windows it is even more coarse-grained always taking close to 1ms if the parameter is non-zero.
left is requested micros, right is actual
sleep 0 time: 1 sleep 1 time: 98 sleep 3 time: 71 sleep 7 time: 65 sleep 15 time: 72 sleep 31 time: 88 sleep 63 time: 120 sleep 127 time: 187 sleep 255 time: 314 sleep 511 time: 596 sleep 1023 time: 1131 sleep 2047 time: 2140 sleep 4095 time: 4188
- is duplicated by
-
SERVER-10362 yielding during read queries waiting too long for fair locking
- Closed
- related to
-
SERVER-2114 Don't use select timeouts for fast coarse timing
- Closed