|
reference, declaration → definition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced
|
References
include/llvm/IR/PatternMatch.h 1644 (m_One().match(AddLHS) || m_One().match(AddRHS)))
1644 (m_One().match(AddLHS) || m_One().match(AddRHS)))
1649 (m_One().match(AddLHS) || m_One().match(AddRHS)))
1649 (m_One().match(AddLHS) || m_One().match(AddRHS)))
lib/Analysis/InstructionSimplify.cpp 465 if (match(TCmp, m_One()))
470 if (match(FCmp, m_One()) && match(TCmp, m_Zero()))
842 if (match(Op1, m_One()))
938 if (match(Op1, m_One()) || Ty->isIntOrIntVectorTy(1) ||
2514 } else if (match(RHS, m_One())) {
lib/Analysis/ValueTracking.cpp 1754 if (match(V, m_Shl(m_One(), m_Value())))
4887 auto ZeroOrOne = m_CombineOr(m_ZeroInt(), m_One());
lib/CodeGen/CodeGenPrepare.cpp 1720 if (match(CountZeros->getOperand(1), m_One()))
lib/IR/ConstantFold.cpp 1029 if (match(C2, m_Zero()) || match(C2, m_One()))
lib/IR/Constants.cpp 265 PatternMatch::m_One());
lib/Target/Hexagon/HexagonLoopIdiomRecognition.cpp 693 if (match(A, m_Shl(m_One(), m_Specific(CIV)))) {
696 } else if (match(B, m_Shl(m_One(), m_Specific(CIV)))) {
806 } else if (match(CondV, m_ICmp(P, m_Value(C), m_One())) ||
807 match(CondV, m_ICmp(P, m_One(), m_Value(C)))) {
817 if (!match(C, m_And(m_Value(X), m_One())) &&
818 !match(C, m_And(m_One(), m_Value(X))))
827 if (!match(TrueV, m_LShr(m_Value(R), m_One())))
838 if (!match(FalseV, m_LShr(m_Value(R), m_One())))
1309 if (!match(&I, m_LShr(m_Value(V), m_One())))
1399 if (match(&*I, m_LShr(m_Value(V), m_One()))) {
lib/Transforms/AggressiveInstCombine/AggressiveInstCombine.cpp 181 if (match(V, m_And(m_Value(Op0), m_One()))) {
227 else if (match(&I, m_And(m_OneUse(m_Or(m_Value(), m_Value())), m_One())))
lib/Transforms/InstCombine/InstCombineAddSub.cpp 782 if (match(RHS, m_Add(m_Value(X), m_One())))
785 if (match(LHS, m_Add(m_Value(X), m_One()))) {
1063 if (!match(&I, m_Add(m_OneUse(m_Shl(m_One(), m_Value(NBits))), m_AllOnes())))
1187 ? !match(SignExtendingValueBaseConstant, m_One())
1308 if (match(&I, m_c_BinOp(m_Add(m_Value(A), m_One()), m_Not(m_Value(B)))) ||
1309 match(&I, m_BinOp(m_c_Add(m_Not(m_Value(B)), m_Value(A)), m_One())))
1720 if (match(Op1, m_OneUse(m_Add(m_Value(X), m_One()))))
lib/Transforms/InstCombine/InstCombineAndOrXor.cpp 1754 if (match(Op0, m_OneUse(m_LogicalShift(m_One(), m_Value(X)))) &&
lib/Transforms/InstCombine/InstCombineCalls.cpp 1237 if (!match(II.getArgOperand(1), m_One())) {
3721 ((match(Src1, m_One()) && match(Src0, m_ZExt(m_Value(ExtSrc)))) ||
lib/Transforms/InstCombine/InstCombineCompares.cpp 1725 match(And->getOperand(1), m_One()))
1788 match(And->getOperand(1), m_One())) {
1964 if (!match(Shl, m_Shl(m_One(), m_Value(Y))))
2751 if (Pred == ICmpInst::ICMP_SLT && match(Op1, m_One()))
3284 m_Add(m_Shl(m_One(), m_Value()), m_AllOnes())),
3763 if (A && NoOp0WrapProblem && Pred == CmpInst::ICMP_SLE && match(B, m_One()))
3767 if (A && NoOp0WrapProblem && Pred == CmpInst::ICMP_SGT && match(B, m_One()))
3781 if (C && NoOp1WrapProblem && Pred == CmpInst::ICMP_SGE && match(D, m_One()))
3785 if (C && NoOp1WrapProblem && Pred == CmpInst::ICMP_SLT && match(D, m_One()))
3798 if (A && NoOp0WrapProblem && Pred == CmpInst::ICMP_ULE && match(B, m_One()))
3802 if (A && NoOp0WrapProblem && Pred == CmpInst::ICMP_UGT && match(B, m_One()))
3806 if (C && NoOp1WrapProblem && Pred == CmpInst::ICMP_UGE && match(D, m_One()))
3810 if (C && NoOp1WrapProblem && Pred == CmpInst::ICMP_ULT && match(D, m_One()))
4442 return match(RHS, m_One());
4997 if (match(LHS, m_Shl(m_One(), m_Value(X)))) {
5244 } else if (match(B, m_One())) {
5311 m_c_ICmp(Pred, m_OneUse(m_Shl(m_One(), m_Value(Y))), m_Value(X)))) {
5329 m_Add(m_Shl(m_One(), m_Value(Y)),
lib/Transforms/InstCombine/InstCombineMulDivRem.cpp 62 match(One, m_One())) {
138 if (match(&I, m_c_Mul(m_OneUse(m_Select(m_Value(Cond), m_One(), m_AllOnes())),
144 if (match(&I, m_c_Mul(m_OneUse(m_Select(m_Value(Cond), m_AllOnes(), m_One())),
341 if (match(Op0, m_Shl(m_One(), m_Value(Y)))) {
344 } else if (match(Op1, m_Shl(m_One(), m_Value(Y)))) {
764 if (match(Op0, m_One())) {
1371 if (match(Op0, m_One()))
lib/Transforms/InstCombine/InstCombineSelect.cpp 506 match(Cmp->getOperand(1), m_Zero()) && match(FVal, m_One())))
511 if (!match(TVal, m_OneUse(m_And(m_Value(B), m_One()))))
885 if (II->hasOneUse() && !match(II->getArgOperand(1), m_One()))
1288 if (!match(Precond1, m_One()))
1293 if (!match(Precond2, m_One()))
2241 if (match(TrueVal, m_One())) {
2254 if (match(FalseVal, m_One())) {
2284 if (match(TrueVal, m_One()) && match(FalseVal, m_Zero()))
2292 if (match(TrueVal, m_Zero()) && match(FalseVal, m_One())) {
lib/Transforms/InstCombine/InstCombineShifts.cpp 194 auto MaskA = m_Add(m_Shl(m_One(), m_Value(MaskShAmt)), m_AllOnes());
959 if (match(Op0, m_One()) &&
lib/Transforms/Scalar/LowerConstantIntrinsics.cpp 66 } else if (match(BI->getOperand(0), m_One())) {
unittests/IR/PatternMatch.cpp 461 EXPECT_TRUE(m_Add(m_One(), m_Zero()).match(X));
462 EXPECT_FALSE(m_Add(m_Zero(), m_One()).match(X));
464 EXPECT_FALSE(m_Unless(m_Add(m_One(), m_Zero())).match(X));
465 EXPECT_TRUE(m_Unless(m_Add(m_Zero(), m_One())).match(X));
467 EXPECT_TRUE(m_c_Add(m_One(), m_Zero()).match(X));
468 EXPECT_TRUE(m_c_Add(m_Zero(), m_One()).match(X));
470 EXPECT_FALSE(m_Unless(m_c_Add(m_One(), m_Zero())).match(X));
471 EXPECT_FALSE(m_Unless(m_c_Add(m_Zero(), m_One())).match(X));
481 EXPECT_TRUE(m_One().match(One32));
482 EXPECT_FALSE(m_One().match(One64Z));
483 EXPECT_FALSE(m_One().match(One64S));
485 EXPECT_FALSE(m_ZExt(m_One()).match(One32));
486 EXPECT_TRUE(m_ZExt(m_One()).match(One64Z));
487 EXPECT_FALSE(m_ZExt(m_One()).match(One64S));
489 EXPECT_FALSE(m_SExt(m_One()).match(One32));
490 EXPECT_FALSE(m_SExt(m_One()).match(One64Z));
491 EXPECT_TRUE(m_SExt(m_One()).match(One64S));
493 EXPECT_TRUE(m_ZExtOrSelf(m_One()).match(One32));
494 EXPECT_TRUE(m_ZExtOrSelf(m_One()).match(One64Z));
495 EXPECT_FALSE(m_ZExtOrSelf(m_One()).match(One64S));
497 EXPECT_TRUE(m_SExtOrSelf(m_One()).match(One32));
498 EXPECT_FALSE(m_SExtOrSelf(m_One()).match(One64Z));
499 EXPECT_TRUE(m_SExtOrSelf(m_One()).match(One64S));
501 EXPECT_FALSE(m_ZExtOrSExt(m_One()).match(One32));
502 EXPECT_TRUE(m_ZExtOrSExt(m_One()).match(One64Z));
503 EXPECT_TRUE(m_ZExtOrSExt(m_One()).match(One64S));
505 EXPECT_TRUE(m_ZExtOrSExtOrSelf(m_One()).match(One32));
506 EXPECT_TRUE(m_ZExtOrSExtOrSelf(m_One()).match(One64Z));
507 EXPECT_TRUE(m_ZExtOrSExtOrSelf(m_One()).match(One64S));