RFR: 8263002: Remove CDS MiscCode region [v2]
David Holmes
dholmes at openjdk.java.net
Tue Mar 9 10:07:09 UTC 2021
On Tue, 9 Mar 2021 04:53:27 GMT, Ioi Lam <iklam at openjdk.org> wrote:
>> The CDS MiscCode region is used for:
>> (a) C++ vtables
>> (b) Method trampolines
>>
>> (a) can be moved to the ReadWrite region
>> (b) were introduced in JDK-8145221 so we can delay writing into Methods. This was intended to improve copy-on-write sharing to reduce memory footprint. However, this hasn't been shown to have any significant effect (footprint of metadata usually is much smaller than the Java heap), and introduces a lot of complexity in the HotSpot code.
>>
>> Removing (b) will make it easier to implement JDK-8026297 (Generating AdapterHandlerEntry during CDS dump), which will further improve start-up time.
>>
>> ============
>> Other benefits of removing the MiscCode region:
>>
>> - We no longer have a read/write/executable region. This address the concern in JDK-8262922.
>> - We can enable CDS on macOS/AArch64, which does not allow read/write/executable regions. (JDK-8253795)
>
> Ioi Lam has updated the pull request incrementally with two additional commits since the last revision:
>
> - bumped CURRENT_CDS_ARCHIVE_VERSION by one since format has changed
> - @coleenp review: remove temp debug code; fixed accounting of vtable sizes
Hi Ioi,
This looks really good from a code simplification point of view!
I can't claim to fully understand all the code involved though.
Thanks,
David
-------------
Marked as reviewed by dholmes (Reviewer).
PR: https://git.openjdk.java.net/jdk/pull/2861
More information about the hotspot-dev
mailing list