[llvm] Branch folding: Avoid infinite loop with indirect target blocks (PR #96956)

Andy Kaylor via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 29 10:49:46 PDT 2024


andykaylor wrote:

@v01dXYZ Your analysis makes sense to me. I'm a bit concerned by your remark that analyzeBranch ignores INLINEASM_BR, but I suppose in the case of inline assembly we probably wouldn't eliminate an explicit branch instruction anyway, so maybe placing that block after the block that jumps to it would be of limited value anyway. In any case, that's a separate problem, and you should go ahead with the change you suggested to replace isSuccessor().

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


More information about the llvm-commits mailing list