/hg/icedtea8-forest/hotspot: 2 new changesets

andrew at icedtea.classpath.org andrew at icedtea.classpath.org
Mon Aug 1 15:57:01 UTC 2016


changeset ee9bffb3bd39 in /hg/icedtea8-forest/hotspot
details: http://icedtea.classpath.org/hg/icedtea8-forest/hotspot?cmd=changeset;node=ee9bffb3bd39
author: aph
date: Mon Aug 01 16:33:54 2016 +0100

	8157306, PR3121: Random infrequent null pointer exceptions in javac
	Reviewed-by: kvn


changeset fd29eff8b797 in /hg/icedtea8-forest/hotspot
details: http://icedtea.classpath.org/hg/icedtea8-forest/hotspot?cmd=changeset;node=fd29eff8b797
author: roland
date: Wed Jul 27 12:33:33 2016 +0200

	8162384, PR3122: Performance regression: bimorphic inlining may be bypassed by type speculation
	Summary: when speculation fails at a call fallback to profile data at the call site
	Reviewed-by: kvn


diffstat:

 src/share/vm/opto/doCall.cpp |  26 ++++++++++++++++----------
 src/share/vm/opto/lcm.cpp    |   7 +++++--
 2 files changed, 21 insertions(+), 12 deletions(-)

diffs (64 lines):

diff -r ab3e0bde3c15 -r fd29eff8b797 src/share/vm/opto/doCall.cpp
--- a/src/share/vm/opto/doCall.cpp	Tue Jul 26 04:42:03 2016 +0100
+++ b/src/share/vm/opto/doCall.cpp	Wed Jul 27 12:33:33 2016 +0200
@@ -205,16 +205,22 @@
 
       int morphism = profile.morphism();
       if (speculative_receiver_type != NULL) {
-        // We have a speculative type, we should be able to resolve
-        // the call. We do that before looking at the profiling at
-        // this invoke because it may lead to bimorphic inlining which
-        // a speculative type should help us avoid.
-        receiver_method = callee->resolve_invoke(jvms->method()->holder(),
-                                                 speculative_receiver_type);
-        if (receiver_method == NULL) {
+        if (!too_many_traps(caller, bci, Deoptimization::Reason_speculate_class_check)) {
+          // We have a speculative type, we should be able to resolve
+          // the call. We do that before looking at the profiling at
+          // this invoke because it may lead to bimorphic inlining which
+          // a speculative type should help us avoid.
+          receiver_method = callee->resolve_invoke(jvms->method()->holder(),
+                                                   speculative_receiver_type);
+          if (receiver_method == NULL) {
+            speculative_receiver_type = NULL;
+          } else {
+            morphism = 1;
+          }
+        } else {
+          // speculation failed before. Use profiling at the call
+          // (could allow bimorphic inlining for instance).
           speculative_receiver_type = NULL;
-        } else {
-          morphism = 1;
         }
       }
       if (receiver_method == NULL &&
@@ -252,7 +258,7 @@
                                     Deoptimization::Reason_bimorphic :
                                     (speculative_receiver_type == NULL ? Deoptimization::Reason_class_check : Deoptimization::Reason_speculate_class_check);
           if ((morphism == 1 || (morphism == 2 && next_hit_cg != NULL)) &&
-              !too_many_traps(jvms->method(), jvms->bci(), reason)
+              !too_many_traps(caller, bci, reason)
              ) {
             // Generate uncommon trap for class check failure path
             // in case of monomorphic or bimorphic virtual call site.
diff -r ab3e0bde3c15 -r fd29eff8b797 src/share/vm/opto/lcm.cpp
--- a/src/share/vm/opto/lcm.cpp	Tue Jul 26 04:42:03 2016 +0100
+++ b/src/share/vm/opto/lcm.cpp	Wed Jul 27 12:33:33 2016 +0200
@@ -1090,11 +1090,14 @@
     Block *sb = block->_succs[i];
     // Clone the entire area; ignoring the edge fixup for now.
     for( uint j = end; j > beg; j-- ) {
-      // It is safe here to clone a node with anti_dependence
-      // since clones dominate on each path.
       Node *clone = block->get_node(j-1)->clone();
       sb->insert_node(clone, 1);
       map_node_to_block(clone, sb);
+#ifdef AARCH64
+      if (clone->needs_anti_dependence_check()) {
+        insert_anti_dependences(sb, clone);
+      }
+#endif
     }
   }
 


More information about the distro-pkg-dev mailing list