5 ms·
AIUI fsync is built on futex_waitv which has been upstreamed. So this has to be more than that. Edit: ah, it's about wine upstream, not kernel upstream. they w
by the8472 3y ago
AIUI fsync is built on futex_waitv which has been upstreamed. So this has to be more than that.
Edit: ah, it's about wine upstream, not kernel upstream. they won't take esync/fsync because those have some missing features.
https://github.com/torvalds/linux/commit/a0eb2da92b715d0c97b96b09979689ea09faefe6 https://github.com/torvalds/linux/commit/a0eb2da92b715d0c97b...
- mjevans 3y agofutex_waitv was only a small part of the whole FUTEX2 package. https://www.phoronix.com/news/FUTEX2-futex_waitv-v2 ... https://www.phoronix.com/search/FUTEX2 ... https://www.phoronix.com/news/Futex2-System-Call-RFC https://www.phoronix.com/news/FUTEX2-LPC-2020 https://www.phoronix.com/news/FUTEX2-2021-Still-WIP https://www.phoronix.com/news/FUTEX2-Bits-In-Locking-Core Though none of the articles so far have bothered looking up... 'NtPulseEvent() or the "wait-for-all" mode of NtWaitForMultipleObjects()' Not many great hits for NtPulseEvent() but the first result I got says "Function sets event to signaled state, releases all (or one - dependly of EVENT_TYPE) waiting threads, and resets event to non-signaled state. If they're no waiting threads, NtPulseEvent just clear event state." NtWaitForMultipleObjects() https://learn.microsoft.com/en-us/windows/win32/api/synchapi/nf-synchapi-waitformultipleobjects https://learn.microsoft.com/en-us/windows/win32/api/synchapi... After reading this, I'm still unclear about what's missing. A guess is the wakeup on timeout?
- poizan42 3y agoFor the public documentation for NtPulseEvent, see PulseEvent (which just calls NtPulseEvent): https://learn.microsoft.com/en-us/windows/win32/api/winbase/nf-winbase-pulseevent https://learn.microsoft.com/en-us/windows/win32/api/winbase/...
- shmerl 3y agoYeah, it's not upstreamed in Wine, you can check the linked video which explains why (same problem as with esync basically, some Windows logic like wait on all and nt pulse event doesn't work with it). The funny part is that those are almost never used anyway, so it's more of a formality on the Wine part to be always correct. But at least it's moving somewhere now possibly.