JDK-8292635 : Improve CDSHeapVerifier testing
  • Type: Enhancement
  • Component: hotspot
  • Sub-Component: runtime
  • Affected Version: 20
  • Priority: P3
  • Status: Open
  • Resolution: Unresolved
  • Submitted: 2022-08-18
  • Updated: 2023-01-13
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 21
21Unresolved
Related Reports
Relates :  
Description
[1] We should relax the checks so that if a static field K.f1 points to the same object as another static field R.f2, and R is a subgraph root class, K.f1should be considered safe. (Today, we already consider that R.f2 is safe).

E.g., if K.f1 is equal to any of the following, consider it to be safe.

ImmutableCollections::EMPTY;
ImmutableCollections::EMPTY_LIST;
ImmutableCollections::EMPTY_LIST_NULLS;
ImmutableCollections::EMPTY_SET;
ImmutableCollections::EMPTY_MAP;

This way, we can remove the hard-coded exclusion for AccessFlag$Location::EMPTY_SET added in JDK-8292499, and can avoid similar (spurious) failures in the future.

[2] Move ArchivedEnumApp.java into somewhere under test/jdk, so that if changes in JDK causes failures in CDSHeapVerifier, we can investigate for possible issues before the changes are committed into github.



Comments
A pull request was submitted for review. URL: https://git.openjdk.org/jdk/pull/11999 Date: 2023-01-13 21:07:38 +0000
13-01-2023

We should at least do [2] in JDK 21 to avoid inadvertently breaking the ArchivedEnumApp.java test.
05-01-2023