Home | History | Annotate | Download | only in Scalar

Lines Matching defs:Ins

93           Stride(nullptr), Ins(nullptr), Basis(nullptr) {}
96 : CandidateKind(CT), Base(B), Index(Idx), Stride(S), Ins(I),
119 Instruction *Ins;
226 return (Basis.Ins != C.Ins && // skip the same instruction
229 Basis.Ins->getType() == C.Ins->getType() &&
231 DT->dominates(Basis.Ins->getParent(), C.Ins->getParent()) &&
290 return isGEPFoldable(cast<GetElementPtrInst>(C.Ins), TTI, DL);
317 hasOnlyOneNonZeroIndex(cast<GetElementPtrInst>(C.Ins)));
570 cast<GetElementPtrInst>(Basis.Ins)->getType()->getElementType()));
590 IntegerType::get(Basis.Ins->getContext(), IndexOffset.getBitWidth());
613 assert(Basis.Ins->getParent() != nullptr && "the basis is unlinked");
619 if (!C.Ins->getParent())
622 IRBuilder<> Builder(C.Ins);
625 Value *Reduced = nullptr; // equivalent to but weaker than C.Ins
633 Builder.CreateSub(Basis.Ins, BinaryOperator::getNegArgument(Bump));
647 Reduced = Builder.CreateAdd(Basis.Ins, Bump);
652 Type *IntPtrTy = DL->getIntPtrType(C.Ins->getType());
653 bool InBounds = cast<GetElementPtrInst>(C.Ins)->isInBounds();
656 unsigned AS = Basis.Ins->getType()->getPointerAddressSpace();
657 Type *CharTy = Type::getInt8PtrTy(Basis.Ins->getContext(), AS);
658 Reduced = Builder.CreateBitCast(Basis.Ins, CharTy);
664 Reduced = Builder.CreateBitCast(Reduced, C.Ins->getType());
670 Reduced = Builder.CreateInBoundsGEP(nullptr, Basis.Ins, Bump);
672 Reduced = Builder.CreateGEP(nullptr, Basis.Ins, Bump);
679 Reduced->takeName(C.Ins);
680 C.Ins->replaceAllUsesWith(Reduced);
681 // Unlink C.Ins so that we can skip other candidates also corresponding to
682 // C.Ins. The actual deletion is postponed to the end of runOnFunction.
683 C.Ins->removeFromParent();
684 UnlinkedInstructions.push_back(C.Ins);