Diagnostics for finding what paces a frame: causal profiling switches, a capture trigger, a multi-lane stress harness #3508
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3508"
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 trustno1-coder/VIctory-NVIDIA. Originally posted by Aseoriy on 2026-11-30T00:12:01Z.
Three independent commits on top of main
41adb551. Each builds alone (normal anddiagnostics), and the tests they add pass.1. Causal profiling switches (diagnostics builds only)
VICTORY_SLOW_SUBMIT(the submitting thread busy-waits 120 µs per submission) andVICTORY_SLOW_LISTS(each translating thread 80 µs per recording);VICTORY_SLOW_USoverrides the amount. Used withVICTORY_AB, they tell whether a stage sets the frame's pace: if frames get slower by about as much as was added, it does.What it showed while driving (RTX 5070, i7-14700F, Series X profile, 4-way in-run A/B): neither stage slowed frames by the ~2 ms added (−0.3 ms and −0.7 ms over 12 and 11 matched pairs). The card was 76–90 % busy by the card clock, with the title waiting ~11 ms a frame at present. So on this machine, driving frames are paced by the card, and cutting CPU work on either stage alone is neutral; that matched several CPU reductions measured neutral the same day.
2. Capture: a file named
shotin the capture folder captures the next frame, as F9 doesFor tools outside the process (unattended test runs with the display off). Checked every 15 frames; diagnostics builds only.
3. Stress harness for preparing on more than one thread (
shadow::lane_tests)No game needed, about 4 s. Rounds race two writer threads against two lanes' refreshes of random pieces of five nested and overlapping copies of write-watched memory, then stop the writers, refresh every copy whole and check every dword against title memory. A planted lost write (a thread clearing the kernel's write bits behind the journal) is caught, so the harness is known to see what it is for.
VICTORY_LANE_ROUNDS=<n>for longer runs (2,000 rounds clean). Meant as a safety net for work that splits submission preparing across threads.Tested
cargo check -p victory-gpu -p victory-hle, with and withoutdiagnostics;cargo check -p victory --features diagnostics.VICTORY_LANE_ROUNDS=40 cargo test -p victory-gpu --lib lane_tests: 3 passed (including the planted-lost-write check).Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by trustno1-coder on 2026-12-01T18:51:31Z.
Closing this as part of moving main to the texture and video-memory rework (v2026.12.01.01-test). A lot of the code changed, and this pull request no longer applies cleanly to it; it would need to be rewritten against the new main rather than rebased. Thank you for the work. If the change is still needed, please open a new pull request based on the current main.
Pull request closed