diff options
| author | Jim Grosbach <grosbach@apple.com> | 2011-07-13 19:24:09 +0000 |
|---|---|---|
| committer | Jim Grosbach <grosbach@apple.com> | 2011-07-13 19:24:09 +0000 |
| commit | e255be93a897a8369d12fc53efed76865b8d8c10 (patch) | |
| tree | 29719345d858ff9eef6aef56bee6b36111aa8168 /llvm/lib | |
| parent | c8b3619773507229156e35b14bca591aefd27b3a (diff) | |
| download | bcm5719-llvm-e255be93a897a8369d12fc53efed76865b8d8c10.tar.gz bcm5719-llvm-e255be93a897a8369d12fc53efed76865b8d8c10.zip | |
Give the ARM BKPT instruction the right operand type.
The immediate is of limited range and the operand type should reflect that.
llvm-svn: 135066
Diffstat (limited to 'llvm/lib')
| -rw-r--r-- | llvm/lib/Target/ARM/ARMInstrInfo.td | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/llvm/lib/Target/ARM/ARMInstrInfo.td b/llvm/lib/Target/ARM/ARMInstrInfo.td index 4760459e1eb..10410a54e66 100644 --- a/llvm/lib/Target/ARM/ARMInstrInfo.td +++ b/llvm/lib/Target/ARM/ARMInstrInfo.td @@ -255,9 +255,8 @@ def lo16AllZero : PatLeaf<(i32 imm), [{ return (((uint32_t)N->getZExtValue()) & 0xFFFFUL) == 0; }], hi16>; -/// imm0_65535 predicate - True if the 32-bit immediate is in the range -/// [0.65535]. -def imm0_65535 : ImmLeaf<i32, [{ +/// imm0_65535 - An immediate is in the range [0.65535]. +def imm0_65535 : Operand<i32>, ImmLeaf<i32, [{ return Imm >= 0 && Imm < 65536; }]>; @@ -1174,8 +1173,8 @@ def SEV : AI<(outs), (ins), MiscFrm, NoItinerary, "sev", "", // The i32imm operand $val can be used by a debugger to store more information // about the breakpoint. -def BKPT : AI<(outs), (ins i32imm:$val), MiscFrm, NoItinerary, "bkpt", "\t$val", - []>, Requires<[IsARM]> { +def BKPT : AI<(outs), (ins imm0_65535:$val), MiscFrm, NoItinerary, + "bkpt", "\t$val", []>, Requires<[IsARM]> { bits<16> val; let Inst{3-0} = val{3-0}; let Inst{19-8} = val{15-4}; |

