diff options
author | Quentin Colombet <qcolombet@apple.com> | 2013-04-26 17:54:54 +0000 |
---|---|---|
committer | Quentin Colombet <qcolombet@apple.com> | 2013-04-26 17:54:54 +0000 |
commit | 1ad3a410beff11913db0573942fb51b651d01a13 (patch) | |
tree | 326f9e57d272f1977ee94dccdd59171a938b8afe /lib/Target/ARM/ARMInstrInfo.td | |
parent | 140536b936a59b359606dbca7b30d5d16472195a (diff) | |
download | external_llvm-1ad3a410beff11913db0573942fb51b651d01a13.zip external_llvm-1ad3a410beff11913db0573942fb51b651d01a13.tar.gz external_llvm-1ad3a410beff11913db0573942fb51b651d01a13.tar.bz2 |
ARM: Fix encoding of hint instruction for Thumb.
"hint" space for Thumb actually overlaps the encoding space of the CPS
instruction. In actuality, hints can be defined as CPS instructions where imod
and M bits are all nil.
Handle decoding of permitted nop-compatible hints (i.e. nop, yield, wfi, wfe,
sev) in DecodeT2CPSInstruction.
This commit adds a proper diagnostic message for Imm0_4 and updates all tests.
Patch by Mihail Popa <Mihail.Popa@arm.com>.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@180617 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/ARM/ARMInstrInfo.td')
-rw-r--r-- | lib/Target/ARM/ARMInstrInfo.td | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/Target/ARM/ARMInstrInfo.td b/lib/Target/ARM/ARMInstrInfo.td index 8aa608b..5d5380f 100644 --- a/lib/Target/ARM/ARMInstrInfo.td +++ b/lib/Target/ARM/ARMInstrInfo.td @@ -582,7 +582,11 @@ def Imm0_3AsmOperand: ImmAsmOperand { let Name = "Imm0_3"; } def imm0_3 : Operand<i32> { let ParserMatchClass = Imm0_3AsmOperand; } /// imm0_4 predicate - Immediate in the range [0,4]. -def Imm0_4AsmOperand : ImmAsmOperand { let Name = "Imm0_4"; } +def Imm0_4AsmOperand : ImmAsmOperand +{ + let Name = "Imm0_4"; + let DiagnosticType = "ImmRange0_4"; +} def imm0_4 : Operand<i32>, ImmLeaf<i32, [{ return Imm >= 0 && Imm < 5; }]> { let ParserMatchClass = Imm0_4AsmOperand; let DecoderMethod = "DecodeImm0_4"; |