[Git][wine/wine][master] 2 commits: Revert "kernel32/tests: Don't use _ReadWriteBarrier on ARM platforms."
Alexandre Julliard pushed to branch master at wine / wine Commits: 615afdc2 by Jinoh Kang at 2025-04-28T16:31:57+02:00 Revert "kernel32/tests: Don't use _ReadWriteBarrier on ARM platforms." This reverts commit 504a305a60849704f2d83b55e9aabb26d89edf11. The choice of weak barrier was by design. The stronger barrier broke the positive half of the litmus test for FlushProcessWriteBuffers():
virtual.c:4568: Test failed: expected write-read reordering with compiler barrier only (got 0 reorderings)
FlushProcessWriteBuffers() is used in tandem with a compiler-only barrier to implement fast synchronization, where only one side is executed frequently and the other side only occassionally (e.g., garbage collection). Prominent applications include .NET and HotSpot JVM. Although _ReadWriteBarrier() is "marked deprecated," it is in fact used by Microsoft's own STL library (with explicit suppression of warning) to implement a compiler-only memory barrier [1]. The deprecation notice suggests C++11 atomics as the (only?) alternative. [1]: https://github.com/microsoft/STL/blob/b5df16a98934319e2e6864d6036cbe9cd9c74f... - - - - - 8db355e6 by Jinoh Kang at 2025-04-28T16:32:04+02:00 kernel32/tests: Don't use _ReadWriteBarrier() on clang. Some clang versions do not support _ReadWriteBarrier() when targeting armv7-windows (MSVC mode). - - - - - 1 changed file: - dlls/kernel32/tests/virtual.c View it on GitLab: https://gitlab.winehq.org/wine/wine/-/compare/f46c44e0364080ef3c7aa726b9b6f8... -- View it on GitLab: https://gitlab.winehq.org/wine/wine/-/compare/f46c44e0364080ef3c7aa726b9b6f8... You're receiving this email because of your account on gitlab.winehq.org.
participants (1)
-
Alexandre Julliard (@julliard)