Skip to content

GPU/draw: skip repeated output target bindings - #1215

Open
nicolasveilleux wants to merge 1 commit into
fxceless:mainfrom
nicolasveilleux:perf/reuse-output-target-binds
Open

nicolasveilleux wants to merge 1 commit into
fxceless:mainfrom
nicolasveilleux:perf/reuse-output-target-binds

Conversation

@nicolasveilleux

Copy link
Copy Markdown

Skip redundant output-target binds when the ordered color views and the depth view match the last binding on this command-list recording. Match original descriptor contents and retained host resource identities, not the title's descriptor handles. Keep normal binding for changed views, invalidate on replay and reset, and leave the experiment off by default (VICTORY_REUSE_TARGET_BINDS=1).

Adapted from avatarmanz/VIctory-7900XTX ca1d519, inspired by FQY55kai/ZJOU-VICTORY acf478b8.

Validation

Native Windows 11 / i7-10700F / RTX 2070 Super:

  • Target-binding regression passed with typed null RTVs, including rewriting the descriptor at the same address, changing target order, unbinding and replaying.
  • Isolated recording and submission benchmark, 20 paired samples after warmup. For 1 / 1,024 / 16,384 identical typed null RTV requests, median times were 0.0812 -> 0.0819 / 0.2074 -> 0.1032 / 2.5502 -> 0.4571 ms. The repeated workload recorded one native bind with the option enabled.
  • Public code and synthetic fixtures only. No measured effect on gameplay FPS.

Adapt avatarmanz/VIctory-7900XTX ca1d519f18ccece3daf2b05191a43fae17ac6f91, itself inspired by FQY55kai/ZJOU-VICTORY acf478b8. Compare actual view descriptions and retained host identities, not title descriptor handles. Keep opt-in and avoid temporary heap allocation on cache hits.

Copy link
Copy Markdown

I tested this alongside #1212 on an RX 7900 XT, Ryzen 7 9700X, RADV 26.3.1 and Wine 11.22. Both runs used the same binary, including #1200, and reached the first room. With target-bind and root-CBV reuse on, it counted 699 accepted presents in 73.92 s (9.46 FPS). With both off it counted 731 in 73.57 s (9.94 FPS). One pair on a shared desktop leaves the frame-time effect unresolved.

Across the measured intervals, the enabled build skipped 7,689 target binds and recorded zero root-CBV cache hits. Pipeline retention stayed enabled on both sides. The target-rewrite and command-list replay test passed on the physical adapter. For anyone combining these with the retained-capacity reset from #1059, both new recording caches need clearing on reset. Tested source and counters.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants