Shaders/structure: require masks in scc_some, active, and wave_any to… #514
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/fxceless--victory-fork!514
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-514"
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?
@pug205gti6 on GitHub · 2026-11-25 01:56 UTC · original
pug205gti6:pr/445-shaders-structure→main· +127 −9 · 1 files · 1 commits · open… vanish outside block reach
In
structure::Builder::finish:scc_someexported every non-scc_everyentry ofscc_lanewithout checking that the mask is 0 in lanes not reaching its defining blockb(cond[b]). BecauseLower::scc_someevaluateswaveAnyTrueover only the lanes runningb, masks with set bits in inactive lanes (such ass_not_b32 s2, exec_lo,s_cmp_lg_u32 exec_lo, -1, ors_andn2_b32 s2, s_outer, exec_loinside a divergent branch) returnedfalseinstead of hardwareSCC = 1.activecould retain a widenedEXEC(e.g.s_or_saveexec_b32 s5, -1) written inside a divergent block even though lanes outsidecond[b]do not participate inb'swaveActiveBallot.wave_any[b]advertised wave-widewaveAnyTrue/waveAllTruelowering even when a lane outsidecond[b]could decide the branch.branch()needlessly ANDedvccwithexecons_cbranch_vccz/s_cbranch_vccnz(only a no-op becauses_cbranch_vcczomitsEXECfrominst.reads).Enforce
implies(m, cond[b])(or uniform support) when populatingscc_some, pruningactive, and validatingwave_any[b], simplifys_cbranch_vccz/vccnz, and add synthetic unit tests.@Revens2 on GitHub · 2026-11-25 07:36 UTC · original
Duplicate of #445: @AscilCH opened this patch 64 minutes earlier, and
gh pr diffreturns the same bytes for both (+127/-9 on 1 file(s), same title).Please continue in #445 so the review history and any test data stay in one place.
Thanks.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.