Commit Graph

1 Commits

Author SHA1 Message Date
2382568082 rdna2spirv: sign-extend an SDWA source with shifts, not OpBitFieldSExtract (SHADER-SDWA-SEXT-SHIFTS)
On an RTX 4050 Laptop (NVIDIA 621.01) a sext() SDWA source feeding
v_cvt_f32_u32 was converted as signed: v1 = 0x4fbdc08a with src0_sel:BYTE_2
gave -67.0 where the reference model has 0x4f800000. 7 of 400
v_cvt_f32_u32 programs differed; with two shifts (left, then arithmetic
right) the same 400 match, and so do the 4,500 programs of three full
sdwa_diff seeds except one unrelated f16 compare. The bits are the same
as before; the CPU interpreter agrees with the model either way.

Adds tests/semantic/test_sdwa_sext_source.py (every selector, nine values,
no OpBitFieldSExtract in the output), moves the two test_mutations anchors
that named the changed lines, and records the finding in the SDWA row of
docs/design.md.
2026-11-25 12:14:14 -03:00