[llvm-commits] [llvm] r115967 - /llvm/trunk/lib/Target/X86/X86InstrArithmetic.td
Chris Lattner
sabre at nondot.org
Thu Oct 7 13:06:24 PDT 2010
Author: lattner
Date: Thu Oct 7 15:06:24 2010
New Revision: 115967
URL: http://llvm.org/viewvc/llvm-project?rev=115967&view=rev
Log:
the opcode for BinOpMI/BinOpMI8 is always the same, remove the argument.
Modified:
llvm/trunk/lib/Target/X86/X86InstrArithmetic.td
Modified: llvm/trunk/lib/Target/X86/X86InstrArithmetic.td
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/X86/X86InstrArithmetic.td?rev=115967&r1=115966&r2=115967&view=diff
==============================================================================
--- llvm/trunk/lib/Target/X86/X86InstrArithmetic.td (original)
+++ llvm/trunk/lib/Target/X86/X86InstrArithmetic.td Thu Oct 7 15:06:24 2010
@@ -642,7 +642,7 @@
// BinOpRM_RF - Instructions like "add reg, reg, [mem]".
class BinOpRM_RF<bits<8> opcode, string mnemonic, X86TypeInfo typeinfo,
- SDNode opnode>
+ SDNode opnode>
: ITy<opcode, MRMSrcMem, typeinfo,
(outs typeinfo.RegClass:$dst),
(ins typeinfo.RegClass:$src1, typeinfo.MemOperand:$src2),
@@ -708,9 +708,9 @@
(implicit EFLAGS)]>;
// BinOpMI - Instructions like "add [mem], imm".
-class BinOpMI<bits<8> opcode, string mnemonic, X86TypeInfo typeinfo,
+class BinOpMI<string mnemonic, X86TypeInfo typeinfo,
SDNode opnode, Format f>
- : ITy<opcode, f, typeinfo,
+ : ITy<0x80, f, typeinfo,
(outs), (ins typeinfo.MemOperand:$dst, typeinfo.ImmOperand:$src),
mnemonic, "{$src, $dst|$dst, $src}",
[(store (opnode (typeinfo.VT (load addr:$dst)),
@@ -720,9 +720,9 @@
}
// BinOpMI8 - Instructions like "add [mem], imm8".
-class BinOpMI8<bits<8> opcode, string mnemonic, X86TypeInfo typeinfo,
+class BinOpMI8<string mnemonic, X86TypeInfo typeinfo,
SDNode opnode, Format f>
- : ITy<opcode, f, typeinfo,
+ : ITy<0x82, f, typeinfo,
(outs), (ins typeinfo.MemOperand:$dst, typeinfo.Imm8Operand:$src),
mnemonic, "{$src, $dst|$dst, $src}",
[(store (opnode (load addr:$dst),
@@ -789,14 +789,14 @@
def #NAME#32mr : BinOpMR<BaseOpc, mnemonic, Xi32, opnode>;
def #NAME#64mr : BinOpMR<BaseOpc, mnemonic, Xi64, opnode>;
- def #NAME#8mi : BinOpMI<0x80, mnemonic, Xi8 , opnode, MemMRM>;
- def #NAME#16mi : BinOpMI<0x80, mnemonic, Xi16, opnode, MemMRM>;
- def #NAME#32mi : BinOpMI<0x80, mnemonic, Xi32, opnode, MemMRM>;
- def #NAME#64mi32 : BinOpMI<0x80, mnemonic, Xi64, opnode, MemMRM>;
-
- def #NAME#16mi8 : BinOpMI8<0x82, mnemonic, Xi16, opnode, MemMRM>;
- def #NAME#32mi8 : BinOpMI8<0x82, mnemonic, Xi32, opnode, MemMRM>;
- def #NAME#64mi8 : BinOpMI8<0x82, mnemonic, Xi64, opnode, MemMRM>;
+ def #NAME#8mi : BinOpMI<mnemonic, Xi8 , opnode, MemMRM>;
+ def #NAME#16mi : BinOpMI<mnemonic, Xi16, opnode, MemMRM>;
+ def #NAME#32mi : BinOpMI<mnemonic, Xi32, opnode, MemMRM>;
+ def #NAME#64mi32 : BinOpMI<mnemonic, Xi64, opnode, MemMRM>;
+
+ def #NAME#16mi8 : BinOpMI8<mnemonic, Xi16, opnode, MemMRM>;
+ def #NAME#32mi8 : BinOpMI8<mnemonic, Xi32, opnode, MemMRM>;
+ def #NAME#64mi8 : BinOpMI8<mnemonic, Xi64, opnode, MemMRM>;
def #NAME#8i8 : BinOpAI<BaseOpc4, mnemonic, Xi8 , AL>;
def #NAME#16i16 : BinOpAI<BaseOpc4, mnemonic, Xi16, AX>;
@@ -850,14 +850,14 @@
def #NAME#32mr : BinOpMR<BaseOpc, mnemonic, Xi32, opnode>;
def #NAME#64mr : BinOpMR<BaseOpc, mnemonic, Xi64, opnode>;
- def #NAME#8mi : BinOpMI<0x80, mnemonic, Xi8 , opnode, MemMRM>;
- def #NAME#16mi : BinOpMI<0x80, mnemonic, Xi16, opnode, MemMRM>;
- def #NAME#32mi : BinOpMI<0x80, mnemonic, Xi32, opnode, MemMRM>;
- def #NAME#64mi32 : BinOpMI<0x80, mnemonic, Xi64, opnode, MemMRM>;
-
- def #NAME#16mi8 : BinOpMI8<0x82, mnemonic, Xi16, opnode, MemMRM>;
- def #NAME#32mi8 : BinOpMI8<0x82, mnemonic, Xi32, opnode, MemMRM>;
- def #NAME#64mi8 : BinOpMI8<0x82, mnemonic, Xi64, opnode, MemMRM>;
+ def #NAME#8mi : BinOpMI<mnemonic, Xi8 , opnode, MemMRM>;
+ def #NAME#16mi : BinOpMI<mnemonic, Xi16, opnode, MemMRM>;
+ def #NAME#32mi : BinOpMI<mnemonic, Xi32, opnode, MemMRM>;
+ def #NAME#64mi32 : BinOpMI<mnemonic, Xi64, opnode, MemMRM>;
+
+ def #NAME#16mi8 : BinOpMI8<mnemonic, Xi16, opnode, MemMRM>;
+ def #NAME#32mi8 : BinOpMI8<mnemonic, Xi32, opnode, MemMRM>;
+ def #NAME#64mi8 : BinOpMI8<mnemonic, Xi64, opnode, MemMRM>;
def #NAME#8i8 : BinOpAI<BaseOpc4, mnemonic, Xi8 , AL>;
def #NAME#16i16 : BinOpAI<BaseOpc4, mnemonic, Xi16, AX>;
More information about the llvm-commits
mailing list