Bound GPU resource pools and preserve held mip levels with tiles #3828
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3828"
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 trustno1-coder/VIctory-NVIDIA. Originally posted by 1mosce on 2026-11-30T08:29:43Z.
Completed uploads kept staging ranges quarantined for another two seconds, tile mode disabled held-level trimming even for ordinary textures, and pressure could repeatedly recreate readback resources. This patch corrects those lifetimes, pools readback ranges, and accounts for actual texture-heap growth across concurrent workers.
Resource-lifetime fixes for review. The resource regressions have targeted coverage and the builds have run in game. Stable target frame times, complete leak freedom, and visual equivalence across city traversal are still unverified. This does not replace the shared-memory/coherency model.
What it changes
docs/readback-arena.md.How it was tested
Base:
41adb55167fa778fcaa5dc36fa18a1fa8dacd657(still upstream main when preparing this PR).Hardware/profile: Windows, RTX 4070 Laptop 8 GiB, 32 GiB system RAM; Series S, 640x360 internal / 1920x1080 output, DLSS Ultra Performance, frame generation off, RT builder off. Optimized Cargo
diagbuilds with and without thediagnosticsfeature. No shader translation changes; wave-size validation is not applicable.cargo check --locked -p victory-gpu --all-features: passed.cargo test --locked -p victory-gpu --features diagnostics -- --test-threads=1: 1008 passed, 2 failed, 66 ignored. The failures arecompose::tests::bgrx_plane_selects_a_typed_viewandshader_cache::tests::every_switch_of_the_translator_is_in_the_key; both were reproduced on clean main..staging_reuses_completed_uploads_without_a_timed_quarantine: passed on the GPU, including pending-copy protection and zeroed reuse after completion.levels_on_demand_on_the_cardandlevels_reuse_resident_tiles_at_budget: passed on the physical GPU with Windows Graphics Tools / D3D12 debug layer, reported tiled-resources tier 4. Heap-reservation coverage also passed on the adapter.git diff --checkand staged asset policy passed (22 text files).Game observations, not a matched FPS A/B: the 15.6-minute walk with the held-mip fix reached 5,412 MiB local usage after warm-up and remained at least 1,242 MiB below the OS budget in that interval; staging ended at 192 MiB. A separate clean-base walk retained 1,408 MiB staging and reached 8,019 MiB local usage against a 6,983 MiB budget. Routes/cameras diverged, so these do not establish a percentage speedup. The final pool-release build completed a short muted smoke run: 4,799 MiB local usage / 7,180 MiB budget at the end, median 16.7 FPS, no untranslated shaders, refused host pipelines or crash-log entries. Runs ended through the harness, on copied saves.
Known checks/limitations: full workspace tests stop at the three BCPack oracle-parity failures also reproduced on clean main. Strict default/all-feature Clippy fails in unchanged upstream code; a warning-only audit is not a passing strict gate. Full-tree asset policy reports the existing hex-literal run in
victory-loader/src/heap_sites/frame_users.rs; the staged patch passes. Dark character textures reproduce on both baseline and candidate. Ground-level city traversal and other GPUs are unverified. Memory growth while visiting new areas is not sufficient evidence either for or against a leak.Checked for overlap
pool.rs; reconcile the alternatives before merging both.KeptSlotsmodule with an identity cache. This patch keeps the existing owner storage and uses occupancy bits plus the locked owner check. These are alternative implementations of the same scan optimization.Implemented and tested with OpenAI Codex. No game assets, executable bytes, captures, shader dumps or private run logs are included.
Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by trustno1-coder on 2026-12-01T18:48:21Z.
Closing this as part of moving main to the texture and video-memory rework (v2026.12.01.01-test). A lot of the code changed, and this pull request no longer applies cleanly to it; it would need to be rewritten against the new main rather than rebased. Thank you for the work. If the change is still needed, please open a new pull request based on the current main.
Pull request closed