shader: read constant operands of v_pk_fmac_f16 #117
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/117"
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 LakshanSivakumar/Native-Victory-macOS. Originally posted by Olima34 on 2026-11-26T17:18:43Z.
One of the #4 shapes:
v_pk_fmac_f16constant (2 refusals in the latest story-load run).What.
v_pk_fmac_f16(VOP2, noop_sel) with a constant source was refused ("a constant operand of v_pk_fmac_f16").fmac_halfnow reads the operand through the existingf16_operand, as the VOP3P path (packed_src) already does. The constant is the 32-bit value its two halves come from:Source. AMD's ISA text does not say this. LLVM's assembler does:
llvm-mc -mcpu=gfx1030encodes0x3c00as the inline1.0but needs a literal for0x3c003c00, and encodes0xffffffffas-1but0xffffas a literal. Written up in docs/native-host.md.Tests.
packed_fmac_takes_constant_operands(gfx_refusal): inline float, inline integer and literal sources translate. Refused without the change.packed_fmac_reads_constant_halves(valu_tests, Windows GPU/WARP): checks the values, an inline 1.0 multiplying the low halves alone and a literal giving each half its own factor.victory-shader tests, Windows clippy and
cargo xtask policypass.Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by LakshanSivakumar on 2026-11-26T18:09:48Z.
Merged, thanks. Constant operands of
v_pk_fmac_f16now translate, with a GPU value test.