Lines Matching refs:GEP
138 GEP, // &B[..][i * S][..] enumerator
213 void allocateCandidatesAndFindBasisForGEP(GetElementPtrInst *GEP);
234 GetElementPtrInst *GEP);
285 static bool isGEPFoldable(GetElementPtrInst *GEP, in isGEPFoldable() argument
287 SmallVector<const Value *, 4> Indices(GEP->indices()); in isGEPFoldable()
288 return TTI->getGEPCost(GEP->getSourceElementType(), GEP->getPointerOperand(), in isGEPFoldable()
306 if (C.CandidateKind == Candidate::GEP) in isFoldable()
312 static bool hasOnlyOneNonZeroIndex(GetElementPtrInst *GEP) { in hasOnlyOneNonZeroIndex() argument
314 for (Use &Idx : GEP->indices()) { in hasOnlyOneNonZeroIndex()
331 if (C.CandidateKind == Candidate::GEP) { in isSimplestForm()
490 allocateCandidatesAndFindBasis(Candidate::GEP, B, ScaledIdx, S, I); in allocateCandidatesAndFindBasisForGEP()
496 GetElementPtrInst *GEP) { in factorArrayIndex() argument
500 ArrayIdx, ElementSize, GEP); in factorArrayIndex()
517 allocateCandidatesAndFindBasisForGEP(Base, RHS, LHS, ElementSize, GEP); in factorArrayIndex()
524 allocateCandidatesAndFindBasisForGEP(Base, PowerOf2, LHS, ElementSize, GEP); in factorArrayIndex()
529 GetElementPtrInst *GEP) { in allocateCandidatesAndFindBasisForGEP() argument
531 if (GEP->getType()->isVectorTy()) in allocateCandidatesAndFindBasisForGEP()
535 for (Use &Idx : GEP->indices()) in allocateCandidatesAndFindBasisForGEP()
538 gep_type_iterator GTI = gep_type_begin(GEP); in allocateCandidatesAndFindBasisForGEP()
539 for (unsigned I = 1, E = GEP->getNumOperands(); I != E; ++I, ++GTI) { in allocateCandidatesAndFindBasisForGEP()
548 const SCEV *BaseExpr = SE->getGEPExpr(cast<GEPOperator>(GEP), IndexExprs); in allocateCandidatesAndFindBasisForGEP()
549 Value *ArrayIdx = GEP->getOperand(I); in allocateCandidatesAndFindBasisForGEP()
552 DL->getPointerSizeInBits(GEP->getAddressSpace())) { in allocateCandidatesAndFindBasisForGEP()
555 factorArrayIndex(ArrayIdx, BaseExpr, ElementSize, GEP); in allocateCandidatesAndFindBasisForGEP()
563 DL->getPointerSizeInBits(GEP->getAddressSpace())) { in allocateCandidatesAndFindBasisForGEP()
566 factorArrayIndex(TruncatedArrayIdx, BaseExpr, ElementSize, GEP); in allocateCandidatesAndFindBasisForGEP()
591 if (Basis.CandidateKind == Candidate::GEP) { in emitBump()
676 case Candidate::GEP: in rewriteCandidateWithBasis()