let Inst{21} = 1; // overwrite
let Inst{19-16} = addr;
let Inst{11-0} = !if(has_offset, offset{11-0}, 0);
- let DecoderMethod = "DecodeAddrMode2IdxInstruction";
}
def LDRT_POST_IMM
: LDRTImmediate<1, "\t$Rt, $addr, $offset",
- (ins addr_offset_none:$addr, am2offset_imm:$offset)>;
+ (ins addr_offset_none:$addr, am2offset_imm:$offset)> {
+ let DecoderMethod = "DecodeAddrMode2IdxInstruction";
+}
+
def LDRT_POST_IMM_0
: LDRTImmediate<0, "\t$Rt, $addr", (ins addr_offset_none:$addr)>;
let Inst{21} = 1; // overwrite
let Inst{19-16} = addr;
let Inst{11-0} = !if(has_offset, offset{11-0}, 0);
- let DecoderMethod = "DecodeAddrMode2IdxInstruction";
}
def LDRBT_POST_IMM
: LDRBTImmediate<1, "\t$Rt, $addr, $offset",
- (ins addr_offset_none:$addr, am2offset_imm:$offset)>;
+ (ins addr_offset_none:$addr, am2offset_imm:$offset)> {
+ let DecoderMethod = "DecodeAddrMode2IdxInstruction";
+}
+
def LDRBT_POST_IMM_0
: LDRBTImmediate<0, "\t$Rt, $addr", (ins addr_offset_none:$addr)>;
let Inst{21} = 1; // overwrite
let Inst{19-16} = addr;
let Inst{11-0} = !if(has_offset, offset{11-0}, 0);
- let DecoderMethod = "DecodeAddrMode2IdxInstruction";
}
def STRBT_POST_IMM
: STRBTImmediate<1, "\t$Rt, $addr, $offset",
- (ins GPR:$Rt, addr_offset_none:$addr, am2offset_imm:$offset)>;
+ (ins GPR:$Rt, addr_offset_none:$addr, am2offset_imm:$offset)> {
+ let DecoderMethod = "DecodeAddrMode2IdxInstruction";
+}
+
+
def STRBT_POST_IMM_0
: STRBTImmediate<0, "\t$Rt, $addr", (ins GPR:$Rt, addr_offset_none:$addr)>;
let Inst{21} = 1; // overwrite
let Inst{19-16} = addr;
let Inst{11-0} = !if(has_offset, offset{11-0}, 0);
- let DecoderMethod = "DecodeAddrMode2IdxInstruction";
}
def STRT_POST_IMM
: STRTImmediate<1, "\t$Rt, $addr, $offset",
- (ins GPR:$Rt, addr_offset_none:$addr, am2offset_imm:$offset)>;
+ (ins GPR:$Rt, addr_offset_none:$addr, am2offset_imm:$offset)> {
+ let DecoderMethod = "DecodeAddrMode2IdxInstruction";
+}
+
def STRT_POST_IMM_0
: STRTImmediate<0, "\t$Rt, $addr", (ins GPR:$Rt, addr_offset_none:$addr)>;
}
--- /dev/null
+# RUN: llvm-mc -triple armv7 -show-encoding -disassemble < %s | FileCheck %s
+
+0x00 0x10 0xb0 0xe4
+0x00 0x10 0xf0 0xe4
+0x00 0x10 0xa0 0xe4
+0x00 0x10 0xe0 0xe4
+
+# CHECK: ldrt r1, [r0] @ encoding: [0x00,0x10,0xb0,0xe4]
+# CHECK: ldrbt r1, [r0] @ encoding: [0x00,0x10,0xf0,0xe4]
+# CHECK: strt r1, [r0] @ encoding: [0x00,0x10,0xa0,0xe4]
+# CHECK: strbt r1, [r0] @ encoding: [0x00,0x10,0xe0,0xe4]
+