[lworld+fp16] RFR: 8308363: Initial compiler support for FP16 scalar operations. [v7]

Jatin Bhateja jbhateja at openjdk.org
Mon Sep 18 17:42:07 UTC 2023


On Tue, 12 Sep 2023 23:00:24 GMT, Sandhya Viswanathan <sviswanathan at openjdk.org> wrote:

> Very good work in general. I only have couple of comments in the code, please take a look. Also there might be some further optimization opportunities for the path that comes from Op_ConvF2HF -> ReinterpretS2HF. ConvF2HF is doing the conversion from xmm to xmm register and then moves the xmm to gpr. ReinterpretS2HF then moves from gpr back to xmm. This unnecessary movement from xmm->gpr and from gpr->xmm could be optimized out.

Yes, but this can only be done if we factor out xmm -> gpr movement out of ConvF2HF,  its inputs is a IEEE 754 binary32 bit floating point value and output is a binary16 bit value help in a GPR. It will not be proper to remove ConvF2HF + ReinterpretS2HF by a direct ideal transformation currently.

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

PR Comment: https://git.openjdk.org/valhalla/pull/848#issuecomment-1724072435



More information about the valhalla-dev mailing list