https://bugs.winehq.org/show_bug.cgi?id=46144
Bug ID: 46144 Summary: Windows PowerShell Core 6.1 for ARM64 crashes on unimplemented function KERNEL32.dll.RtlPcToFileHeader Product: Wine Version: 3.20 Hardware: aarch64 OS: Linux Status: NEW Severity: normal Priority: P2 Component: kernel32 Assignee: wine-bugs@winehq.org Reporter: focht@gmx.net Distribution: ---
Hello folks,
as it says.
--- snip --- $ WINEDEBUG=+seh,+loaddll,+process wine64 ./pwsh.exe ... 0009:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\powershell611-arm64\pwsh.exe" at 0x140000000: native 0009:trace:loaddll:load_builtin_dll Loaded L"C:\windows\system32\api-ms-win-crt-runtime-l1-1-0.dll" at 0x7f98f00000: builtin 0009:trace:loaddll:load_builtin_dll Loaded L"C:\windows\system32\ucrtbase.dll" at 0x7f98d00000: builtin 0009:trace:loaddll:load_builtin_dll Loaded L"C:\windows\system32\api-ms-win-crt-math-l1-1-0.dll" at 0x7f98cb0000: builtin 0009:trace:loaddll:load_builtin_dll Loaded L"C:\windows\system32\api-ms-win-crt-heap-l1-1-0.dll" at 0x7f98c90000: builtin 0009:trace:loaddll:load_builtin_dll Loaded L"C:\windows\system32\api-ms-win-crt-stdio-l1-1-0.dll" at 0x7f98c70000: builtin 0009:trace:loaddll:load_builtin_dll Loaded L"C:\windows\system32\api-ms-win-crt-string-l1-1-0.dll" at 0x7f98c40000: builtin 0009:trace:loaddll:load_builtin_dll Loaded L"C:\windows\system32\api-ms-win-crt-locale-l1-1-0.dll" at 0x7f98c20000: builtin 0009:trace:loaddll:load_builtin_dll Loaded L"C:\windows\system32\api-ms-win-crt-convert-l1-1-0.dll" at 0x7f98c00000: builtin 0009:trace:loaddll:load_builtin_dll Loaded L"C:\windows\system32\advapi32.dll" at 0x7f98b70000: builtin 0009:trace:loaddll:load_builtin_dll Loaded L"C:\windows\system32\api-ms-win-crt-multibyte-l1-1-0.dll" at 0x7f98b40000: builtin 0009:trace:process:NtQueryInformationProcess (0xffffffffffffffff,0x00000007,0x2afa70,0x00000008,(nil)) 0009:fixme:ntdll:EtwEventRegister ({5eec90ab-c022-44b2-a5dd-fd716a222a15}, 0x1400014e0, 0x14001d4a0, 0x14001d4c0) stub. 0009:fixme:ntdll:EtwEventSetInformation (deadbeef, 2, 0x140018a08, 43) stub 0009:fixme:msvcrt:_configure_wide_argv (1) stub 0009:fixme:msvcrt:_initialize_wide_environment stub 0009:trace:loaddll:load_builtin_dll Loaded L"C:\windows\system32\api-ms-win-crt-filesystem-l1-1-0.dll" at 0x7f98aa0000: builtin 0009:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\powershell611-arm64\hostfxr.dll" at 0x180000000: native 0009:fixme:ntdll:EtwEventRegister ({5eec90ab-c022-44b2-a5dd-fd716a222a15}, 0x1800014e0, 0x180054130, 0x180054150) stub. 0009:fixme:ntdll:EtwEventSetInformation (deadbeef, 2, 0x180047828, 43) stub 0009:trace:seh:raise_exception info[0]=00000001800527f0 0009:trace:seh:raise_exception info[1]=0000000180052bd6 wine: Call from 0x7bcb1a44 to unimplemented function KERNEL32.dll.RtlPcToFileHeader, aborting 0009:trace:seh:call_stack_handlers calling handler at 0x7bcd5d68 code=80000100 flags=1 0009:fixme:seh:RtlUnwind Not implemented on ARM64 0009:trace:loaddll:free_modref Unloaded module L"Z:\home\focht\projects\woa-winrt\powershell611-arm64\hostfxr.dll" : native 0009:trace:loaddll:free_modref Unloaded module L"C:\windows\system32\api-ms-win-crt-filesystem-l1-1-0.dll" : builtin 0009:fixme:ntdll:RtlNtStatusToDosErrorNoTeb no mapping for 80000100 ... --- snip ---
Wine source:
https://source.winehq.org/git/wine.git/blob/HEAD:/dlls/kernel32/kernel32.spe...
--- snip --- 1297 @ stdcall -arch=x86_64,arm RtlPcToFileHeader(ptr ptr) ntdll.RtlPcToFileHeader --- snip ---
$ sha1sum PowerShell-6.1.1-win-arm64.zip dce4e345dafa80cff955b32c10a4ab13ba732705 PowerShell-6.1.1-win-arm64.zip
$ du -sh PowerShell-6.1.1-win-arm64.zip 40M PowerShell-6.1.1-win-arm64.zip
$ wine64 --version wine-3.20-75-gb7cf409169
Regards
https://bugs.winehq.org/show_bug.cgi?id=46144
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- Keywords| |download URL| |https://github.com/PowerShe | |ll/PowerShell/releases/down | |load/v6.1.1/PowerShell-6.1. | |1-win-arm64.zip
https://bugs.winehq.org/show_bug.cgi?id=46144
André H. nerv@dawncrow.de changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |nerv@dawncrow.de
https://bugs.winehq.org/show_bug.cgi?id=46144
--- Comment #1 from André H. nerv@dawncrow.de --- patch sent: https://source.winehq.org/patches/data/154186
https://bugs.winehq.org/show_bug.cgi?id=46144
André H. nerv@dawncrow.de changed:
What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |9f7692e2edc2face389f1cd26fd | |b5f705acaa6ab Status|NEW |RESOLVED Resolution|--- |FIXED
--- Comment #2 from André H. nerv@dawncrow.de --- Should be fixed by: https://source.winehq.org/git/wine.git/commitdiff/9f7692e2edc2face389f1cd26f...
https://bugs.winehq.org/show_bug.cgi?id=46144
--- Comment #3 from Anastasius Focht focht@gmx.net --- Hello André,
yes, it can locate the base address of the PE from the PC now. Thanks
--- snip --- $ WINEDEBUG=+seh,+loaddll,+process,+relay,+ntdll wine64 ./pwsh.exe >>log.txt 2>&1 ... 002b:Ret PE DLL (proc=0x7fb249cedc,module=0x7fb2480000 L"api-ms-win-crt-filesystem-l1-1-",reason=PROCESS_ATTACH,res=(nil)) retval=1 002b:Call PE DLL (proc=0x180035f60,module=0x180000000 L"hostfxr.dll",reason=PROCESS_ATTACH,res=(nil)) ... 002b:Call ntdll.RtlPcToFileHeader(180051d38,002aecf8) ret=180033ffc 002b:Ret ntdll.RtlPcToFileHeader() retval=180000000 ret=180033ffc ... 002b:Call KERNEL32.LoadLibraryExW(002c48e0 L"Z:\home\focht\projects\woa-winrt\powershell611-arm64\hostpolicy.dll",00000000,00001100) ret=180031084 ... 002b:Call KERNEL32.GetProcAddress(180000000,1400150a8 "hostfxr_main_startupinfo") ret=14000c53c 002b:Ret KERNEL32.GetProcAddress() retval=180020050 ret=14000c53c ... 002b:Call KERNEL32.GetEnvironmentVariableW(18003a9f8 L"COREHOST_TRACE",00000000,00000000) ret=180030e7c 002b:Ret KERNEL32.GetEnvironmentVariableW() retval=00000000 ret=180030e7c ... 002b:trace:loaddll:load_native_dll Loaded L"Z:\home\focht\projects\woa-winrt\powershell611-arm64\hostpolicy.dll" at 0x3d0000: native 002b:Call PE DLL (proc=0x408380,module=0x3d0000 L"hostpolicy.dll",reason=PROCESS_ATTACH,res=(nil)) ... 002b:Call ntdll.RtlPcToFileHeader(0044cfb0,002adf58) ret=00405424 002b:Ret ntdll.RtlPcToFileHeader() retval=003d0000 ret=00405424 ... 002b:Call KERNEL32.GetProcAddress(003d0000,18003edd0 "corehost_load") ret=180030c7c 002b:Ret KERNEL32.GetProcAddress() retval=003f1bc0 ret=180030c7c 002b:Call KERNEL32.GetProcAddress(003d0000,18003ede0 "corehost_unload") ret=180030c7c 002b:Ret KERNEL32.GetProcAddress() retval=003da1f0 ret=180030c7c 002b:Call KERNEL32.GetProcAddress(003d0000,18003edf0 "corehost_main") ret=180030c7c 002b:Ret KERNEL32.GetProcAddress() retval=003f1c90 ret=180030c7c ... 002b:Call KERNEL32.GetEnvironmentVariableW(0042e198 L"COREHOST_TRACE",00000000,00000000) ret=00401e4c 002b:Ret KERNEL32.GetEnvironmentVariableW() retval=00000000 ret=00401e4c ... 002b:Ret PE DLL (proc=0x408380,module=0x3d0000 L"hostpolicy.dll",reason=PROCESS_ATTACH,res=(nil)) retval=1 002b:Ret KERNEL32.LoadLibraryExW() retval=003d0000 ret=180031084 --- snip ---
$ wine64 --version wine-3.20-116-g7628b7b40d
Regards
https://bugs.winehq.org/show_bug.cgi?id=46144
Alexandre Julliard julliard@winehq.org changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED
--- Comment #4 from Alexandre Julliard julliard@winehq.org --- Closing bugs fixed in 3.21.
https://bugs.winehq.org/show_bug.cgi?id=46144
Anastasius Focht focht@gmx.net changed:
What |Removed |Added ---------------------------------------------------------------------------- URL|https://github.com/PowerShe |https://web.archive.org/web |ll/PowerShell/releases/down |/20210702120211/https://git |load/v6.1.1/PowerShell-6.1. |hub.com/PowerShell/PowerShe |1-win-arm64.zip |ll/releases/download/v6.1.1 | |/PowerShell-6.1.1-win-arm64 | |.zip