diff options
| author | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2010-10-05 23:10:04 +0000 |
|---|---|---|
| committer | Jakob Stoklund Olesen <stoklund@2pi.dk> | 2010-10-05 23:10:04 +0000 |
| commit | 0445e2a053679f97e1df657e2606a8fba1724a25 (patch) | |
| tree | a8bf5f497fa4932e5e68d5337726a73bdebfef03 /llvm/lib/CodeGen | |
| parent | cff5b0ea362bca811212c635810797871f188931 (diff) | |
| download | bcm5719-llvm-0445e2a053679f97e1df657e2606a8fba1724a25.tar.gz bcm5719-llvm-0445e2a053679f97e1df657e2606a8fba1724a25.zip | |
dupli always has an interval now.
llvm-svn: 115708
Diffstat (limited to 'llvm/lib/CodeGen')
| -rw-r--r-- | llvm/lib/CodeGen/SplitKit.cpp | 25 |
1 files changed, 11 insertions, 14 deletions
diff --git a/llvm/lib/CodeGen/SplitKit.cpp b/llvm/lib/CodeGen/SplitKit.cpp index 1864e378132..b1ce209d456 100644 --- a/llvm/lib/CodeGen/SplitKit.cpp +++ b/llvm/lib/CodeGen/SplitKit.cpp @@ -798,6 +798,7 @@ SplitEditor::addTruncSimpleRange(SlotIndex Start, SlotIndex End, VNInfo *VNI) { /// instructions using curli to use the new intervals. void SplitEditor::rewrite() { assert(!openli_.getLI() && "Previous LI not closed before rewrite"); + assert(dupli_.getLI() && "No dupli for rewrite. Noop spilt?"); // First we need to fill in the live ranges in dupli. // If values were redefined, we need a full recoloring with SSA update. @@ -863,23 +864,19 @@ void SplitEditor::rewrite() { break; } } - if (LI) { - MO.setReg(LI->reg); - sa_.removeUse(MI); - DEBUG(dbgs() << " rewrite " << Idx << '\t' << *MI); - } + MO.setReg(LI->reg); + sa_.removeUse(MI); + DEBUG(dbgs() << " rewrite " << Idx << '\t' << *MI); } // dupli_ goes in last, after rewriting. - if (dupli_.getLI()) { - if (dupli_.getLI()->empty()) { - DEBUG(dbgs() << " dupli became empty?\n"); - lis_.removeInterval(dupli_.getLI()->reg); - dupli_.reset(0); - } else { - dupli_.getLI()->RenumberValues(lis_); - intervals_.push_back(dupli_.getLI()); - } + if (dupli_.getLI()->empty()) { + DEBUG(dbgs() << " dupli became empty?\n"); + lis_.removeInterval(dupli_.getLI()->reg); + dupli_.reset(0); + } else { + dupli_.getLI()->RenumberValues(lis_); + intervals_.push_back(dupli_.getLI()); } // Calculate spill weight and allocation hints for new intervals. |

