Lines Matching defs:BO
168 if (auto *BO = dyn_cast<BinaryOperator>(Op)) {
169 if (BO->getParent() == Mul->getParent() &&
170 IsFreeTruncation(BO->getOperand(0)) &&
171 IsFreeTruncation(BO->getOperand(1)) &&
362 const auto *BO = dyn_cast<BinaryOperator>(EE.getVectorOperand());
363 if (!BO || BO->getOpcode() != Instruction::Add || !BO->hasOneUse())
365 if (EE.getParent() != BO->getParent())
368 unsigned NumElems = cast<FixedVectorType>(BO->getType())->getNumElements();
373 const Value *Op = BO;
376 const auto *BO = dyn_cast<BinaryOperator>(Op);
377 if (!BO || BO->getOpcode() != Instruction::Add)
379 if (EE.getParent() != BO->getParent())
384 if (i != 0 && !BO->hasNUses(2))
387 Value *LHS = BO->getOperand(0);
388 Value *RHS = BO->getOperand(1);
413 // See if this BO is reachable from this Phi by walking forward through single
416 static bool isReachableFromPHI(PHINode *Phi, BinaryOperator *BO) {
422 if (U == BO)
425 while (U->hasOneUse() && U->getOpcode() == BO->getOpcode())
428 return U == BO;
457 if (auto *BO = dyn_cast<BinaryOperator>(V)) {
458 if (BO->getOpcode() == Instruction::Add) {
460 if (BO->hasNUses(BO == Root ? 2 : 1)) {
461 append_range(Worklist, BO->operands());
467 if (BO->hasNUses(BO == Root ? 3 : 2)) {
469 for (auto *U : BO->users())
480 if (!isReachableFromPHI(PN, BO))
484 append_range(Worklist, BO->operands());