[llvm] [SimplifyCFG] Hoist out implied conditions from successor (PR #158773)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Tue Sep 16 02:21:37 PDT 2025
https://github.com/nikic requested changes to this pull request.
It looks like currently you are just looking for any icmp inside the block and hoisting it. This is not correct: It needs to be connected to the control flow in a specific way. Hoisting the condition means that the branch is executed in fewer cases, and you need to make sure that's fine.
(As a trivial counter example, consider the case where the block just contains a completely unused icmp.)
https://github.com/llvm/llvm-project/pull/158773
More information about the llvm-commits
mailing list