hwrt: add DXR 1.1 BLAS/TLAS registry and XboxBvhBuilder HLE (#339) #347
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/347"
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 Androtim/MiniVI. Originally posted by Androtim on 2026-12-02T14:54:38Z.
Implements the core Phase 2 Native DXR 1.1 infrastructure for #339 behind \VICTORY_HW_RT=1\ (off by default; zero RT-off impact):
Verification
Adapted from GPL-3.0 upstream implementations in \TrustNo1-Coder/Darner\ and
eadmet3xt-lab/foxhound.
Imported from Androtim/MiniVI. Originally posted by Androtim on 2026-12-02T16:04:08Z.
Automated triage for the maintainers (not an approval).
Verdict:
needs-gpu-test· CI (check):passingReview Summary
Solid foundational DXR 1.1 infrastructure for
#339, cleanly gated behindVICTORY_HW_RT=1(off by default). CI is passing, and the lock hierarchy inHwRtManager(blas_table->queue->lru->as_map->shown) is acyclic.Verified Changes
crates/victory-gpu/src/host.rs: Minimal addition ofDeferred::held(Vec<Box<dyn Any + Send>>),HostList::hold,Deferred::resetclamping, andHostList::untouchedcheck.crates/victory-gpu/src/hwrt.rs&crates/victory-gpu/src/hwrt/budget.rs:can_enable/supported) checksD3D12_RAYTRACING_TIER_1_1, SM >= 6.5, andID3D12Device5.BlasQueue/Budget/Backlog), VRAM-budgeted LRU eviction (BlasLru+ GPU instance feedback readback viaFeedback), scratch/workLeasePool, andPERFORM_UPDATErefit parity checks (geom_keys_from_descs).clamp_ib_pso/copy_vb_pso) and TLAS instance VA remapping (remap_pso) withWriteBufferImmediate/EmitRaytracingAccelerationStructurePostbuildInforesponses.Minor Edge Cases Noted
HwRtManager::execute_build(crates/victory-gpu/src/hwrt.rs): When building a TLAS,dst_inst_bufis transitioned fromUNORDERED_ACCESStoNON_PIXEL_SHADER_RESOURCEafter the remap dispatch, but ifself.lease(for TLAS scratch) orself.alloc_or_reuse_as(fordest_as) subsequently returnsNone,execute_buildreturns early without transitioningdst_inst_bufback toUNORDERED_ACCESSbeforeLease::dropreturns it toself.leases. Moving the scratch lease /dest_asallocation ahead of the remap barrier (or restoring the state on early return) would prevent a D3D12 state mismatch on allocation failure.len == 0inhwrt::title_memory_freed(crates/victory-gpu/src/hwrt.rs): Returns early whenlen == 0, whereaswatch::title_memory_freedsupportslen == 0for whole-allocationMEM_RELEASEfrees (unlesswatch.rspasses a resolved byte length).(Note: The PR diff payload was truncated at 120 KB of 171 KB, so
sanitize.rs,xboxbvh.rs, the tail ofbudget.rs, and the small wiring hunks inlib.rs/watch.rs/modules/mod.rswere not directly inspected.)Next Step
Warrants a local real-GPU DXR 1.1 smoke test (both RT-off default and
VICTORY_HW_RT=1) before merging.Generated with Antigravity CLI (
agy).Imported from Androtim/MiniVI. Originally posted by Androtim on 2026-12-02T17:04:20Z.
Holding merge (
triage: needs work) per Deep Static Audit Pass #2 (#282comment7352688269, DXR 1.1 P0/P1 findings #1–#20 routed to#339; note#354must not merge without#357'sshader_cache.rskey isolation #10).Imported from Androtim/MiniVI. Originally posted by Androtim on 2026-12-03T00:03:56Z.
Merged into main (
b0efcacc) via the Audit Pass #5 green-lit superset PR #357 (complete #339 DXR 1.1 RayQuery stack behind VICTORY_HW_RT=1, zero non-RT impact).Pull request closed