Add fmaximum, fminimum functions [committed]
Joseph Myers
joseph@codesourcery.com
Mon Oct 4 17:00:03 GMT 2021
On Mon, 4 Oct 2021, Palmer Dabbelt via Libc-alpha wrote:
> > Add these functions to glibc. The implementations use type-generic
> > templates based on those for fmax, fmin, fmaxmag and fminmag, and test
> > inputs are based on those for those functions with appropriate
> > adjustments to the expected results. The RISC-V maintainers might
> > wish to add optimized versions of fmaximum_num and fminimum_num (for
> > float and double), since RISC-V (F extension version 2.2 and later)
>
> Thanks for pointing this out.
>
> I don't actually remember if we had any pre-2.2 hardware that could run glibc:
> pretty sure the HiFive Unleashed is post-2.2, and that's the only thing I can
> think of that would be that old. I'm never quite sure about the dates on
> specs, but I'm seeing May 2017 for 2.2 and Feb 2018 for the HiFive Unleashed
> so I think it's likely fine. Andrew would know for sure, though.
Note that this is F (and D) extension version 2.2 rather than architecture
version 2.2 (architecture version 2.2 has F extension 2.0, where FMAX and
FMIN still referred to the IEEE 754-2008 operations, i.e. fmax and fmin
functions rather than fmaximum_num and fminimum_num).
--
Joseph S. Myers
joseph@codesourcery.com
More information about the Libc-alpha
mailing list