Repository navigation
Conversation
Leyukaka
marked this pull request as draft
November 29, 2026 19:52
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Refs #3477 (item 8, #3477 (comment)).
Stacked on #3463: until it merges, this PR also shows its commit. The change here is the last two commits, 23fa52f and 9699aa4 (head).
Why
In a long local run of the application, the trace could not say which thread stopped issuing work before the stop.
What changes
tools/startup/debug_launch.py: return lines of runtime and movie-player calls (--trace-calls) infiles.txtend withtid=<id> gap_ms=<ms|n/a>. File-hook lines (NtCreateFile,NtOpenFile, ...) keep their format.tools/startup/hook_window.py: newtrace_call_suffix. The gap is per thread, fromtime.monotonic(), between that thread's logged trace lines, in ms with 3 decimals. The first line of a thread hasgap_ms=n/a.Exception and debugger stop lines in
events.txtend withtid=<id>.tools/startup/triage_run.py,tools/startup/exit_report.py: the debugger stop regex accepts the optionaltid=suffix, with the same captures. The exception regexes are not end-anchored and needed no change.live_view.pyand the other consumers of these lines are unaffected.Tests
tests/startup_hook_check.py,tests/startup_triage_run_check.py,tests/startup_exit_report_check.py: pass.cmake --preset dev -DX2W_WITH_OPUS:BOOL=OFF, build targetsstartup_debug_probeandstartup_debug_calls, thenctest -R '^startup_debug(_log|_hooks)?$': 3/3 passed.Mutations, each caught by a failing check:
trace_call_suffixstartup_hook_checktid=dropped from the exception linestartup_debugtriage_run.pystartup_triage_run_checkexit_report.pystartup_exit_report_checkstartup_debug_hookstid=dropped from the debugger stop linestartup_debugstartup_debug_hooks(a new thread reusing the exited thread's id gets a numeric gap instead ofn/a)docs/startup-runtime.mddescribes thetidandgap_msfields.