[llvm-commits] CVS: llvm/lib/CodeGen/LiveInterval.cpp

Chris Lattner lattner at cs.uiuc.edu
Wed Nov 17 21:28:34 PST 2004



Changes in directory llvm/lib/CodeGen:

LiveInterval.cpp updated: 1.17 -> 1.18
---
Log message:

There is no need to check to see if j overflowed in this loop as we're only
incrementing i.


---
Diffs of the changes:  (+3 -1)

Index: llvm/lib/CodeGen/LiveInterval.cpp
diff -u llvm/lib/CodeGen/LiveInterval.cpp:1.17 llvm/lib/CodeGen/LiveInterval.cpp:1.18
--- llvm/lib/CodeGen/LiveInterval.cpp:1.17	Wed Nov 17 23:19:02 2004
+++ llvm/lib/CodeGen/LiveInterval.cpp	Wed Nov 17 23:28:21 2004
@@ -82,7 +82,9 @@
     return true;
   }
 
-  while (i != ie && j != je) {
+  if (j == je) return false;
+
+  while (i != ie) {
     if (i->start > j->start) {
       std::swap(i, j);
       std::swap(ie, je);






More information about the llvm-commits mailing list