Lines Matching defs:Ins
144 : CandidateKind(CT), Base(B), Index(Idx), Stride(S), Ins(I) {}
171 Instruction *Ins = nullptr;
270 return (Basis.Ins != C.Ins && // skip the same instruction
273 Basis.Ins->getType() == C.Ins->getType() &&
275 DT->dominates(Basis.Ins->getParent(), C.Ins->getParent()) &&
303 return isGEPFoldable(cast<GetElementPtrInst>(C.Ins), TTI);
330 hasOnlyOneNonZeroIndex(cast<GetElementPtrInst>(C.Ins)));
594 IntegerType::get(Basis.Ins->getContext(), IndexOffset.getBitWidth());
617 assert(Basis.Ins->getParent() != nullptr && "the basis is unlinked");
623 if (!C.Ins->getParent())
626 IRBuilder<> Builder(C.Ins);
628 Value *Reduced = nullptr; // equivalent to but weaker than C.Ins
636 Reduced = Builder.CreateSub(Basis.Ins, NegBump);
650 Reduced = Builder.CreateAdd(Basis.Ins, Bump);
655 bool InBounds = cast<GetElementPtrInst>(C.Ins)->isInBounds();
657 Reduced = Builder.CreatePtrAdd(Basis.Ins, Bump, "", InBounds);
663 Reduced->takeName(C.Ins);
664 C.Ins->replaceAllUsesWith(Reduced);
665 // Unlink C.Ins so that we can skip other candidates also corresponding to
666 // C.Ins. The actual deletion is postponed to the end of runOnFunction.
667 C.Ins->removeFromParent();
668 UnlinkedInstructions.push_back(C.Ins);