RFR: 8336147: Clarify CDS documentation about static vs dynamic archive
Aleksey Shipilev
shade at openjdk.org
Thu Jul 3 17:12:01 UTC 2025
On Thu, 3 Jul 2025 04:46:28 GMT, Ioi Lam <iklam at openjdk.org> wrote:
> Please review this doc clarification about the difference between CDS static and dynamic archives.
On the first read, I thought "enabling dynamic archive disables the following optimizations", which is not true, right? The limitations are only applied to the dynamic archive parts. Also, less efficient than what? Static archive does not store additional classes, so it is not very sensible to compare with. Would it be fairer to compare "static+dynamic" to "AOTCache"? Time to pitch Leyden's AOT here?
Also, do we really want to talk about implementation limitations in a fairly generic doc? I think we do a high-level overview (usage and general expectations) here.
Suggestion:
"The names "static" and "dynamic" are used for historical reasons. The dynamic archive, while still useful, supports a limited set of CDS optimizations that are normally available in static CDS archive. If the full set of CDS/AOT features is desired for additional classes, consider using AOTCache features."
src/java.base/share/man/java.md line 3761:
> 3759:
> 3760: The names "static" and "dynamic" are used for historical reasons.
> 3761: The dynamic archive may be less efficient as it does not support the
Unnecessarily scary wording here, "less efficient".
-------------
PR Review: https://git.openjdk.org/jdk/pull/26109#pullrequestreview-2983052777
PR Review Comment: https://git.openjdk.org/jdk/pull/26109#discussion_r2182709420
More information about the hotspot-runtime-dev
mailing list