RFR: 8293187: Store initialized Enum classes in AOTCache [v3]

Ioi Lam iklam at openjdk.org
Wed Sep 18 01:16:50 UTC 2024


On Tue, 17 Sep 2024 20:33:28 GMT, Ashutosh Mehra <asmehra at openjdk.org> wrote:

>> Ioi Lam has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains 11 commits:
>> 
>>  - Merge branch 'jep-483-step-03-8329706-implement-xx-aot-class-linking' of /jdk3/yak/open into jep-483-step-04-8293187-support-sun-invoke-util-wrapper-in-cds-archive-heap
>>  - @vnkozlov comments
>>  - Clean up; removed unrelated changes in classPrinter.cpp
>>  - more cleanup
>>  - Merge branch 'jep-483-step-03-8329706-implement-xx-aot-class-linking' of /jdk3/yak/open into jep-483-step-04-8293187-support-sun-invoke-util-wrapper-in-cds-archive-heap
>>  - More clean up for JDK-8293187
>>  - Merge branch 'jep-483-step-03-8329706-implement-xx-aot-class-linking' of /jdk3/yak/open into jep-483-step-04-8293187-support-sun-invoke-util-wrapper-in-cds-archive-heap
>>  - Merge branch 'jep-483-step-03-8329706-implement-xx-aot-class-linking' into jep-483-step-04-8293187-support-sun-invoke-util-wrapper-in-cds-archive-heap
>>  - Merge branch 'jep-483-step-03-8329706-implement-xx-aot-class-linking' into jep-483-step-04-8293187-support-sun-invoke-util-wrapper-in-cds-archive-heap
>>  - Simplified implemented by AOTClassInitializer.
>>  - ... and 1 more: https://git.openjdk.org/jdk/compare/bcddf963...e15e76cd
>
> src/hotspot/share/cds/aotClassInitializer.cpp line 40:
> 
>> 38:     return true;
>> 39:   } else if (ik->is_initialized() &&
>> 40:              (ik->name()->equals("jdk/internal/constant/PrimitiveClassDescImpl") ||
> 
> Is it possible for one of these classes to be not initialized at this stage? IIUC `ik` must be initialized if it is one of these classes. In so, can `ik->is_initialized()` be turned into an assert?

I added the assert as you suggested.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/20958#discussion_r1764260436


More information about the hotspot-dev mailing list