changeset 23153:40f5437c92e9

LSRA: MoveResolver: count number of created stack slots.
author Josef Eisl <josef.eisl@jku.at>
date Thu, 10 Dec 2015 18:21:43 +0100
parents dac2ae5a649f
children f2a8407253da
files graal/com.oracle.graal.lir/src/com/oracle/graal/lir/alloc/lsra/MoveResolver.java
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.graal.lir/src/com/oracle/graal/lir/alloc/lsra/MoveResolver.java	Thu Dec 03 14:26:38 2015 +0100
+++ b/graal/com.oracle.graal.lir/src/com/oracle/graal/lir/alloc/lsra/MoveResolver.java	Thu Dec 10 18:21:43 2015 +0100
@@ -38,6 +38,7 @@
 import jdk.vm.ci.meta.Value;
 
 import com.oracle.graal.debug.Debug;
+import com.oracle.graal.debug.DebugMetric;
 import com.oracle.graal.debug.Indent;
 import com.oracle.graal.lir.LIRInsertionBuffer;
 import com.oracle.graal.lir.LIRInstruction;
@@ -46,6 +47,8 @@
  */
 public class MoveResolver {
 
+    private static final DebugMetric cycleBreakingSlotsAllocated = Debug.metric("LSRA[cycleBreakingSlotsAllocated]");
+
     private final LinearScan allocator;
 
     private int insertIdx;
@@ -369,6 +372,7 @@
         if (spillSlot == null) {
             spillSlot = getAllocator().getFrameMapBuilder().allocateSpillSlot(fromInterval.kind());
             fromInterval.setSpillSlot(spillSlot);
+            cycleBreakingSlotsAllocated.increment();
         }
         spillInterval(spillCandidate, fromInterval, spillSlot);
     }