Skip to content

shader: lower ds_nop in pixel_aot - #853

Merged
R0Y00 merged 2 commits into
R0Y00:mainfrom
stan495:codex/gfx1030-ds-nop
Nov 23, 2026
Merged

R0Y00 merged 2 commits into
R0Y00:mainfrom
stan495:codex/gfx1030-ds-nop

Conversation

@stan495

@stan495 stan495 commented Nov 23, 2026

Copy link
Copy Markdown
Contributor

Change

Lower operandless ds_nop in the straight-line pixel profile. Keep the program-end, color-export and immediate DS swizzle wait guards ahead of the new handling. Reuse the gfx1030 wave64 swizzle fixture to exercise the instruction at entry and under whole-quad EXEC.

Verification

Tested 3d84719 based on 34d03c7. With LLVM 15.0.7, the source-built round trip verified the leading eight-byte encoding and decoded both ds_nop instructions. The Python controls matched the HLSL generated with s_nop 0 at the same positions and rejected operands, GDS, an offset, post-export and post-end placements, and a ds_nop inserted before a required wait. Before the change, the new positive control raised Unsupported instruction 0: ds_nop.

On Windows 11 25H2 build 26200.9974 and DXC 1.8.2502.11, both program variants matched all 256 UINT channel words against the CPU oracle on WARP (10.0.26100.9818) and Radeon RX 7900 XTX (32.0.32029.2010). The D3D12 debug layer reported zero errors and warnings. Both backends caught the existing blue-channel mutation at (0, 0), with 0x3e400000 expected and 0x3d800000 observed. CTest passed 3/3 with zero skips. The targeted coverage report recorded 2/123 gfx1030 DS forms, including ds_nop.

.\tools\dev.ps1
$env:XBOX2WINDOWS_ADAPTER = '7900 XTX'
cmake --preset dev
cmake --build --preset dev --target offscreen_check
ctest --preset dev --no-tests=error -R '^(pixel_aot_ds_swizzle_(warp|hardware)|pixel_aot_warp)$' --output-junit "$PWD/out/results.xml" -V
python -B tests/pixel_aot_check.py
python -B tests/form_coverage_check.py
python -B tests/docs_links_check.py
python -B tests/bidi_controls_check.py
python -B tools/form_coverage.py out/results.xml --json out/coverage.json
git diff --check origin/main...HEAD
python3 -B tests/pixel_aot_check.py binary llvm-mc-15 llvm-objcopy-15 libLLVM-15.so.1
LLVM_LIB=libLLVM-15.so.1 LLVM_MC=llvm-mc-15 LLVM_OBJCOPY=llvm-objcopy-15 python3 -B tests/rdna2_tools_check.py

The LLVM-enabled disassembler suite passed 72/72. The tests use source-built fixtures and measure desktop translation.

AI-assisted (Codex and DeepSeek Harness).

@R0Y00

R0Y00 commented Nov 23, 2026

Copy link
Copy Markdown
Owner

I refreshed the branch in b99e8b5 after #651 changed the shared LLVM round-trip assertions. The test preserves both the branch offsets and the DS NOP encoding/count checks. On Windows 26200.9974, WARP 10.0.26100.9818 and RTX 4060 Laptop driver 32.0.16.1656 each matched both 256-word variants and caught the blue-channel mutation. The debug layer reported zero errors and warnings. LLVM 15 and form coverage passed. GitHub CI is running.

@R0Y00
R0Y00 enabled auto-merge November 23, 2026 13:45
@R0Y00
R0Y00 merged commit d4620fd into R0Y00:main Nov 23, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants