7152961: InlineTree::should_not_inline may exit prematurely
authornever
Tue, 13 Mar 2012 10:03:59 -0700
changeset 12160 c3ce1d6b88e1
parent 12159 714449dc1f6d
child 12161 081f2b3f1823
7152961: InlineTree::should_not_inline may exit prematurely Reviewed-by: kvn, never Contributed-by: nils.eliasson@oracle.com
hotspot/src/share/vm/opto/bytecodeInfo.cpp
--- a/hotspot/src/share/vm/opto/bytecodeInfo.cpp	Mon Mar 12 19:54:41 2012 -0700
+++ b/hotspot/src/share/vm/opto/bytecodeInfo.cpp	Tue Mar 13 10:03:59 2012 -0700
@@ -257,6 +257,18 @@
       return "exception method";
   }
 
+  if (callee_method->should_not_inline()) {
+    return "disallowed by CompilerOracle";
+  }
+
+  if (UseStringCache) {
+    // Do not inline StringCache::profile() method used only at the beginning.
+    if (callee_method->name() == ciSymbol::profile_name() &&
+        callee_method->holder()->name() == ciSymbol::java_lang_StringCache()) {
+      return "profiling method";
+    }
+  }
+
   // use frequency-based objections only for non-trivial methods
   if (callee_method->code_size_for_inlining() <= MaxTrivialSize) return NULL;
 
@@ -278,18 +290,6 @@
     }
   }
 
-  if (callee_method->should_not_inline()) {
-    return "disallowed by CompilerOracle";
-  }
-
-  if (UseStringCache) {
-    // Do not inline StringCache::profile() method used only at the beginning.
-    if (callee_method->name() == ciSymbol::profile_name() &&
-        callee_method->holder()->name() == ciSymbol::java_lang_StringCache()) {
-      return "profiling method";
-    }
-  }
-
   return NULL;
 }