bytecodeInfo.cpp revision 2252
2N/A * or visit www.oracle.com if you need additional information or have any
2N/A#include "precompiled.hpp"
2N/A#include "classfile/systemDictionary.hpp"
2N/A#include "classfile/vmSymbols.hpp"
2N/A#include "compiler/compileBroker.hpp"
2N/A#include "compiler/compileLog.hpp"
2N/A#include "interpreter/linkResolver.hpp"
2N/A#include "oops/objArrayKlass.hpp"
2N/A#include "opto/callGenerator.hpp"
2N/A#include "runtime/handles.inline.hpp"
2N/A assert(!caller_jvms->should_reexecute(), "there should be no reexecute bytecode with inlining");
2N/A assert((caller_tree == NULL ? 0 : caller_tree->stack_depth() + 1) == stack_depth(), "correct (redundant) depth parameter");
2N/A if (UseOldInlining) {
2N/Aconst char* InlineTree::shouldInline(ciMethod* callee_method, ciMethod* caller_method, int caller_bci, ciCallProfile& profile, WarmCallInfo* wci_result) const {
tty->print_cr("Inlined method with many throws (throws=%d):", callee_method->interpreter_throwout_count());
return NULL;
if (!UseOldInlining) {
return NULL;
const char* InlineTree::shouldNotInline(ciMethod *callee_method, ciMethod* caller_method, WarmCallInfo* wci_result) const {
if (!UseOldInlining) {
if (fail) {
return fail;
if (callee_method->has_compiled_code() && callee_method->instructions_size(CompLevel_full_optimization) > InlineSmallCode) {
return NULL;
return NULL;
return NULL;
if( callee_method->has_compiled_code() && callee_method->instructions_size(CompLevel_full_optimization) > InlineSmallCode )
if (UseStringCache) {
return NULL;
const char* InlineTree::try_to_inline(ciMethod* callee_method, ciMethod* caller_method, int caller_bci, ciCallProfile& profile, WarmCallInfo* wci_result) {
return msg;
return msg;
return NULL;
int inline_level = 0;
inline_level++;
return NULL;
#ifndef PRODUCT
void InlineTree::print_inlining(ciMethod* callee_method, int caller_bci, const char* failure_msg) const {
CompileTask::print_inlining(callee_method, inline_depth(), caller_bci, failure_msg ? failure_msg : "inline");
tty->print(" bcs: %d+%d invoked: %d", top->count_inline_bcs(), callee_method->code_size(), callee_method->interpreter_invocation_count());
WarmCallInfo* InlineTree::ok_to_inline(ciMethod* callee_method, JVMState* jvms, ciCallProfile& profile, WarmCallInfo* initial_wci) {
#ifdef ASSERT
if( PrintInlining ) {
return NULL;
#ifndef PRODUCT
if (UseOldInlining) {
if (!InlineWarmCalls) {
if (UseOldInlining)
return NULL;
return freq;
InlineTree *InlineTree::build_inline_tree_for_callee( ciMethod* callee_method, JVMState* caller_jvms, int caller_bci) {
return old_ilt;
int new_depth_adjust = 0;
InlineTree *ilt = new InlineTree(C, this, callee_method, caller_jvms, caller_bci, recur_frequency, _site_depth_adjust + new_depth_adjust);
return ilt;
return sub;
return NULL;
return ilt;
InlineTree* InlineTree::find_subtree_from_root(InlineTree* root, JVMState* jvms, ciMethod* callee, bool create_if_not_found) {
if (!sub) {
return NULL;
return iltp;