changeset 15223:7d6c2a0e60a8

Merge.
author Thomas Wuerthinger <thomas.wuerthinger@oracle.com>
date Fri, 18 Apr 2014 02:00:35 +0200
parents 58d2c5bdb9cd (current diff) b7dbf9403902 (diff)
children 735147ef0176
files
diffstat 3 files changed, 17 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.graal.hotspot.test/src/com/oracle/graal/hotspot/test/CompressedOopTest.java	Fri Apr 18 02:00:24 2014 +0200
+++ b/graal/com.oracle.graal.hotspot.test/src/com/oracle/graal/hotspot/test/CompressedOopTest.java	Fri Apr 18 02:00:35 2014 +0200
@@ -200,7 +200,7 @@
         while (j < objects.length) {
             if (!installedBenchmarkCode.isValid()) {
                 // This can get invalidated due to lack of MDO update
-                installedBenchmarkCode = getInstalledCode("queueTest");
+                installedBenchmarkCode = getInstalledCode("queueTest", Object.class, Object.class);
             }
             installedBenchmarkCode.executeVarargs(q, objects[j]);
             j++;
--- a/graal/com.oracle.graal.java/src/com/oracle/graal/java/GraphBuilderPhase.java	Fri Apr 18 02:00:24 2014 +0200
+++ b/graal/com.oracle.graal.java/src/com/oracle/graal/java/GraphBuilderPhase.java	Fri Apr 18 02:00:35 2014 +0200
@@ -284,12 +284,12 @@
             protected void finishPrepare(FixedWithNextNode startInstr) {
             }
 
-            private BciBlock unwindBlock(int bci) {
+            private BciBlock unwindBlock() {
                 if (unwindBlock == null) {
                     unwindBlock = new ExceptionDispatchBlock();
                     unwindBlock.startBci = -1;
                     unwindBlock.endBci = -1;
-                    unwindBlock.deoptBci = bci;
+                    unwindBlock.deoptBci = FrameState.UNWIND_BCI;
                     unwindBlock.setId(Integer.MAX_VALUE);
                 }
                 return unwindBlock;
@@ -419,7 +419,7 @@
                  * unwind immediately.
                  */
                 if (bci != currentBlock.endBci || dispatchBlock == null) {
-                    dispatchBlock = unwindBlock(bci);
+                    dispatchBlock = unwindBlock();
                 }
 
                 HIRFrameStateBuilder dispatchState = frameState.copy();
@@ -1188,7 +1188,7 @@
                     ResolvedJavaType resolvedCatchType = (ResolvedJavaType) catchType;
                     for (ResolvedJavaType skippedType : graphBuilderConfig.getSkippedExceptionTypes()) {
                         if (skippedType.isAssignableFrom(resolvedCatchType)) {
-                            BciBlock nextBlock = block.getSuccessorCount() == 1 ? unwindBlock(block.deoptBci) : block.getSuccessor(1);
+                            BciBlock nextBlock = block.getSuccessorCount() == 1 ? unwindBlock() : block.getSuccessor(1);
                             ValueNode exception = frameState.stackAt(0);
                             FixedNode trueSuccessor = currentGraph.add(new DeoptimizeNode(InvalidateReprofile, UnreachedCode));
                             FixedNode nextDispatch = createTarget(nextBlock, frameState);
@@ -1199,7 +1199,7 @@
                 }
 
                 if (initialized) {
-                    BciBlock nextBlock = block.getSuccessorCount() == 1 ? unwindBlock(block.deoptBci) : block.getSuccessor(1);
+                    BciBlock nextBlock = block.getSuccessorCount() == 1 ? unwindBlock() : block.getSuccessor(1);
                     ValueNode exception = frameState.stackAt(0);
                     CheckCastNode checkCast = currentGraph.add(new CheckCastNode((ResolvedJavaType) catchType, exception, null, false));
                     frameState.apop();
--- a/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/FrameState.java	Fri Apr 18 02:00:24 2014 +0200
+++ b/graal/com.oracle.graal.nodes/src/com/oracle/graal/nodes/FrameState.java	Fri Apr 18 02:00:35 2014 +0200
@@ -54,31 +54,37 @@
     /**
      * This BCI should be used for frame states that are built for code with no meaningful BCI.
      */
-    public static final int UNKNOWN_BCI = -4;
+    public static final int UNKNOWN_BCI = -5;
+
+    /**
+     * The BCI for the exception unwind block, i.e., the block containing the {@link UnwindNode}.
+     * This block and node is synthetic and has no representation in bytecode.
+     */
+    public static final int UNWIND_BCI = -1;
 
     /**
      * When a node whose frame state has this BCI value is inlined, its frame state will be replaced
      * with the frame state before the inlined invoke node.
      */
-    public static final int BEFORE_BCI = -1;
+    public static final int BEFORE_BCI = -2;
 
     /**
      * When a node whose frame state has this BCI value is inlined, its frame state will be replaced
      * with the frame state {@linkplain Invoke#stateAfter() after} the inlined invoke node.
      */
-    public static final int AFTER_BCI = -2;
+    public static final int AFTER_BCI = -3;
 
     /**
      * When a node whose frame state has this BCI value is inlined, its frame state will be replaced
      * with the frame state at the exception edge of the inlined invoke node.
      */
-    public static final int AFTER_EXCEPTION_BCI = -3;
+    public static final int AFTER_EXCEPTION_BCI = -4;
 
     /**
      * This BCI should be used for frame states that cannot be the target of a deoptimization, like
      * snippet frame states.
      */
-    public static final int INVALID_FRAMESTATE_BCI = -5;
+    public static final int INVALID_FRAMESTATE_BCI = -6;
 
     @Input(InputType.State) private FrameState outerFrameState;