CAUTION: This site hosts draft documentation for the next release. For published content of the latest release, visit www.eclipse.org/openj9/docs

-XX:[+|-]ShareAnonymousClasses

This option enables and disables the storage of VM anonymous classes, those created by Unsafe.defineAnonymousClass, in the shared classes cache.

The option is enabled by default, which means that anonymous classes are stored in the shared classes cache and are therefore available for ahead-of-time (AOT) compilation, potentially improving startup performance.

Syntax

    -XX:[+|-]ShareAnonymousClasses
Setting Effect Default
-XX:+ShareAnonymousClasses Enable yes
-XX:-ShareAnonymousClasses Disable

See also