On Tue, 21 Mar 2023 09:45:56 GMT, Jaikiran Pai <j...@openjdk.org> wrote:
>> Adam Sotona has updated the pull request incrementally with one additional >> commit since the last revision: >> >> Update >> src/java.base/share/classes/jdk/internal/classfile/impl/ClassHierarchyImpl.java >> >> Co-authored-by: liach <7806504+li...@users.noreply.github.com> > > src/java.base/share/classes/jdk/internal/classfile/impl/ClassHierarchyImpl.java > line 172: > >> 170: public StaticClassHierarchyResolver(Collection<ClassDesc> >> interfaceNames, Map<ClassDesc, ClassDesc> classToSuperClass) { >> 171: map = HashMap.newHashMap(interfaceNames.size() + >> classToSuperClass.size() + 1); >> 172: map.put(ConstantDescs.CD_Object, new >> ClassHierarchyInfo(ConstantDescs.CD_Object, false, null)); > > Hello Adam, for this `Object` class representation, perhaps you could just > have a `static final` field which is instantiated to this value and reused > instead of creating a new instance each time? fixed, thanks. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/13099#discussion_r1143179081