hotspot/src/share/vm/ci/ciEnv.cpp
changeset 9328 144894b3384b
parent 8921 14bfe81f2a9d
child 10008 d84de97ad847
equal deleted inserted replaced
9327:23532ae85295 9328:144894b3384b
   754                                                     int index, Bytecodes::Code bc) {
   754                                                     int index, Bytecodes::Code bc) {
   755   // Compare the following logic with InterpreterRuntime::resolve_invokedynamic.
   755   // Compare the following logic with InterpreterRuntime::resolve_invokedynamic.
   756   assert(bc == Bytecodes::_invokedynamic, "must be invokedynamic");
   756   assert(bc == Bytecodes::_invokedynamic, "must be invokedynamic");
   757 
   757 
   758   bool is_resolved = cpool->cache()->main_entry_at(index)->is_resolved(bc);
   758   bool is_resolved = cpool->cache()->main_entry_at(index)->is_resolved(bc);
   759   if (is_resolved && (oop) cpool->cache()->secondary_entry_at(index)->f1() == NULL)
   759   if (is_resolved && cpool->cache()->secondary_entry_at(index)->is_f1_null())
   760     // FIXME: code generation could allow for null (unlinked) call site
   760     // FIXME: code generation could allow for null (unlinked) call site
   761     is_resolved = false;
   761     is_resolved = false;
   762 
   762 
   763   // Call site might not be resolved yet.  We could create a real invoker method from the
   763   // Call site might not be resolved yet.  We could create a real invoker method from the
   764   // compiler, but it is simpler to stop the code path here with an unlinked method.
   764   // compiler, but it is simpler to stop the code path here with an unlinked method.
   768     return get_unloaded_method(mh_klass, ciSymbol::invokeExact_name(), sig_sym);
   768     return get_unloaded_method(mh_klass, ciSymbol::invokeExact_name(), sig_sym);
   769   }
   769   }
   770 
   770 
   771   // Get the invoker methodOop from the constant pool.
   771   // Get the invoker methodOop from the constant pool.
   772   oop f1_value = cpool->cache()->main_entry_at(index)->f1();
   772   oop f1_value = cpool->cache()->main_entry_at(index)->f1();
   773   methodOop signature_invoker = methodOop(f1_value);
   773   methodOop signature_invoker = (methodOop) f1_value;
   774   assert(signature_invoker != NULL && signature_invoker->is_method() && signature_invoker->is_method_handle_invoke(),
   774   assert(signature_invoker != NULL && signature_invoker->is_method() && signature_invoker->is_method_handle_invoke(),
   775          "correct result from LinkResolver::resolve_invokedynamic");
   775          "correct result from LinkResolver::resolve_invokedynamic");
   776 
   776 
   777   return get_object(signature_invoker)->as_method();
   777   return get_object(signature_invoker)->as_method();
   778 }
   778 }