use Pat to implement extloadi8 and extloadi16

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31052 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Rafael Espindola 2006-10-19 17:05:03 +00:00
parent 93c456c4bd
commit 2435786414

View File

@ -168,10 +168,6 @@ def LDRB : InstARM<(ops IntRegs:$dst, IntRegs:$addr),
"ldrb $dst, [$addr]",
[(set IntRegs:$dst, (zextloadi8 IntRegs:$addr))]>;
def LDRB2 : InstARM<(ops IntRegs:$dst, IntRegs:$addr),
"ldrb $dst, [$addr]",
[(set IntRegs:$dst, (extloadi8 IntRegs:$addr))]>;
def LDRSB : InstARM<(ops IntRegs:$dst, IntRegs:$addr),
"ldrsb $dst, [$addr]",
[(set IntRegs:$dst, (sextloadi8 IntRegs:$addr))]>;
@ -180,10 +176,6 @@ def LDRH : InstARM<(ops IntRegs:$dst, IntRegs:$addr),
"ldrh $dst, [$addr]",
[(set IntRegs:$dst, (zextloadi16 IntRegs:$addr))]>;
def LDRH2 : InstARM<(ops IntRegs:$dst, IntRegs:$addr),
"ldrh $dst, [$addr]",
[(set IntRegs:$dst, (extloadi16 IntRegs:$addr))]>;
def LDRSH : InstARM<(ops IntRegs:$dst, IntRegs:$addr),
"ldrsh $dst, [$addr]",
[(set IntRegs:$dst, (sextloadi16 IntRegs:$addr))]>;
@ -342,3 +334,8 @@ def : Pat<(ARMcall tglobaladdr:$dst),
def : Pat<(ARMcall texternalsym:$dst),
(bl texternalsym:$dst)>;
def : Pat<(extloadi8 IntRegs:$addr),
(LDRB IntRegs:$addr)>;
def : Pat<(extloadi16 IntRegs:$addr),
(LDRH IntRegs:$addr)>;