On Mon, 14 Oct 2024 15:52:07 GMT, Dan Heidinga <heidi...@openjdk.org> wrote:

>> Ioi Lam has updated the pull request incrementally with one additional 
>> commit since the last revision:
>> 
>>   Fixed JDK-8341988: jstack launched with AOT cache created with 
>> -XX:+AOTClassLinking crashes
>
> src/hotspot/share/cds/aotLinkedClassBulkLoader.cpp line 235:
> 
>> 233: }
>> 234: 
>> 235: // TODO -- is this really correct? Do we need a special ClassLoaderData 
>> for each hidden class?
> 
> There are multiple kinds of hidden classes: 
> * default ones which can be unloaded immediately when no longer referenced
> * MHs.Lookup.ClassOption::STRONG which are associated with their defining 
> loader and can only be unloaded when that loader is unloaded.
> 
> I think we need special ClassLoaderData for the non-strong (default) hidden 
> classes

We only resolve indys for the boot/platform/app class loaders, so there's no 
need to support class unloading. I've added a comment and tightened up the code 
with asserts. See version 
[382446d](https://github.com/openjdk/jdk/pull/21143/commits/382446d41bb79c4bd2c1dfeda656dfa2a73466b4)

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

PR Review Comment: https://git.openjdk.org/jdk/pull/21143#discussion_r1802208841

Reply via email to