glibc/sysdeps
Adhemerval Zanella 3b1c5a539b math: Add internal roundeven_finite
Some CORE-MATH routines uses roundeven and most of ISA do not have
an specific instruction for the operation.  In this case, the call
will be routed to generic implementation.

However, if the ISA does support round() and ctz() there is a better
alternative (as used by CORE-MATH).

This patch adds such optimization and also enables it on powerpc.
On a power10 it shows the following improvement:

expm1f                      master      patched       improvement
latency                     9.8574       7.0139            28.85%
reciprocal-throughput       4.3742       2.6592            39.21%

Checked on powerpc64le-linux-gnu and aarch64-linux-gnu.

Reviewed-by: DJ Delorie <dj@redhat.com>
2024-11-26 15:07:57 -03:00
..
aarch64 math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
alpha math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
arc math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
arm math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
csky math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
generic math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
gnu
hppa math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
htl htl: move pthread_attr_init into libc. 2024-11-19 01:37:35 +01:00
hurd
i386 math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
ieee754 math: Add internal roundeven_finite 2024-11-26 15:07:57 -03:00
loongarch math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
m68k math: Use lgammaf from CORE-MATH 2024-11-22 10:52:27 -03:00
mach hurd: Add MAP_NORESERVE mmap flag 2024-11-25 00:55:33 +01:00
microblaze math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
mips math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
nios2 math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
nptl linux: Add support for getrandom vDSO 2024-11-12 14:42:12 -03:00
or1k math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
posix Silence most -Wzero-as-null-pointer-constant diagnostics 2024-11-25 16:45:59 -03:00
powerpc math: Add internal roundeven_finite 2024-11-26 15:07:57 -03:00
pthread Rename new tst-sem17 test to tst-sem18 2024-11-08 17:08:09 +00:00
riscv RISC-V: Use builtin for fma and fmaf 2024-11-25 16:45:59 -03:00
s390 math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
sh math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
sparc math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00
unix Silence most -Wzero-as-null-pointer-constant diagnostics 2024-11-25 16:45:59 -03:00
wordsize-32
wordsize-64
x86 Silence most -Wzero-as-null-pointer-constant diagnostics 2024-11-25 16:45:59 -03:00
x86_64 math: Use tanf from CORE-MATH 2024-11-22 10:52:27 -03:00