Lines Matching refs:DRS
413 bool validateRootSet(DAGRootSet &DRS);
433 void replaceIV(DAGRootSet &DRS, const SCEV *Start, const SCEV *IncrExpr);
883 bool LoopReroll::DAGRootTracker::validateRootSet(DAGRootSet &DRS) { in validateRootSet() argument
884 if (DRS.Roots.empty()) in validateRootSet()
890 if (hasUsesOutsideLoop(DRS.BaseInst, L)) in validateRootSet()
902 const auto *ADR = dyn_cast<SCEVAddRecExpr>(SE->getSCEV(DRS.BaseInst)); in validateRootSet()
907 unsigned N = DRS.Roots.size() + 1; in validateRootSet()
908 const SCEV *StepSCEV = SE->getMinusSCEV(SE->getSCEV(DRS.Roots[0]), ADR); in validateRootSet()
917 const SCEV *NewStepSCEV = SE->getMinusSCEV(SE->getSCEV(DRS.Roots[i]), in validateRootSet()
918 SE->getSCEV(DRS.Roots[i-1])); in validateRootSet()
943 DAGRootSet DRS; in findRootsBase() local
944 DRS.BaseInst = nullptr; in findRootsBase()
949 if (!DRS.BaseInst) { in findRootsBase()
950 DRS.BaseInst = KV.second; in findRootsBase()
951 DRS.SubsumedInsts = SubsumedInsts; in findRootsBase()
952 } else if (DRS.Roots.empty()) { in findRootsBase()
953 DRS.Roots.push_back(KV.second); in findRootsBase()
955 DRS.Roots.push_back(KV.second); in findRootsBase()
958 if (!validateRootSet(DRS)) in findRootsBase()
962 PotentialRootSets.push_back(DRS); in findRootsBase()
963 DRS.BaseInst = KV.second; in findRootsBase()
964 DRS.Roots.clear(); in findRootsBase()
968 if (!validateRootSet(DRS)) in findRootsBase()
971 PotentialRootSets.push_back(DRS); in findRootsBase()
1031 for (auto &DRS : RootSets) { in collectUsedInstructions() local
1032 Exclude.insert(DRS.Roots.begin(), DRS.Roots.end()); in collectUsedInstructions()
1033 Exclude.insert(DRS.SubsumedInsts.begin(), DRS.SubsumedInsts.end()); in collectUsedInstructions()
1034 Exclude.insert(DRS.BaseInst); in collectUsedInstructions()
1038 for (auto &DRS : RootSets) { in collectUsedInstructions() local
1040 collectInLoopUserSet(DRS.BaseInst, Exclude, PossibleRedSet, VBase); in collectUsedInstructions()
1046 for (auto *Root : DRS.Roots) { in collectUsedInstructions()
1063 for (auto *I : DRS.SubsumedInsts) { in collectUsedInstructions()
1071 for (auto &DRS : RootSets) { in collectUsedInstructions() local
1072 Exclude.insert(DRS.Roots.begin(), DRS.Roots.end()); in collectUsedInstructions()
1073 Exclude.insert(DRS.SubsumedInsts.begin(), DRS.SubsumedInsts.end()); in collectUsedInstructions()
1074 Exclude.insert(DRS.BaseInst); in collectUsedInstructions()
1107 for (auto &DRS : RootSets) { in isBaseInst() local
1108 if (DRS.BaseInst == I) in isBaseInst()
1115 for (auto &DRS : RootSets) { in isRootInst() local
1116 if (is_contained(DRS.Roots, I)) in isRootInst()
1382 for (auto &DRS : RootSets) { in validate() local
1383 if (DRS.Roots[Iter-1] == (Instruction*) Op2) { in validate()
1384 Op2 = DRS.BaseInst; in validate()
1446 for (auto &DRS : RootSets) { in replace() local
1448 cast<SCEVAddRecExpr>(SE->getSCEV(DRS.BaseInst)); in replace()
1450 IncrExprs.push_back(SE->getMinusSCEV(SE->getSCEV(DRS.Roots[0]), IVSCEV)); in replace()
1497 void LoopReroll::DAGRootTracker::replaceIV(DAGRootSet &DRS, in replaceIV() argument
1501 Instruction *Inst = DRS.BaseInst; in replaceIV()