[Bug 56359] New: Winedbg is broken when trying to break
https://bugs.winehq.org/show_bug.cgi?id=56359 Bug ID: 56359 Summary: Winedbg is broken when trying to break Product: Wine Version: 8.0 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: winedbg Assignee: wine-bugs(a)winehq.org Reporter: rikul(a)inbox.ru Distribution: --- Steps to reproduce: 1. Run "wine64 winedbg notepad" 2. "c" 3. Ctrl+C (might need to do it twice if nothing changes the first time) It broke starting from [b1f59bc679a8c2dea18a6789a5b9b1a1ae825129] makefiles: Add support for multiple PE architectures. Reverting it fixes winedbg, however reverting stops helping after [cc2cfb9b792bee681b96c5859084fd6d4d0bbed7] loader: Make the loader position-independent on 64-bit. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56359 Eric Pouech <eric.pouech(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |eric.pouech(a)gmail.com --- Comment #1 from Eric Pouech <eric.pouech(a)gmail.com> --- Can't repro here on wine9.* please detail which version you're using (assuming 8.0 from bugzilla ticket) and what's the behavior you see (including console output). -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56359 --- Comment #2 from BugSeeker <rikul(a)inbox.ru> --- Created attachment 76116 --> https://bugs.winehq.org/attachment.cgi?id=76116 winedbg log file: -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56359 --- Comment #3 from BugSeeker <rikul(a)inbox.ru> --- Reproduced on latest stable released version wine-9.0 using custom build on RedHat7.9. Console log with +winedbg channel is attached. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56359 --- Comment #4 from Eric Pouech <eric.pouech(a)gmail.com> --- thanks for the log what seems to happen is - Ctrl-C is caught on console and sent to debuggee (good) ``` Ctrl-C: stopping debuggee ``` - signal handler in debuggee creates the console event dispatch thread, and debuggee catches the thread creation events (good) ``` 0118:trace:winedbg:dbg_handle_debug_event 011c:0130: create thread D @00007F08D1B229B0 ``` - but this crashes immediately, moreover at the very address of the start of the thread ``` 0118:trace:winedbg:dbg_handle_debug_event 011c:0130: exception code=c0000005 0118:trace:winedbg:dbg_handle_exception exception=c0000005 first_chance=Y 0118:trace:winedbg:dbg_handle_debug_event 011c:0130: exception code=c0000005 Unhandled exception: page fault on execute access to 0x00007f08d1b229b0 in 64-bit code (0x007f08d1b229b0). ``` (and afterwards - actually winedbg restarts because the access violation isn't handled by first instance - the faulty address isn't present in process address space) as I can't repro here, I'll ask for more info (esp. to try to grasp where we end up in this faulty address) could send back the log (+winedbg) of the session, using the following winedbg commands
info share info maps p &ntdll.so!p__wine_ctrl_routine disas ntdll.so!p__wine_ctrl_routine watch * &ntdll.so!p__wine_ctrl_routine cont
TIA -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56359 --- Comment #5 from BugSeeker <rikul(a)inbox.ru> --- Created attachment 76117 --> https://bugs.winehq.org/attachment.cgi?id=76117 New log with additional steps Thanks for the quick reply! -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56359 --- Comment #6 from Eric Pouech <eric.pouech(a)gmail.com> --- Created attachment 76119 --> https://bugs.winehq.org/attachment.cgi?id=76119 HACK Aahhh.... you are not cross-compiling Wine in your custom build. I can now reproduce locally. The attached hack should make it work again. A correct fix would require quite some work. Note also that the "magic" address used here could clash will real addresses (unlike the wow case). -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56359 --- Comment #7 from BugSeeker <rikul(a)inbox.ru> --- Patch perfectly worked. Thank you! Following your advise the latest wine was built with minGw compiler, and I confirm that the problem does NOT exist there. Attached is the backtrace of notepad with cross-compiled wine and the debug info for some modules could not be found., e.g. ntdll ( 0 0x006fffffca5de1 in ntdll (+0x55de1) (0000000000000000) ). Is that expected behavior? -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56359 --- Comment #8 from BugSeeker <rikul(a)inbox.ru> --- Created attachment 76120 --> https://bugs.winehq.org/attachment.cgi?id=76120 Cross-compiled wine backtrace -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=56359 --- Comment #9 from Eric Pouech <eric.pouech(a)gmail.com> ---
Attached is the backtrace of notepad with cross-compiled wine and the debug info for some modules could not be found., e.g. ntdll ( 0 0x006fffffca5de1 in ntdll (+0x55de1) (0000000000000000) ).
Is that expected behavior?
yes this looks correct (winedbg reports the break from a dedicated thread, so you may want to use 'bt <tid>' or 'bt all' to get a grisp if what the program is doing). it's likely you'll get more correct features (wrt. Windows) and more support when cross-compiling Wine. So, if it's something you can consider, it would be the best approach. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
participants (1)
-
WineHQ Bugzilla