Thumb2 t2LDMDB[_UPD] assembly parsing to recognize .w suffix.

rdar://10348844

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143110 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Jim Grosbach 2011-10-27 17:33:59 +00:00
parent 3529c53d2f
commit 88484c0030
2 changed files with 10 additions and 0 deletions

View File

@ -3944,6 +3944,12 @@ def : t2InstAlias<"push${p} $regs", (t2STMDB_UPD SP, pred:$p, reglist:$regs)>;
def : t2InstAlias<"pop${p}.w $regs", (t2LDMIA_UPD SP, pred:$p, reglist:$regs)>;
def : t2InstAlias<"pop${p} $regs", (t2LDMIA_UPD SP, pred:$p, reglist:$regs)>;
// LDMDB/LDMDB_UPD aliases w/ the optional .w suffix
def : t2InstAlias<"ldmdb${p}.w $Rn, $regs",
(t2LDMDB GPR:$Rn, pred:$p, reglist:$regs)>;
def : t2InstAlias<"ldmdb${p}.w $Rn!, $regs",
(t2LDMDB_UPD GPR:$Rn, pred:$p, reglist:$regs)>;
// Alias for REV/REV16/REVSH without the ".w" optional width specifier.
def : t2InstAlias<"rev${p} $Rd, $Rm", (t2REV rGPR:$Rd, rGPR:$Rm, pred:$p)>;
def : t2InstAlias<"rev16${p} $Rd, $Rm", (t2REV16 rGPR:$Rd, rGPR:$Rm, pred:$p)>;

View File

@ -599,11 +599,15 @@ _func:
ldmdb r4, {r5, r6}
ldmdb r5!, {r3, r8}
ldmea r5!, {r3, r8}
ldmdb.w r4, {r5, r6}
ldmdb.w r5!, {r3, r8}
@ CHECK: ldmdb r4, {r4, r5, r8, r9} @ encoding: [0x14,0xe9,0x30,0x03]
@ CHECK: ldmdb r4, {r5, r6} @ encoding: [0x14,0xe9,0x60,0x00]
@ CHECK: ldmdb r5!, {r3, r8} @ encoding: [0x35,0xe9,0x08,0x01]
@ CHECK: ldmdb r5!, {r3, r8} @ encoding: [0x35,0xe9,0x08,0x01]
@ CHECK: ldmdb r4, {r5, r6} @ encoding: [0x14,0xe9,0x60,0x00]
@ CHECK: ldmdb r5!, {r3, r8} @ encoding: [0x35,0xe9,0x08,0x01]
@------------------------------------------------------------------------------