RFR: JDK-8232069: Enable CDS even when UseCompressedClassPointers and/or UseCompressedOops are false
Yumin Qi
yumin.qi at oracle.com
Wed Feb 5 02:01:47 UTC 2020
Hi,
Please review fix:
Bug: https://bugs.openjdk.java.net/browse/JDK-8232069
Webrev:http://cr.openjdk.java.net/~minqi/8232069/webrev/
Description: Currently CDS only works when using compressed Oops
turned on, -XX:+UseCompressedOops (default), the fix is allowing CDS
works with uncompressed oops and uncompressed class pointers. The
contents of InstanceKlass::_fields are depending on UseCompressedOops
and UseCompressedClassPointers on/off. There are three suggestions as
described in bug description:
1. Remember the compression mode at CDS dump time. At runtime, disable
CDS if the compression mode is changed.
2. Same as 1, but save more than one CDS archives in the JDK image.
Choose the appropriate one at start-up
3. Recompute re-compute InstanceKlass::_fields at runtime.
The fix takes the first one, storing UseCompressedOops and
UseCompressedClassPointers in shared archive. CDS is only allowed at
runtime if the flags are consistent with the stored versions in archive.
Testing: hs-tier1-2
Thanks
Yumin
More information about the hotspot-runtime-dev
mailing list