RFR: 8271569: Rename cdsoffsets.cpp to cdsConstants.cpp [v2]

Ioi Lam iklam at openjdk.java.net
Mon Sep 13 20:42:59 UTC 2021


On Mon, 13 Sep 2021 19:07:30 GMT, Yumin Qi <minqi at openjdk.org> wrote:

>> So we are trading off use of constexpr versus broken encapsulation? :( I can't say I understand the details here.
>
> For constexpr array --- the initialization requires every item in the array must be initialized with const expression. I have rolled back the access change. By putting the global arrays offsets and constants inside CDSConstants, and making CDSConstants a friend class of the accessed class, we can avoid such changes. Thanks!

`_base_region_crc` should be private and `CDSConstants` should be a friend class of `DynamicArchiveHeader`

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

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


More information about the hotspot-runtime-dev mailing list