Lines Matching refs:Op
25 for (auto &Op : I.operands()) { in extractOperandsFromModule() local
27 if (Value *Reduced = ReduceValue(Op)) in extractOperandsFromModule()
28 Op.set(Reduced); in extractOperandsFromModule()
35 static bool isOne(Use &Op) { in isOne() argument
36 auto *C = dyn_cast<Constant>(Op); in isOne()
40 static bool isZero(Use &Op) { in isZero() argument
41 auto *C = dyn_cast<Constant>(Op); in isZero()
45 static bool isZeroOrOneFP(Value *Op) { in isZeroOrOneFP() argument
47 return match(Op, m_APFloat(C)) && in isZeroOrOneFP()
51 static bool shouldReduceOperand(Use &Op) { in shouldReduceOperand() argument
52 Type *Ty = Op->getType(); in shouldReduceOperand()
57 if (isa<GEPOperator>(Op.getUser())) in shouldReduceOperand()
59 if (auto *CB = dyn_cast<CallBase>(Op.getUser())) { in shouldReduceOperand()
60 if (&CB->getCalledOperandUse() == &Op) in shouldReduceOperand()
68 auto ReduceValue = [](Use &Op) -> Value * { in reduceOperandsOneDeltaPass() argument
69 if (!shouldReduceOperand(Op)) in reduceOperandsOneDeltaPass()
72 Type *Ty = Op->getType(); in reduceOperandsOneDeltaPass()
75 return (isOne(Op) || isZero(Op)) ? nullptr : ConstantInt::get(IntTy, 1); in reduceOperandsOneDeltaPass()
79 return isZeroOrOneFP(Op) ? nullptr : ConstantFP::get(Ty, 1.0); in reduceOperandsOneDeltaPass()
82 if (isOne(Op) || isZero(Op) || isZeroOrOneFP(Op)) in reduceOperandsOneDeltaPass()
102 auto ReduceValue = [](Use &Op) -> Value * { in reduceOperandsZeroDeltaPass() argument
103 if (!shouldReduceOperand(Op)) in reduceOperandsZeroDeltaPass()
106 return isZero(Op) ? nullptr : Constant::getNullValue(Op->getType()); in reduceOperandsZeroDeltaPass()
115 auto ReduceValue = [](Use &Op) -> Value * { in reduceOperandsNaNDeltaPass() argument
116 Type *Ty = Op->getType(); in reduceOperandsNaNDeltaPass()
124 if (match(Op.get(), m_NaN()) || isZeroOrOneFP(Op.get())) in reduceOperandsNaNDeltaPass()