RFR: 8266973: Migrate to ClassHierarchyIterator when enumerating subclasses [v2]

Vladimir Ivanov vlivanov at openjdk.java.net
Thu May 13 09:39:58 UTC 2021


On Wed, 12 May 2021 18:49:41 GMT, Coleen Phillimore <coleenp at openjdk.org> wrote:

> I wonder if you can now make subklass() and next_sibling() functions private to Klass with it having ClassHierarchyIterator as a friend.

There are some usages of `subklass()`/`next_sibling()` which don't benefit much from migration to `ClassHierarchyIterator` (e.g., `Dependencies::check_leaf_type()` and `ciInstanceKlass::dump_replay_data()`). I decided to leave them intact.

Nevertheless, I spotted 2 more occurrences (in JFR code) that benefit from migration to `ClassHierarchyIterator`. 

(Passed `hs-tier5-rt` - `hs-tier7-rt` testing.)

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

PR: https://git.openjdk.java.net/jdk/pull/3995


More information about the hotspot-runtime-dev mailing list