From 418d1d954daf87965757f5aa5bf8d546d3e40a82 Mon Sep 17 00:00:00 2001 From: Anton Korobeynikov Date: Sat, 15 May 2010 17:19:20 +0000 Subject: [PATCH] "trap" pseudo-op turned out to be apple-local. Temporary emit it as raw bytes until it will be added to binutils as well. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@103878 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/ARM/ARMInstrInfo.td | 5 ++++- lib/Target/ARM/ARMInstrThumb.td | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/lib/Target/ARM/ARMInstrInfo.td b/lib/Target/ARM/ARMInstrInfo.td index 29c474703d3..5969d9430c8 100644 --- a/lib/Target/ARM/ARMInstrInfo.td +++ b/lib/Target/ARM/ARMInstrInfo.td @@ -791,8 +791,11 @@ def DBG : AI<(outs), (ins i32imm:$opt), MiscFrm, NoItinerary, "dbg", "\t$opt", } // A5.4 Permanently UNDEFINED instructions. +// FIXME: Temporary emitted as raw bytes until this pseudo-op will be added to +// binutils let isBarrier = 1, isTerminator = 1 in -def TRAP : AXI<(outs), (ins), MiscFrm, NoItinerary, "trap", [(trap)]>, +def TRAP : AXI<(outs), (ins), MiscFrm, NoItinerary, + ".long 0xe7ffdefe @ trap", [(trap)]>, Requires<[IsARM]> { let Inst{27-25} = 0b011; let Inst{24-20} = 0b11111; diff --git a/lib/Target/ARM/ARMInstrThumb.td b/lib/Target/ARM/ARMInstrThumb.td index f62de94e5b4..07238d4386a 100644 --- a/lib/Target/ARM/ARMInstrThumb.td +++ b/lib/Target/ARM/ARMInstrThumb.td @@ -419,8 +419,11 @@ def tSVC : T1pI<(outs), (ins i32imm:$svc), IIC_Br, "svc", "\t$svc", []>, // A8.6.16 B: Encoding T1 // If Inst{11-8} == 0b1110 then UNDEFINED +// FIXME: Temporary emitted as raw bytes until this pseudo-op will be added to +// binutils let isBarrier = 1, isTerminator = 1 in -def tTRAP : TI<(outs), (ins), IIC_Br, "trap", [(trap)]>, Encoding16 { +def tTRAP : TI<(outs), (ins), IIC_Br, + ".word 0xdefe @ trap", [(trap)]>, Encoding16 { let Inst{15-12} = 0b1101; let Inst{11-8} = 0b1110; }