src/share/vm/oops/instanceKlass.cpp

changeset 9285
b955bd18e8fe
parent 8721
575f637864df
child 9286
2c4cecfa5ce5
     1.1 --- a/src/share/vm/oops/instanceKlass.cpp	Wed Jan 03 03:17:10 2018 -0800
     1.2 +++ b/src/share/vm/oops/instanceKlass.cpp	Tue Apr 08 09:51:25 2014 +0200
     1.3 @@ -3682,6 +3682,10 @@
     1.4                ("purge: %s(%s): prev method @%d in version @%d is alive",
     1.5                method->name()->as_C_string(),
     1.6                method->signature()->as_C_string(), j, i));
     1.7 +            if (method->method_data() != NULL) {
     1.8 +              // Clean out any weak method links
     1.9 +              method->method_data()->clean_weak_method_links();
    1.10 +            }
    1.11            }
    1.12          }
    1.13        }
    1.14 @@ -3691,6 +3695,14 @@
    1.15        ("purge: previous version stats: live=%d, deleted=%d", live_count,
    1.16        deleted_count));
    1.17    }
    1.18 +
    1.19 +  Array<Method*>* methods = ik->methods();
    1.20 +  int num_methods = methods->length();
    1.21 +  for (int index2 = 0; index2 < num_methods; ++index2) {
    1.22 +    if (methods->at(index2)->method_data() != NULL) {
    1.23 +      methods->at(index2)->method_data()->clean_weak_method_links();
    1.24 +    }
    1.25 +  }
    1.26  }
    1.27  
    1.28  // External interface for use during class unloading.

mercurial