< prev index next >
src/hotspot/share/code/compiledMethod.cpp
Print this page
*** 387,412 ****
#endif // ASSERT
void CompiledMethod::clean_ic_if_metadata_is_dead(CompiledIC *ic) {
if (ic->is_icholder_call()) {
! // The only exception is compiledICHolder oops which may
// yet be marked below. (We check this further below).
! CompiledICHolder* cichk_oop = ic->cached_icholder();
! if (cichk_oop->is_loader_alive()) {
return;
}
} else {
! Metadata* ic_oop = ic->cached_metadata();
! if (ic_oop != NULL) {
! if (ic_oop->is_klass()) {
! if (((Klass*)ic_oop)->is_loader_alive()) {
return;
}
! } else if (ic_oop->is_method()) {
! if (((Method*)ic_oop)->method_holder()->is_loader_alive()) {
return;
}
} else {
ShouldNotReachHere();
}
--- 387,414 ----
#endif // ASSERT
void CompiledMethod::clean_ic_if_metadata_is_dead(CompiledIC *ic) {
if (ic->is_icholder_call()) {
! // The only exception is compiledICHolder metdata which may
// yet be marked below. (We check this further below).
! CompiledICHolder* cichk_metdata = ic->cached_icholder();
! if (cichk_metdata->is_loader_alive()) {
return;
}
} else {
! Metadata* ic_metdata = ic->cached_metadata();
! if (ic_metdata != NULL) {
! if (ic_metdata->is_klass()) {
! if (((Klass*)ic_metdata)->is_loader_alive()) {
return;
}
! } else if (ic_metdata->is_method()) {
! Method* method = (Method*)ic_metdata;
! assert(!method->is_old(), "old method should have been cleaned");
! if (method->method_holder()->is_loader_alive()) {
return;
}
} else {
ShouldNotReachHere();
}
*** 491,510 ****
low_boundary += NativeJump::instruction_size;
// %%% Note: On SPARC we patch only a 4-byte trap, not a full NativeJump.
// (See comment above.)
}
- // The RedefineClasses() API can cause the class unloading invariant
- // to no longer be true. See jvmtiExport.hpp for details.
- // Also, leave a debugging breadcrumb in local flag.
- if (JvmtiExport::has_redefined_a_class()) {
- // This set of the unloading_occurred flag is done before the
- // call to post_compiled_method_unload() so that the unloading
- // of this nmethod is reported.
- unloading_occurred = true;
- }
-
// Exception cache
clean_exception_cache();
// If class unloading occurred we first iterate over all inline caches and
// clear ICs where the cached oop is referring to an unloaded klass or method.
--- 493,502 ----
*** 579,598 ****
low_boundary += NativeJump::instruction_size;
// %%% Note: On SPARC we patch only a 4-byte trap, not a full NativeJump.
// (See comment above.)
}
- // The RedefineClasses() API can cause the class unloading invariant
- // to no longer be true. See jvmtiExport.hpp for details.
- // Also, leave a debugging breadcrumb in local flag.
- if (JvmtiExport::has_redefined_a_class()) {
- // This set of the unloading_occurred flag is done before the
- // call to post_compiled_method_unload() so that the unloading
- // of this nmethod is reported.
- unloading_occurred = true;
- }
-
// Exception cache
clean_exception_cache();
bool postponed = false;
--- 571,580 ----
< prev index next >