Lines Matching refs:BECount
117 bool runOnLoopBlock(BasicBlock *BB, const SCEV *BECount,
122 bool processLoopStore(StoreInst *SI, const SCEV *BECount);
123 bool processLoopMemSet(MemSetInst *MSI, const SCEV *BECount);
128 const SCEV *BECount, bool NegStride);
131 const SCEV *BECount, bool NegStride);
217 const SCEV *BECount = SE->getBackedgeTakenCount(CurLoop); in runOnCountableLoop() local
218 assert(!isa<SCEVCouldNotCompute>(BECount) && in runOnCountableLoop()
224 if (const SCEVConstant *BECst = dyn_cast<SCEVConstant>(BECount)) in runOnCountableLoop()
242 MadeChange |= runOnLoopBlock(BB, BECount, ExitBlocks); in runOnCountableLoop()
348 BasicBlock *BB, const SCEV *BECount, in runOnLoopBlock() argument
361 MadeChange |= processLoopStore(SI, BECount); in runOnLoopBlock()
368 if (!processLoopMemSet(MSI, BECount)) in runOnLoopBlock()
384 bool LoopIdiomRecognize::processLoopStore(StoreInst *SI, const SCEV *BECount) { in processLoopStore() argument
402 StoredVal, SI, StoreEv, BECount, NegStride)) in processLoopStore()
406 return processLoopStoreOfLoopLoad(SI, StoreSize, StoreEv, BECount, NegStride); in processLoopStore()
411 const SCEV *BECount) { in processLoopMemSet() argument
445 BECount, /*NegStride=*/false); in processLoopMemSet()
452 const SCEV *BECount, unsigned StoreSize, in mayLoopAccessLocation() argument
462 if (const SCEVConstant *BECst = dyn_cast<SCEVConstant>(BECount)) in mayLoopAccessLocation()
483 static const SCEV *getStartForNegStride(const SCEV *Start, const SCEV *BECount, in getStartForNegStride() argument
486 const SCEV *Index = SE->getTruncateOrZeroExtend(BECount, IntPtr); in getStartForNegStride()
498 const SCEV *BECount, bool NegStride) { in processLoopStridedStore() argument
540 Start = getStartForNegStride(Start, BECount, IntPtr, StoreSize, SE); in processLoopStridedStore()
549 if (mayLoopAccessLocation(BasePtr, MRI_ModRef, CurLoop, BECount, StoreSize, in processLoopStridedStore()
561 BECount = SE->getTruncateOrZeroExtend(BECount, IntPtr); in processLoopStridedStore()
564 SE->getAddExpr(BECount, SE->getOne(IntPtr), SCEV::FlagNUW); in processLoopStridedStore()
613 const SCEV *BECount, bool NegStride) { in processLoopStoreOfLoopLoad() argument
648 StrStart = getStartForNegStride(StrStart, BECount, IntPtrTy, StoreSize, SE); in processLoopStoreOfLoopLoad()
659 if (mayLoopAccessLocation(StoreBasePtr, MRI_ModRef, CurLoop, BECount, in processLoopStoreOfLoopLoad()
672 LdStart = getStartForNegStride(LdStart, BECount, IntPtrTy, StoreSize, SE); in processLoopStoreOfLoopLoad()
679 if (mayLoopAccessLocation(LoadBasePtr, MRI_Mod, CurLoop, BECount, StoreSize, in processLoopStoreOfLoopLoad()
692 BECount = SE->getTruncateOrZeroExtend(BECount, IntPtrTy); in processLoopStoreOfLoopLoad()
695 SE->getAddExpr(BECount, SE->getOne(IntPtrTy), SCEV::FlagNUW); in processLoopStoreOfLoopLoad()