Repository navigation
victory-gpu: refresh and route external host textures through one copy - #2726
mgunes1311-lab wants to merge 6 commits into
Conversation
|
Verified the semantics against main:
Tests cover exactly the three risky paths (guarded-page upload, alias first-read, 1/2-plane routing). LGTM. |
DrDarkDK
left a comment
There was a problem hiding this comment.
The alias refresh can still switch host copies mid-recording. host_texture() captures copy, but alias_source() and alias_copy() look up the destination again. If eviction clears the cached host texture after alias_source() picks a writer, alias_copy() can populate a replacement while move_texture() and the return value still use the original copy. The held Arc keeps the original alive, but it doesn’t keep it in the resource cache.
Could the alias lookup and copy use the destination Arc already held by host_texture()? A regression could force eviction between lookup and refresh and check that the returned texture contains the alias writer’s texels.
AI-assisted with Codex.
|
Good catch — threaded the held |
|
Independent WARP/CPU verification for head 14c54b0 against origin/main 13f91ca. State check: open, non-draft, clean merge-tree; no oni-swr comment found. Environment: Windows x64, Rust 1.98.1 (48a229cea 2026-09-01), Windows SDK dxil.dll 10.0.26100.0 (file version 1.8.2502.11); VIctory WARP and D3D12 WARP env vars set. CARGO_TARGET_DIR=D:\victory-warp-2720-target. Commands/results:
Review: no production blocker found in the inspected alias/upload/twin paths. The new eviction regression test currently does not pass with diagnostics enabled, so that configuration needs a test adjustment or explanation. Not tested: physical GPU, retail title/game behavior, release build. AI disclosure: Codex (gpt-6-luna). |
|
Independent Windows 11 + NVIDIA GeForce RTX 5090 + WARP verification and code review of Verification (
|
|
Automated triage for the maintainers. Holding one It is not mergeable as it stands. The What would change the verdict: skip the upload when the alias copy has already run ( Generated by Claude Code |
|
Merged onto current The cause is a semantic conflict with In the same full run, |
|
Updated onto
Re-verified |
Summary
Arc<HostTexture>(resource::host_copy) across use-stamping, content refresh, and state tracking (HostList::move_texture) inexternal::host_texture, preventing concurrent eviction from replacing the host texture between lookup and list state tracking.resource::alias_source->texture::alias_copy) and upload title-written textures (texture::title_written->texture::upload) so host libraries (such asfidelityfxupscaling) sample initialized texels on first use.twin::route: returntwin.planes[0].textureinUNORDERED_ACCESSfor single-plane twins, rejectUNORDERED_ACCESSon multi-plane depth+stencil twins without mutatinglist.twins, and synchronize newer twin writes back into the depth texture before shader or copy reads.capture::note_targetunderdiagnosticswhen an external caller transitions a texture into a write target state.Coordination
Testing
cargo test -p victory-gpu --locked external::tests::(3 synthetic D3D12 GPU tests covering title-written uploads + guarded-page updates, first-read incompatible placed alias copy, and 1-plane/2-plane depth twin routing)cargo test -p victory-hle --test fidelityfx --lockedcargo clippy --workspace --all-targets --all-features --locked -- -D warningscargo run -p xtask --locked -- policy