On Tue, 10 Mar 2026 09:43:38 GMT, Ivan Walulya <[email protected]> wrote:

> Hi,
> 
> Please review this patch to add sorting to 
> `FieldLayoutBuilder::inline_class_field_sorting`.
> 
> Additionally, we use `heapOopSize` to split the  big primitives and  small 
> primitives so that we do not add inline classes with oops to small primitives 
> and can remove `register_embedded_oops_from_list` for small primitives.
> 
> Testing: Tier 1-2 with --enable-preview

src/hotspot/share/classfile/fieldLayoutBuilder.cpp line 990:

> 988:     if (!fieldinfo.access_flags().is_static() && field_alignment > 
> alignment) alignment = field_alignment;
> 989:   }
> 990:   _root_group->sort_by_size();

Good catch on the missing sorting.
The sorting of the _static_fields list should also be added here.

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

PR Review Comment: 
https://git.openjdk.org/valhalla/pull/2213#discussion_r2924325280

Reply via email to