RFR: 8352635: Improve inferencing of Float16 operations with constant inputs [v8]

Emanuel Peter epeter at openjdk.org
Wed Jun 11 14:18:36 UTC 2025


On Wed, 11 Jun 2025 13:47:50 GMT, Jatin Bhateja <jbhateja at openjdk.org> wrote:

>> This is a follow-up PR#22755 to improve Float16 operations inferencing.
>> 
>> The existing scheme to detect Float16 operations for some operations is based on pattern matching which expects to receive inputs through ConvHF2F IR, this patch extends matching to accept constant floating point inputs within the Float16 value range.
>> 
>> Best Regards,
>> Jatin
>
> Jatin Bhateja has updated the pull request incrementally with one additional commit since the last revision:
> 
>   removing deoptimization for  golden result computation

Thanks for the improvements @jatin-bhateja nice progress :)

src/hotspot/share/opto/convertnode.cpp line 303:

> 301:       //   c. The pattern being matched includes a Float to Float16 conversion after binary
> 302:       //   expression, this downcast will still preserve the significand bits of binary32 NaN.
> 303:       bool isnan =  g_isnan((jdouble)con);

Suggestion:

      bool isnan = g_isnan((jdouble)con);

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

PR Review: https://git.openjdk.org/jdk/pull/24179#pullrequestreview-2917388125
PR Review Comment: https://git.openjdk.org/jdk/pull/24179#discussion_r2140288522


More information about the hotspot-compiler-dev mailing list