Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
1359 commits
Select commit Hold shift + click to select a range
5475709
HACK: gamescope: user32: Disable gamescope undecorated windows hack f…
zzhiyi Feb 1, 2024
ef472ae
kernelbase: HACK: Force Vulkan rendering for EACefSubProcess.
Feb 6, 2024
8bcb205
ntdll: HACK: Enable WINE_SIMULATE_WRITECOPY for Dinogen Online.
Feb 6, 2024
24fb10a
wbemprox/tests: Test LIKE queries.
ivyl Feb 3, 2024
c5a4823
wbemprox: Reimplement LIKE.
ivyl Feb 1, 2024
67a77df
server: Check if we have waiting asyncs in (send_socket) before enfor…
Jan 30, 2024
fe1ca09
server: Check if we have waiting asyncs in sock_dispatch_asyncs() bef…
Jan 29, 2024
34145c8
ntdll: HACK: Enable WINE_NO_PRIV_ELEVATION for playway-launcher-insta…
Feb 14, 2024
336ad4e
fixup! winebus: Disable SDL2.30 new behavior for the SDL unix backend.
rbernon Feb 20, 2024
b0b77f1
amd_ags_x64: Implement multi draw instanced functions.
Feb 22, 2024
84a5d61
amd_ags_x64: Implement multi draw instanced indirect count functions.
Feb 22, 2024
463363c
kernelbase: Use KEY_WOW64_64KEY flag when 64 bit registry access is a…
Feb 28, 2024
56388ef
amd_ags_x64: Support v3.2.
Feb 28, 2024
9462b10
amd_ags_x64: Support versions 3.0-3.1.
Feb 28, 2024
36dba03
amd_ags_x64: Add agsDriverExtensionsDX11_SetDiskShaderCacheEnabled() …
Feb 28, 2024
6cd7d79
amd_ags_x64: Add spec stubs for some v3.x functions.
Mar 1, 2024
a9e88d9
amd_ags_x64: Add WINE_HIDE_APU option.
Mar 4, 2024
073ec7f
amd_ags_x64: Add stub implementation for DX12 marker functions.
Mar 4, 2024
28b7fe0
fixup! winex11.drv: Listen to RawMotion and RawButton* events in the …
zzhiyi Feb 22, 2024
220a335
winex11: Process XInput2 events with QS_INPUT filter.
rbernon Jan 28, 2024
15ca840
winex11: Initialize XInput2 extension on every thread.
rbernon Jan 28, 2024
4deef79
winex11: Always listen to XInput2 device changes events.
rbernon Feb 12, 2024
d1404fe
fixup! winex11.drv: Keep track of pointer and device button mappings.
rbernon Mar 4, 2024
d661416
cfgmgr32: Add CM_Get_Device_Interface_PropertyW stub.
TornadoCookie Jan 30, 2024
0df706c
wine.inf: Disable nvcuda.dll by default.
Oct 11, 2021
937719c
winex11: Only listen to RawButton and RawTouch events in the rawinput…
rbernon Mar 13, 2024
4c14aa9
amd_ags_x64: Do not fail context creation for NULL output GPU info.
Mar 13, 2024
24c6dc8
wm_reader: Don't reinit stream if read_compressed didn't change.
Mar 11, 2024
941279c
wm_reader: Fix order of streams in reinit_stream.
Mar 12, 2024
03f4acc
fixup! bcrypt: Add support for none and OAEP-padded asymmetric key en…
Mar 14, 2024
21a3667
fixup! bcrypt: Add support for none and OAEP padded asymmetric key de…
Mar 14, 2024
1dce5ba
fixup! HACK: winex11, winevulkan: Support faking GPU PCI IDs.
Mar 19, 2024
a6fe061
user32/tests: Add some ReleaseCapture() tests.
zzhiyi Mar 8, 2024
17d457d
win32u: Only send mouse input in ReleaseCapture() when a window is ca…
zzhiyi Mar 8, 2024
05c8209
server: Send WM_WINE_SETCURSOR message only when necessary.
rbernon Mar 14, 2024
59a0a95
server: Send WM_WINE_CLIPCURSOR message only when necessary.
rbernon Mar 14, 2024
5ef22c9
imm32: Set lengths to 0 for NULL strings in ImmSetCompositionString().
Mar 9, 2024
d3bab8d
server: Ignore some ICMP-originated socket errors for connectionless …
Mar 15, 2024
a0ede0f
ddraw: Don't demand WINED3D_BIND_SHADER_RESOURCE for making surface i…
Mar 21, 2024
8272418
HACK: ntdll: Add WINE_HEAP_ZERO_MEMORY variable to force zeroing allo…
Feb 9, 2024
1bf1d9f
HACK: ntdll: Extend heap zero hack to private heaps.
zzhiyi Mar 4, 2024
783892c
winegstreamer: Set GST_DEBUG if not set, based on WINEDEBUG channels.
rbernon Mar 26, 2024
1d70508
win32u: Avoid writing past allocated memory in peek_message().
Mar 23, 2024
da557f1
win32u: Avoid leaking previous buffer in get_buffer_space().
Mar 23, 2024
c684d89
winegstreamer: Try to handle broken IStream_Stat implementation in WM…
Apr 3, 2024
759e0e8
mmdevapi: Implement SAC_IsAudioObjectFormatSupported().
Apr 3, 2024
92c2042
Revert "ntdll: Use kernel soft dirty flags for write watches support."
Mar 11, 2024
6affe14
ntdll: Use UFFD for write watches support if available.
May 8, 2020
c11b5a5
ntdll: Use kernel soft dirty flags for write watches support.
Mar 11, 2024
e3eec61
fixup! ntdll: Simulate async file read and IO cancellation to workaro…
Mar 5, 2024
9d1c80f
kernelbase: HACK: Force CEF swiftshader for Aisling and the Tavern of…
Mar 25, 2024
9b2364c
kernelbase: HACK: Force CEF swiftshader for Snares of Ruin 2.
Mar 25, 2024
f68fa77
fixup! ntdll: Implement CPU topology override.
Mar 26, 2024
fc0ac83
opengl32: HACK: Fixup shaders for Joe Danger 2: The Movie.
Mar 27, 2024
3fc523d
opengl32: HACK: Fixup shaders for Joe Danger.
Mar 28, 2024
28270bc
avifil32: Update lCurrentFrame in IGetFrame_fnGetFrame().
Mar 28, 2024
c86914e
kernelbase: HACK: Force in-process-gpu for Summer Islands.
Apr 2, 2024
84756be
kernelbase: HACK: Force in-process-gpu for Total War: WARHAMMER II.
Apr 3, 2024
ac74ba2
kernelbase: HACK: Force CEF swiftshader for Insanity's Blade.
Apr 4, 2024
4d27727
kernelbase: HACK: Force disable direct composition for Bloody Walls.
Apr 4, 2024
bfc79c8
fixup! opengl32: HACK: Fixup shaders for Joe Danger 2: The Movie.
ivyl Apr 5, 2024
9ec33e7
ntdll: Implement NtQuerySystemInformation( SystemProcessIdInformation ).
Apr 12, 2024
3fc1ebf
HACK: winex11: Disable pointer grab wait with gamescope.
rbernon Mar 22, 2024
d19fb99
HACK: winegstreamer: Remove MF_MT_DEFAULT_STRIDE for some games.
rbernon Apr 24, 2024
f06ed68
winegstreamer: Remove pixel-aspect-ratio attribute which we don't sup…
rbernon Mar 4, 2024
7caa84e
evr/dshow: Handle YUY2 sample copy.
nsivov Dec 18, 2023
92bdfd6
evr/dshow: Support NV12 in evr_render.
sulix Feb 25, 2024
a23f0c5
evr: Remove useless code.
Mar 13, 2024
bf99445
evr: Fix YUY2 image copy in evr_copy_sample_buffer().
Mar 6, 2024
afcbb6a
winex11.drv: HACK: Don't clip child windows for C&C Red Alert 2.
Mar 19, 2024
a8514f9
winex11.drv: HACK: Don't clip child windows for C&C Tiberian Sun.
Mar 19, 2024
1ae5166
winebus.sys: Enable hidraw for VKB Gunfighter SCG.
her001 May 4, 2024
ae64f98
mscoree: Implement CLRRuntimeHost_Start.
madewokherd Mar 7, 2024
fb1f1f4
mshtml: Pass DOMEvent instead of nsIDOMEvent during handle_event.
Feb 29, 2024
a51e3ca
mshtml: Use generic event dispatcher for DOMContentLoaded.
Feb 21, 2024
153ff6b
mshtml/tests: Add test for document mode after InitNew and Load.
Feb 26, 2024
42d65f3
mshtml: Always use the event target dispex.
Feb 26, 2024
4c503b8
mshtml: Don't handle special case when doc != node->doc.
Feb 26, 2024
209020b
winhttp: Always return result at once if available in WinHttpQueryDat…
Jan 23, 2024
84b53fa
winhttp: Always return result at once if available in WinHttpReadData().
Jan 23, 2024
f28b464
ntdll: Better track thread pool wait's wait_pending state.
Feb 7, 2024
cfe3c46
ntdll: Make sure wakeups from already unset events are ignored in wai…
Feb 7, 2024
c76e2ad
win32u: Send message with timeout in send_erase().
Feb 9, 2024
d7b95b7
winex11.drv: Default swap interval to 0 for child window drawables in…
Jan 30, 2024
55b0d06
winex11.drv: Fix wglSwapBuffers() with NULL current context with chil…
Jan 22, 2024
d8aa7a8
powershell: Read input command from stdin.
Feb 15, 2024
8bb7a85
winhttp: Mind read size when skipping async read in WinHttpReadData().
Feb 20, 2024
29f286a
nsiproxy.sys: Fix ipv6 route table parsing on Linux.
Feb 24, 2024
1de8c9e
iphlpapi: Partially fill Ipv4 / Ipv6 metric in GetAdaptersAddresses().
Feb 23, 2024
7a60405
Revert "win32u: Use font AA flags when querying glyph outline with GG…
Feb 26, 2024
c129ced
Revert "win32u: Store effective AA flags in gdi_font."
Feb 26, 2024
f3c7bf1
win32u: Store effective AA flags in font_physdev.
Feb 26, 2024
39cf9ea
win32u: Use font AA flags when querying glyph outline with GGO_METRICS.
Nov 16, 2023
406ca1c
win32u: HACK: Ignore font GASP flags for Alien Swarm Reactive Drop.
May 10, 2024
9f513dc
fixup! ntdll: Use UFFD for write watches support if available.
May 8, 2024
3a83e60
xaudio2: Use FAudioVoice_DestroyVoiceSafeEXT() in destroy_voice().
Feb 27, 2024
e56658c
fixup! ntdll: Read process memory on the client side in NtReadVirtual…
Mar 1, 2024
394905b
dbghelp: Stop embedding unwind info in minidumps (X86_64).
Mar 4, 2024
1ddf137
win32u: HACK: Clear queue QS_RAWINPUT if NtUserGetRawInputBuffer() go…
Mar 7, 2024
bfa8348
ntdll: Wait for thread suspension in NtSuspendThread().
Mar 14, 2024
5202875
fixup! fshack: winex11: Always blit fs_hack in wglFlush and wglFinish…
Mar 15, 2024
b480bf1
ddraw: Store material handles in the global table.
Mar 16, 2024
fa8cc7c
ddraw: Store surface handles in the global table.
Mar 16, 2024
4c0bdee
ddraw: Store matrix handle in the global table.
Mar 19, 2024
f504f28
ddraw: Don't apply state in ddraw_surface_blt().
Mar 19, 2024
6ed9065
wined3d: Factor out wined3d_texture_set_lod() function.
Mar 19, 2024
a36b8fb
ddraw: Store wined3d state in d3d_device.
Mar 19, 2024
e7e725e
ddraw: Sync wined3d render target in d3d_device_sync_rendertarget().
Mar 20, 2024
d6e902c
ddraw: Support multiple devices per ddraw object.
Mar 16, 2024
6172467
ddraw/tests: Add tests for multiple devices.
Mar 16, 2024
b0105fd
wintypes: Report some API contracts as present in api_information_sta…
Mar 25, 2024
3b8c774
windows.perception.stub: Add stub IHolographicSpaceInterop interface.
Mar 25, 2024
a94be92
windows.perception.stub: HACK: Set WS_EX_NOACTIVATE for window in hol…
Mar 25, 2024
f6abe13
ntdll: Don't leak objattr allocation in NtCreateSemaphore.
ishitatsuyuki Feb 17, 2024
78e9837
winex11.drv: Apply the GL vendor override for Intel GPUs too
renatopereyra Mar 7, 2024
e2d141e
Revert "ntdll: Validate xstate alignment in validate_context_xstate()."
Mar 26, 2024
fdd5150
Revert "ntdll: Validate context xstate at once in NtGetContextThread()."
Mar 26, 2024
85d1df6
Revert "ntdll: Factor out validate_context_xstate() function."
Mar 26, 2024
b5f4941
ntdll: Fix exception list offset in call_user_mode_callback / user_mo…
Jan 18, 2024
3e5be42
ntdll: Don't hardcode xstate feature mask.
Jan 31, 2024
4ec17bd
ntdll: Don't hardcode xstate size in syscall frame.
Jan 31, 2024
2287354
ntdll: Don't hardcode xstate size in exception stack layout.
Jan 31, 2024
0537080
ntdll: On x86_64, don't access %gs in signal_start_thread().
mrpippy Feb 21, 2024
39e61aa
ntdll: Mind context compaction mask in context_from_server().
Feb 1, 2024
9335f98
ntdll: Don't copy xstate from / to syscall frame in usr1_handler().
Feb 1, 2024
415b248
ntdll: Support generic xstate config in context manipulation functions.
Jan 18, 2024
1867894
ntdll: Respect red zone in usr1_handler() on x64.
Mar 5, 2024
ec53413
ntdll: Only save AVX xstate in wine_syscall_dispatcher.
Mar 18, 2024
d628ac5
ntdll: Preserve untouched parts of xstate in NtSetContextThread().
Feb 8, 2024
9a1fd68
ntdll: Support generic xstate in Unix-side manipulation functions.
Jan 17, 2024
f5d2bb1
ntdll: Factor out xstate_from_server() function.
Mar 18, 2024
aa26113
ntdll: Factor out context_to_server() function.
Mar 18, 2024
7e42dca
ntdll: Mind generic xstate masks in server context conversion.
Mar 18, 2024
99c7958
ntdll: Support more xstate features.
Jan 18, 2024
726b962
ntdll/tests: Add more tests for xstate.
Mar 18, 2024
7970eaa
ntdll: Factor out validate_context_xstate() function.
Jun 16, 2022
fed4b67
ntdll: Validate context xstate at once in NtGetContextThread().
Jun 16, 2022
5889ab8
ntdll: Validate xstate alignment in validate_context_xstate().
Jun 16, 2022
42e80b2
ntdll: Return STATUS_NO_YIELD_PERFORMED from NtYieldExecution() on Li…
Apr 5, 2024
7f671f1
ntdll/tests: Remove unnecessary shared header.
julliard Apr 25, 2024
684675d
ntdll/tests: Add tests for CONTEXT_EXCEPTION_REQUEST.
Apr 5, 2024
8f954bb
ntdll: Set exception reporting flags in NtGetContextThread().
Apr 9, 2024
be35c81
ntdll: Store exception reporting flags in server context.
Apr 9, 2024
40c7d0b
ntdll: Store exception reporting flags on suspend.
Apr 10, 2024
7330f68
ntdll: Store exception reporting flags for debug events.
Apr 8, 2024
863fd3a
Revert "ntdll: Add WINE_DISABLE_WRITE_WATCH env var to disable write …
Apr 10, 2024
89addd7
win32u: Store desktop flags in shared memory and use that in is_virtu…
Apr 11, 2024
4105fcb
user32: HACK: Avoid triggering displays update in GetDisplayConfigBuf…
Apr 11, 2024
c1c54ce
winex11.drv: Support _SHIFT_ARB attributes in X11DRV_wglGetPixelForma…
Apr 25, 2024
30c71f5
crypt32: Mind constructor tag in CRYPT_AsnDecodeOCSPSignatureInfoCert…
Apr 24, 2024
370f9ab
cryptnet: Do not use InternetCombineUrlW() in build_request_url().
Apr 25, 2024
d95cdad
fixup! ntdll: Support gpuvis tracing.
Apr 30, 2024
ac56865
msvcr80/tests: Fix errno access in tests.
PiotrCW Apr 30, 2024
e883a57
msvcrt: Implement _mbsncpy_s[_l]().
Apr 27, 2024
cb18b5e
kernelbase: HACK: Force angle d3d9 for Antenna.
Apr 30, 2024
5e7f269
kernelbase: HACK: Force angle d3d9 for A Raven Monologue.
Apr 30, 2024
ce7a111
fshack: winex11.drv: Use a better fshack interpolation in xrender_bli…
May 3, 2024
57bed4f
fshack: winex11.drv: Interpolate image in x11drv_surface_flush() with…
May 3, 2024
b2eb8e8
Revert "explorer: Don't pop start menu on "minimize all windows" syst…
Feb 14, 2024
7b59dbb
explorer: Don't pop start menu on "minimize all windows" systray comm…
Jan 9, 2024
2baf98c
explorer: Don't pop start menu on "undo minimize all windows" systray…
Feb 6, 2024
46c01b4
win32u: Update last message time in NtUserGetRawInputBuffer().
May 4, 2024
cf2056d
kernelbase: HACK: Force angle d3d9 for Alpha League.
May 7, 2024
b1c3eec
HACK: ntdll: Enable WINE_SIMULATE_WRITECOPY for Hentai Maid Memories.
zzhiyi Apr 3, 2024
49636aa
ntdll: HACK: Enable WINE_SIMULATE_WRITECOPY for Lovey-Dovey Lockdown.
May 7, 2024
1a25b90
win32u: Use FT_LOAD_PEDANTIC on first load try in freetype_get_glyph_…
May 10, 2024
1a96b5b
faudio: Don't destroy voice when it is output to other voices
Feb 29, 2024
dc36af0
dsound/tests: Test that formats with more than two channels require W…
zzhiyi Feb 20, 2024
1388e3f
dsound: Reject WAVEFORMATEX formats with more than two channels.
zzhiyi Feb 20, 2024
4e6eeb9
advapi32: Check NULL return key pointers when creating registry keys.
zzhiyi Mar 4, 2024
4122fd9
advapi32/tests: Test creating registry keys with a NULL return key po…
zzhiyi Mar 4, 2024
2d25b07
fshack: winex11.drv: Introduce fs_hack_is_window_rect_fullscreen().
zzhiyi Mar 26, 2024
c9d1e56
uxtheme/tests: Test that scrollbar parts should have very few #ffffff…
zzhiyi Apr 18, 2024
ecb4393
light.msstyles: Use #fefefe instead of #ffffff for scrollbar parts.
zzhiyi Apr 17, 2024
84d0a4c
bcrypt: Support RSA/PKCS1 signatures with unspecified hash algorithm.
May 7, 2024
a6a4908
ntdll: HACK: Substitute different d3dcompiler version for BDO.
Jan 24, 2024
154cb2e
mlang/tests: Test for GetGlobalFontLinkObject.
tati-frog Oct 16, 2023
1176268
mlang: Implement GetGlobalFontLinkObject.
tati-frog Oct 16, 2023
af887a1
mlang/tests: Test codepages priority bug in GetStrCodepages.
tati-frog Nov 28, 2023
98b40bd
mlang: Fix bug with codepage priority in GetStrCodePages.
tati-frog Nov 28, 2023
7fdb98f
gdiplus: Replace HDC with GpGraphics in parameters.
tati-frog Jan 30, 2024
c5dc563
gdiplus/tests: Add interactive test for font linking.
tati-frog Dec 11, 2023
9e54429
gdiplus: Implement font linking for gdiplus.
tati-frog Nov 14, 2023
f689e63
gdiplus: Switch to a struct for gdip_format_string callback args.
madewokherd Feb 23, 2024
0341570
gdiplus: Pass gdip_format_string_info to font link functions.
madewokherd Feb 23, 2024
68f2633
gdiplus: Restore hdc argument to gdip_format_string.
madewokherd Feb 23, 2024
cce5499
gdiplus: Fix crash in GdipAddPathString.
madewokherd Feb 28, 2024
c0af298
gdiplus: Fix use after free in GdipAddPathString.
madewokherd Mar 1, 2024
ba97639
gdiplus: Implement font linking in GdipAddPathString.
madewokherd Mar 1, 2024
c63d290
HACK: winebuild: Include target arch in the hash used for timestamp.
ivyl Apr 9, 2024
d454600
winegstreamer: Support WMA with 5.1 and 7.1 audio.
ivyl Nov 23, 2023
aa475fa
FAudio: Create fake codec data for WMA3.
ivyl Dec 29, 2023
e4d2cb0
winevulkan: Prepare for VK_KHR_calibrated_timestamps.
DadSchoorse Feb 3, 2024
04b68ae
winevulkan: Update to VK spec version 1.3.277.
DadSchoorse Feb 3, 2024
bb0304c
Update vk.xml to 1.3.277.
ivyl Mar 5, 2024
9b73daa
winevulkan: Update to VK spec version 1.3.278.
cjacek Feb 20, 2024
16443f5
Update vk.xml to 1.3.278.
ivyl Mar 6, 2024
d675919
winevulkan: Remove no longer needed spec workarounds.
cjacek Feb 20, 2024
49448ae
winevulkan: Update to VK spec version 1.3.279.
doitsujin Mar 2, 2024
3d753ff
Update vk.xml to 1.3.279.
ivyl Mar 6, 2024
33f9b2d
winevulkan: Return result through NtCallbackReturn for the debug call…
julliard Jan 19, 2024
71344f3
winevulkan: Keep the create_info HWND on the surface wrappers.
rbernon Nov 25, 2023
04006f0
winevulkan: Rename wine_device_memory mapping to vm_map.
cjacek Feb 21, 2024
c993972
winevulkan: Use handle map for memory objects.
cjacek Feb 21, 2024
b15ff0d
winevulkan: Remove handle mapping after host destory is called.
ivyl Apr 9, 2024
e8927f9
winevulkan: Make client's device memory wrapper available to callback…
ivyl Apr 11, 2024
e41a8a4
winevulkan: Update vk.xml to 1.3.285.
ivyl May 10, 2024
be45899
win32u: Update Nvidia's DriverVersion to match 552.12.
ivyl Apr 15, 2024
d7df004
win32u: Update Nvidia's DriverVersion to match 552.44.
ivyl May 20, 2024
dec5bfb
mscoree: Update Wine Mono to 9.0.0.
madewokherd Feb 2, 2024
7e7f73b
mscoree: Update Wine Mono to 9.1.0.
ivyl Apr 18, 2024
35d05c9
loader: Expose the standard debugging symbols for GDB.
rbernon Nov 26, 2023
972cc18
ntdll: Maintain a PE module link map and expose it to GDB.
rbernon Nov 26, 2023
3c2c090
tools: Add gdbunwind.py script with a syscall unwinder.
rbernon Nov 26, 2023
cab07f3
HACK: loader: Map /run/host to / in the link map.
rbernon Jan 22, 2024
8661d3b
fixup! user32: Add or remove rawinput devices individually on WM_DEVI…
rbernon Apr 29, 2024
1965485
win32u: Move rawinput device cache ticks check to rawinput_update_dev…
rbernon May 2, 2024
4e28237
win32u: Post device arrival messages in NtUserRegisterRawInputDevices.
rbernon May 2, 2024
dfd6fdb
explorer: Add an environment variable setting to start Xalia.
madewokherd Feb 25, 2023
1f35caf
winex11.drv: Mark Xalia overlay window as a gamescope overlay.
madewokherd Mar 8, 2023
547009b
winex11.drv: Do not shape layered windows in Gamescope.
madewokherd Mar 5, 2024
5dd24d5
win32u: Implement EVENT_OBJECT_STATECHANGE.
madewokherd Mar 12, 2024
84b32cf
win32u: Implement EVENT_OBJECT_LOCATIONCHANGE.
madewokherd Mar 13, 2024
d02075f
win32u: Add support for raising EVENT_OBJECT_DESTROY events on windows.
Conmanx360 Feb 16, 2023
51b6593
win32u: Implement cross-process GetScrollBarInfo.
madewokherd Aug 19, 2023
e61db19
win32u: Implement cross-process GetScrollInfo.
madewokherd Aug 19, 2023
026e911
win32u: Implement winevents for scrollbars.
madewokherd Mar 15, 2024
e53b579
win32u: Implement EVENT_SYSTEM_FOREGROUND.
madewokherd May 13, 2024
2e91838
winegstreamer: Integrate media-converter to winegstreamer.
ziqingh Nov 15, 2023
6130c17
msvcrt/tests: Add tests for check buffering state of standard streams.
Apr 4, 2024
51eec58
ucrtbase/tests: Add tests for checking buffering state of standard st…
Apr 4, 2024
d31497f
ucrtbase: Let stderr be always be unbuffered.
Apr 3, 2024
9fbaa06
gdiplus/tests: Add tests for GdipPrivateAddMemoryFont().
zzhiyi Mar 29, 2024
42c2d33
gdiplus: Search microsoft platform names first in load_ttf_name_id().
zzhiyi Mar 28, 2024
bd333a8
wmvcore: Start and stop read & delivery threads on OP_START/OP_STOP.
Feb 28, 2024
a7db676
wine.inf: Add a font replacement for Segoe UI.
jactry Feb 28, 2024
8dbda21
ntdll: Fill object pointer in NtQueryInformation( SystemHandleInforma…
May 17, 2024
679a882
winhttp: Set actual default receive response timeout to 21sec.
Apr 9, 2024
3a8f5bd
winhttp/tests: Add some tests for actual connection caching.
Apr 9, 2024
eb55f0b
winhttp: Do not cache connection if suggested by request headers.
Apr 9, 2024
07e2dcf
fshack: Use texture name hack for Descent 3
Frogging101 Dec 28, 2023
783de2b
opengl32: Prefer formats with depth if unspecified in wglChoosePixelF…
May 14, 2024
7c8dfb3
wine.inf: Add InstallationType field to CurrentVersion.
May 17, 2024
52fbd1e
nsiproxy.sys: Return success and zero count from ipv6_forward_enumera…
May 15, 2024
0e4b4af
crypt32: Fix CryptBinaryToString not adding a separator.
tati-frog Mar 22, 2024
a1e18c3
winegstreamer/media-converter: Continue creating state object even if…
ziqingh May 23, 2024
a030525
uiautomationcore: NULL initialize SAFEARRAY variable passed to IRawEl…
Conmanx360 May 31, 2024
d3e8885
dinput/tests: Add some IRawGameController2 interface tests.
rbernon Apr 25, 2022
f80ddae
windows.gaming.input: Stub IRawGameController2 interface.
rbernon Feb 21, 2022
97817cd
fix: compositor will always be bypassed on fullscreen apps
Jaskowicz1 Aug 31, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
196 changes: 196 additions & 0 deletions README.esync
Original file line number Diff line number Diff line change
@@ -0,0 +1,196 @@
This is eventfd-based synchronization, or 'esync' for short. Turn it on with
WINEESYNC=1; debug it with +esync.

== BUGS AND LIMITATIONS ==

Please let me know if you find any bugs. If you can, also attach a log with
+seh,+pid,+esync,+server,+timestamp.

If you get something like "eventfd: Too many open files" and then things start
crashing, you've probably run out of file descriptors. esync creates one
eventfd descriptor for each synchronization object, and some games may use a
large number of these. Linux by default limits a process to 4096 file
descriptors, which probably was reasonable back in the nineties but isn't
really anymore. (Fortunately Debian and derivatives [Ubuntu, Mint] already
have a reasonable limit.) To raise the limit you'll want to edit
/etc/security/limits.conf and add a line like

* hard nofile 1048576

then restart your session.

On distributions using systemd, the settings in `/etc/security/limits.conf`
will be overridden by systemd's own settings. If you run `ulimit -Hn` and it
returns a lower number than the one you've previously set, then you can set

DefaultLimitNOFILE=1024:1048576

in both `/etc/systemd/system.conf` and `/etc/systemd/user.conf`. You can then
execute `sudo systemctl daemon-reexec` and restart your session. Check again
with `ulimit -Hn` that the limit is correct.

Also note that if the wineserver has esync active, all clients also must, and
vice versa. Otherwise things will probably crash quite badly.

== EXPLANATION ==

The aim is to execute all synchronization operations in "user-space", that is,
without going through wineserver. We do this using Linux's eventfd
facility. The main impetus to using eventfd is so that we can poll multiple
objects at once; in particular we can't do this with futexes, or pthread
semaphores, or the like. The only way I know of to wait on any of multiple
objects is to use select/poll/epoll to wait on multiple fds, and eventfd gives
us those fds in a quite usable way.

Whenever a semaphore, event, or mutex is created, we have the server, instead
of creating a traditional server-side event/semaphore/mutex, instead create an
'esync' primitive. These live in esync.c and are very slim objects; in fact,
they don't even know what type of primitive they are. The server is involved
at all because we still need a way of creating named objects, passing handles
to another process, etc.

The server creates an eventfd file descriptor with the requested parameters
and passes it back to ntdll. ntdll creates an object of the appropriate type,
then caches it in a table. This table is copied almost wholesale from the fd
cache code in server.c.

Specific operations follow quite straightforwardly from eventfd:

* To release an object, or set an event, we simply write() to it.
* An object is signalled if read() succeeds on it. Notably, we create all
eventfd descriptors with O_NONBLOCK, so that we can atomically check if an
object is signalled and grab it if it is. This also lets us reset events.
* For objects whose state should not be reset upon waiting—e.g. manual-reset
events—we simply check for the POLLIN flag instead of reading.
* Semaphores are handled by the EFD_SEMAPHORE flag. This matches up quite well
(although with some difficulties; see below).
* Mutexes store their owner thread locally. This isn't reliable information if
a different process's thread owns the mutex, but this doesn't matter—a
thread should only care whether it owns the mutex, so it knows whether to
try waiting on it or simply to increase the recursion count.

The interesting part about esync is that (almost) all waits happen in ntdll,
including those on server-bound objects. The idea here is that on the server
side, for any waitable object, we create an eventfd file descriptor (not an
esync primitive), and then pass it to ntdll if the program tries to wait on
it. These are cached too, so only the first wait will require a round trip to
the server. Then the server signals the file descriptor as appropriate, and
thereby wakes up the client. So far this is implemented for processes,
threads, message queues (difficult; see below), and device managers (necessary
for drivers to work). All of these are necessarily server-bound, so we
wouldn't really gain anything by signalling on the client side instead. Of
course, except possibly for message queues, it's not likely that any program
(cutting-edge D3D game or not) is going to be causing a great wineserver load
by waiting on any of these objects; the motivation was rather to provide a way
to wait on ntdll-bound and server-bound objects at the same time.

Some cases are still passed to the server, and there's probably no reason not
to keep them that way. Those that I noticed while testing include: async
objects, which are internal to the file APIs and never exposed to userspace,
startup_info objects, which are internal to the loader and signalled when a
process starts, and keyed events, which are exposed through an ntdll API
(although not through kernel32) but can't be mixed with other objects (you
have to use NtWaitForKeyedEvent()). Other cases include: named pipes, debug
events, sockets, and timers. It's unlikely we'll want to optimize debug events
or sockets (or any of the other, rather rare, objects), but it is possible
we'll want to optimize named pipes or timers.

