fix(libc): name a guest abort() in the crash report #5957
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/5957"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by xXPBSXx on 2026-10-14T17:04:34Z.
What
The guest libc ends
abort()inint 0x45; nop; ud2. Windows reports theint 0x45as an access violation: a read of0xffffffffffffffff. The crash report printed that as a genericFATAL: unhandled exception 0xc0000005withread of 0xffffffffffffffff, which looks like a bad pointer.Title: Sifu (PPSA03001), 300 s run, Windows 10, MinGW GCC 15.2, Release, the run ends after about 224 s:
PPSA03001_rN/run_183839.errline 40FATAL: unhandled exception 0xc0000005, line 41rip 0x00007ffd424b4270 libc.prx.guest.prx+0x14270, line 42read of 0xffffffffffffffff; the title's stdout log (run_183839.outlines 3295-3296) has just before it the Unreal Engine messageLowLevelFatalError [File:Unknown] [Line: 1214]/GameThread timed out waiting for RenderThread after 120.00 secs, so the title calledabort()after its own watchdog fired.The report now adds one line,
guest abort() (int 0x45), when the access violation is a read of0xffffffffffffffffand the two bytes atriparecd 45. In the run above it is line 43 ofrun_183839.err. Nothing else in the report changes and the process still ends the same way. Thewindows_exception_testschild-process test gets a second child that executesint 0x45.This does not fix the stalled render thread; it only makes such logs sortable. Related, closed: #3209 (the same title's RenderThread).
Tested
Windows 10 (19045), MinGW-w64 GCC 15.2.0 (WinLibs), Release, on
maine34c479210c78d7b160d7054f3e72de422b23d7a+ this commit (f4b45af04,git statusclean):windows_exception_tests(target built and run alone): with the fix exit code0; without the fix (the same tree withCrashReport.cpptaken back frommain) exit code0xC0000409(fast fail fromabort()).maine34c47921plus this commit and three unrelated local commits that are not part of this pull request (mmap, pthread attribute and clock id checks inlibkernel); fulllibsand relinker rebuilt from that tree, title relinked with it; the log showsguest abort() (int 0x45)as above. I did not repeat the title run on the tree with this commit alone.python tools/check_conventions.py --base upstream/mainwith this title and body passes ("All conventions checks passed.").Checklist
main(e34c47921); no other open PR implements the same changeNotImplemented_nid_no_patch); no silent stubs added.mdfiles or images added to the repositoryAI-assisted (Claude Code).
🤖 Generated with Claude Code
Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-15T12:12:16Z.
Some comparisons could not be completed because a pull request conflicts with the base branch. Review these shared files manually before concluding that there is no overlap.
core/libs/tests/WindowsExceptions.cppcore/libs/prx/libc/src/specifics/windows/CrashReport.cppImported from boykopovar/AnyPS5. Originally posted by xXPBSXx on 2026-10-15T17:14:19Z.
@adriadam10 a short request for review of this PR. Head
f4b45af04isMERGEABLE, the Conventions, Eligibility and Intake checks are green, and the description names the title (Sifu, PPSA03001), the log line and the test that fails without the change. It is a diagnostic-only change (the crash report names a guestabort()). If a review or a full Build run is possible, I will answer any finding the same day.AI-assisted (Claude Code).
Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-16T19:01:22Z.
Checked the diff: the
int 0x45detection reads the two bytes atripthroughReadCodeand only fires for a read of0xffffffffffffffff, so other access violations are unchanged; the newguest-abortchild inwindows_exception_testspins the report line. Windows-only, so the Windows Build run is the gate; merging once it is green.Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-16T21:26:06Z.
Review: CHANGES_REQUESTED
The full Build (windows, run 38967687206) fails
windows_exceptionswith this PR:Exit code 0xc0000409,unhandled exception 'St13runtime_error',what(): child process setup failed. The same test passes on the recentmainpush builds, so it comes from this change.core/libs/tests/WindowsExceptions.cpptestGuestAbortReport: the exit code check goes throughRequireHandle, whose message is generic, so the log doesn't say which assertion failed. On the runner theguest-abortchild probably doesn't exit with0xC0000005or doesn't print the new line. Please make the failure report the child's exit code and output (a dedicatedthrow std::runtime_errorwith both), then fix what it shows. The runner is not the Windows 10 machine the test was tried on, so compare there before assumingint 0x45behaves the same.Imported from boykopovar/AnyPS5. Originally posted by xXPBSXx on 2026-10-19T01:56:36Z.
Thanks for the run link. Pushed
3050c8932on top (no amend):testGuestAbortReportnow throws onestd::runtime_errorthat carries the child's exit code and its full output when the exit code is not0xC0000005or the lineguest abort() (int 0x45)is missing, so the next Full Build log shows which of the two it was and what the child printed.Local check (Windows 10 19045, MinGW GCC 15.2.0, Release,
5d9dcc42d+ both commits of this PR):windows_exceptionspasses (1.41 s), so the child exits with0xC0000005and names the abort there. I have not reproduced the runner failure and am not assumingint 0x45behaves the same on it; the fix, if one is needed, follows from the new message.Could you dispatch the Full Build for this PR once more? The failure message now carries the exit code and output of the child, and that tells us what to fix on the runner.
AI-assisted (Claude Code).