@@ -251,14 +251,9 @@ class BinOpRI8_RF<bits<8> opcode, string mnemonic, X86TypeInfo typeinfo,
251
251
[(set typeinfo.RegClass:$dst, EFLAGS,
252
252
(opnode typeinfo.RegClass:$src1, typeinfo.Imm8Operator:$src2))]>;
253
253
254
- // BinOpRI8_RFF - Binary instructions with inputs "reg, imm8", where the pattern
255
- // has both a regclass and EFLAGS as a result, and has EFLAGS as input.
256
- class BinOpRI8_RFF<bits<8> opcode, string mnemonic, X86TypeInfo typeinfo,
257
- SDPatternOperator opnode, Format f>
258
- : BinOpRI8<opcode, mnemonic, typeinfo, f, (outs typeinfo.RegClass:$dst), WriteADC,
259
- [(set typeinfo.RegClass:$dst, EFLAGS,
260
- (opnode typeinfo.RegClass:$src1, typeinfo.Imm8Operator:$src2,
261
- EFLAGS))]>;
254
+ // BinOpRI8_RFF - Binary instructions with inputs "reg, imm8".
255
+ class BinOpRI8_RFF<bits<8> opcode, string mnemonic, X86TypeInfo typeinfo, Format f>
256
+ : BinOpRI8<opcode, mnemonic, typeinfo, f, (outs typeinfo.RegClass:$dst), WriteADC, []>;
262
257
263
258
// BinOpMR - Binary instructions with inputs "[mem], reg".
264
259
class BinOpMR<bits<8> opcode, string mnemonic, X86TypeInfo typeinfo,
@@ -362,15 +357,9 @@ class BinOpMI8_RMW<string mnemonic, X86TypeInfo typeinfo,
362
357
(implicit EFLAGS)]>,
363
358
Sched<[WriteALURMW]>;
364
359
365
- // BinOpMI8_RMW_FF - Binary instructions with inputs "[mem], imm8", where the
366
- // pattern sets EFLAGS and implicitly uses EFLAGS.
367
- class BinOpMI8_RMW_FF<string mnemonic, X86TypeInfo typeinfo,
368
- SDPatternOperator opnode, Format f>
369
- : BinOpMI8<mnemonic, typeinfo, f,
370
- [(store (opnode (load addr:$dst),
371
- typeinfo.Imm8Operator:$src, EFLAGS), addr:$dst),
372
- (implicit EFLAGS)]>,
373
- Sched<[WriteADCRMW]>;
360
+ // BinOpMI8_RMW_FF - Binary instructions with inputs "[mem], imm8".
361
+ class BinOpMI8_RMW_FF<string mnemonic, X86TypeInfo typeinfo, Format f>
362
+ : BinOpMI8<mnemonic, typeinfo, f, []>, Sched<[WriteADCRMW]>;
374
363
375
364
// BinOpMI8_F - Binary instructions with inputs "[mem], imm8", where the pattern
376
365
// has EFLAGS as a result.
@@ -979,9 +968,9 @@ multiclass ArithBinOp_RFF<bits<8> BaseOpc, bits<8> BaseOpc2, bits<8> BaseOpc4,
979
968
let isConvertibleToThreeAddress = ConvertibleToThreeAddress in {
980
969
// NOTE: These are order specific, we want the ri8 forms to be listed
981
970
// first so that they are slightly preferred to the ri forms.
982
- def NAME#16ri8 : BinOpRI8_RFF<0x82, mnemonic, Xi16, opnode, RegMRM>;
983
- def NAME#32ri8 : BinOpRI8_RFF<0x82, mnemonic, Xi32, opnode, RegMRM>;
984
- def NAME#64ri8 : BinOpRI8_RFF<0x82, mnemonic, Xi64, opnode, RegMRM>;
971
+ def NAME#16ri8 : BinOpRI8_RFF<0x82, mnemonic, Xi16, RegMRM>;
972
+ def NAME#32ri8 : BinOpRI8_RFF<0x82, mnemonic, Xi32, RegMRM>;
973
+ def NAME#64ri8 : BinOpRI8_RFF<0x82, mnemonic, Xi64, RegMRM>;
985
974
986
975
def NAME#16ri : BinOpRI_RFF<0x80, mnemonic, Xi16, opnode, RegMRM>;
987
976
def NAME#32ri : BinOpRI_RFF<0x80, mnemonic, Xi32, opnode, RegMRM>;
@@ -996,10 +985,10 @@ multiclass ArithBinOp_RFF<bits<8> BaseOpc, bits<8> BaseOpc2, bits<8> BaseOpc4,
996
985
997
986
// NOTE: These are order specific, we want the mi8 forms to be listed
998
987
// first so that they are slightly preferred to the mi forms.
999
- def NAME#16mi8 : BinOpMI8_RMW_FF<mnemonic, Xi16, opnode, MemMRM>;
1000
- def NAME#32mi8 : BinOpMI8_RMW_FF<mnemonic, Xi32, opnode, MemMRM>;
988
+ def NAME#16mi8 : BinOpMI8_RMW_FF<mnemonic, Xi16, MemMRM>;
989
+ def NAME#32mi8 : BinOpMI8_RMW_FF<mnemonic, Xi32, MemMRM>;
1001
990
let Predicates = [In64BitMode] in
1002
- def NAME#64mi8 : BinOpMI8_RMW_FF<mnemonic, Xi64, opnode, MemMRM>;
991
+ def NAME#64mi8 : BinOpMI8_RMW_FF<mnemonic, Xi64, MemMRM>;
1003
992
1004
993
def NAME#8mi : BinOpMI_RMW_FF<0x80, mnemonic, Xi8 , opnode, MemMRM>;
1005
994
def NAME#16mi : BinOpMI_RMW_FF<0x80, mnemonic, Xi16, opnode, MemMRM>;
@@ -1012,9 +1001,9 @@ multiclass ArithBinOp_RFF<bits<8> BaseOpc, bits<8> BaseOpc2, bits<8> BaseOpc4,
1012
1001
let Predicates = [Not64BitMode], isCodeGenOnly = 1, ForceDisassemble = 1,
1013
1002
hasSideEffects = 0 in {
1014
1003
let Constraints = "$src1 = $dst" in
1015
- def NAME#8ri8 : BinOpRI8_RFF<0x82, mnemonic, Xi8, null_frag, RegMRM>;
1004
+ def NAME#8ri8 : BinOpRI8_RFF<0x82, mnemonic, Xi8, RegMRM>;
1016
1005
let mayLoad = 1, mayStore = 1 in
1017
- def NAME#8mi8 : BinOpMI8_RMW_FF<mnemonic, Xi8, null_frag, MemMRM>;
1006
+ def NAME#8mi8 : BinOpMI8_RMW_FF<mnemonic, Xi8, MemMRM>;
1018
1007
}
1019
1008
} // Uses = [EFLAGS], Defs = [EFLAGS]
1020
1009
0 commit comments