RFR: 8297914: Remove java_lang_Class::process_archived_mirror() [v2]

Ioi Lam iklam at openjdk.org
Thu Jan 12 19:14:48 UTC 2023


On Tue, 10 Jan 2023 19:14:27 GMT, Ashutosh Mehra <duke at openjdk.org> wrote:

>> Ioi Lam has updated the pull request incrementally with three additional commits since the last revision:
>> 
>>  - review comments from @ashu-mehra and @dholmes-ora
>>  - fixed repo
>>  - tmp
>
> src/hotspot/share/cds/heapShared.cpp line 379:
> 
>> 377: };
>> 378: 
>> 379: static KlassToOopHandleTable* _scratch_java_mirror_table = NULL;
> 
> Any reason why `_scratch_basic_type_mirrors` is a static member of `HeapShared` but `_scratch_java_mirror_table` is not?

I moved this field as a static member of `HeapShared` as well.

> src/hotspot/share/classfile/javaClasses.cpp line 1347:
> 
>> 1345:     assert(java_class == Universe::void_mirror(), "only valid non-array primitive");
>> 1346:   }
>> 1347:   assert(Universe::java_mirror(type) == java_class ||
> 
> If we need the condition `HeapShared::scratch_java_mirror(type) == java_class` here, shouldn't the previous assert be also updated to check for scratch java mirror for void type?
> 
>   `assert(java_class == Universe::void_mirror() |, "only valid non-array primitive");`

This change doesn't seem to be needed. I've removed it and my local tests passed. I'll test more thoroughly in my CI pipeline.

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

PR: https://git.openjdk.org/jdk/pull/11853


More information about the hotspot-dev mailing list