Diagnostics: copies up and back by the title's memory protection (VICTORY_WC_STATS=1) #476
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/476"
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 Belobug/VIctory-Belobug-AMD. Originally posted by icecreammule277-dot on 2026-11-27T05:19:31Z.
AI-assisted (Claude Code). Numbers and log lines only.
Diagnostics only, off by default (
VICTORY_WC_STATS=1): copies up to the card and back into title memory, split by the memory protection the title asked for. The split is write-combined (0x400), uncached (0x200) or cached. The console's CPU writes write-combined memory but doesn't read it back, so this shows how much of the copy traffic goes to memory the title never reads.What it does
note_protectionreports every protection the title asks for (victory_gpu::title_memory_protection).wc.rskeeps an interval map of them, where the newest request wins.What it showed
In a heavy scene (about 67 ms a frame), copy-back was 46.2 MB a frame, 100% of it into write-combined memory. Copy-up was 79 MB, 85% write-combined. That's the basis for the follow-up PR, which leaves shaders' writes to such memory on the card.
Tests
cargo test -p victory-gpu --lib -- wc::covers the newest request cutting older ranges, and the protection bits picking the kind. Built with--profile diag --features diagnostics.🤖 Generated with Claude Code
Imported from Belobug/VIctory-Belobug-AMD. Originally posted by MamaLeVrai on 2026-11-27T07:01:48Z.
Tested on an RX 6950 XT (RDNA 2), driver 32.0.21045.29003, Windows 11 build 26300, Rust 1.98.1, release. At
a78f788:victory-gpu398 passed, 0 failed, 34 ignored;victory-hle162 passed, 0 failed, 2 ignored.AI-assisted (Claude Code); no game data.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.