changeset 9578:5cf60de9d7d2

Merge.
author Doug Simon <doug.simon@oracle.com>
date Mon, 06 May 2013 16:29:36 +0200
parents ffd3d85e055f (current diff) d6bf345d58c1 (diff)
children ff153f4ae48b
files
diffstat 3 files changed, 14 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.graal.loop/src/com/oracle/graal/loop/CountedLoopInfo.java	Mon May 06 15:22:59 2013 +0200
+++ b/graal/com.oracle.graal.loop/src/com/oracle/graal/loop/CountedLoopInfo.java	Mon May 06 16:29:36 2013 +0200
@@ -140,7 +140,7 @@
                 cond = graph.unique(new IntegerLessThanNode(v1, end));
             } else {
                 assert iv.direction() == Direction.Down;
-                IntegerArithmeticNode v1 = add(ConstantNode.forIntegerKind(kind, kind.getMinValue(), graph), add(iv.strideNode(), one));
+                IntegerArithmeticNode v1 = add(ConstantNode.forIntegerKind(kind, kind.getMinValue(), graph), sub(one, iv.strideNode()));
                 if (oneOff) {
                     v1 = add(v1, one);
                 }
--- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/ExpandLogicPhase.java	Mon May 06 15:22:59 2013 +0200
+++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/ExpandLogicPhase.java	Mon May 06 16:29:36 2013 +0200
@@ -34,6 +34,7 @@
         for (LogicBinaryNode logic : graph.getNodes(LogicBinaryNode.class)) {
             processBinary(logic);
         }
+        assert graph.getNodes(LogicBinaryNode.class).isEmpty();
     }
 
     private static void processBinary(LogicBinaryNode binary) {
--- a/src/share/vm/runtime/deoptimization.cpp	Mon May 06 15:22:59 2013 +0200
+++ b/src/share/vm/runtime/deoptimization.cpp	Mon May 06 16:29:36 2013 +0200
@@ -1344,8 +1344,19 @@
     // Ensure that we can record deopt. history:
     bool create_if_missing = ProfileTraps;
 
+    methodHandle profiled_method;
+#ifdef GRAAL
+    if (nm->is_compiled_by_graal()) {
+      profiled_method = nm->method();
+    } else {
+      profiled_method = trap_method;
+    }
+#else
+    profiled_method = trap_method;
+#endif
+
     MethodData* trap_mdo =
-      get_method_data(thread, trap_method, create_if_missing);
+      get_method_data(thread, profiled_method, create_if_missing);
 
     // Log a message
     Events::log_deopt_message(thread, "Uncommon trap: reason=%s action=%s pc=" INTPTR_FORMAT " method=%s @ %d",
@@ -1538,7 +1549,6 @@
     bool inc_recompile_count = false;
     ProfileData* pdata = NULL;
     if (ProfileTraps && update_trap_state && trap_mdo != NULL) {
-      assert(trap_mdo == get_method_data(thread, trap_method, false), "sanity");
       uint this_trap_count = 0;
       bool maybe_prior_trap = false;
       bool maybe_prior_recompile = false;