Rename statistic and add another one.
authorAlkis Evlogimenos <alkis@evlogimenos.com>
Fri, 20 Feb 2004 20:43:08 +0000 (20:43 +0000)
committerAlkis Evlogimenos <alkis@evlogimenos.com>
Fri, 20 Feb 2004 20:43:08 +0000 (20:43 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11674 91177308-0d34-0410-b5e6-96231b3b80d8

lib/CodeGen/LiveIntervalAnalysis.cpp

index 55c0370ad2c018f80851bd204777c6c25f73bab0..53768ae95c2c58e24724624ac1301992c2d9d660 100644 (file)
@@ -42,7 +42,10 @@ namespace {
                                       "Live Interval Analysis");
 
     Statistic<> numIntervals("liveintervals", "Number of intervals");
-    Statistic<> numJoined   ("liveintervals", "Number of joined intervals");
+    Statistic<> numJoined   ("liveintervals", "Number of intervals after "
+                             "coalescing");
+    Statistic<> numJoins    ("liveintervals", "Number of interval joins "
+                             "performed");
     Statistic<> numPeep     ("liveintervals", "Number of identity moves "
                              "eliminated after coalescing");
     Statistic<> numFolded   ("liveintervals", "Number of register operands "
@@ -636,8 +639,8 @@ void LiveIntervals::Interval::join(const LiveIntervals::Interval& other)
         cur = mergeRangesForward(cur);
         cur = mergeRangesBackward(cur);
     }
-    if (MRegisterInfo::isVirtualRegister(reg))
-        weight += other.weight;
+    weight += other.weight;
+    ++numJoins;
 }
 
 LiveIntervals::Interval::Ranges::iterator