fix(shader): accept clamp on VOP3 16-bit integer min, max and shifts #19337
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/19337"
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 boykopovar/AnyPS5. Originally posted by al3w0f205 on 2026-11-13T04:15:46Z.
What
Accept the VOP3 clamp modifier bit on 16-bit binary integer instructions (
v_mul_lo_u16,v_lshrrev_b16,v_ashrrev_i16,v_max_u16,v_max_i16,v_min_u16,v_min_i16,v_lshlrev_b16) incheckNativeVop3Modifiers()without throwingstd::invalid_argument.Like their packed VOP3P integer counterparts (PR #19190), RDNA2 ignores the clamp bit on 16-bit integer operations.
supportsNativeVop3Clamp(opcode)remainsfalsefor these opcodes, leaving destination clamp unset so execution semantics match hardware behavior.Tested
Vop3Integer16Clamp.cppcovering 32 threads across all 8 instructions with clamp set: verified expected results across all lanes against hardware execution.Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed under Silent stubs in their library's technical debt file.mdfiles or images added to the repository (attach them to this PR)