Home
last modified time | relevance | path

Searched refs:CmpRHS (Results 1 – 17 of 17) sorted by relevance

/openbsd/src/gnu/llvm/llvm/lib/Transforms/InstCombine/
DInstCombineSelect.cpp581 Value *CmpRHS = IC->getOperand(1); in foldSelectICmpLshrAshr() local
582 if (!CmpRHS->getType()->isIntOrIntVectorTy()) in foldSelectICmpLshrAshr()
586 unsigned Bitwidth = CmpRHS->getType()->getScalarSizeInBits(); in foldSelectICmpLshrAshr()
588 !match(CmpRHS, in foldSelectICmpLshrAshr()
591 !match(CmpRHS, in foldSelectICmpLshrAshr()
634 Value *CmpRHS = IC->getOperand(1); in foldSelectICmpAndOr() local
641 if (!match(CmpRHS, m_Zero())) in foldSelectICmpAndOr()
656 if ((IsEqualZero && !match(CmpRHS, m_AllOnes())) || in foldSelectICmpAndOr()
657 (!IsEqualZero && !match(CmpRHS, m_Zero()))) in foldSelectICmpAndOr()
989 Value *CmpRHS = ICI->getOperand(1); in foldSelectCttzCtlz() local
[all …]
/openbsd/src/gnu/llvm/llvm/include/llvm/CodeGen/
DSwitchLoweringUtils.h127 const Value *CmpLHS, *CmpMHS, *CmpRHS; member
149 : CC(cc), CmpLHS(cmplhs), CmpMHS(cmpmiddle), CmpRHS(cmprhs), in CC()
161 CmpRHS(cmprhs), TrueBB(truebb), FalseBB(falsebb), ThisBB(me),
/openbsd/src/gnu/llvm/llvm/lib/Analysis/
DValueTracking.cpp5950 Value *CmpLHS, Value *CmpRHS, in matchFastFloatClamp() argument
5959 if (CmpRHS == FalseVal) { in matchFastFloatClamp()
5969 if (CmpRHS != TrueVal || !match(CmpRHS, m_APFloat(FC1)) || !FC1->isFinite()) in matchFastFloatClamp()
6004 Value *CmpLHS, Value *CmpRHS, in matchClamp() argument
6007 if (CmpRHS != TrueVal) { in matchClamp()
6012 if (CmpRHS == TrueVal && match(CmpRHS, m_APInt(C1))) { in matchClamp()
6040 Value *CmpLHS, Value *CmpRHS, in matchMinMaxOfMinMax() argument
6063 std::swap(CmpLHS, CmpRHS); in matchMinMaxOfMinMax()
6071 std::swap(CmpLHS, CmpRHS); in matchMinMaxOfMinMax()
6079 std::swap(CmpLHS, CmpRHS); in matchMinMaxOfMinMax()
[all …]
DInstructionSimplify.cpp2627 Value *CmpLHS = Cmp->getOperand(0), *CmpRHS = Cmp->getOperand(1); in extractEquivalentCondition() local
2628 if (Pred == Cmp->getPredicate() && LHS == CmpLHS && RHS == CmpRHS) in extractEquivalentCondition()
2631 LHS == CmpRHS && RHS == CmpLHS) in extractEquivalentCondition()
4322 static Value *simplifyCmpSelOfMaxMin(Value *CmpLHS, Value *CmpRHS, in simplifyCmpSelOfMaxMin() argument
4326 if (CmpRHS == TVal || CmpRHS == FVal) { in simplifyCmpSelOfMaxMin()
4327 std::swap(CmpLHS, CmpRHS); in simplifyCmpSelOfMaxMin()
4339 Value *X = CmpLHS, *Y = CmpRHS; in simplifyCmpSelOfMaxMin()
4396 static Value *simplifySelectWithFakeICmpEq(Value *CmpLHS, Value *CmpRHS, in simplifySelectWithFakeICmpEq() argument
4401 if (!decomposeBitTestICmp(CmpLHS, CmpRHS, Pred, X, Mask)) in simplifySelectWithFakeICmpEq()
4415 Value *CmpLHS, *CmpRHS; in simplifySelectWithICmpCond() local
[all …]
/openbsd/src/gnu/llvm/llvm/lib/Transforms/Scalar/
DGuardWidening.cpp601 const Value *CmpLHS = IC->getOperand(0), *CmpRHS = IC->getOperand(1); in parseRangeChecks() local
603 std::swap(CmpLHS, CmpRHS); in parseRangeChecks()
608 CmpLHS, cast<ConstantInt>(ConstantInt::getNullValue(CmpRHS->getType())), in parseRangeChecks()
609 CmpRHS, IC); in parseRangeChecks()
DGVN.cpp1959 Value *CmpRHS = CmpI->getOperand(1); in processAssumeIntrinsic() local
1965 if (isa<Constant>(CmpLHS) && !isa<Constant>(CmpRHS)) in processAssumeIntrinsic()
1966 std::swap(CmpLHS, CmpRHS); in processAssumeIntrinsic()
1967 if (!isa<Instruction>(CmpLHS) && isa<Instruction>(CmpRHS)) in processAssumeIntrinsic()
1968 std::swap(CmpLHS, CmpRHS); in processAssumeIntrinsic()
1969 if ((isa<Argument>(CmpLHS) && isa<Argument>(CmpRHS)) || in processAssumeIntrinsic()
1970 (isa<Instruction>(CmpLHS) && isa<Instruction>(CmpRHS))) { in processAssumeIntrinsic()
1974 uint32_t RVN = VN.lookupOrAdd(CmpRHS); in processAssumeIntrinsic()
1976 std::swap(CmpLHS, CmpRHS); in processAssumeIntrinsic()
1981 if (isa<Constant>(CmpLHS) && isa<Constant>(CmpRHS)) in processAssumeIntrinsic()
[all …]
DLoopIdiomRecognize.cpp2307 Value *CmpLHS, *CmpRHS; in detectShiftUntilBitTestIdiom() local
2310 m_Br(m_ICmp(Pred, m_Value(CmpLHS), m_Value(CmpRHS)), in detectShiftUntilBitTestIdiom()
2319 return ICmpInst::isEquality(Pred) && match(CmpRHS, m_Zero()) && in detectShiftUntilBitTestIdiom()
2328 return ICmpInst::isEquality(Pred) && match(CmpRHS, m_Zero()) && in detectShiftUntilBitTestIdiom()
2335 return llvm::decomposeBitTestICmp(CmpLHS, CmpRHS, Pred, CurrX, Mask) && in detectShiftUntilBitTestIdiom()
DJumpThreading.cpp839 Value *CmpRHS = Cmp->getOperand(1); in computeValueKnownInPredecessorsImpl() local
844 PN = dyn_cast<PHINode>(CmpRHS); in computeValueKnownInPredecessorsImpl()
854 RHS = CmpRHS->DoPHITranslation(BB, PredBB); in computeValueKnownInPredecessorsImpl()
887 if (isa<Constant>(CmpRHS) && !CmpType->isVectorTy()) { in computeValueKnownInPredecessorsImpl()
888 Constant *CmpConst = cast<Constant>(CmpRHS); in computeValueKnownInPredecessorsImpl()
/openbsd/src/gnu/llvm/llvm/lib/Target/X86/
DX86FastISel.cpp1661 const Value *CmpRHS = CI->getOperand(1); in X86SelectBranch() local
1668 const auto *CmpRHSC = dyn_cast<ConstantFP>(CmpRHS); in X86SelectBranch()
1670 CmpRHS = CmpLHS; in X86SelectBranch()
1701 std::swap(CmpLHS, CmpRHS); in X86SelectBranch()
1704 if (!X86FastEmitCompare(CmpLHS, CmpRHS, VT, CI->getDebugLoc())) in X86SelectBranch()
2070 const Value *CmpRHS = CI->getOperand(1); in X86FastEmitCMoveSelect() local
2072 std::swap(CmpLHS, CmpRHS); in X86FastEmitCMoveSelect()
2076 if (!X86FastEmitCompare(CmpLHS, CmpRHS, CmpVT, CI->getDebugLoc())) in X86FastEmitCMoveSelect()
2165 const Value *CmpRHS = CI->getOperand(1); in X86FastEmitSSESelect() local
2172 const auto *CmpRHSC = dyn_cast<ConstantFP>(CmpRHS); in X86FastEmitSSESelect()
[all …]
DX86ISelLowering.cpp46279 SDValue CmpRHS = Cmp.getOperand(1); in combineSetCCAtomicArith() local
46298 auto *CmpRHSC = dyn_cast<ConstantSDNode>(CmpRHS); in combineSetCCAtomicArith()
46339 /*RHS*/ DAG.getConstant(NegAddend, SDLoc(CmpRHS), CmpVT), in combineSetCCAtomicArith()
/openbsd/src/gnu/llvm/llvm/lib/CodeGen/GlobalISel/
DIRTranslator.cpp550 Cases[0].CmpRHS == Cases[1].CmpRHS) || in shouldEmitAsBranches()
551 (Cases[0].CmpRHS == Cases[1].CmpLHS && in shouldEmitAsBranches()
552 Cases[0].CmpLHS == Cases[1].CmpRHS)) { in shouldEmitAsBranches()
558 if (Cases[0].CmpRHS == Cases[1].CmpRHS && in shouldEmitAsBranches()
560 isa<Constant>(Cases[0].CmpRHS) && in shouldEmitAsBranches()
561 cast<Constant>(Cases[0].CmpRHS)->isNullValue()) { in shouldEmitAsBranches()
843 const auto *CI = dyn_cast<ConstantInt>(CB.CmpRHS); in emitSwitchCase()
851 Register CondRHS = getOrCreateVReg(*CB.CmpRHS); in emitSwitchCase()
864 const APInt& High = cast<ConstantInt>(CB.CmpRHS)->getValue(); in emitSwitchCase()
868 Register CondRHS = getOrCreateVReg(*CB.CmpRHS); in emitSwitchCase()
DCombinerHelper.cpp6098 Register CmpLHS, CmpRHS; in matchFPSelectToMinMax() local
6101 m_GFCmp(m_Pred(Pred), m_Reg(CmpLHS), m_Reg(CmpRHS)))) || in matchFPSelectToMinMax()
6105 computeRetValAgainstNaN(CmpLHS, CmpRHS, CmpInst::isOrdered(Pred)); in matchFPSelectToMinMax()
6108 if (TrueVal == CmpRHS && FalseVal == CmpLHS) { in matchFPSelectToMinMax()
6109 std::swap(CmpLHS, CmpRHS); in matchFPSelectToMinMax()
6116 if (TrueVal != CmpLHS || FalseVal != CmpRHS) in matchFPSelectToMinMax()
6130 KnownNonZeroSide = getFConstantVRegValWithLookThrough(CmpRHS, MRI); in matchFPSelectToMinMax()
6136 B.buildInstr(Opc, {Dst}, {CmpLHS, CmpRHS}); in matchFPSelectToMinMax()
/openbsd/src/gnu/llvm/llvm/lib/Transforms/Utils/
DSimplifyIndVar.cpp1987 Value *CmpRHS; in calculatePostIncRange() local
1989 m_Value(CmpRHS)))) in calculatePostIncRange()
1995 auto CmpRHSRange = SE->getSignedRange(SE->getSCEV(CmpRHS)); in calculatePostIncRange()
/openbsd/src/gnu/llvm/llvm/lib/CodeGen/SelectionDAG/
DSelectionDAGBuilder.cpp2394 Cases[0].CmpRHS == Cases[1].CmpRHS) || in ShouldEmitAsBranches()
2395 (Cases[0].CmpRHS == Cases[1].CmpLHS && in ShouldEmitAsBranches()
2396 Cases[0].CmpLHS == Cases[1].CmpRHS)) { in ShouldEmitAsBranches()
2402 if (Cases[0].CmpRHS == Cases[1].CmpRHS && in ShouldEmitAsBranches()
2404 isa<Constant>(Cases[0].CmpRHS) && in ShouldEmitAsBranches()
2405 cast<Constant>(Cases[0].CmpRHS)->isNullValue()) { in ShouldEmitAsBranches()
2483 ExportFromCurrentBlock(SL->SwitchCases[i].CmpRHS); in visitBr()
2536 if (CB.CmpRHS == ConstantInt::getTrue(*DAG.getContext()) && in visitSwitchCase()
2539 else if (CB.CmpRHS == ConstantInt::getFalse(*DAG.getContext()) && in visitSwitchCase()
2544 SDValue CondRHS = getValue(CB.CmpRHS); in visitSwitchCase()
[all …]
DTargetLowering.cpp4880 SDValue CmpRHS = DAG.getConstant(C1.lshr(ShiftBits), dl, ShValTy); in SimplifySetCC() local
4881 return DAG.getSetCC(dl, VT, Shift, CmpRHS, Cond); in SimplifySetCC()
4908 SDValue CmpRHS = DAG.getConstant(NewC, dl, ShValTy); in SimplifySetCC() local
4909 return DAG.getSetCC(dl, VT, Shift, CmpRHS, NewCond); in SimplifySetCC()
/openbsd/src/gnu/llvm/llvm/lib/Target/PowerPC/
DPPCISelDAGToDAG.cpp4697 SDValue CmpRHS = N->getOperand(3); in tryFoldSWTestBRCC() local
4698 if (!isa<ConstantSDNode>(CmpRHS) || in tryFoldSWTestBRCC()
4699 cast<ConstantSDNode>(CmpRHS)->getSExtValue() != 0) in tryFoldSWTestBRCC()
/openbsd/src/gnu/llvm/llvm/lib/Target/AArch64/
DAArch64ISelLowering.cpp20128 SDValue CmpRHS = OpCmp.getOperand(1); in foldCSELOfCSEL() local
20130 if (CmpRHS.getOpcode() == AArch64ISD::CSEL) in foldCSELOfCSEL()
20131 std::swap(CmpLHS, CmpRHS); in foldCSELOfCSEL()
20153 if (CmpRHS == Y) in foldCSELOfCSEL()
20155 else if (CmpRHS != X) in foldCSELOfCSEL()
20577 SDNode *CmpRHS = SetCC.getOperand(1).getNode(); in performVSelectCombine() local
20587 SplatLHSVal.isOne() && ISD::isConstantSplatVectorAllOnes(CmpRHS) && in performVSelectCombine()