[llvm] [SPIR-V] Fix block sorting with irreducible CFG (PR #116996)

Steven Perron via llvm-commits llvm-commits at lists.llvm.org
Fri Nov 22 06:02:56 PST 2024


s-perron wrote:

> What's important in such case is that loops belongs before the exit node.

Why is this important? I thought that was part of the spec, but I cannot find it. Is it part of how the structurizer is implemented?

For changes to this PR, you should update the comments in SPIRVUtils.h to mention the case where it might fail to give a topological order, and why it does not matter. There should be an assert that when it fails we do not need to run the structurizer (we are not compiling for Vulkan).

https://github.com/llvm/llvm-project/pull/116996


More information about the llvm-commits mailing list