diff options
author | jrose <none@none> | 2009-04-21 23:21:04 -0700 |
---|---|---|
committer | jrose <none@none> | 2009-04-21 23:21:04 -0700 |
commit | e95fc1b19ae2eaca9a91d9e27f09a248bbe3da50 (patch) | |
tree | 5704ad3778987120bc8ca1f9c313b6006813d54e /src/share/vm/opto | |
parent | 4c08465f35c8d3e10b19d956893e3b94069a3718 (diff) | |
download | jdk8u_hotspot-e95fc1b19ae2eaca9a91d9e27f09a248bbe3da50.tar.gz |
6655646: dynamic languages need dynamically linked call sites
Summary: invokedynamic instruction (JSR 292 RI)
Reviewed-by: twisti, never
Diffstat (limited to 'src/share/vm/opto')
-rw-r--r-- | src/share/vm/opto/bytecodeInfo.cpp | 2 | ||||
-rw-r--r-- | src/share/vm/opto/doCall.cpp | 10 | ||||
-rw-r--r-- | src/share/vm/opto/graphKit.cpp | 1 | ||||
-rw-r--r-- | src/share/vm/opto/parse1.cpp | 1 | ||||
-rw-r--r-- | src/share/vm/opto/parse2.cpp | 1 | ||||
-rw-r--r-- | src/share/vm/opto/parseHelper.cpp | 1 |
6 files changed, 15 insertions, 1 deletions
diff --git a/src/share/vm/opto/bytecodeInfo.cpp b/src/share/vm/opto/bytecodeInfo.cpp index a66c873e2..20e1faff5 100644 --- a/src/share/vm/opto/bytecodeInfo.cpp +++ b/src/share/vm/opto/bytecodeInfo.cpp @@ -321,7 +321,7 @@ bool pass_initial_checks(ciMethod* caller_method, int caller_bci, ciMethod* call // stricter than callee_holder->is_initialized() ciBytecodeStream iter(caller_method); iter.force_bci(caller_bci); - int index = iter.get_index_big(); + int index = iter.get_index_int(); if( !caller_method->is_klass_loaded(index, true) ) { return false; } diff --git a/src/share/vm/opto/doCall.cpp b/src/share/vm/opto/doCall.cpp index 66cb13b9f..ca53445c6 100644 --- a/src/share/vm/opto/doCall.cpp +++ b/src/share/vm/opto/doCall.cpp @@ -248,6 +248,14 @@ bool Parse::can_not_compile_call_site(ciMethod *dest_method, ciInstanceKlass* kl holder_klass); return true; } + if (dest_method->is_method_handle_invoke() + && holder_klass->name() == ciSymbol::java_dyn_Dynamic()) { + // FIXME: NYI + uncommon_trap(Deoptimization::Reason_unhandled, + Deoptimization::Action_none, + holder_klass); + return true; + } assert(dest_method->will_link(method()->holder(), klass, bc()), "dest_method: typeflow responsibility"); return false; @@ -748,6 +756,7 @@ void Parse::count_compiled_calls(bool at_method_entry, bool is_inline) { case Bytecodes::_invokevirtual: increment_counter(SharedRuntime::nof_inlined_calls_addr()); break; case Bytecodes::_invokeinterface: increment_counter(SharedRuntime::nof_inlined_interface_calls_addr()); break; case Bytecodes::_invokestatic: + case Bytecodes::_invokedynamic: case Bytecodes::_invokespecial: increment_counter(SharedRuntime::nof_inlined_static_calls_addr()); break; default: fatal("unexpected call bytecode"); } @@ -756,6 +765,7 @@ void Parse::count_compiled_calls(bool at_method_entry, bool is_inline) { case Bytecodes::_invokevirtual: increment_counter(SharedRuntime::nof_normal_calls_addr()); break; case Bytecodes::_invokeinterface: increment_counter(SharedRuntime::nof_interface_calls_addr()); break; case Bytecodes::_invokestatic: + case Bytecodes::_invokedynamic: case Bytecodes::_invokespecial: increment_counter(SharedRuntime::nof_static_calls_addr()); break; default: fatal("unexpected call bytecode"); } diff --git a/src/share/vm/opto/graphKit.cpp b/src/share/vm/opto/graphKit.cpp index e28730d27..c37e7c85d 100644 --- a/src/share/vm/opto/graphKit.cpp +++ b/src/share/vm/opto/graphKit.cpp @@ -947,6 +947,7 @@ bool GraphKit::compute_stack_effects(int& inputs, int& depth) { case Bytecodes::_invokevirtual: case Bytecodes::_invokespecial: case Bytecodes::_invokestatic: + case Bytecodes::_invokedynamic: case Bytecodes::_invokeinterface: { bool is_static = (depth == 0); diff --git a/src/share/vm/opto/parse1.cpp b/src/share/vm/opto/parse1.cpp index da9537eb3..a7f4007ae 100644 --- a/src/share/vm/opto/parse1.cpp +++ b/src/share/vm/opto/parse1.cpp @@ -828,6 +828,7 @@ bool Parse::can_rerun_bytecode() { break; case Bytecodes::_invokestatic: + case Bytecodes::_invokedynamic: case Bytecodes::_invokespecial: case Bytecodes::_invokevirtual: case Bytecodes::_invokeinterface: diff --git a/src/share/vm/opto/parse2.cpp b/src/share/vm/opto/parse2.cpp index 201ffad99..64cd9bda2 100644 --- a/src/share/vm/opto/parse2.cpp +++ b/src/share/vm/opto/parse2.cpp @@ -2156,6 +2156,7 @@ void Parse::do_one_bytecode() { break; case Bytecodes::_invokestatic: + case Bytecodes::_invokedynamic: case Bytecodes::_invokespecial: case Bytecodes::_invokevirtual: case Bytecodes::_invokeinterface: diff --git a/src/share/vm/opto/parseHelper.cpp b/src/share/vm/opto/parseHelper.cpp index b5553cbe8..7e87d7702 100644 --- a/src/share/vm/opto/parseHelper.cpp +++ b/src/share/vm/opto/parseHelper.cpp @@ -414,6 +414,7 @@ void Parse::profile_call(Node* receiver) { profile_receiver_type(receiver); break; case Bytecodes::_invokestatic: + case Bytecodes::_invokedynamic: case Bytecodes::_invokespecial: break; default: fatal("unexpected call bytecode"); |