[llvm] [SPIR-V] Replace assert with report_fatal (PR #118617)

Steven Perron via llvm-commits llvm-commits at lists.llvm.org
Wed Dec 4 04:28:03 PST 2024


s-perron wrote:

I thought this was an analysis/visitor that is intended to visit the blocks in a certain order. It was used to order the blocks, but that had changed. 

If we cannot traverse the block in the expected order, we should issue an error. Algorithms using it could silently do the wrong thing. 

I prefer having a prerequisite the graph must be reducible, and enforcing it. Then it is the callers responsibility to explicitly decide what to do with irreducible graphs.

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


More information about the llvm-commits mailing list