perf(gpu): sift refresh batches with the scoped worker pool #3705
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3705"
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 victorportelada on 2026-11-30T04:22:58Z.
What it changes
The refresh sifting paths allocated fresh
Arc<Vec<AtomicBool>>marks and anArc<Vec<...>>of items for every large flush, then cloned them once per worker. On a 6-core host this was measurable overhead in the submitting thread's critical path.This patch:
Vec<AtomicBool>toBatchand a genericretain_scopedhelper that checks items on the existing scoped worker pool, reuses the marks allocation, and retains entries in order.VICTORY_FRONT_SIFT) and the batch refreshes (VICTORY_FLUSH_SIFT), replacing the two duplicateArc-based sift functions.Measurement
On an RTX 5060 8 GB / Ryzen 5 5600 with a gated headless replay driver (same tape, settings and 3,000-draw gate): median frame 68.3 ms → 58.9 ms (14.6 → 17.0 fps), p95 80.3 → 78.6 ms. This was the only structural patch in a long A/B series that produced a clear fps gain. The 1-second report's refresh cost fell from ~21.8 ms to ~16.3 ms per frame.
Verification
mainafter resolving one conflict with the newerahead_snapshot_intopath (the snapshot was unused and removed).cargo test -p victory-gpu --lib sampled: passes.cargo xtask policy: the only reported violation (heap_sites/frame_users.rs, 2022 hex digits) is pre-existing on upstreammain, not in this patch.cargo clippy -D warningscurrently fails on clean upstreammainwith pre-existing lints; this patch adds none.Docs/analysis from the investigation are included in
docs/cpu-submission-critical-path.md.Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by trustno1-coder on 2026-12-01T18:49:35Z.
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