On Tue, 4 Nov 2025 18:10:42 GMT, Claes Redestad <[email protected]> wrote:

>> Interestingly, this hurt the fast-path about 5%, but the control case about 
>> 35%.  I'm going to leave it as-is on the basis of data.
>
> Ok, if the split helps the JIT peel and optimize better some amount of code 
> duplication can be fine, but maybe then split out the two implementations to 
> separate methods (to help inlining) and comment that the code duplication is 
> intentional and should be handled with care.

The comment is a good idea, but splitting out the duplication may make 
maintenance even worse by separating the duplicate sections.  What do you think?

Also, I'll benchmark with the split to get the impact data.  Not sure I can 
meaningfully validate an impact to inlining.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/28116#discussion_r2491667225

Reply via email to