Home | History | Annotate | Download | only in Utils

Lines Matching refs:SE

46     ScalarEvolution  *SE;
54 SimplifyIndvar(Loop *Loop, ScalarEvolution *SE, LPPassManager *LPM,
58 SE(SE),
112 assert(SE->isSCEVable(IVSrc->getType()) && "Expect SCEVable IV operand");
124 FoldedExpr = SE->getUDivExpr(SE->getSCEV(IVSrc), SE->getSCEV(D));
127 if (!SE->isSCEVable(UseInst->getType()))
131 if (SE->getSCEV(UseInst) != FoldedExpr)
138 assert(SE->getSCEV(UseInst) == FoldedExpr && "bad SCEV with folded oper");
160 const SCEV *S = SE->getSCEV(ICmp->getOperand(IVOperIdx));
161 const SCEV *X = SE->getSCEV(ICmp->getOperand(1 - IVOperIdx));
165 S = SE->getSCEVAtScope(S, ICmpLoop);
166 X = SE->getSCEVAtScope(X, ICmpLoop);
170 if (SE->isKnownPredicate(Pred, S, X))
172 else if (SE->isKnownPredicate(ICmpInst::getInversePredicate(Pred), S, X))
194 const SCEV *S = SE->getSCEV(Rem->getOperand(0));
195 const SCEV *X = SE->getSCEV(Rem->getOperand(1));
199 S = SE->getSCEVAtScope(S, ICmpLoop);
200 X = SE->getSCEVAtScope(X, ICmpLoop);
203 if ((!IsSigned || SE->isKnownNonNegative(S)) &&
204 SE->isKnownPredicate(IsSigned ? ICmpInst::ICMP_SLT : ICmpInst::ICMP_ULT,
210 SE->getMinusSCEV(S, SE->getConstant(S->getType(), 1));
211 if (IsSigned && !SE->isKnownNonNegative(LessOne))
214 if (!SE->isKnownPredicate(IsSigned ?
252 if (!SE->isSCEVable(UseInst->getType()) ||
254 (SE->getSCEV(UseInst) != SE->getSCEV(IVOperand)))
292 static bool isSimpleIVUser(Instruction *I, const Loop *L, ScalarEvolution *SE) {
293 if (!SE->isSCEVable(I->getType()))
297 const SCEV *S = SE->getSCEV(I);
320 if (!SE->isSCEVable(CurrIV->getType()))
361 if (isSimpleIVUser(UseOper.first, L, SE)) {
373 bool simplifyUsersOfIV(PHINode *CurrIV, ScalarEvolution *SE, LPPassManager *LPM,
377 SimplifyIndvar SIV(LI->getLoopFor(CurrIV->getParent()), SE, LPM, Dead);
384 bool simplifyLoopIVs(Loop *L, ScalarEvolution *SE, LPPassManager *LPM,
388 Changed |= simplifyUsersOfIV(cast<PHINode>(I), SE, LPM, Dead);