diff options
author | Szabolcs Nagy <szabolcs.nagy@arm.com> | 2018-06-26 17:27:50 +0300 |
---|---|---|
committer | Corinna Vinschen <corinna@vinschen.de> | 2018-06-27 16:40:49 +0300 |
commit | e5791079c6235c5e40a273bd15d39c0f91609e7c (patch) | |
tree | 77390af1d37a6ce84826d099a85bed367584f7d0 /newlib/libm/common/fdlibm.h | |
parent | fb929067dbb05bfc9156a5f3e2bfc72dc951ade1 (diff) |
New log implementation
The new implementations are provided under !__OBSOLETE_MATH, it uses
ISO C99 code. With default settings the worst case error in nearest
rounding mode is 0.519 ULP with inlined fma and fma contraction. It uses
a 2 KB lookup table, on aarch64 .text+.rodata size of libm.a is increased
by 1703 bytes. The w_log.c wrapper is disabled since error handling is
inline in the new code.
New __HAVE_FAST_FMA and __HAVE_FAST_FMA_DEFAULT feature macros were
added to enable selecting between the code path that uses fma and the
one that does not. Targets supposed to set __HAVE_FAST_FMA_DEFAULT
if they have single instruction fma and the compiler can actually
inline it (gcc has __FP_FAST_FMA macro but that does not guarantee
inlining with -fno-builtin-fma).
Improvements on Cortex-A72:
latency: 1.9x
thruput: 2.3x
Diffstat (limited to 'newlib/libm/common/fdlibm.h')
-rw-r--r-- | newlib/libm/common/fdlibm.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/newlib/libm/common/fdlibm.h b/newlib/libm/common/fdlibm.h index f6c3740e3..ae85569ad 100644 --- a/newlib/libm/common/fdlibm.h +++ b/newlib/libm/common/fdlibm.h @@ -232,6 +232,7 @@ extern float __ieee754_scalbf __P((float,float)); extern symbol is reserved whenever the caller is reserved) and there are no observable error handling side effects. */ # define __ieee754_exp(x) exp(x) +# define __ieee754_log(x) log(x) # define __ieee754_expf(x) expf(x) # define __ieee754_logf(x) logf(x) # define __ieee754_powf(x,y) powf(x,y) |