shader: admit modeled scalar ALU in pixel_aot masked regions #1064
No reviewers
Labels
No labels
accessibility
awaiting author
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
priority: P0
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/R0Y00--Xbox2Windows!1064
Loading…
Reference in a new issue
No description provided.
Delete branch "gh-pr/1064/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?
@romn4rch on GitHub · 2026-11-24 00:01 UTC · original
romn4rch:romn4rch-pixel-aot-scalar-masking→main· +232 −28 · 4 files · 2 commits · merged 2026-11-24 00:37 UTCChange
Implements the narrow scalar-ALU follow-up for #987 (Refs #987). Masked pixel_aot regions now accept only the existing lowerings for
s_mov_b32,s_movk_i32,s_add_i32,s_mul_i32, signeds_cmp_*_i32, ands_cselect_b32, with inputs the scalar tracker can prove. Region-written SGPRs and SCC remain usable within that region but are treated as conditional after restore; reads reject until an unconditional rewrite. Scalar loads and other scalar operations remain refused. Both openers, save-pair checks, and existing empty-wave-skip rules are preserved.Added translation controls, fixture binary round-trip inputs, WARP and hardware CTest entries, and experiment documentation. The draw fixture checks mixed, full, and empty masks and expects the unmasked reference to mismatch.
Verification
& .\out\pe-env\Scripts\python.exe -B tests\pixel_aot_check.py— passed.cmake --build --preset dev --target offscreen_check— passed with the Visual Studio 2022 x64 developer environment loaded bytools/dev.ps1.ctest --preset dev --no-tests=error -R '^pixel_aot_region_scalar_alu_warp$' -V— passed (1/1), Windows 11 build 26300, WARP backend. The deliberate unmasked-reference negative control was detected as a mismatch; no unexpected mismatch occurred.ctest --preset dev --no-tests=error -R '^pixel_aot_region_waits_warp$' -V— passed (1/1), preserving the existing masked-wait stage.& .\out\pe-env\Scripts\python.exe -B tests\docs_links_check.py— passed (15 Markdown files, 237 links).& .\out\pe-env\Scripts\python.exe -B tests\bidi_controls_check.py— passed (889 tracked files checked).git diff --check— passed.llvm-mc,llvm-objcopy, andLLVM-C.dllare unavailable in this environment.Evidence and follow-up
Fixtures are synthetic, source-built instruction sequences in
tests/pixel_aot_check.py; no game files or proprietary binaries are used. WARP readback verifies only these fixtures and does not establish behavior for arbitrary shaders. The LLVM round-trip remains to be run in an environment with LLVM 15 gfx1013 support.Checklist
AI-assisted.
@R0Y00 on GitHub · 2026-11-24 00:18 UTC · original
I resolved the shared scalar-tracker conflict and kept both mask invalidation and masked-region definedness. I also corrected the round-trip fixture: LLVM 15 rejects two distinct literal operands on the same scalar select, so the fixture materializes the same constants before the region. The full LLVM 15 binary suite and all six Windows Release masked-region tests passed on the integrated candidate (RTX 4060 Laptop and WARP).
Candidate:
8e45488a08