There were two sort of complications when working out the above. The first one
was events. The trouble is that (1) the server actually creates some events by
itself and (2) the server sometimes manipulates events passed by the
client. Resolving the first case was easy enough, and merely entailed creating
eventfd descriptors for the events the same way as for processes and threads
(note that we don't really lose anything this way; the events include
"LowMemoryCondition" and the event that signals system processes to shut
down). For the second case I basically had to hook the server-side event
functions to redirect to esync versions if the event was actually an esync
primitive.

The second complication was message queues. The difficulty here is that X11
signals events by writing into a pipe (at least I think it's a pipe?), and so
as a result wineserver has to poll on that descriptor. In theory we could just
let wineserver do so and then signal us as appropriate, except that wineserver
only polls on the pipe when the thread is waiting for events (otherwise we'd
get e.g. keyboard input while the thread is doing something else, and spin
forever trying to wake up a thread that doesn't care). The obvious solution is
just to poll on that fd ourselves, and that's what I did—it's just that
getting the fd from wineserver was kind of ugly, and the code for waiting was
also kind of ugly basically because we have to wait on both X11's fd and the
"normal" process/thread-style wineserver fd that we use to signal sent
messages. The upshot about the whole thing was that races are basically
impossible, since a thread can only wait on its own queue.

System APCs already work, since the server will forcibly suspend a thread if
it's not already waiting, and so we just need to check for EINTR from
poll(). User APCs and alertable waits are implemented in a similar style to
message queues (well, sort of): whenever someone executes an alertable wait,
we add an additional eventfd to the list, which the server signals when an APC
arrives. If that eventfd gets signaled, we hand it off to the server to take
care of, and return STATUS_USER_APC.

Originally I kept the volatile state of semaphores and mutexes inside a
variable local to the handle, with the knowledge that this would break if
someone tried to open the handle elsewhere or duplicate it. It did, and so now
this state is stored inside shared memory. This is of the POSIX variety, is
allocated by the server (but never mapped there) and lives under the path
"/wine-esync".

There are a couple things that this infrastructure can't handle, although
surprisingly there aren't that many. In particular:
* Implementing wait-all, i.e. WaitForMultipleObjects(..., TRUE, ...), is not
exactly possible the way we'd like it to be possible. In theory that
function should wait until it knows all objects are available, then grab
them all at once atomically. The server (like the kernel) can do this
because the server is single-threaded and can't race with itself. We can't
do this in ntdll, though. The approach I've taken I've laid out in great
detail in the relevant patch, but for a quick summary we poll on each object
until it's signaled (but don't grab it), check them all again, and if
they're all signaled we try to grab them all at once in a tight loop, and if
we fail on any of them we reset the count on whatever we shouldn't have
consumed. Such a blip would necessarily be very quick.
* The whole patchset only works on Linux, where eventfd is available. However,
it should be possible to make it work on a Mac, since eventfd is just a
quicker, easier way to use pipes (i.e. instead of writing 1 to the fd you'd
write 1 byte; instead of reading a 64-bit value from the fd you'd read as
many bytes as you can carry, which is admittedly less than 2**64 but
can probably be something reasonable.) It's also possible, although I
haven't yet looked, to use some different kind of synchronization
primitives, but pipes would be easiest to tack onto this framework.
* PulseEvent() can't work the way it's supposed to work. Fortunately it's rare
and deprecated. It's also explicitly mentioned on MSDN that a thread can
miss the notification for a kernel APC, so in a sense we're not necessarily
doing anything wrong.

There are some things that are perfectly implementable but that I just haven't
done yet:
* Other synchronizable server primitives. It's unlikely we'll need any of
these, except perhaps named pipes (which would honestly be rather difficult)
and (maybe) timers.
* Access masks. We'd need to store these inside ntdll, and validate them when
someone tries to execute esync operations.

This patchset was inspired by Daniel Santos' "hybrid synchronization"
patchset. My idea was to create a framework whereby even contended waits could
be executed in userspace, eliminating a lot of the complexity that his
synchronization primitives used. I do however owe some significant gratitude
toward him for setting me on the right path.

I've tried to maximize code separation, both to make any potential rebases
easier and to ensure that esync is only active when configured. All code in
existing source files is guarded with "if (do_esync())", and generally that
condition is followed by "return esync_version_of_this_method(...);", where
the latter lives in esync.c and is declared in esync.h. I've also tried to
make the patchset very clear and readable—to write it as if I were going to
submit it upstream. (Some intermediate patches do break things, which Wine is
generally against, but I think it's for the better in this case.) I have cut
some corners, though; there is some error checking missing, or implicit
assumptions that the program is behaving correctly.

I've tried to be careful about races. There are a lot of comments whose
purpose are basically to assure me that races are impossible. In most cases we
don't have to worry about races since all of the low-level synchronization is
done by the kernel.

Anyway, yeah, this is esync. Use it if you like.

--Zebediah Figura
8 changes: 8 additions & 0 deletions autogen.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/sh
set -e
tools/make_requests
dlls/winevulkan/make_vulkan -x vk.xml
autoreconf -ifv
rm -rf autom4te.cache

echo "Now run ./configure"
Loading