[libc-commits] [libc] [llvm] [libc] Extend fputil::sqrt to use floating point instructions for arm32. (PR #134499)

via libc-commits libc-commits at lists.llvm.org
Sun Apr 6 09:12:22 PDT 2025


lntue wrote:

> > > Does it have to be element wise? Isn't this only required if the argument is a vector?
> > 
> > 
> > Yes, `__builtin_sqrt` is whatever GNU decided it to do, which implies some standard handling. `__builtin_elementwise_sqrt` is more straightforward and type generic.
> 
> I see.
> 
> Can we move the implementation out of the platform-specific dirs? Something like https://github.com/llvm/llvm-project/blob/main/libc/src/__support/FPUtil/FMA.h but for sqrt?

Done.  I also make riscv support to match arm on the current set up.

https://github.com/llvm/llvm-project/pull/134499


More information about the libc-commits mailing list