RFR: 8292329: Enable CDS shared heap for zero builds
Thomas Stuefe
stuefe at openjdk.org
Tue Aug 23 20:08:30 UTC 2022
On Tue, 23 Aug 2022 16:57:20 GMT, Ioi Lam <iklam at openjdk.org> wrote:
> > Stupid question, does that not mean that the CDS dump generated at build time is not usable with the VM at runtime if that is started with default options?
>
> The CDS archive is still useable.
>
> * If G1 is used at runtime, the shared heap is mmaped
> * If a non-G1 collector is used, all the objects in the shared heap will be copied into the Java heap.
>
> See comments near `HeapShared::can_use()`:
>
> https://github.com/openjdk/jdk/blob/d24b7b7026cf85f1aecf44f60819762872cfd5c1/src/hotspot/share/cds/heapShared.hpp#L151-L157
Thanks for the clarification!
-------------
PR: https://git.openjdk.org/jdk/pull/9984
More information about the build-dev
mailing list