Lines Matching full:regions

1 //===- IROutliner.cpp -- Outline Similar Regions ----------------*- C++ -*-===//
68 /// a set of regions that are structurally similar to one another, such as the
70 /// and a list of the different regions. This information is used in the
71 /// deduplication of extracted regions with the same structure.
74 std::vector<OutlinableRegion *> Regions; member
127 /// Regions.
130 /// Regions.
137 /// For the \ref Regions, we look at every Value. If it is a constant,
144 /// For the regions, look at each set of GVN stores needed and account for
213 /// when PHINodes are included in outlined regions.
601 for (OutlinableRegion *Region : Regions) in findSameConstants()
606 for (OutlinableRegion *OS : Regions) in collectGVNStoreSets()
616 /// Get the subprogram if it exists for one of the outlined regions.
618 /// \param [in] Group - The set of regions to find a subprogram for.
621 for (OutlinableRegion *OS : Group.Regions) in getSubprogramOrNull()
642 for (OutlinableRegion *R : Group.Regions) { in createFunction()
858 /// have the same constant value in the regions structurally similar to
903 // TODO: Support regions with sunken allocas: values whose lifetimes are in getCodeExtractorArguments()
1019 // same inputs for all of the different regions contained in the in findExtractedInputToOverallInputMapping()
1168 /// identify different output schemes for the set of regions.
1424 /// function constructed from the deduplicated similar regions, replacing and
1429 /// \param [in] Region - The regions of extracted code to be replaced with a new
1699 OutlinableRegion *FirstRegion = Group.Regions[0]; in findOrCreatePHIInBlock()
1800 /// function to define the overall outlined function for all the regions, or
1801 /// if we are operating on one of the following regions.
1884 Region.findCorrespondingValueIn(*Group.Regions[0], ValueOperand); in replaceArgumentUses()
2064 /// \param [in] OG - The OutlinableGroup of regions to be outlined.
2150 /// \param [in] OG - The group of regions to be outlined.
2159 // regions. The second will occur when we have two outputs that are combined in createSwitchStatement()
2234 /// the extracted regions of a certain structure from the first region in the
2235 /// list of regions. Replace this first region's extracted function with the
2239 /// \param [in] CurrentGroup - The group of regions to be outlined.
2251 OutlinableRegion *CurrentOS = CurrentGroup.Regions[0]; in fillOverallFunction()
2308 for (unsigned Idx = 1; Idx < CurrentGroup.Regions.size(); Idx++) { in deduplicateExtractedSections()
2309 CurrentOS = CurrentGroup.Regions[Idx]; in deduplicateExtractedSections()
2461 // Greedily prune out any regions that will overlap with already chosen in pruneIncompatibleRegions()
2462 // regions. in pruneIncompatibleRegions()
2478 CurrentGroup.Regions.push_back(OS); in pruneIncompatibleRegions()
2487 for (OutlinableRegion *Region : CurrentGroup.Regions) { in findBenefitFromAllRegions()
2531 for (OutlinableRegion *Region : CurrentGroup.Regions) { in findCostOutputReloads()
2565 OutlinableRegion &FirstRegion = *CurrentGroup.Regions[0]; in findCostForOutputBlocks()
2566 IRSimilarityCandidate &Candidate = *CurrentGroup.Regions[0]->Candidate; in findCostForOutputBlocks()
2642 RegionBenefit / CurrentGroup.Regions.size(); in findCostBenefit()
2644 unsigned NumRegions = CurrentGroup.Regions.size(); in findCostBenefit()
2646 getTTI(*CurrentGroup.Regions[0]->Candidate->getFunction()); in findCostBenefit()
2749 // The sequences of outlinable regions has now changed. We must fix the in extractSection()
2821 // We pruned the number of regions to 0 to 1, meaning that it's not worth in doOutline()
2824 if (CurrentGroup.Regions.size() < 2) in doOutline()
2839 for (OutlinableRegion *OS : CurrentGroup.Regions) { in doOutline()
2865 CurrentGroup.Regions = std::move(OutlinedRegions); in doOutline()
2867 if (CurrentGroup.Regions.empty()) in doOutline()
2879 getORE(*CurrentGroup.Regions[0]->Candidate->getFunction()); in doOutline()
2881 IRSimilarityCandidate *C = CurrentGroup.Regions[0]->Candidate; in doOutline()
2885 << ore::NV(std::to_string(CurrentGroup.Regions.size())) in doOutline()
2886 << " regions due to estimated increase of " in doOutline()
2891 CurrentGroup.Regions.begin(), CurrentGroup.Regions.end(), in doOutline()
2919 for (OutlinableRegion *Region : CurrentGroup.Regions) { in doOutline()
2931 // we are still outlining enough regions to make up for the added cost. in doOutline()
2932 CurrentGroup.Regions = std::move(OutlinedRegions); in doOutline()
2941 for (OutlinableRegion *Region : CurrentGroup.Regions) { in doOutline()
2948 CurrentGroup.Regions = std::move(OutlinedRegions); in doOutline()
2949 if (CurrentGroup.Regions.size() < 2) { in doOutline()
2950 for (OutlinableRegion *R : CurrentGroup.Regions) in doOutline()
2955 LLVM_DEBUG(dbgs() << "Outlining regions with cost " << CurrentGroup.Cost in doOutline()
2960 for (OutlinableRegion *OS : CurrentGroup.Regions) { in doOutline()
2982 CurrentGroup.Regions = std::move(OutlinedRegions); in doOutline()
2984 if (CurrentGroup.Regions.empty()) in doOutline()
2988 getORE(*CurrentGroup.Regions[0]->Call->getFunction()); in doOutline()
2990 IRSimilarityCandidate *C = CurrentGroup.Regions[0]->Candidate; in doOutline()
2992 R << "outlined " << ore::NV(std::to_string(CurrentGroup.Regions.size())) in doOutline()
2993 << " regions with decrease of " in doOutline()
2997 CurrentGroup.Regions.begin(), CurrentGroup.Regions.end(), in doOutline()