ARM: avoid duplicating branches during constant islands.
authorTim Northover <tnorthover@apple.com>
Thu, 13 Nov 2014 17:58:51 +0000 (17:58 +0000)
committerTim Northover <tnorthover@apple.com>
Thu, 13 Nov 2014 17:58:51 +0000 (17:58 +0000)
commit064da63fcbceb03d9ee6d3f975bba5201558df95
treeee59b022b9b598c9fca84092afc1f392f34082c7
parent5bd311bf17ffbf6a09ed68fbfeee94f6edb5a9a7
ARM: avoid duplicating branches during constant islands.

We were using a naive heuristic to determine whether a basic block already had
an unconditional branch at the end. This mostly corresponded to reality
(assuming branches got optimised) because there's not much point in a branch to
the next block, but could go wrong.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@221904 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/ARM/ARMConstantIslandPass.cpp
test/CodeGen/ARM/constant-islands.ll [new file with mode: 0644]