Lower scalar byte and halfword sign extension in pixel AOT #527
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/533"
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 R0Y00/Xbox2Windows. Originally posted by descent81 on 2026-11-22T10:01:01Z.
Instructions and observable behavior
This adds the two SOP1 sign-extension forms
s_sext_i32_i8ands_sext_i32_i16to the straight-line pixel translator. Only the low byte or low halfword supplies the sign. Both instructions preserve SCC, so a later conditional select must still observe the condition set before the extension. See the AMD RDNA 2 ISA, integer arithmetic.How the fixture distinguishes mistakes
The shader compares each full 32-bit result with a runtime CPU reference. Python derives the reference by decoding the corresponding low bytes as signed little-endian integers. Two additional output channels independently expose the saved SCC after each width.
The first two rows place the byte and halfword sign bits in opposition. Changing the last row's references to 255 and 65535 must turn both equality channels off while the two SCC channels stay on.
Local verification
aba0555. The fixture exercises two SOP1 mnemonics present in both dashboard references. Aggregate coverage depends on the measured CI run.