RFR: 8361706: Parallel weak klass link cleaning does not clean out previous klasses

Erik Österlund eosterlund at openjdk.org
Fri Jul 11 11:25:37 UTC 2025


On Fri, 11 Jul 2025 10:38:51 GMT, Thomas Schatzl <tschatzl at openjdk.org> wrote:

> Hi all,
> 
>   please review this fix to parallel weak klass link cleaning.
> 
> `KlassCleaningTask::work()` misses cleaning out previous versions of klasses (created by JVMTI class redefinition) as the regular single-threaded variant would do when calling `Klass::clean_weak_klass_links()` with `clean_live_klasses = true`.
> 
> The fix moves the cleaning of weak klass links for previous versions of the klass into `InstanceKlass::clean_weak_instanceklass_links()`.
> 
> Testing: gha, tier1-5, many runs of `vmTestbase/nsk/jvmti/RedefineClasses/StressRedefine/TestDescription.java`(with JDK-8361952 also out for review)
> 
> Thanks,
>   Thomas

Marked as reviewed by eosterlund (Reviewer).

-------------

PR Review: https://git.openjdk.org/jdk/pull/26263#pullrequestreview-3009862639


More information about the hotspot-gc-dev mailing list