Mistake: glslc should not do if-optimize for some subgroup op.
- Dominant language
- C++
- Stars
- 2.2k
- Forks
- 445
- Avg merge
- 11h 6m
- Merged PRs (30d)
- 6
Description
Hi, i found glslc may add some if-optimize for && statement.
but somtimes it make error case( Some subgroup-op require all lane in active state), eg code like this:

compiling code is below:

now subgroup-op was placed in if-statement, and may no active in all quad lane, then will case some compute error.
if change the code like this:

now all quad lane can active to compute, and the result is right:

Contributor guide
Assessment
This issue has not been assessed yet.