Repository navigation
Conversation
…seconds A diagnostic for boots that hang: with --trace and LEONIDA_HANG_DUMP=<seconds>, that many seconds after the trace opens every other thread is suspended just long enough to read its registers, and its stack is walked (with the exception events' walker) after it resumes and written as a thread_stack event. The retail title's watchdog gives up after 30 seconds when its main thread stops progressing; this shows where each thread waits. Documented in docs/boot.md and runtime/README.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> (cherry picked from commit cc424342d8725eb24d45aa4fa0b9ad5a6903010a) (cherry picked from commit 7acba811a885dbc6fb7d481aa4399bf9fed94ed5)
|
Reviewed e6438eb: Static bug found: Also note: while Recommendation: Fix first |
|
Closing this: |
Claimed in the coordination issue as: RT-HANG-DUMP (#14 (comment))
What and why
A retail boot that faults leaves a last exception in the trace; one that hangs leaves nothing to look at. With
LEONIDA_HANG_DUMP=<seconds>,gta6rtwaits that long and then writes the stack of every thread in the process to thestartup trace (each thread is suspended briefly while its context is read, then resumed), so a stalled boot shows
where each thread waits. Unset, nothing changes: no thread is started.
The code is in
runtime/shims/startup_trace.h;docs/boot.mdandruntime/README.mdname the variable.The commit is 4ld0-vito's (from their fork, where it was used for the boot work), carried over unchanged with its
author kept.
Tested
gta6rt,gta6rt_tls_host,unimplemented_policy_testandxapu_chad_testwith MSVC 2022 (Windows 11,RelWithDebInfo, Ninja) on this branch: all link; the two shim tests that include
startup_trace.hpass.GPUs tested: n/a (no GPU code)
AI-assisted: yes
Checklist
mainand merges cleanly (a conflicting pull request is labeledneeds rebase).docs/design.md, with how it was confirmed. (n/a: no translator change)