GPU: textures the host refused for lack of memory are tried again, a bounded number of times #241
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/241"
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 fxceless/victory-fork. Originally posted by fffluffy-dev on 2026-11-24T22:58:51Z.
When
host_texturefailed, the texture was marked refused for good, and a failed slot still counted as made, so it read zeros (black) for the rest of the run even after memory freed. Marvisak/VIctory#1226 showsE_OUTOFMEMORY(0x8007000E) on ordinary textures under commit pressure; #109 shows an 8 GB card at its budget.E_OUTOFMEMORYis retried: after 1 s, doubling, at most 8 more tries (the last about 4 minutes after the first), then given up as before. Every other failure (E_INVALIDARG, anyDXGI_ERROR_DEVICE_*, no code) keeps today's behaviour, and a device removal on a later try ends the retries.refused_for_nowin descriptor/host.rs): it is remade when the texture is made, read through a table, or looked at again by the picked-by-index pass 16 frames later.REFUSALScounts refusals, permanent refusals, late successes and give-ups (not printed yet); "host texture made on a later try" is logged once per recovery.Not covered: depth twins, and slots picked by index with
VICTORY_LAZY_TEXTURES=0.Validation (cargo-xwin, tests under Wine):
cargo test -p victory-gpu111 passed, 1 ignored, new testonly_a_lack_of_memory_is_tried_again_and_not_for_ever; clippy clean both ways; policy ok. Not run on a card under memory pressure.AI use: written with Claude Code (Claude Opus 5.5); reviewed and posted with my approval. No game files were used.
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.