GPU: do not wait for title-memory remaps when refreshing textures by default #393
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/fxceless--victory-fork!393
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/393/head"
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?
@relativespace2K on GitHub · 2026-11-25 00:19 UTC · original
relativespace2K:texture-no-wait-default→main· +36 −10 · 2 files · 1 commits · closed without mergingWhat
VICTORY_TEXTURE_NO_WAITis now on by default: a texture refresh asks for the title-memory mapping lock without waiting. If the runtime is remapping, it reads through the kernel instead (or leaves the texture for its next refresh, a frame later); it never reads a partly mapped texture.VICTORY_TEXTURE_NO_WAIT=0restores the old waiting behaviour.This follows the proposal in #178 (RX 7900 XT, RADV) with a second AMD data point on native Windows D3D12.
Measurements
Machine: RX 6800 XT 16 GB (RDNA2), driver 32.0.21045.29003, Ryzen 5 5600, 32 GB, Windows 11 26100, Series X profile, diagnostics build, 1920x1080.
Opening cutscene, same phase, warm shader cache:
VICTORY_TEXTURE_NO_WAIT=1The texture line names the wait as the whole cost:
texture refreshes per frame ... 0.0 ms waiting for title memory to hold stillwith the switch, against seconds without it.Prologue (same checkpoint, 180 s runs):
VICTORY_TEXTURE_NO_WAIT=0The large win is while the world is streaming in; once the prologue settles the wait is small, so the default does not change the steady state much there. The run reached the prologue with ~5,000 draws/frame, ~17 GB working set and no device loss.
Checks
cargo test --workspace --locked -- --test-threads=1: 497 passed, 0 failed, 7 ignored.cargo clippy -p victory-gpu --all-targets --locked -- -D warnings: clean.cargo xtask policy: 169 files ok.texture::title_memory_tests::texture_refreshes_do_not_wait_unless_asked_tocovers the unset/1/0parsing.No game files, shaders or captures are included; the runs were on the reporter's own copy.
AI-assisted: the patch and the runs above were made with an AI agent on my machine; I reviewed the result and the logs.
Refs #178.
@relativespace2K on GitHub · 2026-11-25 01:06 UTC · original
Superseded by #175, which fixes the root cause by scoping the mapping lock to the affected ranges and keeping the in-place texture read. I validated #175 on an RX 6800 XT (Windows 11, native D3D12): mapping wait median 0.0 ms and max 35.5 ms over 107 windows, against a 7,886.5 ms worst window before; prologue at 1.2-1.5 fps with no device loss. Details in #175. Closing this in favor of #175.
Pull request closed