gpu(device),shader(native): log 0x1c8/0x218 loose pipeline parts and build 0x218 pipelines via VICTORY_LOOSE_PIPELINES=1 #117
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/117"
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-11-29T12:31:32Z.
Summary
0x1c8and0x218incrates/victory-gpu/src/device.rsandcrates/victory-shader/src/native.rs.DXBCcontainers viacrates/victory-shader/src/dxbc.rsandcrates/victory-shader/src/lib.rs, and build0x218compute pipelines whenVICTORY_LOOSE_PIPELINES=1(off by default).loose_compute_parts_make_a_containerandloose_metadata_reads_both_versions.VIctorycommit9a02d21d(GPL-3.0).Verification
cargo +1.98.1-x86_64-pc-windows-gnu xtask policy->asset policy: 303 files okcargo +1.98.1-x86_64-pc-windows-gnu test -p victory-shader --lib --locked -- native::->test result: ok. 18 passed; 0 failed; 0 ignoredcargo +1.98.1-x86_64-pc-windows-gnu test -p victory-shader --lib --locked -- dxbc::->test result: ok. 2 passed; 0 failed; 0 ignoredcargo +1.98.1-x86_64-pc-windows-gnu test -p victory-gpu --lib --locked -- device::->test result: ok. 6 passed; 0 failed; 0 ignored; 0 measured; 550 filtered out; finished in 0.25scargo +1.98.1-x86_64-pc-windows-gnu clippy --workspace --all-targets --locked -- -D warnings->0 warningscargo +1.98.1-x86_64-pc-windows-gnu clippy --workspace --all-targets --features diagnostics --locked -- -D warnings->0 warningsImported from Androtim/MiniVI. Originally posted by Androtim on 2026-11-29T13:03:36Z.
Automated triage for the maintainers (not an approval).
Verdict:
needs-gpu-test· CI (check):passingTechnical Review
CI is passing, and the logic, bounds checks, and unit tests look solid.
Verified details:
crates/victory-shader/src/native.rs:records()cleanly fromfspx_program()with unchanged0x41/0x42/0x43handling.loose_metadata()validates version (2or3), minimum header length (from), and declared size viachecked_addbefore parsing records.loose_compute()validates the0x1c-byte register packet, computes the thread-group product inu64(avoiding overflow) and enforces1..=1024with non-zeroPACKET_RSRC2, slices code safely withcode.get(..dwords * 4), synthesizes the FSPXkind7metadata and container, and round-trip validates it withfspx_program(&fspx)?before wrapping indxbc::build(&[(FourCC::ACCC, &fspx)]).loose_metadata_reads_both_versions,loose_compute_parts_make_a_container,loose_metadata_and_compute_reject_short_metadata,loose_compute_rejects_overflowing_thread_product) cover both versions and malformed/overflowing inputs.crates/victory-gpu/src/device.rs:unknown_pipeline<SLOT>keeps the default path safe (VICTORY_LOOSE_PIPELINES=1is opt-in, off by default), bounds kernel reads to<= 1 MiBviacrate::host::read_into, and logs only on the first 4 and power-of-two calls.VICTORY_LOOSE_PIPELINES=1is set on slot0x218, the local#[repr(C)] Headstruct matchespipeline::ComputeHead(root: This,stage: Bytecode { code: *const u8, size: usize }incrates/victory-gpu/src/pipeline.rs), andcontainerremains live across thepipeline::create_computecall (which copies the container bytes).Minor non-blocking note:
loose_compute,dwords * 4is safe on 64-bit targets (u32 as usize * 4), thoughdwords.checked_mul(4)would make it target-width agnostic.Because this touches GPU device pipeline creation (
0x1c8/0x218) and shader container synthesis, a quick real-GPU smoke test (both default and withVICTORY_LOOSE_PIPELINES=1) is recommended before merging.Generated with Antigravity CLI (
agy).Imported from Androtim/MiniVI. Originally posted by Androtim on 2026-11-29T13:12:15Z.
Addressed the \minivi-triage\ findings at $sha117\ (rebased onto \origin/main\ \
1d0ca527):Imported from Androtim/MiniVI. Originally posted by Androtim on 2026-11-29T14:33:16Z.
Automated RTX 4060 Ti 8 GB Wave 3 A/B hardware verification passed (
playtest/wave3vsorigin/mainc7ed150— 5/5 A/B gates PASS):cargo test(RTX 4060 Ti):victory-gpu542 passed, 0 failed (36 ignored);victory-shader323 passed, 0 Wave 3 regressions (the 3 PSV0 validation failures inemit::rect::testsandemit::barycentric_testsalso fail identically onorigin/mainc7ed150).scripts/verify-world.ps1, DLSS Quality + golden autosave):10.25 fpsvs10.7 fpsbaseline (min FPS improved6.9vs4.2, preparing45.35 msvs50.3 ms)5948 MBvs6073 MB(-125 MB,0 MBover budget)final_waiting=5487vs7350(-1863);no room for new ones38vs43mapped_rate=20.95 ms/svs37.22 ms/s(-44%)frame-10645.png,frame-10669.png), luma82.77vs23.2, edge energy2.27vs1.81, magenta0.0%.