glibc/sysdeps
Szabolcs Nagy 4ea49f4c08 New generic powf
without wrapper on aarch64:
powf reciprocal-throughput: 4.2x faster
powf latency: 2.6x faster
old worst-case error: 1.11 ulp
new worst-case error: 0.82 ulp
aarch64 .text size: -780 bytes
aarch64 .rodata size: +144 bytes

powf(x,y) is implemented as exp2(y*log2(x)) with the same algorithms
that are used in exp2f and log2f, except that the log2f polynomial is
larger for extra precision and its output (and exp2f input) may be
scaled by a power of 2 (POWF_SCALE) to simplify the argument reduction
step of exp2 (possible when efficient round and convert toint operation
is available).

The special case handling tries to minimize the checks in the hot path.
When the input of exp2_inline is checked, int arithmetics is used as
that was faster on the tested aarch64 cores.

	* math/Makefile (type-float-routines): Add e_powf_log2_data.
	* sysdeps/ieee754/flt-32/e_powf.c: New implementation.
	* sysdeps/ieee754/flt-32/e_powf_log2_data.c: New file.
	* sysdeps/ieee754/flt-32/math_config.h (__powf_log2_data): Define.
	(issignalingf_inline): Likewise.
	(POWF_LOG2_TABLE_BITS): Likewise.
	(POWF_LOG2_POLY_ORDER): Likewise.
	(POWF_SCALE_BITS): Likewise.
	(POWF_SCALE): Likewise.
	* sysdeps/i386/fpu/e_powf_log2_data.c: New file.
	* sysdeps/ia64/fpu/e_powf_log2_data.c: New file.
	* sysdeps/m68k/m680x0/fpu/e_powf_log2_data.c: New file.
2017-09-29 17:30:53 +01:00
..
aarch64 AArch64: update libm-test-ulps 2017-09-28 15:28:46 +01:00
alpha Remove ancient __signbit inlines 2017-09-28 19:52:13 +01:00
arm Enable unwind info in libc-start.c and backtrace.c 2017-09-19 15:07:58 +01:00
generic Define and use libm_alias_float128. 2017-09-14 01:11:46 +00:00
gnu hurd: Fix `getifaddrs' and `freeifaddrs' symbol exposition 2017-09-28 01:05:18 +02:00
hppa Obsolete pow10 functions. 2017-09-01 21:13:18 +00:00
i386 New generic powf 2017-09-29 17:30:53 +01:00
ia64 New generic powf 2017-09-29 17:30:53 +01:00
ieee754 New generic powf 2017-09-29 17:30:53 +01:00
init_array Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
m68k New generic powf 2017-09-29 17:30:53 +01:00
mach hurd: Fix `seekdir' symbol exposition from `rewinddir' 2017-09-28 00:49:59 +02:00
microblaze Obsolete pow10 functions. 2017-09-01 21:13:18 +00:00
mips Enable unwind info in libc-start.c and backtrace.c 2017-09-19 15:07:58 +01:00
nios2 Enable unwind info in libc-start.c and backtrace.c 2017-09-19 15:07:58 +01:00
nptl Remove extra semicolons in struct pthread_mutex (bug 21804) 2017-07-24 12:22:05 +02:00
posix hurd: Fix dirfd symbol exposition from ftw 2017-09-28 00:49:05 +02:00
powerpc Remove ancient __signbit inlines 2017-09-28 19:52:13 +01:00
pthread aio: Remove internal_function function attribute 2017-08-31 15:59:06 +02:00
s390 Remove ancient __signbit inlines 2017-09-28 19:52:13 +01:00
sh Enable unwind info in libc-start.c and backtrace.c 2017-09-19 15:07:58 +01:00
sparc Remove ancient __signbit inlines 2017-09-28 19:52:13 +01:00
tile Remove ancient __signbit inlines 2017-09-28 19:52:13 +01:00
unix Update sysdeps/unix/sysv/linux/ifaddrs.c 2017-09-27 17:18:32 -07:00
wordsize-32 Build divdi3 only for architecture that required it 2017-04-06 15:14:34 -03:00
wordsize-64 posix: Consolidate Linux glob implementation 2017-09-08 16:34:02 +02:00
x86 Remove ancient __signbit inlines 2017-09-28 19:52:13 +01:00
x86_64 x86: Allow undefined _DYNAMIC in static executable 2017-09-28 15:28:12 -07:00