Lines Matching refs:ToBePromoted
7126 void promoteImpl(Instruction *ToBePromoted);
7254 bool canPromote(const Instruction *ToBePromoted) const { in canPromote()
7256 return isa<BinaryOperator>(ToBePromoted); in canPromote()
7261 bool shouldPromote(const Instruction *ToBePromoted) const { in shouldPromote()
7264 for (const Use &U : ToBePromoted->operands()) { in shouldPromote()
7270 if (canCauseUndefinedBehavior(ToBePromoted, U.getOperandNo())) in shouldPromote()
7279 int ISDOpcode = TLI.InstructionOpcodeToISD(ToBePromoted->getOpcode()); in shouldPromote()
7293 void enqueueForPromotion(Instruction *ToBePromoted) { in enqueueForPromotion() argument
7294 InstsToBePromoted.push_back(ToBePromoted); in enqueueForPromotion()
7318 for (auto &ToBePromoted : InstsToBePromoted) in promote() local
7319 promoteImpl(ToBePromoted); in promote()
7327 void VectorPromoteHelper::promoteImpl(Instruction *ToBePromoted) { in promoteImpl() argument
7336 assert(ToBePromoted->getType() == Transition->getType() && in promoteImpl()
7339 ToBePromoted->replaceAllUsesWith(Transition); in promoteImpl()
7343 ToBePromoted->mutateType(TransitionTy); in promoteImpl()
7347 for (Use &U : ToBePromoted->operands()) { in promoteImpl()
7358 canCauseUndefinedBehavior(ToBePromoted, U.getOperandNo())); in promoteImpl()
7362 ToBePromoted->setOperand(U.getOperandNo(), NewVal); in promoteImpl()
7364 Transition->moveAfter(ToBePromoted); in promoteImpl()
7365 Transition->setOperand(getTransitionOriginalValueIdx(), ToBePromoted); in promoteImpl()
7392 Instruction *ToBePromoted = cast<Instruction>(*Inst->user_begin()); in optimizeExtractElementInst() local
7393 LLVM_DEBUG(dbgs() << "Use: " << *ToBePromoted << '\n'); in optimizeExtractElementInst()
7395 if (ToBePromoted->getParent() != Parent) { in optimizeExtractElementInst()
7397 << ToBePromoted->getParent()->getName() in optimizeExtractElementInst()
7403 if (VPH.canCombine(ToBePromoted)) { in optimizeExtractElementInst()
7405 << "will be combined with: " << *ToBePromoted << '\n'); in optimizeExtractElementInst()
7406 VPH.recordCombineInstruction(ToBePromoted); in optimizeExtractElementInst()
7413 if (!VPH.canPromote(ToBePromoted) || !VPH.shouldPromote(ToBePromoted)) in optimizeExtractElementInst()
7418 VPH.enqueueForPromotion(ToBePromoted); in optimizeExtractElementInst()
7419 Inst = ToBePromoted; in optimizeExtractElementInst()