OSDN Git Service

[ARM] Diagnose PC-writing instructions in IT blocks
authorOliver Stannard <oliver.stannard@arm.com>
Tue, 28 Feb 2017 10:04:36 +0000 (10:04 +0000)
committerOliver Stannard <oliver.stannard@arm.com>
Tue, 28 Feb 2017 10:04:36 +0000 (10:04 +0000)
commitc492675c31a54f2ef7b2f26c288f9f7432e05ad1
tree47ba52cb4b952672f2d1b2533ec1570ee156d2ce
parent76b7c3efa92357a3b328231b205d22ce5c86704c
[ARM] Diagnose PC-writing instructions in IT blocks

In Thumb2, instructions which write to the PC are UNPREDICTABLE if they are in
an IT block but not the last instruction in the block.

Previously, we only diagnosed this for LDM instructions, this patch extends the
diagnostic to cover all of the relevant instructions.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@296459 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/ARM/AsmParser/ARMAsmParser.cpp
test/MC/ARM/arm-thumb-trustzone.s
test/MC/ARM/basic-thumb2-instructions.s
test/MC/ARM/unpred-control-flow-in-it-block.s [new file with mode: 0644]