https://bugs.winehq.org/show_bug.cgi?id=46126
Bug ID: 46126 Summary: Provide more exception context information in ARM64 implementation of raise_exception() Product: Wine Version: 3.20 Hardware: aarch64 OS: Linux Status: NEW Severity: normal Priority: P2 Component: ntdll Assignee: wine-bugs@winehq.org Reporter: focht@gmx.net Distribution: ---
Hello folks,
as it says.
Currently the diagnosis via tracing is very limited because the exception code, exception address and register context is not dumped at all.
Example:
--- snip --- $ WINEDEBUG=+seh,+loaddll,+process wine64 ./vlc.exe ... 0009:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\vlc-4.0.0-dev\plugins\video_output\libyuv_plugin.dll" at 0x85d0000: native 0009:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\vlc-4.0.0-dev\plugins\video_splitter\libclone_plugin.dll" at 0x85f0000: native 0009:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\vlc-4.0.0-dev\plugins\video_splitter\libpanoramix_plugin.dll" at 0x8600000: native 0009:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\vlc-4.0.0-dev\plugins\video_splitter\libwall_plugin.dll" at 0x8610000: native 0009:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\vlc-4.0.0-dev\plugins\visualization\libgoom_plugin.dll" at 0x8630000: native 0009:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\vlc-4.0.0-dev\plugins\visualization\libvisual_plugin.dll" at 0x8680000: native 0009:trace:seh:raise_exception info[0]=0000000000000031 0009:trace:seh:raise_exception info[1]=0000000000078490 0009:trace:seh:call_vectored_handlers calling handler at 0x46b1540 code=40010006 flags=0 0009:trace:seh:call_vectored_handlers handler at 0x46b1540 returned 0 0009:trace:seh:call_vectored_handlers calling handler at 0x2e72e60 code=40010006 flags=0 0009:trace:seh:call_vectored_handlers handler at 0x2e72e60 returned 0 0009:trace:seh:call_vectored_handlers calling handler at 0x1fe64fc code=40010006 flags=0 0009:trace:seh:call_vectored_handlers handler at 0x1fe64fc returned 0 0009:trace:seh:call_vectored_handlers calling handler at 0x33c1c8 code=40010006 flags=0 0009:trace:seh:call_vectored_handlers handler at 0x33c1c8 returned 0 0009:trace:seh:call_stack_handlers calling handler at 0x7b4b4888 code=40010006 flags=0 0009:fixme:seh:RtlUnwind Not implemented on ARM64 0009:trace:process:NtQueryInformationProcess (0xffffffffffffffff,0x0000000c,0x22eb8c,0x00000004,(nil)) 0009:trace:process:NtQueryInformationProcess (0xffffffffffffffff,0x0000000c,0x22eb8c,0x00000004,(nil)) 0009:trace:seh:raise_exception info[0]=0000000000000054 0009:trace:seh:raise_exception info[1]=0000000000078490 0009:trace:seh:call_vectored_handlers calling handler at 0x46b1540 code=40010006 flags=0 0009:trace:seh:call_vectored_handlers handler at 0x46b1540 returned 0 0009:trace:seh:call_vectored_handlers calling handler at 0x2e72e60 code=40010006 flags=0 0009:trace:seh:call_vectored_handlers handler at 0x2e72e60 returned 0 0009:trace:seh:call_vectored_handlers calling handler at 0x1fe64fc code=40010006 flags=0 0009:trace:seh:call_vectored_handlers handler at 0x1fe64fc returned 0 0009:trace:seh:call_vectored_handlers calling handler at 0x33c1c8 code=40010006 flags=0 0009:trace:seh:call_vectored_handlers handler at 0x33c1c8 returned 0 0009:trace:seh:call_stack_handlers calling handler at 0x7b4b4888 code=40010006 flags=0 0009:fixme:seh:RtlUnwind Not implemented on ARM64 ... --- snip ---
Wine source:
https://source.winehq.org/git/wine.git/blob/HEAD:/dlls/ntdll/signal_arm64.c#...
--- snip --- 540 static NTSTATUS raise_exception( EXCEPTION_RECORD *rec, CONTEXT *context, BOOL first_chance ) 541 { 542 NTSTATUS status; 543 544 if (first_chance) 545 { 546 DWORD c; 547 548 for (c = 0; c < rec->NumberParameters; c++) 549 TRACE( " info[%d]=%016lx\n", c, rec->ExceptionInformation[c] ); 550 if (rec->ExceptionCode == EXCEPTION_WINE_STUB) 551 { 552 if (rec->ExceptionInformation[1] >> 16) 553 MESSAGE( "wine: Call from %p to unimplemented function %s.%s, aborting\n", 554 rec->ExceptionAddress, 555 (char*)rec->ExceptionInformation[0], (char*)rec->ExceptionInformation[1] ); 556 else 557 MESSAGE( "wine: Call from %p to unimplemented function %s.%ld, aborting\n", 558 rec->ExceptionAddress, 559 (char*)rec->ExceptionInformation[0], rec->ExceptionInformation[1] ); 560 } 561 else 562 { 563 /* FIXME: dump context */ 564 } 565 566 status = send_debug_event( rec, TRUE, context ); 567 if (status == DBG_CONTINUE || status == DBG_EXCEPTION_HANDLED) 568 return STATUS_SUCCESS; 569 570 if (call_vectored_handlers( rec, context ) == EXCEPTION_CONTINUE_EXECUTION) 571 return STATUS_SUCCESS; 572 573 if ((status = call_stack_handlers( rec, context )) != STATUS_UNHANDLED_EXCEPTION) 574 return status; 575 } 576 577 /* last chance exception */ 578 579 status = send_debug_event( rec, FALSE, context ); 580 if (status != DBG_CONTINUE) 581 { 582 if (rec->ExceptionFlags & EH_STACK_INVALID) 583 ERR("Exception frame is not in stack limits => unable to dispatch exception.\n"); 584 else if (rec->ExceptionCode == STATUS_NONCONTINUABLE_EXCEPTION) 585 ERR("Process attempted to continue execution after noncontinuable exception.\n"); 586 else 587 ERR("Unhandled exception code %x flags %x addr %p\n", 588 rec->ExceptionCode, rec->ExceptionFlags, rec->ExceptionAddress ); 589 NtTerminateProcess( NtCurrentProcess(), rec->ExceptionCode ); 590 } 591 return STATUS_SUCCESS; 592 } --- snip ---
--- snip --- System information: Wine build: wine-3.20-7-ga0a7090301 Platform: arm64 Version: Windows 7 Host system: Linux Host version: 4.18.14-yocto-standard --- snip ---
Regards
https://bugs.winehq.org/show_bug.cgi?id=46126
André H. nerv@dawncrow.de changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |nerv@dawncrow.de
https://bugs.winehq.org/show_bug.cgi?id=46126
André H. nerv@dawncrow.de changed:
What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|NEW |RESOLVED Fixed by SHA1| |b78a5db2dc6147ed8b62bdcff21 | |0a78f448e0fa9
--- Comment #1 from André H. nerv@dawncrow.de --- Should be fixed by: https://source.winehq.org/git/wine.git/commitdiff/b78a5db2dc6147ed8b62bdcff2...
https://bugs.winehq.org/show_bug.cgi?id=46126
--- Comment #2 from Anastasius Focht focht@gmx.net --- Hello André,
--- quote --- Should be fixed --- quote ---
yes, thanks.
--- snip --- $ WINEDEBUG=+seh,+loaddll,+process,+debugstr wine64 ./vlc.exe ... 0009:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\vlc-4.0.0-dev\vlc.exe" at 0x140000000: native ... 0009:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\vlc-4.0.0-dev\libvlccore.dll" at 0x230000: native 0009:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\vlc-4.0.0-dev\libvlc.dll" at 0x180000000: native ... 0009:warn:debugstr:OutputDebugStringA "main libvlc debug: VLC media player - 4.0.0-dev Otto Chriek\n" 0009:trace:seh:raise_exception code=40010006 flags=0 addr=0x7bcb1b74 pc=7bcb1b74 tid=0009 0009:trace:seh:raise_exception info[0]=000000000000003d 0009:trace:seh:raise_exception info[1]=00000000000209e0 0009:trace:seh:raise_exception x0=000000000022edc8 x1=000000000022f3c0 x2=0000000000000010 x3=000000000022f3c0 0009:trace:seh:raise_exception x4=000000000022f3d0 x5=000000000022f1c8 x6=000000000000003d x7=00000000000209e0 0009:trace:seh:raise_exception x8=0101010101010101 x9=000000007bcb3e5c x10=202d20726579616c x11=65642d302e302e34 0009:trace:seh:raise_exception x12=43206f74744f2076 x13=226e5c6b65697268 x14=ffffffffffffff9a x15=0000000000000001 0009:trace:seh:raise_exception x16=000000007b663000 x17=0000007f815eddd0 x18=000000007ffd8000 x19=0000000000482b50 0009:trace:seh:raise_exception x20=0000000000482be0 x21=0000000000482be0 x22=000000000000003d x23=000000007b476aec 0009:trace:seh:raise_exception x24=00000000003738ff x25=00000000003573df x26=0000000000000000 x27=000000000022f4d0 0009:trace:seh:raise_exception x28=000000000022f4e0 fp=000000000022eda0 lr=000000007bcb3e74 sp=000000000022eda0 0009:trace:seh:raise_exception pc=000000007bcb1b74 0009:trace:seh:call_vectored_handlers calling handler at 0x33c1c8 code=40010006 flags=0 0009:trace:seh:call_vectored_handlers handler at 0x33c1c8 returned 0 0009:trace:seh:call_stack_handlers calling handler at 0x7b4b49c0 code=40010006 flags=0 0009:fixme:seh:RtlUnwind Not implemented on ARM64 ... --- snip ---
$ wine64 --version wine-3.20-150-gb2ce7868cb
Regards
https://bugs.winehq.org/show_bug.cgi?id=46126
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #3 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 3.21.
https://bugs.winehq.org/show_bug.cgi?id=46126
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- URL| |https://web.archive.org/web | |/20180812143722/http://peop | |le.videolan.org/~jb/Builds/ | |ARM/vlc-4.0.0-dev-20180508- | |aarch64.zip Keywords| |download