[NFCI-ish][SimplifyCFG] FoldBranchToCommonDest(): really don't deal with uncond branches
authorRoman Lebedev <lebedev.ri@gmail.com>
Thu, 21 Jan 2021 20:23:52 +0000 (23:23 +0300)
committerRoman Lebedev <lebedev.ri@gmail.com>
Fri, 22 Jan 2021 14:23:10 +0000 (17:23 +0300)
commitaabed3718ae25476c0f6b7e70c83ba4658f00e5c
tree6f32f3f647c9d12145036b28180055840d6b2a77
parent0895b836d74ed333468ddece2102140494eb33b6
[NFCI-ish][SimplifyCFG] FoldBranchToCommonDest(): really don't deal with uncond branches

While we already ignore uncond branches, we could still potentially
end up with a conditional branches with identical destinations
due to the visitation order, or because we were called as an utility.
But if we have such a disguised uncond branch,
we still probably shouldn't deal with it here.
llvm/lib/Transforms/Utils/SimplifyCFG.cpp