glibc/sysdeps
Pavel Kozlov dab6344279 ARC:fpu: add extra capability check before use of sqrt and fma builtins
Add extra check for compiler definitions to ensure that compiler provides
sqrt and fma hw fpu instructions else use software implementation.

As divide/sqrt and FMA hw support from CPU side is optional,
the compiler can be configured by options to generate hw FPU instructions,
but without use of FDDIV, FDSQRT, FSDIV, FSSQRT, FDMADD and FSMADD
instructions. In this case __builtin_sqrt and __builtin_sqrtf provided by
compiler can't be used inside the glibc code, as these builtins are used
in implementations of sqrt() and sqrtf() functions but at the same time
these builtins unfold to sqrt() and sqrtf(). So it is possible to receive
code like that:

0001c4b4 <__ieee754_sqrtf>:
   1c4b4:    0001 0000      b     0         ;1c4b4 <__ieee754_sqrtf>

The same is also true for __builtin_fma and __builtin_fmaf.
Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2023-02-17 16:17:58 -03:00
..
aarch64 string: Remove string_private.h 2023-02-17 15:56:54 -03:00
alpha alpha: Add string-fza, string-fzb.h, string-fzi.h, and string-shift.h 2023-02-06 16:19:35 -03:00
arc ARC:fpu: add extra capability check before use of sqrt and fma builtins 2023-02-17 16:17:58 -03:00
arm arm: Add string-fza.h 2023-02-06 16:19:35 -03:00
csky C-SKY: Strip hard float abi from hard float feature. 2023-02-07 16:34:24 +08:00
generic string: Remove string_private.h 2023-02-17 15:56:54 -03:00
gnu Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
hppa hppa: Add string-fza.h, string-fzc.h, and string-fzi.h 2023-02-06 16:19:35 -03:00
htl htl: Remove ./sysdeps/htl/bits/types/struct___pthread_mutex.h 2023-02-12 17:28:32 +01:00
hurd Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
i386 htl: Generalize i386 pt-machdep.h to x86 2023-02-12 16:33:39 +01:00
ia64 ia64: Regenerate ulps 2023-01-24 11:21:38 -05:00
ieee754 math: Suppress -O0 warnings for soft-fp fsqrt [BZ #19444] 2023-01-11 17:50:51 -03:00
loongarch Regenerate configure. 2023-01-31 17:51:40 -05:00
m68k string: Remove string_private.h 2023-02-17 15:56:54 -03:00
mach [hurd] Fix i686 build breakage caused by 4fedebc911 2023-02-17 11:21:28 +01:00
microblaze Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
mips Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
nios2 Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
nptl Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
or1k Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
posix Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
powerpc string: Add libc_hidden_proto for memrchr 2023-02-08 17:13:58 -03:00
pthread Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
riscv riscv: Add string-fza.h and string-fzi.h 2023-02-06 16:19:35 -03:00
s390 string: Remove string_private.h 2023-02-17 15:56:54 -03:00
sh sh: Add string-fzb.h 2023-02-06 16:19:35 -03:00
sparc sparc (64bit): Regenerate ulps 2023-01-24 11:21:50 -05:00
unix ARC: align child stack in clone 2023-02-17 16:12:52 -03:00
wordsize-32 Update copyright dates with scripts/update-copyrights 2023-01-06 21:14:39 +00:00
wordsize-64 C2x strtol binary constant handling 2023-02-16 23:02:40 +00:00
x86 string: Remove string_private.h 2023-02-17 15:56:54 -03:00
x86_64 hurd, htl: Add some x86_64-specific code 2023-02-12 16:35:03 +01:00