From 232128aa2d2eab3799dad4edf7e3ff8f32046aa7 Mon Sep 17 00:00:00 2001 From: never Date: Tue, 13 Mar 2012 10:03:59 -0700 Subject: [PATCH] 7152961: InlineTree::should_not_inline may exit prematurely Reviewed-by: kvn, never Contributed-by: nils.eliasson@oracle.com --- src/share/vm/opto/bytecodeInfo.cpp | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/share/vm/opto/bytecodeInfo.cpp b/src/share/vm/opto/bytecodeInfo.cpp index 71754274b..a8e95fcec 100644 --- a/src/share/vm/opto/bytecodeInfo.cpp +++ b/src/share/vm/opto/bytecodeInfo.cpp @@ -257,6 +257,18 @@ const char* InlineTree::should_not_inline(ciMethod *callee_method, ciMethod* cal 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 @@ const char* InlineTree::should_not_inline(ciMethod *callee_method, ciMethod* cal } } - 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; } -- GitLab