shader: cover all 256 scalar codes in ir::unspill table #28
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: launcher
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
run report
security: hold
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs gpu test
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Androtim--MiniVI!28
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/28/head"
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?
@Androtim on GitHub · 2026-11-28 08:47 UTC · original
Androtim:feat/iter43-ir-scalar-code-bounds→main· +18 −1 · 1 files · 1 commits · closed without mergingSummary
Port
fxceless/victory-fork2f3f399(PR #1495) intocrates/victory-shader/src/ir.rs:usedfrom[false; 128]to[false; 256]insideunspill()soReg::S(c)codes>= 128(constants /NULL) encountered during scalar-parking analysis cannot index past the end of the table and panic.ir::tests::scalar_codes_past_the_registers_do_not_panic.Rig Specs Tested On
Run Settings & Profile
release@c2e1988(targeted shader IR unit-test & static build verification; no runtime behavior change for shaders already within bounds)victory-shader+victory-gpuonwindows-latest)VICTORY_*Overrides: N/AMeasurements & Verification
cargo +1.98.1-x86_64-pc-windows-gnu run -p xtask -- policy(asset policy: 294 files ok)cargo +1.98.1-x86_64-pc-windows-gnu test -p xtask(6 passed; 0 failed)cargo +1.98.1-x86_64-pc-windows-gnu clippy --workspace --all-targets -- -D warnings(0warnings)cargo +1.98.1-x86_64-pc-windows-gnu clippy --workspace --all-targets --features victory-gpu/diagnostics -- -D warnings(0warnings)cargo +1.98.1-x86_64-pc-windows-gnu test -p victory-shader --lib ir::tests(11 passed; 0 failed, includingscalar_codes_past_the_registers_do_not_panic)cargo +1.98.1-x86_64-pc-windows-gnu build --release -p victory(objdump -p:0non-system MinGW DLLs)@Androtim on GitHub · 2026-11-28 10:04 UTC · original
Automated triage for the maintainers (not an approval).
Verdict:
proposed-close· CI (check):passingTechnical Review
crates/victory-shader/src/ir.rs,unspill): Widensusedfrom[false; 128]to[false; 256]soReg::S(c) => used[usize::from(c)] = true(line 336) cannot panic onu8scalar codes>= 128(constants /NULL).usedis only read inplanat lines 544–546 (for c in (0..105).chain(108..=123) { free[c] = !used[c]; }), so widening the array does not alter scratch-register allocation or behavior for in-bounds shaders.ir::tests::scalar_codes_past_the_registers_do_not_panic, which pairsv_writelane_b32 v1, s0, 0(PARK) with three wave32/wave64 instruction encodings throughbuild(&code, wave64, 256). CI is passing.Verdict: Proposed Close (Duplicate of #8)
The patch itself is clean and minimal, and does not require a local GPU test, but it duplicates open PR #8 (
Iter 23: Fix scalar code bounds panic in ir::unspill), which targets the same bounds panic inir::unspill. Recommend closing one of #8 or #28 depending on which branch/history is preferred for merge.Generated with Antigravity CLI (
agy).@Androtim on GitHub · 2026-11-28 21:18 UTC · original
Closing as superseded duplicate of merged PR #8.
Pull request closed