Re: [PATCH v17 0/2] MR3504: ntdll: An implementation of SRWLOCK that closer matches Windows'.
31 Aug
2023
31 Aug
'23
12:25 p.m.
On Thu Aug 31 12:25:16 2023 +0000, Yuxuan Shui wrote:
oh my, native SRWLOCK is really really fast. Even when compared to the current, no wait list version. I noticed with exclusive locks, current SRWLOCK would show >100% CPU usage. I think this means there are some spinning going on? I see, in current version all threads Waits on the same Address, so the address' futex queue is contended. Threads are spinning on `queue->lock`, so there is a chance for the lock to be released and the threads never actually call `futex` (in this synthetic test anyway).
Whereas with this MR threads are generally waiting on different addresses, so they always enter futex. -- https://gitlab.winehq.org/wine/wine/-/merge_requests/3504#note_43958
839
Age (days ago)
839
Last active (days ago)
0 comments
1 participants
participants (1)
-
Yuxuan Shui (@yshui)