hwrt: add meshlet IB & quant24 VB decoders, menu switch, and telemetry (#339) #349
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/349"
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-02T15:01:47Z.
Completes Phase 2 Native DXR 1.1 BLAS/TLAS support for #339 on top of #347 (still strictly behind \VICTORY_HW_RT=1, zero RT-off impact):
eadable_len\ / \ itle_readable\ combining \watch::materialize\ + \VirtualQuery\ across lazy placeholder views.
Verification
Adapted from GPL-3.0 upstream \TrustNo1-Coder/Darner.
Imported from Androtim/MiniVI. Originally posted by Androtim on 2026-12-02T15:11:24Z.
Automated triage for the maintainers (not an approval).
Verdict:
needs-gpu-test· CI (check):passingReview Summary
Logic, bounds checking, and isolation look solid, and CI is passing. Because this PR adds D3D12 upload-buffer caching (
cached_meshlet_ib/MeshletCache), DXR 1.1 BLAS geometry decoders (decode_title_meshlet_ib,decode_title_quant24_vb), an in-game menu toggle (VICTORY_HW_RT), and periodic host telemetry (hwrt::report_line), it warrants a local real-GPU smoke test (with PR #347 merged first, since this branch builds on #347).Verified Details
crates/victory-gpu/src/host/menu.rs:VICTORY_HW_RTdefaults toUNSET_ON(off) withlive: false.crates/victory-gpu/src/shader_cache.rs:VICTORY_HW_RT=1/VICTORY_HW_RT_LIFT=0are only hashed into the cache key whencrate::hwrt::requested()is true, avoiding RT-off cache invalidation.crates/victory-gpu/src/host.rs&crates/victory-gpu/src/hwrt.rs:hwrt::report_linereturns immediately when!requested(), and acquires manager locks individually in separate scopes (no lock-ordering hazards).crates/victory-gpu/src/hwrt/decoders.rs):readable_len/title_readablematerialize lazy views viawatch::materializeand verify committed, non-guard, readable pages viaVirtualQuerybefore any raw pointer reads.decode_title_meshlet_ibbounds-checksnum_meshlets,packed_tris_off,vertex_indices_off,meshlet_id, andbase_vi + max_locagainstmax_vi_u16s, supportsflip_winding, and degenerates out-of-range triangles viasane_triangle.decode_title_quant24_vbvalidatesvb_va >= 0x20, checks header/vertex readability and finiteness ofbias/scale, and sanitizes output viasane_position.MeshletCacheenforces the 256 MiB (MESHLET_CACHE_BYTES) budget with generation tracking onforget(called fromtitle_memory_freed), andcached_meshlet_ibcallslist.keep(&entry.buffer)before dropping retired entries outside the cache lock.crates/victory-gpu/src/hwrt.rs):prepare_trianglescaches max scanned indices invalidated_ibs(evicted ontitle_memory_freed) and expandseff_vcwhen the existing non-staged shadow buffer coversexp_bytes, falling back to GPU index clamping otherwise.prepare_trianglesusesstd::slice::from_raw_partsonindex_bufferafter checkinghost_ib.is_multiple_of(isize); this relies on shadow buffer GPU VA preserving alignment modulo 2/4 and assumes no concurrent title CPU writes to the IB during the scan.Local GPU Verification Needed
hardware RT:log lines, and no regression.VICTORY_HW_RT=1(and toggle via the F1/settings menu) on a DXR 1.1 GPU, verifyhardware RT:/hardware RT meshlet index cache:telemetry logs report decoded quant24 VBs and meshlet IBs without device removal, validation errors, or unbounded upload memory growth.Generated with Antigravity CLI (
agy).Imported from Androtim/MiniVI. Originally posted by Androtim on 2026-12-02T17:04:24Z.
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:04:00Z.
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