446 return (mcs == NULL) ? 0 : mcs->increment_interpreter_invocation_count();
447 }
448 #endif
449
450 #ifndef PRODUCT
451 int compiled_invocation_count() const { return _compiled_invocation_count; }
452 void set_compiled_invocation_count(int count) { _compiled_invocation_count = count; }
453 #else
454 // for PrintMethodData in a product build
455 int compiled_invocation_count() const { return 0; }
456 #endif // not PRODUCT
457
458 // Clear (non-shared space) pointers which could not be relevant
459 // if this (shared) method were mapped into another JVM.
460 void remove_unshareable_info();
461
462 // nmethod/verified compiler entry
463 address verified_code_entry();
464 bool check_code() const; // Not inline to avoid circular ref
465 CompiledMethod* volatile code() const;
466 void clear_code(bool acquire_lock = true); // Clear out any compiled code
467 static void set_code(const methodHandle& mh, CompiledMethod* code);
468 void set_adapter_entry(AdapterHandlerEntry* adapter) {
469 constMethod()->set_adapter_entry(adapter);
470 }
471 void update_adapter_trampoline(AdapterHandlerEntry* adapter) {
472 constMethod()->update_adapter_trampoline(adapter);
473 }
474
475 address get_i2c_entry();
476 address get_c2i_entry();
477 address get_c2i_unverified_entry();
478 AdapterHandlerEntry* adapter() const {
479 return constMethod()->adapter();
480 }
481 // setup entry points
482 void link_method(const methodHandle& method, TRAPS);
483 // clear entry points. Used by sharing code during dump time
484 void unlink_method() NOT_CDS_RETURN;
485
486 virtual void metaspace_pointers_do(MetaspaceClosure* iter);
|
446 return (mcs == NULL) ? 0 : mcs->increment_interpreter_invocation_count();
447 }
448 #endif
449
450 #ifndef PRODUCT
451 int compiled_invocation_count() const { return _compiled_invocation_count; }
452 void set_compiled_invocation_count(int count) { _compiled_invocation_count = count; }
453 #else
454 // for PrintMethodData in a product build
455 int compiled_invocation_count() const { return 0; }
456 #endif // not PRODUCT
457
458 // Clear (non-shared space) pointers which could not be relevant
459 // if this (shared) method were mapped into another JVM.
460 void remove_unshareable_info();
461
462 // nmethod/verified compiler entry
463 address verified_code_entry();
464 bool check_code() const; // Not inline to avoid circular ref
465 CompiledMethod* volatile code() const;
466
467 static void unlink_code(Method *method, CompiledMethod *compare);
468 static void unlink_code(Method *method);
469
470 private:
471 // Either called with CompiledMethod_lock held or from constructor.
472 void clear_code();
473
474 public:
475 static void set_code(const methodHandle& mh, CompiledMethod* code);
476 void set_adapter_entry(AdapterHandlerEntry* adapter) {
477 constMethod()->set_adapter_entry(adapter);
478 }
479 void update_adapter_trampoline(AdapterHandlerEntry* adapter) {
480 constMethod()->update_adapter_trampoline(adapter);
481 }
482
483 address get_i2c_entry();
484 address get_c2i_entry();
485 address get_c2i_unverified_entry();
486 AdapterHandlerEntry* adapter() const {
487 return constMethod()->adapter();
488 }
489 // setup entry points
490 void link_method(const methodHandle& method, TRAPS);
491 // clear entry points. Used by sharing code during dump time
492 void unlink_method() NOT_CDS_RETURN;
493
494 virtual void metaspace_pointers_do(MetaspaceClosure* iter);
|