[llvm-commits] [llvm] r159019 - /llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp

Jakob Stoklund Olesen stoklund at 2pi.dk
Fri Jun 22 11:38:57 PDT 2012


Author: stoklund
Date: Fri Jun 22 13:38:57 2012
New Revision: 159019

URL: http://llvm.org/viewvc/llvm-project?rev=159019&view=rev
Log:
Simplify handleMove() a bit.

There is no need to check for physreg live ranges. They don't exist any
more.

Modified:
    llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp

Modified: llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp?rev=159019&r1=159018&r2=159019&view=diff
==============================================================================
--- llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp (original)
+++ llvm/trunk/lib/CodeGen/LiveIntervalAnalysis.cpp Fri Jun 22 13:38:57 2012
@@ -1000,15 +1000,15 @@
 
       // Collect ranges for register units. These live ranges are computed on
       // demand, so just skip any that haven't been computed yet.
-      if (TargetRegisterInfo::isPhysicalRegister(Reg))
+      if (TargetRegisterInfo::isPhysicalRegister(Reg)) {
         for (MCRegUnitIterator Units(Reg, &TRI); Units.isValid(); ++Units)
           if (LiveInterval *LI = LIS.getCachedRegUnit(*Units))
             collectRanges(MO, LI, Entering, Internal, Exiting, OldIdx);
-
-      // Collect ranges for individual registers.
-      if (LIS.hasInterval(Reg))
+      } else {
+        // Collect ranges for individual virtual registers.
         collectRanges(MO, &LIS.getInterval(Reg),
                       Entering, Internal, Exiting, OldIdx);
+      }
     }
   }
 





More information about the llvm-commits mailing list