changeset 18549:8f4945c8126a

Merge.
author Doug Simon <doug.simon@oracle.com>
date Wed, 26 Nov 2014 21:00:02 +0100
parents 5851c17b571e (current diff) 11f353f259ae (diff)
children bbf27a6ffb52 99c57f4c3fa3
files
diffstat 3 files changed, 8 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/ProfileCompiledMethodsPhase.java	Wed Nov 26 20:58:18 2014 +0100
+++ b/graal/com.oracle.graal.phases.common/src/com/oracle/graal/phases/common/ProfileCompiledMethodsPhase.java	Wed Nov 26 21:00:02 2014 +0100
@@ -57,7 +57,7 @@
     private static final String GROUP_NAME_WITHOUT = "~profiled weight (invoke-free sections)";
     private static final String GROUP_NAME_INVOKES = "~profiled invokes";
 
-    private static final boolean WITH_SECTION_HEADER = false;
+    private static final boolean WITH_SECTION_HEADER = Boolean.parseBoolean(System.getProperty("ProfileCompiledMethodsPhase.WITH_SECTION_HEADER", "false"));
     private static final boolean WITH_INVOKE_FREE_SECTIONS = Boolean.parseBoolean(System.getProperty("ProfileCompiledMethodsPhase.WITH_FREE_SECTIONS", "false"));
     private static final boolean WITH_INVOKES = Boolean.parseBoolean(System.getProperty("ProfileCompiledMethodsPhase.WITH_INVOKES", "true"));
 
--- a/graal/com.oracle.graal.truffle/src/com/oracle/graal/truffle/PartialEvaluator.java	Wed Nov 26 20:58:18 2014 +0100
+++ b/graal/com.oracle.graal.truffle/src/com/oracle/graal/truffle/PartialEvaluator.java	Wed Nov 26 21:00:02 2014 +0100
@@ -139,6 +139,7 @@
             // EA frame and clean up.
             try (Scope pe = Debug.scope("TrufflePartialEscape", graph)) {
                 new PartialEscapePhase(true, canonicalizer).apply(graph, tierContext);
+                new IncrementalCanonicalizerPhase<>(canonicalizer, new ConditionalEliminationPhase()).apply(graph, tierContext);
             } catch (Throwable t) {
                 Debug.handle(t);
             }
@@ -147,6 +148,7 @@
             while (expandTree(graph, assumptions, expansionLogger)) {
                 try (Scope pe = Debug.scope("TrufflePartialEscape", graph)) {
                     new PartialEscapePhase(true, canonicalizer).apply(graph, tierContext);
+                    new IncrementalCanonicalizerPhase<>(canonicalizer, new ConditionalEliminationPhase()).apply(graph, tierContext);
                 } catch (Throwable t) {
                     Debug.handle(t);
                 }
--- a/src/share/vm/runtime/thread.cpp	Wed Nov 26 20:58:18 2014 +0100
+++ b/src/share/vm/runtime/thread.cpp	Wed Nov 26 21:00:02 2014 +0100
@@ -1431,8 +1431,9 @@
 
 jlong* JavaThread::_graal_old_thread_counters;
 
-bool graal_counters_include(oop threadObj) {
-  return !GraalCountersExcludeCompiler || threadObj == NULL || threadObj->klass() != SystemDictionary::CompilerThread_klass();
+bool graal_counters_include(JavaThread* thread) {
+  oop threadObj = thread->threadObj();
+  return !GraalCountersExcludeCompiler || (!thread->is_Compiler_thread() && (threadObj == NULL || threadObj->klass() != SystemDictionary::CompilerThread_klass()));
 }
 
 void JavaThread::collect_counters(typeArrayOop array) {
@@ -1442,7 +1443,7 @@
       array->long_at_put(i, _graal_old_thread_counters[i]);
     }
     for (JavaThread* tp = Threads::first(); tp != NULL; tp = tp->next()) {
-      if (graal_counters_include(tp->threadObj())) {
+      if (graal_counters_include(tp)) {
         for (int i = 0; i < array->length(); i++) {
           array->long_at_put(i, array->long_at(i) + tp->_graal_counters[i]);
         }
@@ -1696,7 +1697,7 @@
 
 #ifdef GRAAL
   if (GraalCounterSize > 0) {
-    if (graal_counters_include(threadObj())) {
+    if (graal_counters_include(this)) {
       for (int i = 0; i < GraalCounterSize; i++) {
         _graal_old_thread_counters[i] += _graal_counters[i];
       }