Shaders: lower scalar byte and halfword sign extension #182
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/fxceless--victory-fork!182
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-182"
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?
@GeaorgeAyvazov on GitHub · 2026-11-24 22:17 UTC · original
GeaorgeAyvazov:shader/scalar-sign-extension→main· +50 −0 · 2 files · 1 commits · openThe GFX10 decoder recognizes S_SEXT_I32_I8 and S_SEXT_I32_I16 but lowering rejects them. Reuse the byte/word selection helper to sign-extend the low byte or halfword into the scalar destination. AMD RDNA 2 ISA section 5.4 specifies that both preserve SCC.
The regression translates synthetic GFX10 compute shaders and reads the result back from a UAV. Six input words cover both sign boundaries and discarded high bits. Each runs with both incoming SCC states, consumed by a following scalar select. Before the patch the test stopped at Unsupported s_sext_i32_i8. The focused test passed on the RTX 3070 Ti Laptop and Intel Iris Xe using temporary explicit DXGI adapter selection and the hardware/WARP harness. The full shader library suite reported 204 passed, 7 failed, 2 ignored, with the same seven failures recorded on the base emitter. No game assets or title-level claims.
Implemented and tested with OpenAI Codex.
View command line instructions
Manual merge helper
Use this merge commit message when completing the merge manually.
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.