shader: lower v_cvt_norm_i16_f16 and v_cvt_norm_u16_f16 in direct Compute and Pixel DXIL #3293
Labels
No labels
accessibility
awaiting author
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
priority: P0
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/R0Y00--Xbox2Windows#3293
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
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?
@legacy-code-archaeologist on GitHub · 2026-11-28 05:34 UTC · original
Refs #2935.
Lower VOP1 (
0x63/0x64) and VOP3 (0x1e3/0x1e4)v_cvt_norm_i16_f16andv_cvt_norm_u16_f16inDirectCompute::float_alu()(src/gfx1013_direct_compute.inl) for both direct Compute and Pixel DXIL:tools/pixel_aot.py::f16_cvt_norm_result(round_rne(clamp(x, -1, 1) * 32767)andround_rne(clamp(x, 0, 1) * 65535)), avoiding binary32 double-rounding on0x3801..0x3804/0xb801..0xb802and preserving binary16 subnormals.NaN -> 0,+Inf -> +32767/65535,-Inf -> -32767/0.abs[0],neg[0],op_sel[0](high-half VGPR read),op_sel[3](high-half write preserving unwritten half), and VGPR / SGPR / literal / inline-constant sources under the strict((mode_bits ^ 0xf0u) & 0x8000ccu)binary16 mode gate, while refusingclamp,omod, unused modifier bits, high-halfop_selon non-VGPR sources, DPP/SDWA, special scalar sources, and dynamic/flush binary16 modes.AI-assisted.