[ARM] Make sure that the constant pool does not keep in the middle of an IT block.
authorSimi Pallipurath <simi.pallipurath@arm.com>
Wed, 24 Jul 2019 13:54:14 +0000 (13:54 +0000)
committerSimi Pallipurath <simi.pallipurath@arm.com>
Wed, 24 Jul 2019 13:54:14 +0000 (13:54 +0000)
commit724888af45beb0cb648a340c0640e02166257e19
tree881529b1f44774dbb2f4191b95bd88a741c6712d
parenta19f5a76e6ad511af948192bf728c365870aedf8
[ARM] Make sure that the constant pool does not keep in the middle of an IT block.

This change make sure that llvm does not emit an invalid IT block
by putting the constant pool in the middle of an IT block.

We have code to try to avoid putting a constant island in the middle of an
IT block, but it only works if we see an IT between the one currently
referencing CPE and possible insertion point. If the first instruction
we look at is the VLDRD after the IT , we never see the IT and does not
realize that the instruction doing the load could be in an IT block itself.

Differential Revision: https://reviews.llvm.org/D64621

Change-Id: I24cecb37cded75e8992870bd997f6226853bd920
llvm-svn: 366905
llvm/lib/Target/ARM/ARMConstantIslandPass.cpp
llvm/test/CodeGen/ARM/constant-islands-split-IT.mir [new file with mode: 0644]