GPU: refresh view-memory textures that host-side writers changed #438
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!438
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-438"
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?
@sennecools on GitHub · 2026-11-25 00:49 UTC · original
sennecools:contrib/view-memory-refresh→main· +659 −52 · 10 files · 1 commits · draftA texture in view memory is guarded (read-only, a write faults once) and otherwise hashed only every eighth frame, so writes the guard does not see leave it up to eight frames stale. Two such writers were unseen: the title filling physical pages through its pool while the same pages are sampled through its tiled heap, and the runtime writing physical pages through views of its own (DirectStorage page destinations, xmem
write_physical).Changes
VICTORY_GUARD_ALIASES=0turns this off).physical_written.kernel_will_writereturns a hold: the blocks are not guarded again (through either view) until the kernel write is done;write_mappedtakes it itself.Why: with
VICTORY_TEXTURE_GUARD=0(hash every check) orVICTORY_KEEP_VIEWS=0, flickering tiles in the intro went from 317 to 2 of 480, so stale content was the cause.Testing
diagnostics; clippy clean.Known limits: a runtime writer that neither faults nor reports (possibly the media code) stays unseen; an overlapped
ReadFileis held only until it is started.AI-assisted (Claude Code)
Draft: it is in our combined build and ran in the game without problems, but its effect on the flicker has not been measured yet.
AI-assisted.
@Fimpos on GitHub · 2026-11-25 01:54 UTC · original
Tested on RTX 5070 12 GB (Windows 11 25H2, driver 621.24) on top of
c96b4f2with VICTORY_RELAY=2 (plus #206, #410, #451, #457, #460, #462, #481, #139):@Pin0d1 on GitHub · 2026-11-25 09:03 UTC · original
@sennecools, @Revens2 pointed me here from #555. Both PRs have the same head,
5af49b5. I reran the three tests on the test-only commit, whose parent is that exact head.A write through a sibling mapping produced 0x11223344 in both independent GPU readbacks. Both journal consumers saw the same write, and the synchronous four-byte file read returned TEST while another holder covered part of its destination. All three passed in two fresh processes per adapter setting on Windows. The command is
cargo test --locked -p victory-gpu --lib watch:: -- --test-threads=1.Prepared with the help of Codex 6.2 Astra Max.
View command line instructions
Manual merge helper
Use this merge commit message when completing the merge manually.
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.