Closed paulthomson closed 5 years ago
The problem is that dead branch elimination is simplifying the back edge. There is code that is suppose to stop this from happening, but it assumes the back edge is in the continue block, which is not always the case.
Given the following glsl:
I do the following to get optimized and unoptimized spirv, and their disassembly:
The final command fails:
One of the loop headers does not have a back-edge.
I attach the files. shaders.zip