Attribute observed graphics queue gaps to lane states #1126
No reviewers
Labels
No labels
AMD
audio
bug
confirmed
crash
cutscene
dlss
documentation
duplicate
enhancement
fixed-on-main
frame-generation
good first issue
help wanted
input
INTEL
invalid
lighting
linux-proton
memory
needs-info
needs-logs
needs-rebase
NVIDIA
performance
pr-diagnostics
pr-docs
pr-feature
pr-fix
pr-performance
pr-refactor
pr-tests
question
RAYTRACING
rendering
report
series-s
shaders
spam
startup
upstream
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/trustno1-coder--VIctory-NVIDIA!1126
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-1126"
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?
@ghptc on GitHub · 2026-11-28 13:43 UTC · original
ghptc:perf/queue→main· +294 −20 · 8 files · 1 commits · merged 2026-11-29 08:16 UTCAttribute observed graphics queue gaps to lane states
An observed completion of VIctory’s newest graphics fence opens an interval. The next instrumented send closes it. The old message described every microsecond outside marked submit work as time the title had not submitted. The lane can already contain submitted lists whose translation or dependencies are incomplete.
This change labels the remainder accurately and adds
VICTORY_QUEUE_GAPS=1. An exclusive observer accumulates microseconds during marked submit work, a parked lane with no entries, recording/fence/value-blocked heads, mixed heads, a notified lane awaiting recheck, and unknown activity. The readiness decision supplies the head classification. New notifications invalidate the parked classification under the lane mutex. Timed polling shares the same readiness decision. A periodic report cuts any open interval at its boundary and exports an independently reconcilable total. The old clock continues to charge a whole interval when it closes. Device removal, a failed event registration and a failed wait cannot open a new observed interval.In diagnostics builds a short timeline can correlate demand for an unfinished recording with its queued/dequeued/closed identity, actual pipeline condition waits on that worker, and GPU timestamps. Enable the gap switch as well to see lane state and marked work transitions. Recording identities are local to their live allocation. The trace writer’s loss counter and clipped edges matter. No scheduling order, dependency test, PSO budget or buffer ownership rule is changed by the telemetry. The opt-in accounting takes a mutex near readiness and notification. Observer overhead under a real workload is unmeasured.
Tests. Synthetic mixed blockers and a delayed recording verify exact time conservation across report boundaries and submit-work overlap. A native fixture drives the production generic consumer through no entries → delayed folded recording → wake → send using a CPU job backend. The added Windows lane regression checks that a fence-guarded job only runs after the producer. All Windows-target tests type-checked with default features and diagnostics. Actual driver timing is a subsequent measurement.
Prior work. Searches of open and closed NVIDIA-fork PRs for “card clock”, “queue starvation”, “nothing of ours queued”, and timeline titles found keep-awake, submission and existing trace changes. The calibrated timestamp lifetime fix, timeline wait aggregation, and eight-core contention report supply complementary measurements. No matching lane/observer intersection was found in the reviewed results. Timestamp fix · Timeline test #598 · Contention #833
Reproduce
From this independent PR head with the pinned Rust toolchain on Linux, compile the production module directly.
On Windows use
cargo test --release --locked -j 2 -p victory-gpu --lib host::gaps::tests -- --test-threads=1. Also runcargo test --release --locked -j 2 -p victory-gpu --lib queue::behind::tests::a_delayed_fence_reports_its_head_until_the_producer_finishes -- --exact --test-threads=1on Windows. The Windows target type-checked with and without diagnostics. The CPU regressions passed again on the submitted commit. Gameplay timings and driver overhead remain unmeasured.25f168c8e7to6e3f83970a