Valgrind support requires a fork, which I've published to https://gitlab.winehq.org/rbernon/valgrind. The fork implements loading DWARF debug info from PE files, instead of the old and broken upstream PDB support. I've tried to upstream these changes a long time ago but didn't receive any feedback.
I think we could maybe consider keeping a fork, which I'm happy to maintain, as the changes aren't too large. We may want to investigate adding 32-on-64 support, which may require a bit more changes (to VEX specifically, because its amd64 guest doesn't support segment register manipulation).
The changes here are not all related to Valgrind, and I'll create separate MR for those which may make sense independently from Valgrind / GDB.
Also included is a suppression file to silent some annoying false positives, many of which are coming from the cross-stack accesses during syscalls, which are confusing Valgrind's stack heuristics. One can try this out with something like:
`WINELOADERNOEXEC=1 valgrind --suppressions=tools/valgrind.supp wine64/loader/wine64 wine64/programs/winecfg/winecfg.exe`
--
v8: ntdll: Avoid writing to invalid memory in i386 unix dispatcher.
ntdll: Set %rsp before args in x86_64 call_user_mode_callback.
ntdll: Fix incorrect i386 call_user_mode_callback CFI.
ntdll: Avoid marking freed block header as undefined for valgrind.
ntdll: Force HEAP_TAIL_CHECKING_ENABLED flag with valgrind.
ntdll: Fix valgrind notifications from ntdll.so.
ntdll: Import valgrind headers for PE side ntdll.
ntdll: Maintain a PE module link map and expose it to GDB.
ntdll: Pass a UNICODE_STRING to load_builtin and virtual_map_image.
loader: Expose a shadow copy of ld.so link map to GDB.
ntdll: Add .cfi_signal_frame to __wine_syscall_dispatcher.
https://gitlab.winehq.org/wine/wine/-/merge_requests/1074
Add the stub function D3DXComputeTangent based on the staging patch.
https://bugs.winehq.org/show_bug.cgi?id=41697
Since this will at least make the application go further.
Even though the implementation is based on documentation
https://learn.microsoft.com/en-us/windows/win32/direct3d9/d3dxcomputetangent
--
v5: d3dx9: Stub D3DXComputeTangent
wineps: Store font substitution table in DEVMODE.
wineps: Store data from PPD file used in unixlib in DEVMODE.
wineps: Use standard DEVMODEW structure instead of PSDRV_DEVMODE when possible.
wineps: Remove unused fields from PSDRV_DEVMODE.
wineps: Remove gdi_physdev from print_ctx structure.
winemac: Use the default IME implementation for ImeSetCompositionString.
winex11: Use the default IME implementation for ImeSetCompositionString.
kernelbase/tests: Use win_skip() for missing APIs.
kernel32/tests: Use win_skip() for missing APIs.
qcap/tests: Test the audio capture CLSID.
qcap/tests: Test audio capture pin information.
qcap/tests: Test audio capture pin interfaces.
qcap/audiorecord: Add a stub source pin.
qcap/audiorecord: Get rid of the AudioRecord typedef.
kernelbase: Move Wow64EnableWow64FsRedirection() from kernel32 to kernelbase.
win32u: Don't export wow64 Unix call functions.
ntdll: Move the Unix function tables to avoid forward declarations, and make them static.
ntdll: Add a helper function to free a range of pages.
ntdll: Add logging for free ranges.
ntdll: Support partial view release in NtFreeVirtualMemory().
ntdll: Factor out some view manipulation functions.
ntdll: Fully support unaligned views in free ranges management.
ntdll: Fix size validation in NtFreeVirtualMemory().
kernelbase: Validate nonzero size for MEM_RELEASE in VirtualFreeEx().
ntdll/tests: Add tests for freeing a part of view.
This merge request has too many patches to be relayed via email.
Please visit the URL below to see the contents of the merge request.
https://gitlab.winehq.org/wine/wine/-/merge_requests/2795
On Fri May 12 21:14:16 2023 +0000, Zebediah Figura wrote:
> I kind of ask because—while I don't want to hold up progress upstream—as
> the person who is both maintaining the Wine-Staging patch, and working
> on (admittedly long stalled) actual tests for tangents, if this doesn't
> actually help the bug, all this patch is going to do is add more rebase
> headache for me.
I know that this makes staging rebase as mess, this is necessary to reduce the stalled patches to be mainlined as its been ages.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/2795#note_32683
On Fri May 12 21:07:04 2023 +0000, Matteo Bruni wrote:
> Ah, now I realize I read the "go further" in the MR description as
> "work". I'd like to know that too.
I kind of ask because—while I don't want to hold up progress upstream—as the person who is both maintaining the Wine-Staging patch, and working on (admittedly long stalled) actual tests for tangents, if this doesn't actually help the bug, all this patch is going to do is add more rebase headache for me.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/2795#note_32671
On Fri May 12 21:07:04 2023 +0000, Zebediah Figura wrote:
> Does this actually make the program work?
Ah, now I realize I read the "go further" in the MR description as "work". I'd like to know that too.
--
https://gitlab.winehq.org/wine/wine/-/merge_requests/2795#note_32670