shader: read constant operands of v_pk_fmac_f16 #117
No reviewers
Labels
No labels
accessibility
bug
claimed
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
tester report
urgent
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/LakshanSivakumar--Native-Victory-macOS!117
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-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?
@Olima34 on GitHub · 2026-11-26 17:18 UTC · original
Olima34:fix/shader-pk-fmac-constants→main· +65 −6 · 4 files · 1 commits · merged 2026-11-26 18:09 UTCOne 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.@LakshanSivakumar on GitHub · 2026-11-26 18:09 UTC · original
Merged, thanks. Constant operands of
v_pk_fmac_f16now translate, with a GPU value test.