[PATCH] arm: Add ARM VFPv4 VFMA instruction support in fma/fmaf (BZ 15503)
Joseph Myers
josmyers@redhat.com
Thu Oct 30 17:10:18 GMT 2025
On Thu, 30 Oct 2025, Adhemerval Zanella Netto wrote:
> It is also on my backlog to check if we can consolidate all the generic double
> fma implementation on only one. Current we have:
>
> sysdeps/ieee754/dbl-64/s_fma.c
> sysdeps/ieee754/ldbl-96/s_fma.c
> sysdeps/ieee754/ldbl-128/s_fma.c
> sysdeps/ieee754/soft-fp/s_fma.c
>
> All but the sofp-fp uses the floating-point exceptions to change rounding and
> check for exceptions. I think the soft-fp would most likely be a better
> default even for ldbl-96/ldbl-128.
We don't have sfp-machine.h with support for hardware exceptions /
rounding modes on all architectures that have such exceptions and rounding
modes, which is required to use the soft-fp fma implementation for such an
architecture. (Likewise for the narrowing functions that also have
sysdeps/ieee754/soft-fp/ implementations and a default implementation
using round-to-odd that relies on changing the hardware rounding mode and
reading hardware exception flags - in both cases I don't know how to
performance of the two approaches compares. Though I suspect that the
ldbl-128 implementation of (double) fma is very unlikely to be the best
approach in those cases where ldbl-128 itself is implemented based on
soft-fp.)
--
Joseph S. Myers
josmyers@redhat.com
More information about the Libc-alpha
mailing list