Guest exceptions abort silently on Linux instead of following the documented terminate path #13

Closed
opened 2026-09-26 20:08:10 +00:00 by obelisk-complex · 0 comments
obelisk-complex commented 2026-09-26 20:08:10 +00:00 (Migrated from github.com)
Contributor

Imported from boykopovar/AnyPS5. Originally posted by obelisk-complex on 2026-09-26T20:08:10Z.


On Linux, seven ctest cases abort with a bare SIGABRT and no message, instead of following the behaviour the README documents: unsupported states throw std::runtime_error, what() is printed to stderr, and the process terminates. Six of the seven (guest_rendering_wait, guest_buffer_reuse, guest_shader_link, guest_system_exit_parameters, guest_memory, guest_search) are the same failures #7 already recorded as pre-existing on Linux; guest_once is a seventh case of the same bug.

Root cause: these test executables and the .prx shared libraries they load dynamically link the system libstdc++/libgcc on Linux. A plain throw goes through the system's __cxa_throw/_Unwind_RaiseException. That still calls this project's own __gxx_personality_v0_nid_postfix (the CIE's personality pointer is a raw function address, so whichever unwinder is walking the stack calls it), but hands it libgcc's own private _Unwind_Context layout rather than this project's own, so every field Personality.cpp reads off it is garbage, and the process aborts deep inside the custom DWARF decoder instead of ever reaching a terminate handler.

This is Linux-only. Windows avoids it structurally: configure_windows_unwind() renames .eh_frame so there is never a competing system unwinder in that process.

🤖 Generated with Claude Code

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:5596949479 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/issues/13). Originally posted by [obelisk-complex](https://github.com/obelisk-complex) on 2026-09-26T20:08:10Z. --- On Linux, seven `ctest` cases abort with a bare `SIGABRT` and no message, instead of following the behaviour the README documents: unsupported states throw `std::runtime_error`, `what()` is printed to stderr, and the process terminates. Six of the seven (`guest_rendering_wait`, `guest_buffer_reuse`, `guest_shader_link`, `guest_system_exit_parameters`, `guest_memory`, `guest_search`) are the same failures #7 already recorded as pre-existing on Linux; `guest_once` is a seventh case of the same bug. Root cause: these test executables and the `.prx` shared libraries they load dynamically link the system libstdc++/libgcc on Linux. A plain `throw` goes through the system's `__cxa_throw`/`_Unwind_RaiseException`. That still calls this project's own `__gxx_personality_v0_nid_postfix` (the CIE's personality pointer is a raw function address, so whichever unwinder is walking the stack calls it), but hands it libgcc's own private `_Unwind_Context` layout rather than this project's own, so every field `Personality.cpp` reads off it is garbage, and the process aborts deep inside the custom DWARF decoder instead of ever reaching a terminate handler. This is Linux-only. Windows avoids it structurally: `configure_windows_unwind()` renames `.eh_frame` so there is never a competing system unwinder in that process. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
boykopovar/AnyPS5#13
No description provided.