On Fri, 18 Sep 2026 11:42:04 GMT, Stefan Karlsson <[email protected]> wrote:
>> Johan Sjölen has updated the pull request with a new target base due to a >> merge or a rebase. The pull request now contains 30 commits: >> >> - Merge remote-tracking branch 'origin/master' into simplify2 >> - Service agent fixes >> - Merge branch 'master' into simplify2 >> - Check first >> - Need to include BUFFERED >> - Remove faulting assert (maybe worth looking into?) >> - Rename to largest_layout_of >> - Use least_restrictive_layout_of >> - Fix bug >> - Use a ternary and remove the default value >> - ... and 20 more: https://git.openjdk.org/jdk/compare/f33a724f...c834aa37 > > src/hotspot/share/oops/layoutKind.hpp line 98: > >> 96: NULLABLE_NON_ATOMIC_FLAT = 5, // flat, include a null marker, >> non-atomic, only used for strict final non-static fields >> 97: UNKNOWN = 6, // used for uninitialized fields >> of type LayoutKind >> 98: COUNT = UNKNOWN > > Adding COUNT here pollutes the LayoutKind type with something that is not a > layout kind. Could this be a constant outside of the enum? I would call this fairly standard Hotspot code, we use this in `LogTag`, `MemTag`, `AdapterBlog`, `CompileCommandEnum`. I think it's standard enough to not be considered a pollutant, its reason for existing is clear. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/32276#discussion_r4046684412
