LiveIntervals::Interval::liveAt. Both were considering the live ranges
closed in the end, when they are actually open.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10835
91177308-0d34-0410-b5e6-
96231b3b80d8
bool LiveIntervals::Interval::liveAt(unsigned index) const
{
Ranges::const_iterator r = ranges.begin();
- while (r != ranges.end() && index < r->second) {
+ while (r != ranges.end() && index < (r->second - 1)) {
if (index >= r->first)
return true;
++r;
while (i != ranges.end() && j != other.ranges.end()) {
if (i->first < j->first) {
- if (i->second > j->first) {
+ if ((i->second - 1) > j->first) {
return true;
}
else {
}
}
else if (j->first < i->first) {
- if (j->second > i->first) {
+ if ((j->second - 1) > i->first) {
return true;
}
else {