diff options
author | Joseph Myers <joseph@codesourcery.com> | 2017-09-15 20:05:09 +0000 |
---|---|---|
committer | Joseph Myers <joseph@codesourcery.com> | 2017-09-15 20:05:09 +0000 |
commit | c67a2328c88fec0e91c646ad4a9d9edfb7140f0a (patch) | |
tree | 8e1fcc20769ecb8602bc9655a1f8c5187b5862a9 /math/s_asinhl.c | |
parent | 61c45f250528dae431391823a9766053e61ccde1 (diff) | |
download | glibc-c67a2328c88fec0e91c646ad4a9d9edfb7140f0a.tar.gz glibc-c67a2328c88fec0e91c646ad4a9d9edfb7140f0a.tar.xz glibc-c67a2328c88fec0e91c646ad4a9d9edfb7140f0a.zip |
Remove ENOSYS math/ function stubs.
The math/ directory has various stub implementations of functions (generally long double functions, plus sqrtf128) that set errno to ENOSYS and print a message. These are a relic of when the long double libm implementation in glibc was originally incomplete. They are only present for a limited set of libm functions, not all those that would need implementing for any hypothetical new long double format, and only for long double (plus sqrtf128), not for other floating-point types. I removed the corresponding ENOSYS tests in the testsuite in <https://sourceware.org/ml/libc-alpha/2013-05/msg00599.html>. I think these stubs are an inherently different case from stubs for functionality needing OS-specific implementations, since floating-point formats are generally standardized between modern processors (a new long double format does not seem likely - I'd expect new ports all to have long double = binary128 or long double = binary64 - though _Float16 functions *f16 are entirely possible in future) and libm functions are generally only expected to fail for domain / range / pole errors, not for other unknown system-specific conditions the way the functions needing OS-specific implementations may fail. This patch removes these stub implementations. The effect (which, as noted above, was actually mostly already the case, given the incompleteness of the set of stubs, and was certainly the case if you wanted your libm port to *work* rather than just build) is that any new long double format needs to provide a full set of functions for the build to succeed; any port using ldbl-128 needs to provide sqrtl (possibly using the soft-fp version from another port); any port using ldbl-96 needs to provide all those functions that all of x86_64/i386/ia64/m68k provide rather than getting from the ldbl-96 directory; any port with _Float128 as a type with a distinct format needs to provide sqrtf128. Tested for x86_64. Also tested with build-many-glibcs.py that installed stripped shared libraries are unchanged by the patch. * math/e_acoshl.c: Remove. * math/e_acosl.c: Likewise. * math/e_asinl.c: Likewise. * math/e_atan2l.c: Likewise. * math/e_atanhl.c: Likewise. * math/e_coshl.c: Likewise. * math/e_expl.c: Likewise. * math/e_fmodl.c: Likewise. * math/e_gammal_r.c: Likewise. * math/e_hypotl.c: Likewise. * math/e_j0l.c: Likewise. * math/e_j1l.c: Likewise. * math/e_jnl.c: Likewise. * math/e_lgammal_r.c: Likewise. * math/e_log10l.c: Likewise. * math/e_log2l.c: Likewise. * math/e_logl.c: Likewise. * math/e_powl.c: Likewise. * math/e_rem_pio2l.c: Likewise. * math/e_sinhl.c: Likewise. * math/e_sqrtf128.c: Likewise. * math/e_sqrtl.c: Likewise. * math/k_cosl.c: Likewise. * math/k_sinl.c: Likewise. * math/k_tanl.c: Likewise. * math/s_asinhl.c: Likewise. * math/s_atanl.c: Likewise. * math/s_cbrtl.c: Likewise. * math/s_erfl.c: Likewise. * math/s_expm1l.c: Likewise. * math/s_log1pl.c: Likewise. * math/s_tanhl.c: Likewise.
Diffstat (limited to 'math/s_asinhl.c')
-rw-r--r-- | math/s_asinhl.c | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/math/s_asinhl.c b/math/s_asinhl.c deleted file mode 100644 index 8232fcd38d..0000000000 --- a/math/s_asinhl.c +++ /dev/null @@ -1,14 +0,0 @@ -#include <math.h> -#include <stdio.h> -#include <errno.h> - -long double -__asinhl(long double x) -{ - fputs ("__asinhl not implemented\n", stderr); - __set_errno (ENOSYS); - return 0.0; -} - -weak_alias (__asinhl, asinhl) -stub_warning (asinhl) |