Loading... (original) (raw)

Before nmethod is unloaded, all relevant dependencies are removed. But empty nmethodBucket entries are kept. It's a memory leak.
InstanceKlass::clean_dependent_nmethods() does the right job, but it's rarely invoked (only G1KlassCleaningTask::clean_klass() does it).

backported by

Backport - A issue that is required to port a Bug or Feature into another product release. This issue type is generally associated with the main Bug/Feature to represent each individual release of the port. JDK-8149225 InstanceKlass::_dependencies list isn't cleared from empty nmethodBucket entries

Backport - A issue that is required to port a Bug or Feature into another product release. This issue type is generally associated with the main Bug/Feature to represent each individual release of the port. JDK-8155321 InstanceKlass::_dependencies list isn't cleared from empty nmethodBucket entries

Backport - A issue that is required to port a Bug or Feature into another product release. This issue type is generally associated with the main Bug/Feature to represent each individual release of the port. JDK-8144581 InstanceKlass::_dependencies list isn't cleared from empty nmethodBucket entries

relates to

Enhancement - null JDK-8049421 G1 Class Unloading after completing a concurrent mark cycle