2 ms·
It's not entirely clear from the article, but my understanding was that "longest wait" maintains per-thread timestamps, i.e. the time to lock() within a single
by RossBencina 7y ago
It's not entirely clear from the article, but my understanding was that "longest wait" maintains per-thread timestamps, i.e. the time to lock() within a single thread, whereas "idle time" uses a single global atomic timestamp that measures the time from when the last thread unlocks until the next thread locks -- even if the unlock() and subsequent lock() are on different threads.