trace: Driver.EndSubmission nests through the rewind tail, so worker_busy_pct counts time many times #8092
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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 CPritch on 2026-10-19T21:15:24Z.
On the pipelined path, Driver::execute keeps its Driver.EndSubmission timer open while it runs the rewind tail (PacketExecution.cpp:468, 480). executeRewindTail ends in execute(tail) (Submission.cpp:322), which runs the tail's packets and opens the next Driver.EndSubmission inside the first. TraceThread's account adds each slice's whole length to its scope's total (PerformanceTrace.hpp:247), and the summary adds the totals of Driver.Packet, Driver.Suspend, Driver.EndSubmission, Driver.Rewind and Driver.Completion into worker_busy_pct (PerformanceTrace.hpp:466). A chain of n tails is counted n times under Driver.EndSubmission, and its packets once more under Driver.Packet. The non-pipelined path finishes the timer before it runs the tail (PacketExecution.cpp:499-500). Line numbers are at main
bf2c63f85.Seen on GTA V (PPSA04263 01.010.002), Linux, RTX 5060 Laptop GPU, NVIDIA 615.71.09, main
544f29106, APS5_TRACE_FRAMES=3700:1400 (118 s): worker_busy_pct "queue worker 0x0" 3740.454, and top_phases_ms_per_frame Driver.EndSubmission 3079.377 at a frame p50 of 82.1 ms. A second capture (APS5_TRACE_FRAMES=3500:700, APS5_TRACE_EVENTS=4194304, nothing dropped) gives 3726.552 and 3045.4 at a p50 of 81.2 ms.In the trace of queue worker 0x0 (the first 5.68 s of the first capture, before its buffer filled), 4,830 Driver.EndSubmission slices add up to 207.6 s. 4,761 of them lie inside another one, none crosses another's end, and they nest up to 70 deep; their union is 5.66 s. 207.6 / 5.68 = 36.5, the ratio of 3,079 ms to the 84 ms frame.
Not checked: other titles, and whether other scopes nest the same way.
AI-assisted: yes
Imported from boykopovar/AnyPS5. Originally posted by milescoviello on 2026-10-19T22:00:56Z.
@CPritch thanks, your trace analysis pointed straight at it. #8108 finishes the
Driver.EndSubmissiontimer before the pipelined branch runs the released tail, as the non-pipelined path already does. Its test runs one trace window over 12 released REWIND tails. Queue worker 0x0'sworker_busy_pctcomes out at 677-704% without the change and 91-94% with it.AI-assisted: yes (Claude Code)