Integrated: 8267189: Remove duplicated unregistered classes from dynamic archive
Ioi Lam
iklam at openjdk.java.net
Thu Jun 17 22:22:39 UTC 2021
On Thu, 17 Jun 2021 04:03:09 GMT, Ioi Lam <iklam at openjdk.org> wrote:
> In the CDS archive, "unregistered" classes are those to be loaded by custom loaders.
>
> When doing a CDS dynamic dump (with -XX:ArchiveClassesAtExit=foo.jsa), a class of the same name may be loaded by several custom class loaders. Currently we write all of these unregistered classes into the archive. However, only one copy of them will be usable at runtime.
>
> For size saving, we should avoid writing such duplicated classes into the archive.
>
> (Note that this problem does not affect the CDS static dump, which is driven by a classlist file. We already disallow duplicate unregistered classes in the classlist.)
>
> Testing: mach5 tiers 1-4. Also tested locally with Eclipse IDE.
This pull request has now been integrated.
Changeset: bb24fa65
Author: Ioi Lam <iklam at openjdk.org>
URL: https://git.openjdk.java.net/jdk/commit/bb24fa652aa1edc8ece8713f559be2fe3437d666
Stats: 318 lines in 8 files changed: 299 ins; 2 del; 17 mod
8267189: Remove duplicated unregistered classes from dynamic archive
Reviewed-by: ccheung, minqi
-------------
PR: https://git.openjdk.java.net/jdk/pull/4515
More information about the hotspot-runtime-dev
mailing list