RFR: 8357525: Default CDS archive becomes non-deterministic after JDK-8305895 [v2]

Ioi Lam iklam at openjdk.org
Tue May 27 18:23:53 UTC 2025


On Thu, 22 May 2025 10:32:59 GMT, Aleksey Shipilev <shade at openjdk.org> wrote:

> This looks fine.
> 
> Looks to me we mis-attributing the root cause a bit: it is not just about [JDK-8305895](https://bugs.openjdk.org/browse/JDK-8305895) that made some `IK`-s allocated at more arbitrary locations outside of Class Space. Even in Class Space there is a positional randomness, right?
> 
> So I think the actual root cause is the the address-based tie-breaker introduced in [JDK-8180450](https://bugs.openjdk.org/browse/JDK-8180450). Let's link those issues up and change the synopsis accordingly?

I updated the PR and JBS synopsis to include  [JDK-8180450](https://bugs.openjdk.org/browse/JDK-8180450).

Determinism is required only when creating the default CDS archive during the JDK build, where we run a single thread to load the classes. As far as I know, the address order in the class space happens to be the same as in the CDS output buffer, but that's just a happy co-incidence and could change in the future. This RFE will guard against such changes.

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

PR Comment: https://git.openjdk.org/jdk/pull/25373#issuecomment-2913514412


More information about the hotspot-dev mailing list