Lines Matching full:segments
66 if (I == segments().end()) { in createDeadDef()
88 segments().insert(I, Segment(Def, Def.getDeadSlot(), VNI)); in createDeadDef()
93 if (segments().empty()) in extendInBlock()
97 if (I == segments().begin()) in extendInBlock()
109 /// merge and eliminate all segments that this will overlap
112 assert(I != segments().end() && "Not a valid segment!"); in extendSegmentEndTo()
118 for (; MergeTo != segments().end() && NewEnd >= MergeTo->end; ++MergeTo) in extendSegmentEndTo()
125 // have the same value number, merge the two segments into one segment. in extendSegmentEndTo()
126 if (MergeTo != segments().end() && MergeTo->start <= I->end && in extendSegmentEndTo()
132 // Erase any dead segments. in extendSegmentEndTo()
133 segments().erase(std::next(I), MergeTo); in extendSegmentEndTo()
138 /// merge and eliminate all segments that this will overlap with.
140 assert(I != segments().end() && "Not a valid segment!"); in extendSegmentStartTo()
147 if (MergeTo == segments().begin()) { in extendSegmentStartTo()
149 segments().erase(MergeTo, I); in extendSegmentStartTo()
168 segments().erase(std::next(MergeTo), std::next(I)); in extendSegmentStartTo()
178 if (I != segments().begin()) { in addSegment()
186 // Check to make sure that we are not overlapping two live segments with in addSegment()
189 "Cannot overlap two segments with differing ValID's" in addSegment()
196 if (I != segments().end()) { in addSegment()
208 // Check to make sure that we are not overlapping two live segments with in addSegment()
211 "Cannot overlap two segments with differing ValID's"); in addSegment()
218 return segments().insert(I, S); in addSegment()
224 CollectionT &segments() { return impl().segmentsColl(); } in segments() function in __anon2acf1db40111::CalcLiveRangeUtilBase
236 LiveRange::Segments> CalcLiveRangeUtilVectorBase;
245 LiveRange::Segments &segmentsColl() { return LR->segments; } in segmentsColl()
247 void insertAtEnd(const Segment &S) { LR->segments.push_back(S); } in insertAtEnd()
445 for (const Segment &O : Other.segments) { in covers()
450 // Check adjacent live segments and see if we can get behind O.end. in covers()
480 for (const Segment &S : segments) { in RenumberValues()
506 assert(segments.empty() || segments.back().end <= S.start); in append()
507 segments.push_back(S); in append()
549 segments.erase(I); // Removed the whole Segment. in removeSegment()
567 segments.insert(std::next(I), Segment(End, OldEnd, ValNo)); in removeSegment()
570 /// removeValNo - Remove all the segments defined by the specified value#.
574 segments.erase(std::remove_if(begin(), end(), [ValNo](const Segment &S) { in removeValNo()
626 // If we merge some segments, chop off the end. in join()
628 segments.erase(OutIt, end()); in join()
633 // touching segments that now have identical values. That's OK since Other is in join()
635 for (Segment &S : Other.segments) in join()
654 // Okay, now insert the RHS live segments into the LHS. in join()
656 for (Segment &S : Other.segments) in join()
660 /// Merge all of the segments in RHS into this live range as the specified
661 /// value number. The segments in RHS are allowed to overlap with segments in
662 /// the current range, but only if the overlapping segments have the
667 for (const Segment &S : RHS.segments) in MergeSegmentsInAsValue()
671 /// MergeValueInAsValue - Merge all of the live segments of a specific val#
673 /// The segments in RHS are allowed to overlap with segments in the
675 /// segments with the specified value number.
680 for (const Segment &S : RHS.segments) in MergeValueInAsValue()
687 /// segments with the V1 value number with the V2 value number. This can
703 // Merge V1 segments into V2. in MergeValueNumberInto()
716 segments.erase(S); in MergeValueNumberInto()
726 // If we can merge it into later V2 segments, do so now. We ignore any in MergeValueNumberInto()
727 // following V1 segments, as they will be merged in subsequent iterations in MergeValueNumberInto()
732 segments.erase(I); in MergeValueNumberInto()
747 segments.empty() && in flushSegmentSet()
749 segments.append(segmentSet->begin(), segmentSet->end()); in flushSegmentSet()
766 // If there are no segments that end after the first slot, we're done. in isLiveAtIndexes()
822 for (const Segment &S : segments) in getSize()
841 for (const Segment &S : segments) { in print()
945 // Otherwise, segments are kept in three separate areas:
952 // - Segments in all three areas are fully ordered and coalesced.
953 // - Segments in area 1 precede and can't coalesce with segments in area 2.
954 // - Segments in Spills precede and can't coalesce with segments in area 2.
955 // - No coalescing is possible between segments in Spills and segments in area
956 // 1, and there are no overlapping segments.
958 // The segments in Spills are not ordered with respect to the segments in area
994 assert(A.start <= B.start && "Unordered live segments."); in coalescable()
1018 assert(Spills.empty() && "Leftover spilled segments"); in add()
1079 LR->segments.push_back(Seg); in add()
1085 // Merge as many spilled segments as possible into the gap between WriteI
1120 LR->segments.erase(WriteI, ReadI); in flush()
1130 LR->segments.insert(ReadI, Spills.size() - GapSize, LiveRange::Segment()); in flush()
1135 LR->segments.erase(WriteI + Spills.size(), ReadI); in flush()