startup: the vector select refuses a negated source operand (2 of 29 loading-screen shader refusals) #1709
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#1709
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?
@triggered02 on GitHub · 2026-11-24 17:34 UTC · original
Found while triaging the refusals in the first main-game loading-screen shader cache (#870). 2 of 29 refused shaders.
Problem
A VOP3
v_cndmask_b32can carry the-source modifier. In an integer instruction that modifier is the source's sign bit flipped — the same bit pattern a float negation produces. The select handler passed the printed operand straight to the uint helper:Fix
The select reads both sources through a small helper that flips the sign bit for a
-operand ((v30 ^ 0x80000000u)) and returns the plain register otherwise, so the no-modifier output is unchanged. The helper is used only where the translation models the modifier: another integer instruction carrying the same-operand still refuses rather than silently flipping a bit.Measured
VOP2-as-VOP3 encodings built in the test (
0b110101prefix, opcode0x100 + 0x01, neg bitsw1[31:29]),mainat68969ed8:v_cndmask_b32_e64 v31, v30, v30(s0 & 1) ? v30 : v30v_cndmask_b32_e64 v31, v30, -v30(s0 & 1) ? (v30 ^ 0x80000000u) : v30v_cndmask_b32_e64 v31, -v30, v30v_and_b32_e64 v1, v30, -v30Census A/B over the local cache (aggregates only): refusals grouped as
operand '-v…'go 2 → 0, and those shaders progress to the next form (v_cvt_pknorm_u16_f32,v_cmp_class_f32).Done when
docs/experiments.mdrecords the accepted form.Not in this slice:
|vN|(absolute) on an integer source, negations on other integer instructions, and proving the loading screen gets further (counts are aggregates only).AI-assisted (Claude Code).