Before this change, the setting of the 
`jdk.internal.lambda.disableEagerInitialization` property was not captured 
during dumping of lambda proxy classes. There's a workaround in 
`LambdaProxyClassArchive.find`, it won't call `findFromArchive` if the above 
property is set.

This change adds handling of the 
`jdk.internal.lambda.disableEagerInitialization` property, specifically:

- remove the above workaround;

- capture the setting of the property in the archive header during CDS dump 
time;

- during runtime when finding an archived lambda proxy class, the setting of 
the property will be compared with the stored value in the archive header.
If the values don't match, the archived lambda proxy class won't be used.

Tests:

- [x] ran all cds tests locally on linux-x64

- [x] ran the `hotspot_appcds_dynamic` test group with 
`-Dtest.dynamic.cds.archive=true` on linux-x64

- [x] mach5 tiers 1,2,3 (in progress)

-------------

Commit messages:
 - Merge branch 'master' into 8256487-disableEagerInit
 - 8256487: Handle disableEagerInitialization for archived lambda proxy classes

Changes: https://git.openjdk.java.net/jdk/pull/1301/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=1301&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8256487
  Stats: 263 lines in 15 files changed: 246 ins; 0 del; 17 mod
  Patch: https://git.openjdk.java.net/jdk/pull/1301.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/1301/head:pull/1301

PR: https://git.openjdk.java.net/jdk/pull/1301

Reply via email to