Thumb assembly parsing and encoding for LDRSB and LDRSH.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138061 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Jim Grosbach 2011-08-19 19:17:58 +00:00
parent 38466309d5
commit 05b0156734
2 changed files with 11 additions and 0 deletions

View File

@ -120,6 +120,7 @@ def t_addrmode_rr : Operand<i32>,
let EncoderMethod = "getThumbAddrModeRegRegOpValue";
let PrintMethod = "printThumbAddrModeRROperand";
let DecoderMethod = "DecodeThumbAddrModeRR";
let ParserMatchClass = t_addrmode_rr_asm_operand;
let MIOperandInfo = (ops tGPR:$base, tGPR:$offsreg);
}

View File

@ -250,3 +250,13 @@ _func:
ldrh r6, [r2, r6]
@ CHECK: ldrh r6, [r2, r6] @ encoding: [0x96,0x5b]
@------------------------------------------------------------------------------
@ LDRSB/LDRSH
@------------------------------------------------------------------------------
ldrsb r6, [r2, r6]
ldrsh r3, [r7, r1]
@ CHECK: ldrsb r6, [r2, r6] @ encoding: [0x96,0x57]
@ CHECK: ldrsh r3, [r7, r1] @ encoding: [0x7b,0x5e]