Lines Matching refs:CMP
10649 SDValue Cond = DAG.getNode(X86ISD::CMP, dl, MVT::i32,
11650 return DAG.getNode(X86ISD::CMP, dl, MVT::i32, Op,
11690 // Emit a CMP with 0, which is the TEST pattern.
11692 // return DAG.getNode(X86ISD::CMP, dl, MVT::i1, Op,
11694 return DAG.getNode(X86ISD::CMP, dl, MVT::i32, Op,
11867 // Emit a CMP with 0, which is the TEST pattern.
11868 return DAG.getNode(X86ISD::CMP, dl, MVT::i32, Op,
11881 /// Emit nodes that will be selected as "cmp Op0,Op1", or something
11908 // Use SUB instead of CMP to enable CSE between SUB and CMP.
11914 return DAG.getNode(X86ISD::CMP, dl, MVT::i32, Op0, Op1);
11918 SDValue X86TargetLowering::ConvertCmpIfNecessary(SDValue Cmp,
11923 Cmp.getOpcode() != X86ISD::CMP ||
11924 !Cmp.getOperand(0).getValueType().isFloatingPoint() ||
11925 !Cmp.getOperand(1).getValueType().isFloatingPoint())
11926 return Cmp;
11932 SDLoc dl(Cmp);
11933 SDValue TruncFPSW = DAG.getNode(ISD::TRUNCATE, dl, MVT::i16, Cmp);
12475 if (Opc == X86ISD::CMP || Opc == X86ISD::COMI || Opc == X86ISD::UCOMI ||
12517 // Lower fp selects into a CMP/AND/ANDN/OR sequence when the necessary SSE ops
12530 SDValue Cmp = DAG.getNode(X86ISD::FSETCC, DL, MVT::i1, CondOp0, CondOp1,
12532 return DAG.getNode(X86ISD::SELECT, DL, VT, Cmp, Op1, Op2);
12534 SDValue Cmp = DAG.getNode(X86ISD::FSETCC, DL, VT, CondOp0, CondOp1,
12536 SDValue AndN = DAG.getNode(X86ISD::FANDN, DL, VT, Cmp, Op2);
12537 SDValue And = DAG.getNode(X86ISD::FAND, DL, VT, Cmp, Op1);
12553 Cond.getOperand(1).getOpcode() == X86ISD::CMP &&
12555 SDValue Cmp = Cond.getOperand(1);
12563 SDValue CmpOp0 = Cmp.getOperand(0);
12580 Cmp = DAG.getNode(X86ISD::CMP, DL, MVT::i32,
12582 Cmp = ConvertCmpIfNecessary(Cmp, DAG);
12586 DAG.getConstant(X86::COND_B, MVT::i8), Cmp);
12598 // Look past (and (setcc_carry (cmp ...)), 1).
12606 // If condition flag is set by a X86ISD::CMP, then use it as the condition
12613 SDValue Cmp = Cond.getOperand(1);
12614 unsigned Opc = Cmp.getOpcode();
12622 if ((isX86LogicalCmp(Cmp) && !IllegalFPCMov) ||
12624 Cond = Cmp;
12870 // Look pass (and (setcc_carry (cmp ...)), 1).
12878 // If condition flag is set by a X86ISD::CMP, then use it as the condition
12885 SDValue Cmp = Cond.getOperand(1);
12886 unsigned Opc = Cmp.getOpcode();
12888 if (isX86LogicalCmp(Cmp) || Opc == X86ISD::BT) {
12889 Cond = Cmp;
12958 SDValue Cmp = Cond.getOperand(0).getOperand(1);
12963 if (Cmp == Cond.getOperand(1).getOperand(1) &&
12964 isX86LogicalCmp(Cmp)) {
12967 Chain, Dest, CC, Cmp);
12969 Cond = Cmp;
12978 if (Cmp == Cond.getOperand(1).getOperand(1) &&
12979 isX86LogicalCmp(Cmp) &&
12998 Chain, Dest, CC, Cmp);
13003 Cond = Cmp;
13038 SDValue Cmp = DAG.getNode(X86ISD::CMP, dl, MVT::i32,
13040 Cmp = ConvertCmpIfNecessary(Cmp, DAG);
13043 Chain, Dest, CC, Cmp);
13045 Cond = Cmp;
13068 SDValue Cmp = DAG.getNode(X86ISD::CMP, dl, MVT::i32,
13070 Cmp = ConvertCmpIfNecessary(Cmp, DAG);
13073 Chain, Dest, CC, Cmp);
13075 Cond = Cmp;
16500 case X86ISD::CMP: return "X86ISD::CMP";
19781 // (Op (CMP (SETCC Cond EFLAGS) 1) EQ) or
19782 // (Op (CMP (SETCC Cond EFLAGS) 0) NEQ)
19785 // (Op (CMP (SETCC Cond EFLAGS) 0) EQ) or
19786 // (Op (CMP (SETCC Cond EFLAGS) 1) NEQ)
19791 static SDValue checkBoolTestSetCCCombine(SDValue Cmp, X86::CondCode &CC) {
19792 // Quit if not CMP and SUB with its value result used.
19793 if (Cmp.getOpcode() != X86ISD::CMP &&
19794 (Cmp.getOpcode() != X86ISD::SUB || Cmp.getNode()->hasAnyUseOfValue(0)))
19801 // Check CMP operands. One of them should be 0 or 1 and the other should be
19803 SDValue Op1 = Cmp.getOperand(0);
19804 SDValue Op2 = Cmp.getOperand(1);
20043 // of CMOV and CMP.
20058 if ((Cond.getOpcode() == X86ISD::CMP || Cond.getOpcode() == X86ISD::SUB) &&
20336 // where both setccs reference the same FP CMP, and rewrite for CMPEQSS
20343 // SSE1 supports CMP{eq|ne}SS, and SSE2 added CMP{eq|ne}SD, but
20352 // The SETCCs should both refer to the same CMP.
20353 if (CMP0.getOpcode() != X86ISD::CMP || CMP0 != CMP1)
21752 // Do not flip "e > c", where "c" is a constant, because Cmp instruction
21882 SDValue Cmp = SetCC.getOperand(1);
21883 if (Cmp.getOpcode() != X86ISD::CMP || !Cmp.hasOneUse() ||
21884 !X86::isZeroNode(Cmp.getOperand(1)) ||
21885 !Cmp.getOperand(0).getValueType().isInteger())
21888 SDValue CmpOp0 = Cmp.getOperand(0);
21889 SDValue NewCmp = DAG.getNode(X86ISD::CMP, DL, MVT::i32, CmpOp0,