Fix constant island pass's handling of tBR_JTr. The offset of the instruction does...
authorEvan Cheng <evan.cheng@apple.com>
Thu, 22 Jul 2010 02:09:47 +0000 (02:09 +0000)
committerEvan Cheng <evan.cheng@apple.com>
Thu, 22 Jul 2010 02:09:47 +0000 (02:09 +0000)
commitb1c857bb7b3d7bc187de4e97439eb212a8604bf0
treecff281770af99f5481c3c7ec7b0027c64b52adc3
parent624e0b2be6a8db6187206090ee5bc8f24cf55cb7
Fix constant island pass's handling of tBR_JTr. The offset of the instruction does not have to be 4-byte aligned. Rather, it's the offset + 2 that must be aligned since the instruction expands into:
        mov     pc, r1
        .align  2
LJTI0_0_0:
        .long    LBB0_14

This fixes rdar://8213383. No test case since it's not possible to come up with a suitable small one.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109076 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/ARM/ARMConstantIslandPass.cpp