glibc/sysdeps/i386/fpu
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
..
Implies
Versions
doasin.c
e_acos.S
e_acosf.S
e_acosh.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_acoshf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_acoshl.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_acosl.c
e_asin.S Refactor i386 libm code forcing underflow exceptions. 2015-09-24 21:41:00 +00:00
e_asinf.S Refactor i386 libm code forcing underflow exceptions. 2015-09-24 21:41:00 +00:00
e_atan2.S Refactor i386 libm code forcing underflow exceptions. 2015-09-24 21:41:00 +00:00
e_atan2f.S Refactor i386 libm code forcing underflow exceptions. 2015-09-24 21:41:00 +00:00
e_atan2l.c
e_atanh.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_atanhf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_atanhl.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_exp.S Avoid excess range in results from i386 exp, hypot, pow functions (bug 18980). 2015-09-18 21:53:22 +00:00
e_exp2.S Avoid excess range in results from i386 exp, hypot, pow functions (bug 18980). 2015-09-18 21:53:22 +00:00
e_exp2f.S Avoid excess range in results from i386 exp, hypot, pow functions (bug 18980). 2015-09-18 21:53:22 +00:00
e_exp2f_data.c Optimized generic expf and exp2f with wrappers 2017-09-25 10:44:39 +01:00
e_exp2l.S Refactor i386 libm code forcing underflow exceptions. 2015-09-24 21:41:00 +00:00
e_exp10.S Avoid excess range in results from i386 exp, hypot, pow functions (bug 18980). 2015-09-18 21:53:22 +00:00
e_exp10f.S Avoid excess range in results from i386 exp, hypot, pow functions (bug 18980). 2015-09-18 21:53:22 +00:00
e_exp10l.S
e_expf.S Avoid excess range in results from i386 exp, hypot, pow functions (bug 18980). 2015-09-18 21:53:22 +00:00
e_expl.S Fix i386/x86_64 expl, exp10l, expm1l for sNaN input (bug 20226). 2016-06-08 21:55:06 +00:00
e_fmod.S
e_fmodf.S
e_fmodl.c
e_hypot.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_hypotf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_ilogb.S
e_ilogbf.S
e_ilogbl.S
e_log.S Fix i386/x86_64 log* (1) zero sign for -ffinite-math-only (bug 19213). 2015-11-05 21:56:31 +00:00
e_log2.S Fix log2 (1) in round-downward mode (bug 17042). 2014-06-10 12:07:15 +00:00
e_log2f.S Fix log2 (1) in round-downward mode (bug 17042). 2014-06-10 12:07:15 +00:00
e_log2f_data.c New generic log2f 2017-09-29 17:17:41 +01:00
e_log2l.S Fix i386/x86_64 log2l (sNaN) (bug 20235). 2016-06-09 18:04:30 +00:00
e_log10.S Fix log10 (1) in round-downward mode (bug 16977). 2014-05-23 12:07:50 +00:00
e_log10f.S Fix log10 (1) in round-downward mode (bug 16977). 2014-05-23 12:07:50 +00:00
e_log10l.S Fix i386/x86_64 log10l (sNaN) (bug 20228). 2016-06-08 22:59:18 +00:00
e_logf.S Fix i386/x86_64 log* (1) zero sign for -ffinite-math-only (bug 19213). 2015-11-05 21:56:31 +00:00
e_logf_data.c New generic logf 2017-09-29 11:46:46 +01:00
e_logl.S Fix i386/x86_64 logl (sNaN) (bug 20227). 2016-06-08 22:24:06 +00:00
e_pow.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_powf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_powf_log2_data.c New generic powf 2017-09-29 17:30:53 +01:00
e_powl.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_rem_pio2.c
e_remainder.S
e_remainderf.S
e_remainderl.S
e_scalb.S Avoid excess range in results from i386 scalb functions (bug 18981). 2015-09-18 20:34:59 +00:00
e_scalbf.S Avoid excess range in results from i386 scalb functions (bug 18981). 2015-09-18 20:34:59 +00:00
e_scalbl.S Fix i386/x86_64 scalbl with sNaN input (bug 20296). 2016-06-23 22:17:41 +00:00
e_sqrt.S
e_sqrtf.S
e_sqrtl.c
fclrexcpt.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
fedisblxcpt.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
feenablxcpt.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
fegetenv.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
fegetexcept.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
fegetmode.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
fegetround.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
feholdexcpt.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
fenv_private.h Add float128 support for x86_64, x86. 2017-06-26 22:02:24 +00:00
fesetenv.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
fesetexcept.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
fesetmode.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
fesetround.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
feupdateenv.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
fgetexcptflg.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
fraiseexcpt.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
fsetexcptflg.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
ftestexcept.c Check if SSE is available with HAS_CPU_FEATURE 2017-04-07 07:44:59 -07:00
halfulp.c
i386-math-asm.h Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
libm-test-ulps Obsolete pow10 functions. 2017-09-01 21:13:18 +00:00
libm-test-ulps-name Do not hardcode platform names in manual/libm-err-tab.pl (bug 14139). 2016-11-04 16:49:06 +00:00
math-tests.h Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
math_errf.c Optimized generic expf and exp2f with wrappers 2017-09-25 10:44:39 +01:00
math_private.h Fix math_private.h multiple include guards. 2015-11-20 23:46:23 +00:00
mpatan.c
mpatan2.c
mpexp.c
mplog.c
mpsqrt.c
s_asinh.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_asinhf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_asinhl.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_atan.S Refactor i386 libm code forcing underflow exceptions. 2015-09-24 21:41:00 +00:00
s_atanf.S Refactor i386 libm code forcing underflow exceptions. 2015-09-24 21:41:00 +00:00
s_atanl.c
s_cbrt.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_cbrtf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_cbrtl.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_ceil.S Avoid "inexact" exceptions in i386/x86_64 ceil functions (bug 15479). 2016-06-27 17:24:30 +00:00
s_ceilf.S Avoid "inexact" exceptions in i386/x86_64 ceil functions (bug 15479). 2016-06-27 17:24:30 +00:00
s_ceill.S Avoid "inexact" exceptions in i386/x86_64 ceil functions (bug 15479). 2016-06-27 17:24:30 +00:00
s_copysign.S
s_copysignf.S
s_copysignl.S
s_expm1.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_expm1f.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_expm1l.S
s_fabs.S
s_fabsf.S
s_fabsl.S
s_fdim.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_finite.S
s_finitef.S
s_finitel.S
s_floor.S Avoid "inexact" exceptions in i386/x86_64 floor functions (bug 15479). 2016-06-27 17:25:47 +00:00
s_floorf.S Avoid "inexact" exceptions in i386/x86_64 floor functions (bug 15479). 2016-06-27 17:25:47 +00:00
s_floorl.S Avoid "inexact" exceptions in i386/x86_64 floor functions (bug 15479). 2016-06-27 17:25:47 +00:00
s_fmax.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_fmaxf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_fmaxl.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_fmin.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_fminf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_fminl.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_fpclassifyl.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_frexp.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_frexpf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_frexpl.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_isinfl.c
s_isnanl.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_llrint.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_llrintf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_llrintl.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_log1p.S Refactor i386 libm code forcing underflow exceptions. 2015-09-24 21:41:00 +00:00
s_log1pf.S Refactor i386 libm code forcing underflow exceptions. 2015-09-24 21:41:00 +00:00
s_log1pl.S Fix i386/x86_64 log1pl (sNaN) (bug 20229). 2016-06-08 23:11:42 +00:00
s_logb.S
s_logbf.S
s_logbl.c
s_lrint.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_lrintf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_lrintl.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_nearbyint.S Simplify x86 nearbyint functions. 2016-06-22 15:40:30 +00:00
s_nearbyintf.S Simplify x86 nearbyint functions. 2016-06-22 15:40:30 +00:00
s_nearbyintl.S Simplify x86 nearbyint functions. 2016-06-22 15:40:30 +00:00
s_nextafterl.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_nexttoward.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_nexttowardf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_remquo.S
s_remquof.S
s_remquol.S
s_rint.S
s_rintf.S
s_rintl.c
s_scalbln.c
s_scalblnf.c
s_scalblnl.c
s_scalbn.S Avoid excess range in results from i386 scalb functions (bug 18981). 2015-09-18 20:34:59 +00:00
s_scalbnf.S Avoid excess range in results from i386 scalb functions (bug 18981). 2015-09-18 20:34:59 +00:00
s_scalbnl.S Make scalbn set errno (bug 6803). 2015-09-16 21:11:00 +00:00
s_significand.S
s_significandf.S
s_significandl.c
s_trunc.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_truncf.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_truncl.S Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
slowexp.c
slowpow.c
t_exp.c
w_sqrt.c Prefer new libm function wrappers for !LIBM_SVID_COMPAT. 2017-09-05 23:35:55 +00:00
w_sqrt_compat.c Move wrappers to libm-compat-calls-auto 2017-01-04 16:25:04 -02:00