Lines Matching refs:LF
1751 const LSRFixup &LF,
1755 Value *Expand(const LSRFixup &LF,
1760 void RewriteForPHI(PHINode *PN, const LSRFixup &LF,
1764 void Rewrite(const LSRFixup &LF,
2942 LSRFixup &LF = getNewFixup();
2943 LF.UserInst = UserInst;
2944 LF.OperandValToReplace = U.getOperandValToReplace();
2945 LF.PostIncLoops = U.getPostIncLoops();
2949 if (isAddressUse(LF.UserInst, LF.OperandValToReplace)) {
2951 AccessTy = getAccessType(LF.UserInst);
2962 if (ICmpInst *CI = dyn_cast<ICmpInst>(LF.UserInst))
2967 if (NV == LF.OperandValToReplace) {
2980 LF.PostIncLoops, SE, DT);
2995 LF.LUIdx = P.first;
2996 LF.Offset = P.second;
2997 LSRUse &LU = Uses[LF.LUIdx];
2998 LU.AllFixupsOutsideLoop &= LF.isUseFullyOutsideLoop(L);
3001 SE.getTypeSizeInBits(LF.OperandValToReplace->getType()))
3002 LU.WidestFixupType = LF.OperandValToReplace->getType();
3006 InsertInitialFormula(S, LU, LF.LUIdx);
3007 CountRegisters(LU.Formulae.back(), LF.LUIdx);
3133 LSRFixup &LF = getNewFixup();
3134 LF.UserInst = const_cast<Instruction *>(UserInst);
3135 LF.OperandValToReplace = U;
3138 LF.LUIdx = P.first;
3139 LF.Offset = P.second;
3140 LSRUse &LU = Uses[LF.LUIdx];
3141 LU.AllFixupsOutsideLoop &= LF.isUseFullyOutsideLoop(L);
3144 SE.getTypeSizeInBits(LF.OperandValToReplace->getType()))
3145 LU.WidestFixupType = LF.OperandValToReplace->getType();
3146 InsertSupplementalFormula(US, LU, LF.LUIdx);
4370 const LSRFixup &LF,
4377 if (Instruction *I = dyn_cast<Instruction>(LF.OperandValToReplace))
4381 dyn_cast<Instruction>(cast<ICmpInst>(LF.UserInst)->getOperand(1)))
4383 if (LF.PostIncLoops.count(L)) {
4384 if (LF.isUseFullyOutsideLoop(L))
4391 for (const Loop *PIL : LF.PostIncLoops) {
4433 Value *LSRInstance::Expand(const LSRFixup &LF,
4438 const LSRUse &LU = Uses[LF.LUIdx];
4440 return LF.OperandValToReplace;
4444 IP = AdjustInsertPositionForExpand(IP, LF, LU, Rewriter);
4448 Rewriter.setPostInc(LF.PostIncLoops);
4451 Type *OpTy = LF.OperandValToReplace->getType();
4471 PostIncLoopSet &Loops = const_cast<PostIncLoopSet &>(LF.PostIncLoops);
4473 LF.UserInst, LF.OperandValToReplace,
4485 PostIncLoopSet &Loops = const_cast<PostIncLoopSet &>(LF.PostIncLoops);
4487 LF.UserInst, LF.OperandValToReplace,
4543 int64_t Offset = (uint64_t)F.BaseOffset + LF.Offset;
4582 ICmpInst *CI = cast<ICmpInst>(LF.UserInst);
4619 const LSRFixup &LF,
4625 if (PN->getIncomingValue(i) == LF.OperandValToReplace) {
4672 Value *FullV = Expand(LF, F, BB->getTerminator()->getIterator(),
4676 Type *OpTy = LF.OperandValToReplace->getType();
4681 FullV, LF.OperandValToReplace->getType(),
4693 void LSRInstance::Rewrite(const LSRFixup &LF,
4699 if (PHINode *PN = dyn_cast<PHINode>(LF.UserInst)) {
4700 RewriteForPHI(PN, LF, F, Rewriter, DeadInsts);
4703 Expand(LF, F, LF.UserInst->getIterator(), Rewriter, DeadInsts);
4706 Type *OpTy = LF.OperandValToReplace->getType();
4710 FullV, OpTy, "tmp", LF.UserInst);
4716 // its new value may happen to be equal to LF.OperandValToReplace, in
4719 if (Uses[LF.LUIdx].Kind == LSRUse::ICmpZero)
4720 LF.UserInst->setOperand(0, FullV);
4722 LF.UserInst->replaceUsesOfWith(LF.OperandValToReplace, FullV);
4725 DeadInsts.emplace_back(LF.OperandValToReplace);
4900 for (const LSRFixup &LF : Fixups) {
4902 LF.print(OS);