mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-28 15:24:43 +02:00
8202669: Intermittent crash in ClassLoadingService::compute_class_size()
Don't report classes that failed to load when reporting class unloading. Remove the classes first. Reviewed-by: dholmes, lfoltan, ccheung
This commit is contained in:
parent
3b38d1b418
commit
37e51f4074
3 changed files with 77 additions and 4 deletions
|
@ -573,9 +573,6 @@ void ClassLoaderData::remove_class(Klass* scratch_class) {
|
|||
void ClassLoaderData::unload() {
|
||||
_unloading = true;
|
||||
|
||||
// Tell serviceability tools these classes are unloading
|
||||
classes_do(InstanceKlass::notify_unload_class);
|
||||
|
||||
LogTarget(Debug, class, loader, data) lt;
|
||||
if (lt.is_enabled()) {
|
||||
ResourceMark rm;
|
||||
|
@ -589,6 +586,10 @@ void ClassLoaderData::unload() {
|
|||
// if they are not already on the _klasses list.
|
||||
unload_deallocate_list();
|
||||
|
||||
// Tell serviceability tools these classes are unloading
|
||||
// after erroneous classes are released.
|
||||
classes_do(InstanceKlass::notify_unload_class);
|
||||
|
||||
// Clean up global class iterator for compiler
|
||||
static_klass_iterator.adjust_saved_class(this);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue