glibc/sysdeps/ieee754/dbl-64/e_gamma_r.c

224 lines
6.1 KiB
C
Raw Normal View History

Update. 1997-06-19 19:38 Ulrich Drepper <drepper@cygnus.com> * features.h: Define __STDC_IEC_559__ and _STDC_IEC_559_COMPLEX__. * elf/dl-minimal.c (__dcgettext): Remove assertion. * inet/rcmd.c: Correct a few typos. Reported by Eric Troan. * manual/Makefile (distribute): Add dir. * manual/dir: New file. * math/Makefile (libm-support): Rename s_rinttol, s_rinttoll, s_roundtol, and s_roundtoll to s_lrint, s_llrint, s_lround, and s_llround respectively. (libm-calls): Add e_gamma_r. * math/libm-test.c (check_int_exc): New function. (signbit_test): Remove test for sign of NaN. (gamma_test): Clear exception after test of existence. Correct tests and and epsilons. (lgamma_test): Likewise. (ilogb_test): Correct all tests. (scalb_test): Rewrite. (rinttol_test): Rename to lrint_test and correct tests. (rinttoll_test): Likewise. (roundtol_test): Likewise. (roundtoll_test): Likewise. (main): Call lrint/lround functions instead of rinttol/roundtol. * math/math.h: Change prototypes for rinttol/roundtol. * math/mathcalls.h: Rearrange prototypes according to ISO C9X draft. * sysdeps/generic/mathbits.h: Define FP_ILOGB0 and FP_ILOGBNAN. * sysdeps/i386/mathbits.h: Likewise. * sysdeps/libm-i387/e_scalb.S: Handle special cases correctly. * sysdeps/libm-i387/e_scalbf.S: Likewise. * sysdeps/libm-i387/e_scalbl.S: Likewise. * sysdeps/libm-i387/s_asinh.S: Handle -inf correctly. * sysdeps/libm-i387/s_asinhf.S: Likewise. * sysdeps/libm-i387/s_asinhl.S: Likewise. * sysdeps/libm-i387/s_ilogb.S: Optimize. * sysdeps/libm-i387/s_ilogbf.S: Likewise. * sysdeps/libm-i387/s_ilogbl.S: Likewise. * sysdeps/libm-i387/s_rinttol.S: Rename to... * sysdeps/libm-i387/s_lrint.S: ...this. * sysdeps/libm-i387/s_rinttoll.S: Rename to... * sysdeps/libm-i387/s_llrint.S: ...this. * sysdeps/libm-i387/s_remquo.S: Correctly set sign of remainder. * sysdeps/libm-i387/s_remquof.S: Likewise. * sysdeps/libm-i387/s_remquol.S: Likewise. * sysdeps/libm-i387/e_gamma_r.c: New file. Implementation of gamma function according to ISO C. * sysdeps/libm-i387/e_gammaf_r.c: New file. * sysdeps/libm-i387/e_gammal_r.c: New file. * sysdeps/libm-i387/e_lgamma_r.c: Don't let optimize compile the generation of exceptions away. * sysdeps/libm-i387/e_lgammaf_r.c: Likewise. * sysdeps/libm-i387/k_standard.c: Correct return value for infinity points of gamma function when not SVID mode. * sysdeps/libm-i387/s_rinttoll.c: Renamed to... * sysdeps/libm-i387/s_llrint.c: ...this. * sysdeps/libm-i387/s_rinttol.c: Renamed to... * sysdeps/libm-i387/s_lrint.c: ...this. * sysdeps/libm-i387/s_roundtoll.c: Renamed to... * sysdeps/libm-i387/s_llround.c: ...this. * sysdeps/libm-i387/s_roundtol.c: Renamed to... * sysdeps/libm-i387/s_lround.c: ..this. * sysdeps/libm-i387/s_scalbn.c: Change second parameter according to ISO C. * sysdeps/libm-i387/s_scalbnf.c: Likewise. * sysdeps/libm-i387/s_scalbnl.c: Likewise. * sysdeps/libm-i387/w_gamma.c: Call __ieee754_gamma_r if library mode is not _SVID_. * sysdeps/libm-i387/w_gammaf.c: Likewise. * sysdeps/libm-i387/w_gammal.c: Likewise. * sysdeps/m68k/fpu/__math.h: Rename __rinttol to __lrint and rinttol to lrint. * sysdeps/m68k/fpu/s_rinttol.c: Renamed to... * sysdeps/m68k/fpu/s_lrint.c: ...this. * sysdeps/m68k/fpu/s_rinttoll.c: Renamed to... * sysdeps/m68k/fpu/s_llrint.c: ...this. * md5-crypt/Makefile: Link md5test program with md5.o. * stdio-common/temptest.c: Don't use __stdio_gen_tempname which is not exported by the libc.so. * stdio-common/vfscanf.c: Correct scanning of strings after last change. * sysdeps/unix/sysv/linux/i386/sysdep.S: Use .comm to define errno. 1997-06-19 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * time/tzfile.c (__tzfile_read): Store getc () return in int. 1997-06-13 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (argp_version_parser): Include `(PROGRAM ERROR)' in the no-version error text to indicate that something's fucked. [!_] (N_): New macro. (argp_default_options, argp_version_options): Wrap doc strings in N_(). 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (parser_parse_opt): Detect and report unhandled options here. (parser_parse_arg): Handle ARGP_KEY_ARGS here. Adjust NEXT pointer back if we fail to parse anything. (parser_parse_next): Simplify arg code. Leave state NEXT frobbing to parser_parse_arg. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp.h (ARGP_KEY_ARGS, ARGP_KEY_FINI): New macros. * argp/argp-parse.c (parser_finalize): Do another pass over the parsers with ARGP_KEY_FINI. 1997-06-18 Miles Bader <miles@gnu.ai.mit.edu> * string/Makefile (routines): Add argz-replace. 1997-06-16 00:16 Miles Bader <miles@gnu.ai.mit.edu> * manual/string.texi (Argz Functions): Document argz_replace. 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * string/argz.h (__argz_replace, argz_replace): New declarations. * string/argz-replace.c: New file. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * manual/argp.texi (Argp Special Keys): Document ARGP_KEY_ARGS. 1997-06-16 23:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * Makeconfig (libc-map): Remove definition. * Makerules (libc-map): Define it here, using the full name. (load-map-file): Remove case for empty $(..). ($(common-objpfx)libc.so): Revert last change. 1997-06-17 22:18 Mark Kettenis <kettenis@phys.uva.nl> * login/programs/utmpd.c (main): Improve signal handling. * login/programs/request.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/utmpd.h (setutent_request, updwtmp_request): Get rid of fixed length file field. * login/utmp_daemon.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/request.c (do_pututline): Don't fail if connection->position is -1 on entry. 1997-06-15 16:32 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (updwtmp_file): Use the same method for appending an entry as in pututline_file. 1997-06-11 18:59 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (getutent_r_file): Use read lock instead of write lock. (getutline_r_file, internal_getut_r): Lock utmp file. (updwtmp_file): Use fcntl to lock file instead of flock. 1997-06-18 00:11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * stdio-common/vfscanf.c (inchar, ungetc): Don't count EOF as character read in/put back. * stdio-common/tstscanf.c: Add test case for this. 1997-06-17 22:17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * libc.map: Add more symbols. 1997-06-18 12:01 Ulrich Drepper <drepper@cygnus.com> * manual/Makefile (install): Make sure `dir' file exists if we use install-info. 1997-06-17 19:32 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * manual/Makefile (info): Depend on dir-add.info. 1997-06-17 17:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/ldd.bash.in: Fix spacing in message. 1997-06-17 14:28 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/do-rel.h (elf_dynamic_do_rel): Always use version information if available. 1997-06-17 11:34 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sunrpc/Makefile ($(rpcsvc:%.x=$(objpfx)rpcsvc/%.h)): Make command non-empty to force make to recheck modification time. ($(rpcsvc:%.x=$(objpfx)x%.c)): Likewise. 1997-06-17 00:26 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/stub/e_acoshl.c: Set errno to ENOSYS. * sysdeps/stub/e_acosl.c: Likewise. * sysdeps/stub/e_asinl.c: Likewise. * sysdeps/stub/e_atan2l.c: Likewise. * sysdeps/stub/e_expl.c: Likewise. * sysdeps/stub/e_fmodl.c: Likewise. * sysdeps/stub/e_j0l.c: Likewise. * sysdeps/stub/e_j1l.c: Likewise. * sysdeps/stub/e_jnl.c: Likewise. * sysdeps/stub/e_lgammal_r.c: Likewise. * sysdeps/stub/e_log10l.c: Likewise. * sysdeps/stub/e_logl.c: Likewise. * sysdeps/stub/e_powl.c: Likewise. * sysdeps/stub/e_rem_pio2l.c: Likewise. * sysdeps/stub/e_sqrtl.c: Likewise. * sysdeps/stub/k_cosl.c: Likewise. * sysdeps/stub/k_rem_pio2l.c: Likewise. * sysdeps/stub/k_sinl.c: Likewise. * sysdeps/stub/k_tanl.c: Likewise. * sysdeps/stub/s_atanl.c: Likewise. * sysdeps/stub/s_erfl.c: Likewise. * sysdeps/stub/s_exp2.c: Likewise. * sysdeps/stub/s_exp2f.c: Likewise. * sysdeps/stub/s_exp2l.c: Likewise. * sysdeps/stub/s_expm1l.c: Likewise. * sysdeps/stub/s_log1pl.c: Likewise. * sysdeps/stub/s_log2l.c: Likewise. 1997-06-18 11:46 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/w_gamma.c: If _LIB_VERSION is _SVID_ compute result as before last change. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. 1997-06-16 23:37 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/libm-ieee754/s_remquo.c: Fix off-by-one when computing quotient. * sysdeps/libm-ieee754/s_remquof.c: Likewise. * sysdeps/libm-ieee754/s_remquol.c: Likewise. * sysdeps/m68k/fpu/s_remquo.c: Remove FIXME and special case for quotient. * sysdeps/libm-ieee754/w_gamma.c: Add missing call to exp function. Don't use global signgam. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. * math/Makefile (libm-calls): Remove w_gamma_r. * sysdeps/libm-ieee754/w_gamma_r.c: Remove file. * sysdeps/libm-ieee754/w_gammaf_r.c: Remove file. * sysdeps/libm-ieee754/w_gammal_r.c: Remove file. * math/libm-test.c (atanh_test): Declare x only if needed. (signbit_test): Fix typo. (gamma_test): Check whether function is implemented. Add epsilons. (lgamma_test): Likewise. (fmod_test): Add epsilons. (exp2_test): Use right function for existence test. 1997-06-07 09:20 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/powerpc/Dist: Add fenv_const.c. * sysdeps/unix/sysv/linux/Dist: Add net/if_slip.h. * sysdeps/unix/sysv/linux/powerpc/Dist: Add init-first.h and syscall.h. * sysdeps/unix/sysv/linux/sparc/Dist: Add init-first.h. * string/Makefile (distribute): Add tst-svc.expect. * nis/Makefile (distribute): Add nis_intern.h and Banner. * elf/Makefile (distribute): Add dl-hash.h. * Rules (subdir_echo-distinfo): Add headers from $(distribute). * login/Makefile (others): Add utmpdump. * sysdeps/unix/sysv/linux/Makefile (sysdep_headers): Add net/if_slip.h. * manual/Makefile (dir-add.texi): Also look in indirectly included files. 1997-06-16 23:15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/configure.in: Remove commands to generate stdio_lim.h. * sysdeps/unix/sysv/linux/mk-stdiolim.c: Remove. * sysdeps/unix/sysv/linux/Makefile: Add rules to generate stdio_lim.h here. (common-generated): Add generated files. (inhibit-stdio_lim): Define. * sysdeps/posix/Makefile [$(inhibit-stdio_lim)=yes]: Disable rules to generate stdio_lim.h. * sysdeps/unix/sysv/linux/Makefile: Suppress inclusion of dependecy files if no_deps is set. ($(objpfx)syscall-%.d): Add header file as target to dependency generation. 1997-06-14 19:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/arm/Dist: New file. 1997-06-14 17:59 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * extra-lib.mk (others): Depend on versioned shared library, not the unversioned one. * Makerules (build-shlib): Don't make the version link here. ($(common-objpfx)libc.so$(libc.so-version)): New rule for libc version link. 1997-06-16 03:07 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/k_standard.c: Undo change of Tue Aug 6 01:13:56 1996. * argp/argp-help.c (argp_args_usage): Supply correct argp to filter_doc. * argp/argp-help.c (hol_add_cluster): Initialize CL->depth. * argp/argp-help.c (_help): Supply STATE to argp_args_usage. * argp/argp.h (ARGP_KEY_HELP_ARGS_DOC): New macro. * argp/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp.h (OPTION_NO_USAGE): New macro. * argp/argp-help.c (usage_long_opt, usage_argful_short_opt, * argp/argp-fmtstream.c (__argp_fmtstream_update): Account for case * argp/argp-help.c <stddef.h>: New include. * argp/argp.h (argp_state_help, __argp_state_help, argp_usage, * argp/argp.h (argp_program_bug_address): Make const. * argp/argp-parse.c (argp_default_parser): Set STATE->name for OPT_PROGNAME. * argp/argp-help.c (__argp_error, __argp_failure, __argp_state_help): * argp/argp-parse.c (parser_init): Set PARSER->state.flags.
1997-06-19 21:11:22 +02:00
/* Implementation of gamma function according to ISO C.
Copyright (C) 1997-2018 Free Software Foundation, Inc.
Update. 1997-04-09 01:24 Ulrich Drepper <drepper@cygnus.com> * rellns-sh: Rewrite to work also in presence of symlinks. * arpg/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp-fmtstream.h: Likewise. * argp/argp-help.c: Likewise. * elf/dl-minimal.c: Add definition of calloc. * elf/version.c: Add casts to prevent warnings. (_dl_check_map_versions): Use calloc instead of malloc+memset. * locale/setlocale.c (_nl_current): Add element with index LC_ALL. Reported by Greg McGary <gkm@eng.ascend.com>. * manual/libc.texinfo: Update malloc documentation for new malloc. * manual/memory.texi: Likewise. Patch by Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>. * math/libm-test.c (check_long): New function. (check_longlong): New function. (rinttol_test): New function. (rinttoll_test): New function. * nis/nss_compat/compat-grp.c (in_blacklist): Improve a bit. * nis/nss_compat/compat-pwd.c: Likewise. * nis/nss_compat/compat-spwd.c: Likewise. * stdlib/erand48_r.c (erand48_r): Build double value using ieee754_double union and use random bits in different order to increase effect of seed. Reported by David Mosberger-Tang <davidm@AZStarNet.com>. * sunrpc/svc_auth.c: Moved to ... * sysdeps/generic/svc_auth.c: ...here. * time/time.h: Pretty print. 1997-04-08 07:19 H.J. Lu <hjl@gnu.ai.mit.edu> * libio/genops.c (_IO_flush_all_linebuffered): don't flush on a read-only stream. 1997-04-09 01:19 Ulrich Drepper <drepper@cygnus.com> * malloc/malloc.c (mALLOC_STATs) [MALLOC_DEBUG>1]: Put declaration in correct place. Patch by Marcus G. Daniels <marcus@cathcart.sysc.pdx.edu>. 1997-04-07 15:34 Ulrich Drepper <drepper@cygnus.com> * stdio-common/Makefile (tests): Add tst-ferror. * stdio-common/tst-ferror.c: New file. Some tests for error indicator of streams. * stdio-common/tst-ferror.input: New file. * isomac.c: Let tests not fail because the compiler defines itself symbols which violate the name space rules. gcc defines symbols for the architecture which are not protected by an underscore character. * math/Makefile (libm-support): Add s_rinttol and s_rinttoll. (libm-calls): Add s_clog. * sysdeps/libm-ieee754/s_clog.c: New file. Implementation of logarithm of complex value. * sysdeps/libm-ieee754/s_clogf.c: New file. * sysdeps/libm-ieee754/s_clogl.c: New file. * math/libm-test.c (clog_test): Compile this function. Fix a few typos. (main): Call clog_test. * sysdeps/libm-ieee754/s_rinttol.c: New file. Round long double value to long int. * sysdeps/libm-i387/s_rinttol.S: New file. * sysdeps/libm-ieee754/s_rinttoll.c: new file. Round long double value to long long int. * sysdeps/libm-i387/s_rinttoll.S: New file. * sysdeps/libm-ieee754/s_rintl.c: Many corrections. The previous version was full of errors. * math/math.h (rinttol): Argument is of type `long double' not `double'. (rinttoll): Likewise. (roundtol): Likewise. (roundtoll): Likewise. 1997-04-06 11:32 H.J. Lu <hjl@gnu.ai.mit.edu> * posix/getopt.c (_getopt_initialize): Preserve optind. (_getopt_internal): Set optind to 1 if optind == 0 before calling _getopt_initialize (). 1997-04-05 16:45 Thorsten Kukuk <kukuk@vt.uni-paderborn.de> * nis/rpcsvc/nislib.h: Change const nis_name to new type const_nis_name. * nis/nis_intern.c: Likewise. * nis/nis_intern.h: Likewise. * nis/nis_server.c: Likewise. * nis/nis_subr.c: Likewise. * nis/nis_table.c: Likewise. * nis/nis_names.c: Likewise. Fill out ns_request structure in nis_add(). * nis/nss_compat/compat-pwd.c: Use reentrant netgroup functions. * nis/nss_compat/compat-spwd.c: Likewise. 1997-03-27 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * libio/fileops.c (_IO_file_overflow): Set error when try to write on a read-only stream. * sysdeps/gnu/utmpbits.h (ut_xtime): New symbol. (ut_time): Define it only if _NO_UT_TIME is not defined. 1997-04-06 00:42 Ulrich Drepper <drepper@cygnus.com> * misc/tst-tsearch.c: Include <string.h>. Define _GNU_SOURCE only if not already defined. 1997-04-05 16:14 Ulrich Drepper <drepper@cygnus.com> * sysdeps/unix/sysv/linux/netatalk/at.h: Include <sys/socket.h> to get definition of sa_family_t for <linux/atalk.h>. Reported by a sun <asun@zoology.washington.edu>. * malloc/malloc.c (cALLOc): Little optimization.
1997-04-09 01:42:08 +02:00
This file is part of the GNU C Library.
Contributed by Ulrich Drepper <drepper@cygnus.com>, 1997.
The GNU C Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
Update. 1997-04-09 01:24 Ulrich Drepper <drepper@cygnus.com> * rellns-sh: Rewrite to work also in presence of symlinks. * arpg/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp-fmtstream.h: Likewise. * argp/argp-help.c: Likewise. * elf/dl-minimal.c: Add definition of calloc. * elf/version.c: Add casts to prevent warnings. (_dl_check_map_versions): Use calloc instead of malloc+memset. * locale/setlocale.c (_nl_current): Add element with index LC_ALL. Reported by Greg McGary <gkm@eng.ascend.com>. * manual/libc.texinfo: Update malloc documentation for new malloc. * manual/memory.texi: Likewise. Patch by Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>. * math/libm-test.c (check_long): New function. (check_longlong): New function. (rinttol_test): New function. (rinttoll_test): New function. * nis/nss_compat/compat-grp.c (in_blacklist): Improve a bit. * nis/nss_compat/compat-pwd.c: Likewise. * nis/nss_compat/compat-spwd.c: Likewise. * stdlib/erand48_r.c (erand48_r): Build double value using ieee754_double union and use random bits in different order to increase effect of seed. Reported by David Mosberger-Tang <davidm@AZStarNet.com>. * sunrpc/svc_auth.c: Moved to ... * sysdeps/generic/svc_auth.c: ...here. * time/time.h: Pretty print. 1997-04-08 07:19 H.J. Lu <hjl@gnu.ai.mit.edu> * libio/genops.c (_IO_flush_all_linebuffered): don't flush on a read-only stream. 1997-04-09 01:19 Ulrich Drepper <drepper@cygnus.com> * malloc/malloc.c (mALLOC_STATs) [MALLOC_DEBUG>1]: Put declaration in correct place. Patch by Marcus G. Daniels <marcus@cathcart.sysc.pdx.edu>. 1997-04-07 15:34 Ulrich Drepper <drepper@cygnus.com> * stdio-common/Makefile (tests): Add tst-ferror. * stdio-common/tst-ferror.c: New file. Some tests for error indicator of streams. * stdio-common/tst-ferror.input: New file. * isomac.c: Let tests not fail because the compiler defines itself symbols which violate the name space rules. gcc defines symbols for the architecture which are not protected by an underscore character. * math/Makefile (libm-support): Add s_rinttol and s_rinttoll. (libm-calls): Add s_clog. * sysdeps/libm-ieee754/s_clog.c: New file. Implementation of logarithm of complex value. * sysdeps/libm-ieee754/s_clogf.c: New file. * sysdeps/libm-ieee754/s_clogl.c: New file. * math/libm-test.c (clog_test): Compile this function. Fix a few typos. (main): Call clog_test. * sysdeps/libm-ieee754/s_rinttol.c: New file. Round long double value to long int. * sysdeps/libm-i387/s_rinttol.S: New file. * sysdeps/libm-ieee754/s_rinttoll.c: new file. Round long double value to long long int. * sysdeps/libm-i387/s_rinttoll.S: New file. * sysdeps/libm-ieee754/s_rintl.c: Many corrections. The previous version was full of errors. * math/math.h (rinttol): Argument is of type `long double' not `double'. (rinttoll): Likewise. (roundtol): Likewise. (roundtoll): Likewise. 1997-04-06 11:32 H.J. Lu <hjl@gnu.ai.mit.edu> * posix/getopt.c (_getopt_initialize): Preserve optind. (_getopt_internal): Set optind to 1 if optind == 0 before calling _getopt_initialize (). 1997-04-05 16:45 Thorsten Kukuk <kukuk@vt.uni-paderborn.de> * nis/rpcsvc/nislib.h: Change const nis_name to new type const_nis_name. * nis/nis_intern.c: Likewise. * nis/nis_intern.h: Likewise. * nis/nis_server.c: Likewise. * nis/nis_subr.c: Likewise. * nis/nis_table.c: Likewise. * nis/nis_names.c: Likewise. Fill out ns_request structure in nis_add(). * nis/nss_compat/compat-pwd.c: Use reentrant netgroup functions. * nis/nss_compat/compat-spwd.c: Likewise. 1997-03-27 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * libio/fileops.c (_IO_file_overflow): Set error when try to write on a read-only stream. * sysdeps/gnu/utmpbits.h (ut_xtime): New symbol. (ut_time): Define it only if _NO_UT_TIME is not defined. 1997-04-06 00:42 Ulrich Drepper <drepper@cygnus.com> * misc/tst-tsearch.c: Include <string.h>. Define _GNU_SOURCE only if not already defined. 1997-04-05 16:14 Ulrich Drepper <drepper@cygnus.com> * sysdeps/unix/sysv/linux/netatalk/at.h: Include <sys/socket.h> to get definition of sa_family_t for <linux/atalk.h>. Reported by a sun <asun@zoology.washington.edu>. * malloc/malloc.c (cALLOc): Little optimization.
1997-04-09 01:42:08 +02:00
The GNU C Library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
Update. 1997-04-09 01:24 Ulrich Drepper <drepper@cygnus.com> * rellns-sh: Rewrite to work also in presence of symlinks. * arpg/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp-fmtstream.h: Likewise. * argp/argp-help.c: Likewise. * elf/dl-minimal.c: Add definition of calloc. * elf/version.c: Add casts to prevent warnings. (_dl_check_map_versions): Use calloc instead of malloc+memset. * locale/setlocale.c (_nl_current): Add element with index LC_ALL. Reported by Greg McGary <gkm@eng.ascend.com>. * manual/libc.texinfo: Update malloc documentation for new malloc. * manual/memory.texi: Likewise. Patch by Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>. * math/libm-test.c (check_long): New function. (check_longlong): New function. (rinttol_test): New function. (rinttoll_test): New function. * nis/nss_compat/compat-grp.c (in_blacklist): Improve a bit. * nis/nss_compat/compat-pwd.c: Likewise. * nis/nss_compat/compat-spwd.c: Likewise. * stdlib/erand48_r.c (erand48_r): Build double value using ieee754_double union and use random bits in different order to increase effect of seed. Reported by David Mosberger-Tang <davidm@AZStarNet.com>. * sunrpc/svc_auth.c: Moved to ... * sysdeps/generic/svc_auth.c: ...here. * time/time.h: Pretty print. 1997-04-08 07:19 H.J. Lu <hjl@gnu.ai.mit.edu> * libio/genops.c (_IO_flush_all_linebuffered): don't flush on a read-only stream. 1997-04-09 01:19 Ulrich Drepper <drepper@cygnus.com> * malloc/malloc.c (mALLOC_STATs) [MALLOC_DEBUG>1]: Put declaration in correct place. Patch by Marcus G. Daniels <marcus@cathcart.sysc.pdx.edu>. 1997-04-07 15:34 Ulrich Drepper <drepper@cygnus.com> * stdio-common/Makefile (tests): Add tst-ferror. * stdio-common/tst-ferror.c: New file. Some tests for error indicator of streams. * stdio-common/tst-ferror.input: New file. * isomac.c: Let tests not fail because the compiler defines itself symbols which violate the name space rules. gcc defines symbols for the architecture which are not protected by an underscore character. * math/Makefile (libm-support): Add s_rinttol and s_rinttoll. (libm-calls): Add s_clog. * sysdeps/libm-ieee754/s_clog.c: New file. Implementation of logarithm of complex value. * sysdeps/libm-ieee754/s_clogf.c: New file. * sysdeps/libm-ieee754/s_clogl.c: New file. * math/libm-test.c (clog_test): Compile this function. Fix a few typos. (main): Call clog_test. * sysdeps/libm-ieee754/s_rinttol.c: New file. Round long double value to long int. * sysdeps/libm-i387/s_rinttol.S: New file. * sysdeps/libm-ieee754/s_rinttoll.c: new file. Round long double value to long long int. * sysdeps/libm-i387/s_rinttoll.S: New file. * sysdeps/libm-ieee754/s_rintl.c: Many corrections. The previous version was full of errors. * math/math.h (rinttol): Argument is of type `long double' not `double'. (rinttoll): Likewise. (roundtol): Likewise. (roundtoll): Likewise. 1997-04-06 11:32 H.J. Lu <hjl@gnu.ai.mit.edu> * posix/getopt.c (_getopt_initialize): Preserve optind. (_getopt_internal): Set optind to 1 if optind == 0 before calling _getopt_initialize (). 1997-04-05 16:45 Thorsten Kukuk <kukuk@vt.uni-paderborn.de> * nis/rpcsvc/nislib.h: Change const nis_name to new type const_nis_name. * nis/nis_intern.c: Likewise. * nis/nis_intern.h: Likewise. * nis/nis_server.c: Likewise. * nis/nis_subr.c: Likewise. * nis/nis_table.c: Likewise. * nis/nis_names.c: Likewise. Fill out ns_request structure in nis_add(). * nis/nss_compat/compat-pwd.c: Use reentrant netgroup functions. * nis/nss_compat/compat-spwd.c: Likewise. 1997-03-27 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * libio/fileops.c (_IO_file_overflow): Set error when try to write on a read-only stream. * sysdeps/gnu/utmpbits.h (ut_xtime): New symbol. (ut_time): Define it only if _NO_UT_TIME is not defined. 1997-04-06 00:42 Ulrich Drepper <drepper@cygnus.com> * misc/tst-tsearch.c: Include <string.h>. Define _GNU_SOURCE only if not already defined. 1997-04-05 16:14 Ulrich Drepper <drepper@cygnus.com> * sysdeps/unix/sysv/linux/netatalk/at.h: Include <sys/socket.h> to get definition of sa_family_t for <linux/atalk.h>. Reported by a sun <asun@zoology.washington.edu>. * malloc/malloc.c (cALLOc): Little optimization.
1997-04-09 01:42:08 +02:00
You should have received a copy of the GNU Lesser General Public
License along with the GNU C Library; if not, see
<http://www.gnu.org/licenses/>. */
Update. 1997-04-09 01:24 Ulrich Drepper <drepper@cygnus.com> * rellns-sh: Rewrite to work also in presence of symlinks. * arpg/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp-fmtstream.h: Likewise. * argp/argp-help.c: Likewise. * elf/dl-minimal.c: Add definition of calloc. * elf/version.c: Add casts to prevent warnings. (_dl_check_map_versions): Use calloc instead of malloc+memset. * locale/setlocale.c (_nl_current): Add element with index LC_ALL. Reported by Greg McGary <gkm@eng.ascend.com>. * manual/libc.texinfo: Update malloc documentation for new malloc. * manual/memory.texi: Likewise. Patch by Wolfram Gloger <wmglo@dent.med.uni-muenchen.de>. * math/libm-test.c (check_long): New function. (check_longlong): New function. (rinttol_test): New function. (rinttoll_test): New function. * nis/nss_compat/compat-grp.c (in_blacklist): Improve a bit. * nis/nss_compat/compat-pwd.c: Likewise. * nis/nss_compat/compat-spwd.c: Likewise. * stdlib/erand48_r.c (erand48_r): Build double value using ieee754_double union and use random bits in different order to increase effect of seed. Reported by David Mosberger-Tang <davidm@AZStarNet.com>. * sunrpc/svc_auth.c: Moved to ... * sysdeps/generic/svc_auth.c: ...here. * time/time.h: Pretty print. 1997-04-08 07:19 H.J. Lu <hjl@gnu.ai.mit.edu> * libio/genops.c (_IO_flush_all_linebuffered): don't flush on a read-only stream. 1997-04-09 01:19 Ulrich Drepper <drepper@cygnus.com> * malloc/malloc.c (mALLOC_STATs) [MALLOC_DEBUG>1]: Put declaration in correct place. Patch by Marcus G. Daniels <marcus@cathcart.sysc.pdx.edu>. 1997-04-07 15:34 Ulrich Drepper <drepper@cygnus.com> * stdio-common/Makefile (tests): Add tst-ferror. * stdio-common/tst-ferror.c: New file. Some tests for error indicator of streams. * stdio-common/tst-ferror.input: New file. * isomac.c: Let tests not fail because the compiler defines itself symbols which violate the name space rules. gcc defines symbols for the architecture which are not protected by an underscore character. * math/Makefile (libm-support): Add s_rinttol and s_rinttoll. (libm-calls): Add s_clog. * sysdeps/libm-ieee754/s_clog.c: New file. Implementation of logarithm of complex value. * sysdeps/libm-ieee754/s_clogf.c: New file. * sysdeps/libm-ieee754/s_clogl.c: New file. * math/libm-test.c (clog_test): Compile this function. Fix a few typos. (main): Call clog_test. * sysdeps/libm-ieee754/s_rinttol.c: New file. Round long double value to long int. * sysdeps/libm-i387/s_rinttol.S: New file. * sysdeps/libm-ieee754/s_rinttoll.c: new file. Round long double value to long long int. * sysdeps/libm-i387/s_rinttoll.S: New file. * sysdeps/libm-ieee754/s_rintl.c: Many corrections. The previous version was full of errors. * math/math.h (rinttol): Argument is of type `long double' not `double'. (rinttoll): Likewise. (roundtol): Likewise. (roundtoll): Likewise. 1997-04-06 11:32 H.J. Lu <hjl@gnu.ai.mit.edu> * posix/getopt.c (_getopt_initialize): Preserve optind. (_getopt_internal): Set optind to 1 if optind == 0 before calling _getopt_initialize (). 1997-04-05 16:45 Thorsten Kukuk <kukuk@vt.uni-paderborn.de> * nis/rpcsvc/nislib.h: Change const nis_name to new type const_nis_name. * nis/nis_intern.c: Likewise. * nis/nis_intern.h: Likewise. * nis/nis_server.c: Likewise. * nis/nis_subr.c: Likewise. * nis/nis_table.c: Likewise. * nis/nis_names.c: Likewise. Fill out ns_request structure in nis_add(). * nis/nss_compat/compat-pwd.c: Use reentrant netgroup functions. * nis/nss_compat/compat-spwd.c: Likewise. 1997-03-27 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * libio/fileops.c (_IO_file_overflow): Set error when try to write on a read-only stream. * sysdeps/gnu/utmpbits.h (ut_xtime): New symbol. (ut_time): Define it only if _NO_UT_TIME is not defined. 1997-04-06 00:42 Ulrich Drepper <drepper@cygnus.com> * misc/tst-tsearch.c: Include <string.h>. Define _GNU_SOURCE only if not already defined. 1997-04-05 16:14 Ulrich Drepper <drepper@cygnus.com> * sysdeps/unix/sysv/linux/netatalk/at.h: Include <sys/socket.h> to get definition of sa_family_t for <linux/atalk.h>. Reported by a sun <asun@zoology.washington.edu>. * malloc/malloc.c (cALLOc): Little optimization.
1997-04-09 01:42:08 +02:00
Update. 1997-06-19 19:38 Ulrich Drepper <drepper@cygnus.com> * features.h: Define __STDC_IEC_559__ and _STDC_IEC_559_COMPLEX__. * elf/dl-minimal.c (__dcgettext): Remove assertion. * inet/rcmd.c: Correct a few typos. Reported by Eric Troan. * manual/Makefile (distribute): Add dir. * manual/dir: New file. * math/Makefile (libm-support): Rename s_rinttol, s_rinttoll, s_roundtol, and s_roundtoll to s_lrint, s_llrint, s_lround, and s_llround respectively. (libm-calls): Add e_gamma_r. * math/libm-test.c (check_int_exc): New function. (signbit_test): Remove test for sign of NaN. (gamma_test): Clear exception after test of existence. Correct tests and and epsilons. (lgamma_test): Likewise. (ilogb_test): Correct all tests. (scalb_test): Rewrite. (rinttol_test): Rename to lrint_test and correct tests. (rinttoll_test): Likewise. (roundtol_test): Likewise. (roundtoll_test): Likewise. (main): Call lrint/lround functions instead of rinttol/roundtol. * math/math.h: Change prototypes for rinttol/roundtol. * math/mathcalls.h: Rearrange prototypes according to ISO C9X draft. * sysdeps/generic/mathbits.h: Define FP_ILOGB0 and FP_ILOGBNAN. * sysdeps/i386/mathbits.h: Likewise. * sysdeps/libm-i387/e_scalb.S: Handle special cases correctly. * sysdeps/libm-i387/e_scalbf.S: Likewise. * sysdeps/libm-i387/e_scalbl.S: Likewise. * sysdeps/libm-i387/s_asinh.S: Handle -inf correctly. * sysdeps/libm-i387/s_asinhf.S: Likewise. * sysdeps/libm-i387/s_asinhl.S: Likewise. * sysdeps/libm-i387/s_ilogb.S: Optimize. * sysdeps/libm-i387/s_ilogbf.S: Likewise. * sysdeps/libm-i387/s_ilogbl.S: Likewise. * sysdeps/libm-i387/s_rinttol.S: Rename to... * sysdeps/libm-i387/s_lrint.S: ...this. * sysdeps/libm-i387/s_rinttoll.S: Rename to... * sysdeps/libm-i387/s_llrint.S: ...this. * sysdeps/libm-i387/s_remquo.S: Correctly set sign of remainder. * sysdeps/libm-i387/s_remquof.S: Likewise. * sysdeps/libm-i387/s_remquol.S: Likewise. * sysdeps/libm-i387/e_gamma_r.c: New file. Implementation of gamma function according to ISO C. * sysdeps/libm-i387/e_gammaf_r.c: New file. * sysdeps/libm-i387/e_gammal_r.c: New file. * sysdeps/libm-i387/e_lgamma_r.c: Don't let optimize compile the generation of exceptions away. * sysdeps/libm-i387/e_lgammaf_r.c: Likewise. * sysdeps/libm-i387/k_standard.c: Correct return value for infinity points of gamma function when not SVID mode. * sysdeps/libm-i387/s_rinttoll.c: Renamed to... * sysdeps/libm-i387/s_llrint.c: ...this. * sysdeps/libm-i387/s_rinttol.c: Renamed to... * sysdeps/libm-i387/s_lrint.c: ...this. * sysdeps/libm-i387/s_roundtoll.c: Renamed to... * sysdeps/libm-i387/s_llround.c: ...this. * sysdeps/libm-i387/s_roundtol.c: Renamed to... * sysdeps/libm-i387/s_lround.c: ..this. * sysdeps/libm-i387/s_scalbn.c: Change second parameter according to ISO C. * sysdeps/libm-i387/s_scalbnf.c: Likewise. * sysdeps/libm-i387/s_scalbnl.c: Likewise. * sysdeps/libm-i387/w_gamma.c: Call __ieee754_gamma_r if library mode is not _SVID_. * sysdeps/libm-i387/w_gammaf.c: Likewise. * sysdeps/libm-i387/w_gammal.c: Likewise. * sysdeps/m68k/fpu/__math.h: Rename __rinttol to __lrint and rinttol to lrint. * sysdeps/m68k/fpu/s_rinttol.c: Renamed to... * sysdeps/m68k/fpu/s_lrint.c: ...this. * sysdeps/m68k/fpu/s_rinttoll.c: Renamed to... * sysdeps/m68k/fpu/s_llrint.c: ...this. * md5-crypt/Makefile: Link md5test program with md5.o. * stdio-common/temptest.c: Don't use __stdio_gen_tempname which is not exported by the libc.so. * stdio-common/vfscanf.c: Correct scanning of strings after last change. * sysdeps/unix/sysv/linux/i386/sysdep.S: Use .comm to define errno. 1997-06-19 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * time/tzfile.c (__tzfile_read): Store getc () return in int. 1997-06-13 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (argp_version_parser): Include `(PROGRAM ERROR)' in the no-version error text to indicate that something's fucked. [!_] (N_): New macro. (argp_default_options, argp_version_options): Wrap doc strings in N_(). 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (parser_parse_opt): Detect and report unhandled options here. (parser_parse_arg): Handle ARGP_KEY_ARGS here. Adjust NEXT pointer back if we fail to parse anything. (parser_parse_next): Simplify arg code. Leave state NEXT frobbing to parser_parse_arg. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp.h (ARGP_KEY_ARGS, ARGP_KEY_FINI): New macros. * argp/argp-parse.c (parser_finalize): Do another pass over the parsers with ARGP_KEY_FINI. 1997-06-18 Miles Bader <miles@gnu.ai.mit.edu> * string/Makefile (routines): Add argz-replace. 1997-06-16 00:16 Miles Bader <miles@gnu.ai.mit.edu> * manual/string.texi (Argz Functions): Document argz_replace. 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * string/argz.h (__argz_replace, argz_replace): New declarations. * string/argz-replace.c: New file. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * manual/argp.texi (Argp Special Keys): Document ARGP_KEY_ARGS. 1997-06-16 23:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * Makeconfig (libc-map): Remove definition. * Makerules (libc-map): Define it here, using the full name. (load-map-file): Remove case for empty $(..). ($(common-objpfx)libc.so): Revert last change. 1997-06-17 22:18 Mark Kettenis <kettenis@phys.uva.nl> * login/programs/utmpd.c (main): Improve signal handling. * login/programs/request.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/utmpd.h (setutent_request, updwtmp_request): Get rid of fixed length file field. * login/utmp_daemon.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/request.c (do_pututline): Don't fail if connection->position is -1 on entry. 1997-06-15 16:32 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (updwtmp_file): Use the same method for appending an entry as in pututline_file. 1997-06-11 18:59 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (getutent_r_file): Use read lock instead of write lock. (getutline_r_file, internal_getut_r): Lock utmp file. (updwtmp_file): Use fcntl to lock file instead of flock. 1997-06-18 00:11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * stdio-common/vfscanf.c (inchar, ungetc): Don't count EOF as character read in/put back. * stdio-common/tstscanf.c: Add test case for this. 1997-06-17 22:17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * libc.map: Add more symbols. 1997-06-18 12:01 Ulrich Drepper <drepper@cygnus.com> * manual/Makefile (install): Make sure `dir' file exists if we use install-info. 1997-06-17 19:32 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * manual/Makefile (info): Depend on dir-add.info. 1997-06-17 17:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/ldd.bash.in: Fix spacing in message. 1997-06-17 14:28 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/do-rel.h (elf_dynamic_do_rel): Always use version information if available. 1997-06-17 11:34 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sunrpc/Makefile ($(rpcsvc:%.x=$(objpfx)rpcsvc/%.h)): Make command non-empty to force make to recheck modification time. ($(rpcsvc:%.x=$(objpfx)x%.c)): Likewise. 1997-06-17 00:26 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/stub/e_acoshl.c: Set errno to ENOSYS. * sysdeps/stub/e_acosl.c: Likewise. * sysdeps/stub/e_asinl.c: Likewise. * sysdeps/stub/e_atan2l.c: Likewise. * sysdeps/stub/e_expl.c: Likewise. * sysdeps/stub/e_fmodl.c: Likewise. * sysdeps/stub/e_j0l.c: Likewise. * sysdeps/stub/e_j1l.c: Likewise. * sysdeps/stub/e_jnl.c: Likewise. * sysdeps/stub/e_lgammal_r.c: Likewise. * sysdeps/stub/e_log10l.c: Likewise. * sysdeps/stub/e_logl.c: Likewise. * sysdeps/stub/e_powl.c: Likewise. * sysdeps/stub/e_rem_pio2l.c: Likewise. * sysdeps/stub/e_sqrtl.c: Likewise. * sysdeps/stub/k_cosl.c: Likewise. * sysdeps/stub/k_rem_pio2l.c: Likewise. * sysdeps/stub/k_sinl.c: Likewise. * sysdeps/stub/k_tanl.c: Likewise. * sysdeps/stub/s_atanl.c: Likewise. * sysdeps/stub/s_erfl.c: Likewise. * sysdeps/stub/s_exp2.c: Likewise. * sysdeps/stub/s_exp2f.c: Likewise. * sysdeps/stub/s_exp2l.c: Likewise. * sysdeps/stub/s_expm1l.c: Likewise. * sysdeps/stub/s_log1pl.c: Likewise. * sysdeps/stub/s_log2l.c: Likewise. 1997-06-18 11:46 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/w_gamma.c: If _LIB_VERSION is _SVID_ compute result as before last change. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. 1997-06-16 23:37 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/libm-ieee754/s_remquo.c: Fix off-by-one when computing quotient. * sysdeps/libm-ieee754/s_remquof.c: Likewise. * sysdeps/libm-ieee754/s_remquol.c: Likewise. * sysdeps/m68k/fpu/s_remquo.c: Remove FIXME and special case for quotient. * sysdeps/libm-ieee754/w_gamma.c: Add missing call to exp function. Don't use global signgam. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. * math/Makefile (libm-calls): Remove w_gamma_r. * sysdeps/libm-ieee754/w_gamma_r.c: Remove file. * sysdeps/libm-ieee754/w_gammaf_r.c: Remove file. * sysdeps/libm-ieee754/w_gammal_r.c: Remove file. * math/libm-test.c (atanh_test): Declare x only if needed. (signbit_test): Fix typo. (gamma_test): Check whether function is implemented. Add epsilons. (lgamma_test): Likewise. (fmod_test): Add epsilons. (exp2_test): Use right function for existence test. 1997-06-07 09:20 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/powerpc/Dist: Add fenv_const.c. * sysdeps/unix/sysv/linux/Dist: Add net/if_slip.h. * sysdeps/unix/sysv/linux/powerpc/Dist: Add init-first.h and syscall.h. * sysdeps/unix/sysv/linux/sparc/Dist: Add init-first.h. * string/Makefile (distribute): Add tst-svc.expect. * nis/Makefile (distribute): Add nis_intern.h and Banner. * elf/Makefile (distribute): Add dl-hash.h. * Rules (subdir_echo-distinfo): Add headers from $(distribute). * login/Makefile (others): Add utmpdump. * sysdeps/unix/sysv/linux/Makefile (sysdep_headers): Add net/if_slip.h. * manual/Makefile (dir-add.texi): Also look in indirectly included files. 1997-06-16 23:15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/configure.in: Remove commands to generate stdio_lim.h. * sysdeps/unix/sysv/linux/mk-stdiolim.c: Remove. * sysdeps/unix/sysv/linux/Makefile: Add rules to generate stdio_lim.h here. (common-generated): Add generated files. (inhibit-stdio_lim): Define. * sysdeps/posix/Makefile [$(inhibit-stdio_lim)=yes]: Disable rules to generate stdio_lim.h. * sysdeps/unix/sysv/linux/Makefile: Suppress inclusion of dependecy files if no_deps is set. ($(objpfx)syscall-%.d): Add header file as target to dependency generation. 1997-06-14 19:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/arm/Dist: New file. 1997-06-14 17:59 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * extra-lib.mk (others): Depend on versioned shared library, not the unversioned one. * Makerules (build-shlib): Don't make the version link here. ($(common-objpfx)libc.so$(libc.so-version)): New rule for libc version link. 1997-06-16 03:07 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/k_standard.c: Undo change of Tue Aug 6 01:13:56 1996. * argp/argp-help.c (argp_args_usage): Supply correct argp to filter_doc. * argp/argp-help.c (hol_add_cluster): Initialize CL->depth. * argp/argp-help.c (_help): Supply STATE to argp_args_usage. * argp/argp.h (ARGP_KEY_HELP_ARGS_DOC): New macro. * argp/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp.h (OPTION_NO_USAGE): New macro. * argp/argp-help.c (usage_long_opt, usage_argful_short_opt, * argp/argp-fmtstream.c (__argp_fmtstream_update): Account for case * argp/argp-help.c <stddef.h>: New include. * argp/argp.h (argp_state_help, __argp_state_help, argp_usage, * argp/argp.h (argp_program_bug_address): Make const. * argp/argp-parse.c (argp_default_parser): Set STATE->name for OPT_PROGNAME. * argp/argp-help.c (__argp_error, __argp_failure, __argp_state_help): * argp/argp-parse.c (parser_init): Set PARSER->state.flags.
1997-06-19 21:11:22 +02:00
#include <math.h>
Move math_narrow_eval to separate math-narrow-eval.h. This patch continues cleaning up the math_private.h header, which contains lots of different definitions many of which are only needed by a limited subset of files using that header (and some of which are overridden by architectures that only want to override selected parts of the header), by moving the math_narrow_eval macro out to a separate math-narrow-eval.h header, only included by those files that need it. That header is placed in include/ (since it's used in stdlib/, not just files built in math/, but no sysdeps variants are needed at present). Tested for x86_64, and with build-many-glibcs.py. (Installed stripped shared libraries change because of line numbers in assertions in strtod_l.c.) * include/math-narrow-eval.h: New file. Contents moved from .... * sysdeps/generic/math_private.h: ... here. (math_narrow_eval): Remove macro. Moved to math-narrow-eval.h. [FLT_EVAL_METHOD != 0] (excess_precision): Likewise. * math/s_fdim_template.c: Include <math-narrow-eval.h>. * stdlib/strtod_l.c: Likewise. * sysdeps/i386/fpu/s_f32xaddf64.c: Likewise. * sysdeps/i386/fpu/s_f32xsubf64.c: Likewise. * sysdeps/i386/fpu/s_fdim.c: Likewise. * sysdeps/ieee754/dbl-64/e_cosh.c: Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c: Likewise. * sysdeps/ieee754/dbl-64/e_j1.c: Likewise. * sysdeps/ieee754/dbl-64/e_jn.c: Likewise. * sysdeps/ieee754/dbl-64/e_lgamma_r.c: Likewise. * sysdeps/ieee754/dbl-64/e_sinh.c: Likewise. * sysdeps/ieee754/dbl-64/gamma_productf.c: Likewise. * sysdeps/ieee754/dbl-64/k_rem_pio2.c: Likewise. * sysdeps/ieee754/dbl-64/lgamma_neg.c: Likewise. * sysdeps/ieee754/dbl-64/s_erf.c: Likewise. * sysdeps/ieee754/dbl-64/s_llrint.c: Likewise. * sysdeps/ieee754/dbl-64/s_lrint.c: Likewise. * sysdeps/ieee754/flt-32/e_coshf.c: Likewise. * sysdeps/ieee754/flt-32/e_exp2f.c: Likewise. * sysdeps/ieee754/flt-32/e_expf.c: Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c: Likewise. * sysdeps/ieee754/flt-32/e_j1f.c: Likewise. * sysdeps/ieee754/flt-32/e_jnf.c: Likewise. * sysdeps/ieee754/flt-32/e_lgammaf_r.c: Likewise. * sysdeps/ieee754/flt-32/e_sinhf.c: Likewise. * sysdeps/ieee754/flt-32/k_rem_pio2f.c: Likewise. * sysdeps/ieee754/flt-32/lgamma_negf.c: Likewise. * sysdeps/ieee754/flt-32/s_erff.c: Likewise. * sysdeps/ieee754/flt-32/s_llrintf.c: Likewise. * sysdeps/ieee754/flt-32/s_lrintf.c: Likewise. * sysdeps/ieee754/ldbl-96/gamma_product.c: Likewise.
2018-05-09 02:15:10 +02:00
#include <math-narrow-eval.h>
Update. 1997-06-19 19:38 Ulrich Drepper <drepper@cygnus.com> * features.h: Define __STDC_IEC_559__ and _STDC_IEC_559_COMPLEX__. * elf/dl-minimal.c (__dcgettext): Remove assertion. * inet/rcmd.c: Correct a few typos. Reported by Eric Troan. * manual/Makefile (distribute): Add dir. * manual/dir: New file. * math/Makefile (libm-support): Rename s_rinttol, s_rinttoll, s_roundtol, and s_roundtoll to s_lrint, s_llrint, s_lround, and s_llround respectively. (libm-calls): Add e_gamma_r. * math/libm-test.c (check_int_exc): New function. (signbit_test): Remove test for sign of NaN. (gamma_test): Clear exception after test of existence. Correct tests and and epsilons. (lgamma_test): Likewise. (ilogb_test): Correct all tests. (scalb_test): Rewrite. (rinttol_test): Rename to lrint_test and correct tests. (rinttoll_test): Likewise. (roundtol_test): Likewise. (roundtoll_test): Likewise. (main): Call lrint/lround functions instead of rinttol/roundtol. * math/math.h: Change prototypes for rinttol/roundtol. * math/mathcalls.h: Rearrange prototypes according to ISO C9X draft. * sysdeps/generic/mathbits.h: Define FP_ILOGB0 and FP_ILOGBNAN. * sysdeps/i386/mathbits.h: Likewise. * sysdeps/libm-i387/e_scalb.S: Handle special cases correctly. * sysdeps/libm-i387/e_scalbf.S: Likewise. * sysdeps/libm-i387/e_scalbl.S: Likewise. * sysdeps/libm-i387/s_asinh.S: Handle -inf correctly. * sysdeps/libm-i387/s_asinhf.S: Likewise. * sysdeps/libm-i387/s_asinhl.S: Likewise. * sysdeps/libm-i387/s_ilogb.S: Optimize. * sysdeps/libm-i387/s_ilogbf.S: Likewise. * sysdeps/libm-i387/s_ilogbl.S: Likewise. * sysdeps/libm-i387/s_rinttol.S: Rename to... * sysdeps/libm-i387/s_lrint.S: ...this. * sysdeps/libm-i387/s_rinttoll.S: Rename to... * sysdeps/libm-i387/s_llrint.S: ...this. * sysdeps/libm-i387/s_remquo.S: Correctly set sign of remainder. * sysdeps/libm-i387/s_remquof.S: Likewise. * sysdeps/libm-i387/s_remquol.S: Likewise. * sysdeps/libm-i387/e_gamma_r.c: New file. Implementation of gamma function according to ISO C. * sysdeps/libm-i387/e_gammaf_r.c: New file. * sysdeps/libm-i387/e_gammal_r.c: New file. * sysdeps/libm-i387/e_lgamma_r.c: Don't let optimize compile the generation of exceptions away. * sysdeps/libm-i387/e_lgammaf_r.c: Likewise. * sysdeps/libm-i387/k_standard.c: Correct return value for infinity points of gamma function when not SVID mode. * sysdeps/libm-i387/s_rinttoll.c: Renamed to... * sysdeps/libm-i387/s_llrint.c: ...this. * sysdeps/libm-i387/s_rinttol.c: Renamed to... * sysdeps/libm-i387/s_lrint.c: ...this. * sysdeps/libm-i387/s_roundtoll.c: Renamed to... * sysdeps/libm-i387/s_llround.c: ...this. * sysdeps/libm-i387/s_roundtol.c: Renamed to... * sysdeps/libm-i387/s_lround.c: ..this. * sysdeps/libm-i387/s_scalbn.c: Change second parameter according to ISO C. * sysdeps/libm-i387/s_scalbnf.c: Likewise. * sysdeps/libm-i387/s_scalbnl.c: Likewise. * sysdeps/libm-i387/w_gamma.c: Call __ieee754_gamma_r if library mode is not _SVID_. * sysdeps/libm-i387/w_gammaf.c: Likewise. * sysdeps/libm-i387/w_gammal.c: Likewise. * sysdeps/m68k/fpu/__math.h: Rename __rinttol to __lrint and rinttol to lrint. * sysdeps/m68k/fpu/s_rinttol.c: Renamed to... * sysdeps/m68k/fpu/s_lrint.c: ...this. * sysdeps/m68k/fpu/s_rinttoll.c: Renamed to... * sysdeps/m68k/fpu/s_llrint.c: ...this. * md5-crypt/Makefile: Link md5test program with md5.o. * stdio-common/temptest.c: Don't use __stdio_gen_tempname which is not exported by the libc.so. * stdio-common/vfscanf.c: Correct scanning of strings after last change. * sysdeps/unix/sysv/linux/i386/sysdep.S: Use .comm to define errno. 1997-06-19 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * time/tzfile.c (__tzfile_read): Store getc () return in int. 1997-06-13 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (argp_version_parser): Include `(PROGRAM ERROR)' in the no-version error text to indicate that something's fucked. [!_] (N_): New macro. (argp_default_options, argp_version_options): Wrap doc strings in N_(). 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (parser_parse_opt): Detect and report unhandled options here. (parser_parse_arg): Handle ARGP_KEY_ARGS here. Adjust NEXT pointer back if we fail to parse anything. (parser_parse_next): Simplify arg code. Leave state NEXT frobbing to parser_parse_arg. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp.h (ARGP_KEY_ARGS, ARGP_KEY_FINI): New macros. * argp/argp-parse.c (parser_finalize): Do another pass over the parsers with ARGP_KEY_FINI. 1997-06-18 Miles Bader <miles@gnu.ai.mit.edu> * string/Makefile (routines): Add argz-replace. 1997-06-16 00:16 Miles Bader <miles@gnu.ai.mit.edu> * manual/string.texi (Argz Functions): Document argz_replace. 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * string/argz.h (__argz_replace, argz_replace): New declarations. * string/argz-replace.c: New file. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * manual/argp.texi (Argp Special Keys): Document ARGP_KEY_ARGS. 1997-06-16 23:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * Makeconfig (libc-map): Remove definition. * Makerules (libc-map): Define it here, using the full name. (load-map-file): Remove case for empty $(..). ($(common-objpfx)libc.so): Revert last change. 1997-06-17 22:18 Mark Kettenis <kettenis@phys.uva.nl> * login/programs/utmpd.c (main): Improve signal handling. * login/programs/request.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/utmpd.h (setutent_request, updwtmp_request): Get rid of fixed length file field. * login/utmp_daemon.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/request.c (do_pututline): Don't fail if connection->position is -1 on entry. 1997-06-15 16:32 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (updwtmp_file): Use the same method for appending an entry as in pututline_file. 1997-06-11 18:59 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (getutent_r_file): Use read lock instead of write lock. (getutline_r_file, internal_getut_r): Lock utmp file. (updwtmp_file): Use fcntl to lock file instead of flock. 1997-06-18 00:11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * stdio-common/vfscanf.c (inchar, ungetc): Don't count EOF as character read in/put back. * stdio-common/tstscanf.c: Add test case for this. 1997-06-17 22:17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * libc.map: Add more symbols. 1997-06-18 12:01 Ulrich Drepper <drepper@cygnus.com> * manual/Makefile (install): Make sure `dir' file exists if we use install-info. 1997-06-17 19:32 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * manual/Makefile (info): Depend on dir-add.info. 1997-06-17 17:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/ldd.bash.in: Fix spacing in message. 1997-06-17 14:28 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/do-rel.h (elf_dynamic_do_rel): Always use version information if available. 1997-06-17 11:34 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sunrpc/Makefile ($(rpcsvc:%.x=$(objpfx)rpcsvc/%.h)): Make command non-empty to force make to recheck modification time. ($(rpcsvc:%.x=$(objpfx)x%.c)): Likewise. 1997-06-17 00:26 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/stub/e_acoshl.c: Set errno to ENOSYS. * sysdeps/stub/e_acosl.c: Likewise. * sysdeps/stub/e_asinl.c: Likewise. * sysdeps/stub/e_atan2l.c: Likewise. * sysdeps/stub/e_expl.c: Likewise. * sysdeps/stub/e_fmodl.c: Likewise. * sysdeps/stub/e_j0l.c: Likewise. * sysdeps/stub/e_j1l.c: Likewise. * sysdeps/stub/e_jnl.c: Likewise. * sysdeps/stub/e_lgammal_r.c: Likewise. * sysdeps/stub/e_log10l.c: Likewise. * sysdeps/stub/e_logl.c: Likewise. * sysdeps/stub/e_powl.c: Likewise. * sysdeps/stub/e_rem_pio2l.c: Likewise. * sysdeps/stub/e_sqrtl.c: Likewise. * sysdeps/stub/k_cosl.c: Likewise. * sysdeps/stub/k_rem_pio2l.c: Likewise. * sysdeps/stub/k_sinl.c: Likewise. * sysdeps/stub/k_tanl.c: Likewise. * sysdeps/stub/s_atanl.c: Likewise. * sysdeps/stub/s_erfl.c: Likewise. * sysdeps/stub/s_exp2.c: Likewise. * sysdeps/stub/s_exp2f.c: Likewise. * sysdeps/stub/s_exp2l.c: Likewise. * sysdeps/stub/s_expm1l.c: Likewise. * sysdeps/stub/s_log1pl.c: Likewise. * sysdeps/stub/s_log2l.c: Likewise. 1997-06-18 11:46 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/w_gamma.c: If _LIB_VERSION is _SVID_ compute result as before last change. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. 1997-06-16 23:37 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/libm-ieee754/s_remquo.c: Fix off-by-one when computing quotient. * sysdeps/libm-ieee754/s_remquof.c: Likewise. * sysdeps/libm-ieee754/s_remquol.c: Likewise. * sysdeps/m68k/fpu/s_remquo.c: Remove FIXME and special case for quotient. * sysdeps/libm-ieee754/w_gamma.c: Add missing call to exp function. Don't use global signgam. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. * math/Makefile (libm-calls): Remove w_gamma_r. * sysdeps/libm-ieee754/w_gamma_r.c: Remove file. * sysdeps/libm-ieee754/w_gammaf_r.c: Remove file. * sysdeps/libm-ieee754/w_gammal_r.c: Remove file. * math/libm-test.c (atanh_test): Declare x only if needed. (signbit_test): Fix typo. (gamma_test): Check whether function is implemented. Add epsilons. (lgamma_test): Likewise. (fmod_test): Add epsilons. (exp2_test): Use right function for existence test. 1997-06-07 09:20 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/powerpc/Dist: Add fenv_const.c. * sysdeps/unix/sysv/linux/Dist: Add net/if_slip.h. * sysdeps/unix/sysv/linux/powerpc/Dist: Add init-first.h and syscall.h. * sysdeps/unix/sysv/linux/sparc/Dist: Add init-first.h. * string/Makefile (distribute): Add tst-svc.expect. * nis/Makefile (distribute): Add nis_intern.h and Banner. * elf/Makefile (distribute): Add dl-hash.h. * Rules (subdir_echo-distinfo): Add headers from $(distribute). * login/Makefile (others): Add utmpdump. * sysdeps/unix/sysv/linux/Makefile (sysdep_headers): Add net/if_slip.h. * manual/Makefile (dir-add.texi): Also look in indirectly included files. 1997-06-16 23:15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/configure.in: Remove commands to generate stdio_lim.h. * sysdeps/unix/sysv/linux/mk-stdiolim.c: Remove. * sysdeps/unix/sysv/linux/Makefile: Add rules to generate stdio_lim.h here. (common-generated): Add generated files. (inhibit-stdio_lim): Define. * sysdeps/posix/Makefile [$(inhibit-stdio_lim)=yes]: Disable rules to generate stdio_lim.h. * sysdeps/unix/sysv/linux/Makefile: Suppress inclusion of dependecy files if no_deps is set. ($(objpfx)syscall-%.d): Add header file as target to dependency generation. 1997-06-14 19:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/arm/Dist: New file. 1997-06-14 17:59 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * extra-lib.mk (others): Depend on versioned shared library, not the unversioned one. * Makerules (build-shlib): Don't make the version link here. ($(common-objpfx)libc.so$(libc.so-version)): New rule for libc version link. 1997-06-16 03:07 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/k_standard.c: Undo change of Tue Aug 6 01:13:56 1996. * argp/argp-help.c (argp_args_usage): Supply correct argp to filter_doc. * argp/argp-help.c (hol_add_cluster): Initialize CL->depth. * argp/argp-help.c (_help): Supply STATE to argp_args_usage. * argp/argp.h (ARGP_KEY_HELP_ARGS_DOC): New macro. * argp/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp.h (OPTION_NO_USAGE): New macro. * argp/argp-help.c (usage_long_opt, usage_argful_short_opt, * argp/argp-fmtstream.c (__argp_fmtstream_update): Account for case * argp/argp-help.c <stddef.h>: New include. * argp/argp.h (argp_state_help, __argp_state_help, argp_usage, * argp/argp.h (argp_program_bug_address): Make const. * argp/argp-parse.c (argp_default_parser): Set STATE->name for OPT_PROGNAME. * argp/argp-help.c (__argp_error, __argp_failure, __argp_state_help): * argp/argp-parse.c (parser_init): Set PARSER->state.flags.
1997-06-19 21:11:22 +02:00
#include <math_private.h>
Do not include fenv_private.h in math_private.h. Continuing the clean-up related to the catch-all math_private.h header, this patch stops math_private.h from including fenv_private.h. Instead, fenv_private.h is included directly from those users of math_private.h that also used interfaces from fenv_private.h. No attempt is made to remove unused includes of math_private.h, but that is a natural followup. (However, since math_private.h sometimes defines optimized versions of math.h interfaces or __* variants thereof, as well as defining its own interfaces, I think it might make sense to get all those optimized versions included from include/math.h, not requiring a separate header at all, before eliminating unused math_private.h includes - that avoids a file quietly becoming less-optimized if someone adds a call to one of those interfaces without restoring a math_private.h include to that file.) There is still a pitfall that if code uses plain fe* and __fe* interfaces, but only includes fenv.h and not fenv_private.h or (before this patch) math_private.h, it will compile on platforms with exceptions and rounding modes but not get the optimized versions (and possibly not compile) on platforms without exception and rounding mode support, so making it easy to break the build for such platforms accidentally. I think it would be most natural to move the inlines / macros for fe* and __fe* in the case of no exceptions and rounding modes into include/fenv.h, so that all code including fenv.h with _ISOMAC not defined automatically gets them. Then fenv_private.h would be purely the header for the libc_fe*, SET_RESTORE_ROUND etc. internal interfaces and the risk of breaking the build on other platforms than the one you tested on because of a missing fenv_private.h include would be much reduced (and there would be some unused fenv_private.h includes to remove along with unused math_private.h includes). Tested for x86_64 and x86, and tested with build-many-glibcs.py that installed stripped shared libraries are unchanged by this patch. * sysdeps/generic/math_private.h: Do not include <fenv_private.h>. * math/fromfp.h: Include <fenv_private.h>. * math/math-narrow.h: Likewise. * math/s_cexp_template.c: Likewise. * math/s_csin_template.c: Likewise. * math/s_csinh_template.c: Likewise. * math/s_ctan_template.c: Likewise. * math/s_ctanh_template.c: Likewise. * math/s_iseqsig_template.c: Likewise. * math/w_acos_compat.c: Likewise. * math/w_acosf_compat.c: Likewise. * math/w_acosl_compat.c: Likewise. * math/w_asin_compat.c: Likewise. * math/w_asinf_compat.c: Likewise. * math/w_asinl_compat.c: Likewise. * math/w_ilogb_template.c: Likewise. * math/w_j0_compat.c: Likewise. * math/w_j0f_compat.c: Likewise. * math/w_j0l_compat.c: Likewise. * math/w_j1_compat.c: Likewise. * math/w_j1f_compat.c: Likewise. * math/w_j1l_compat.c: Likewise. * math/w_jn_compat.c: Likewise. * math/w_jnf_compat.c: Likewise. * math/w_llogb_template.c: Likewise. * math/w_log10_compat.c: Likewise. * math/w_log10f_compat.c: Likewise. * math/w_log10l_compat.c: Likewise. * math/w_log2_compat.c: Likewise. * math/w_log2f_compat.c: Likewise. * math/w_log2l_compat.c: Likewise. * math/w_log_compat.c: Likewise. * math/w_logf_compat.c: Likewise. * math/w_logl_compat.c: Likewise. * sysdeps/aarch64/fpu/feholdexcpt.c: Likewise. * sysdeps/aarch64/fpu/fesetround.c: Likewise. * sysdeps/aarch64/fpu/fgetexcptflg.c: Likewise. * sysdeps/aarch64/fpu/ftestexcept.c: Likewise. * sysdeps/ieee754/dbl-64/e_atan2.c: Likewise. * sysdeps/ieee754/dbl-64/e_exp.c: Likewise. * sysdeps/ieee754/dbl-64/e_exp2.c: Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c: Likewise. * sysdeps/ieee754/dbl-64/e_jn.c: Likewise. * sysdeps/ieee754/dbl-64/e_pow.c: Likewise. * sysdeps/ieee754/dbl-64/e_remainder.c: Likewise. * sysdeps/ieee754/dbl-64/e_sqrt.c: Likewise. * sysdeps/ieee754/dbl-64/gamma_product.c: Likewise. * sysdeps/ieee754/dbl-64/lgamma_neg.c: Likewise. * sysdeps/ieee754/dbl-64/s_atan.c: Likewise. * sysdeps/ieee754/dbl-64/s_fma.c: Likewise. * sysdeps/ieee754/dbl-64/s_fmaf.c: Likewise. * sysdeps/ieee754/dbl-64/s_llrint.c: Likewise. * sysdeps/ieee754/dbl-64/s_llround.c: Likewise. * sysdeps/ieee754/dbl-64/s_lrint.c: Likewise. * sysdeps/ieee754/dbl-64/s_lround.c: Likewise. * sysdeps/ieee754/dbl-64/s_nearbyint.c: Likewise. * sysdeps/ieee754/dbl-64/s_sin.c: Likewise. * sysdeps/ieee754/dbl-64/s_sincos.c: Likewise. * sysdeps/ieee754/dbl-64/s_tan.c: Likewise. * sysdeps/ieee754/dbl-64/wordsize-64/s_lround.c: Likewise. * sysdeps/ieee754/dbl-64/wordsize-64/s_nearbyint.c: Likewise. * sysdeps/ieee754/dbl-64/x2y2m1.c: Likewise. * sysdeps/ieee754/float128/float128_private.h: Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c: Likewise. * sysdeps/ieee754/flt-32/e_j1f.c: Likewise. * sysdeps/ieee754/flt-32/e_jnf.c: Likewise. * sysdeps/ieee754/flt-32/lgamma_negf.c: Likewise. * sysdeps/ieee754/flt-32/s_llrintf.c: Likewise. * sysdeps/ieee754/flt-32/s_llroundf.c: Likewise. * sysdeps/ieee754/flt-32/s_lrintf.c: Likewise. * sysdeps/ieee754/flt-32/s_lroundf.c: Likewise. * sysdeps/ieee754/flt-32/s_nearbyintf.c: Likewise. * sysdeps/ieee754/k_standardl.c: Likewise. * sysdeps/ieee754/ldbl-128/e_expl.c: Likewise. * sysdeps/ieee754/ldbl-128/e_gammal_r.c: Likewise. * sysdeps/ieee754/ldbl-128/e_j1l.c: Likewise. * sysdeps/ieee754/ldbl-128/e_jnl.c: Likewise. * sysdeps/ieee754/ldbl-128/gamma_productl.c: Likewise. * sysdeps/ieee754/ldbl-128/lgamma_negl.c: Likewise. * sysdeps/ieee754/ldbl-128/s_fmal.c: Likewise. * sysdeps/ieee754/ldbl-128/s_llrintl.c: Likewise. * sysdeps/ieee754/ldbl-128/s_llroundl.c: Likewise. * sysdeps/ieee754/ldbl-128/s_lrintl.c: Likewise. * sysdeps/ieee754/ldbl-128/s_lroundl.c: Likewise. * sysdeps/ieee754/ldbl-128/s_nearbyintl.c: Likewise. * sysdeps/ieee754/ldbl-128/x2y2m1l.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_expl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_j1l.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_jnl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/lgamma_negl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_fmal.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_llrintl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_llroundl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_lrintl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_lroundl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_rintl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/x2y2m1l.c: Likewise. * sysdeps/ieee754/ldbl-96/e_gammal_r.c: Likewise. * sysdeps/ieee754/ldbl-96/e_jnl.c: Likewise. * sysdeps/ieee754/ldbl-96/gamma_productl.c: Likewise. * sysdeps/ieee754/ldbl-96/lgamma_negl.c: Likewise. * sysdeps/ieee754/ldbl-96/s_fma.c: Likewise. * sysdeps/ieee754/ldbl-96/s_fmal.c: Likewise. * sysdeps/ieee754/ldbl-96/s_llrintl.c: Likewise. * sysdeps/ieee754/ldbl-96/s_llroundl.c: Likewise. * sysdeps/ieee754/ldbl-96/s_lrintl.c: Likewise. * sysdeps/ieee754/ldbl-96/s_lroundl.c: Likewise. * sysdeps/ieee754/ldbl-96/x2y2m1l.c: Likewise. * sysdeps/powerpc/fpu/e_sqrt.c: Likewise. * sysdeps/powerpc/fpu/e_sqrtf.c: Likewise. * sysdeps/riscv/rv64/rvd/s_ceil.c: Likewise. * sysdeps/riscv/rv64/rvd/s_floor.c: Likewise. * sysdeps/riscv/rv64/rvd/s_nearbyint.c: Likewise. * sysdeps/riscv/rv64/rvd/s_round.c: Likewise. * sysdeps/riscv/rv64/rvd/s_roundeven.c: Likewise. * sysdeps/riscv/rv64/rvd/s_trunc.c: Likewise. * sysdeps/riscv/rvd/s_finite.c: Likewise. * sysdeps/riscv/rvd/s_fmax.c: Likewise. * sysdeps/riscv/rvd/s_fmin.c: Likewise. * sysdeps/riscv/rvd/s_fpclassify.c: Likewise. * sysdeps/riscv/rvd/s_isinf.c: Likewise. * sysdeps/riscv/rvd/s_isnan.c: Likewise. * sysdeps/riscv/rvd/s_issignaling.c: Likewise. * sysdeps/riscv/rvf/fegetround.c: Likewise. * sysdeps/riscv/rvf/feholdexcpt.c: Likewise. * sysdeps/riscv/rvf/fesetenv.c: Likewise. * sysdeps/riscv/rvf/fesetround.c: Likewise. * sysdeps/riscv/rvf/feupdateenv.c: Likewise. * sysdeps/riscv/rvf/fgetexcptflg.c: Likewise. * sysdeps/riscv/rvf/ftestexcept.c: Likewise. * sysdeps/riscv/rvf/s_ceilf.c: Likewise. * sysdeps/riscv/rvf/s_finitef.c: Likewise. * sysdeps/riscv/rvf/s_floorf.c: Likewise. * sysdeps/riscv/rvf/s_fmaxf.c: Likewise. * sysdeps/riscv/rvf/s_fminf.c: Likewise. * sysdeps/riscv/rvf/s_fpclassifyf.c: Likewise. * sysdeps/riscv/rvf/s_isinff.c: Likewise. * sysdeps/riscv/rvf/s_isnanf.c: Likewise. * sysdeps/riscv/rvf/s_issignalingf.c: Likewise. * sysdeps/riscv/rvf/s_nearbyintf.c: Likewise. * sysdeps/riscv/rvf/s_roundevenf.c: Likewise. * sysdeps/riscv/rvf/s_roundf.c: Likewise. * sysdeps/riscv/rvf/s_truncf.c: Likewise.
2018-09-03 23:09:04 +02:00
#include <fenv_private.h>
Move math_check_force_underflow macros to separate math-underflow.h. This patch continues cleaning up math_private.h by moving the math_check_force_underflow set of macros to a separate header math-underflow.h. This header is included by the files that need it rather than from math_private.h. Moving these macros to a separate file removes the math_private.h uses of macros from float.h, so the inclusion of float.h in math_private.h is also removed; files that were depending on that inclusion are fixed to include float.h directly. The inclusion of math-barriers.h from math_private.h will be removed in a separate patch. Tested for x86_64 and x86. Also tested with build-many-glibcs.py that installed stripped shared libraries are unchanged by this patch. * math/math-underflow.h: New file. * sysdeps/generic/math_private.h: Do not include <float.h>. (fabs_tg): Remove macro. Moved to math-underflow.h. (min_of_type_f): Likewise. (min_of_type_): Likewise. (min_of_type_l): Likewise. (min_of_type_f128): Likewise. (min_of_type): Likewise. (math_check_force_underflow): Likewise. (math_check_force_underflow_nonneg): Likewise. (math_check_force_underflow_complex): Likewise. * math/e_exp2_template.c: Include <math-underflow.h>. * math/k_casinh_template.c: Likewise. * math/s_catan_template.c: Likewise. * math/s_catanh_template.c: Likewise. * math/s_ccosh_template.c: Likewise. * math/s_cexp_template.c: Likewise. * math/s_clog10_template.c: Likewise. * math/s_clog_template.c: Likewise. * math/s_csin_template.c: Likewise. * math/s_csinh_template.c: Likewise. * math/s_csqrt_template.c: Likewise. * math/s_ctan_template.c: Likewise. * math/s_ctanh_template.c: Likewise. * sysdeps/ieee754/dbl-64/e_asin.c: Likewise. * sysdeps/ieee754/dbl-64/e_atanh.c: Likewise. * sysdeps/ieee754/dbl-64/e_exp2.c: Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c: Likewise. * sysdeps/ieee754/dbl-64/e_hypot.c: Likewise. * sysdeps/ieee754/dbl-64/e_j1.c: Likewise. * sysdeps/ieee754/dbl-64/e_jn.c: Likewise. * sysdeps/ieee754/dbl-64/e_pow.c: Likewise. * sysdeps/ieee754/dbl-64/e_sinh.c: Likewise. * sysdeps/ieee754/dbl-64/s_asinh.c: Likewise. * sysdeps/ieee754/dbl-64/s_atan.c: Likewise. * sysdeps/ieee754/dbl-64/s_erf.c: Likewise. * sysdeps/ieee754/dbl-64/s_expm1.c: Likewise. * sysdeps/ieee754/dbl-64/s_log1p.c: Likewise. * sysdeps/ieee754/dbl-64/s_sin.c: Likewise. * sysdeps/ieee754/dbl-64/s_sincos.c: Likewise. * sysdeps/ieee754/dbl-64/s_tan.c: Likewise. * sysdeps/ieee754/dbl-64/s_tanh.c: Likewise. * sysdeps/ieee754/flt-32/e_asinf.c: Likewise. * sysdeps/ieee754/flt-32/e_atanhf.c: Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c: Likewise. * sysdeps/ieee754/flt-32/e_j1f.c: Likewise. * sysdeps/ieee754/flt-32/e_jnf.c: Likewise. * sysdeps/ieee754/flt-32/e_sinhf.c: Likewise. * sysdeps/ieee754/flt-32/k_sinf.c: Likewise. * sysdeps/ieee754/flt-32/k_tanf.c: Likewise. * sysdeps/ieee754/flt-32/s_asinhf.c: Likewise. * sysdeps/ieee754/flt-32/s_atanf.c: Likewise. * sysdeps/ieee754/flt-32/s_erff.c: Likewise. * sysdeps/ieee754/flt-32/s_expm1f.c: Likewise. * sysdeps/ieee754/flt-32/s_log1pf.c: Likewise. * sysdeps/ieee754/flt-32/s_tanhf.c: Likewise. * sysdeps/ieee754/ldbl-128/e_asinl.c: Likewise. * sysdeps/ieee754/ldbl-128/e_atanhl.c: Likewise. * sysdeps/ieee754/ldbl-128/e_expl.c: Likewise. * sysdeps/ieee754/ldbl-128/e_gammal_r.c: Likewise. * sysdeps/ieee754/ldbl-128/e_hypotl.c: Likewise. * sysdeps/ieee754/ldbl-128/e_j1l.c: Likewise. * sysdeps/ieee754/ldbl-128/e_jnl.c: Likewise. * sysdeps/ieee754/ldbl-128/e_sinhl.c: Likewise. * sysdeps/ieee754/ldbl-128/k_sincosl.c: Likewise. * sysdeps/ieee754/ldbl-128/k_sinl.c: Likewise. * sysdeps/ieee754/ldbl-128/k_tanl.c: Likewise. * sysdeps/ieee754/ldbl-128/s_asinhl.c: Likewise. * sysdeps/ieee754/ldbl-128/s_atanl.c: Likewise. * sysdeps/ieee754/ldbl-128/s_erfl.c: Likewise. * sysdeps/ieee754/ldbl-128/s_expm1l.c: Likewise. * sysdeps/ieee754/ldbl-128/s_log1pl.c: Likewise. * sysdeps/ieee754/ldbl-128/s_tanhl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_asinl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_atanhl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_hypotl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_j1l.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_jnl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_powl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/e_sinhl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/k_sincosl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/k_sinl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/k_tanl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_asinhl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_atanl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_erfl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_fmal.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_tanhl.c: Likewise. * sysdeps/ieee754/ldbl-96/e_asinl.c: Likewise. * sysdeps/ieee754/ldbl-96/e_atanhl.c: Likewise. * sysdeps/ieee754/ldbl-96/e_gammal_r.c: Likewise. * sysdeps/ieee754/ldbl-96/e_hypotl.c: Likewise. * sysdeps/ieee754/ldbl-96/e_j1l.c: Likewise. * sysdeps/ieee754/ldbl-96/e_jnl.c: Likewise. * sysdeps/ieee754/ldbl-96/e_sinhl.c: Likewise. * sysdeps/ieee754/ldbl-96/k_sinl.c: Likewise. * sysdeps/ieee754/ldbl-96/k_tanl.c: Likewise. * sysdeps/ieee754/ldbl-96/s_asinhl.c: Likewise. * sysdeps/ieee754/ldbl-96/s_erfl.c: Likewise. * sysdeps/ieee754/ldbl-96/s_tanhl.c: Likewise. * sysdeps/powerpc/fpu/e_hypot.c: Likewise. * sysdeps/x86/fpu/powl_helper.c: Likewise. * sysdeps/ieee754/dbl-64/s_nextup.c: Include <float.h>. * sysdeps/ieee754/flt-32/s_nextupf.c: Likewise. * sysdeps/ieee754/ldbl-128/s_nextupl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_nextupl.c: Likewise. * sysdeps/ieee754/ldbl-96/s_nextupl.c: Likewise.
2018-05-10 02:53:04 +02:00
#include <math-underflow.h>
#include <float.h>
Update. 1997-06-19 19:38 Ulrich Drepper <drepper@cygnus.com> * features.h: Define __STDC_IEC_559__ and _STDC_IEC_559_COMPLEX__. * elf/dl-minimal.c (__dcgettext): Remove assertion. * inet/rcmd.c: Correct a few typos. Reported by Eric Troan. * manual/Makefile (distribute): Add dir. * manual/dir: New file. * math/Makefile (libm-support): Rename s_rinttol, s_rinttoll, s_roundtol, and s_roundtoll to s_lrint, s_llrint, s_lround, and s_llround respectively. (libm-calls): Add e_gamma_r. * math/libm-test.c (check_int_exc): New function. (signbit_test): Remove test for sign of NaN. (gamma_test): Clear exception after test of existence. Correct tests and and epsilons. (lgamma_test): Likewise. (ilogb_test): Correct all tests. (scalb_test): Rewrite. (rinttol_test): Rename to lrint_test and correct tests. (rinttoll_test): Likewise. (roundtol_test): Likewise. (roundtoll_test): Likewise. (main): Call lrint/lround functions instead of rinttol/roundtol. * math/math.h: Change prototypes for rinttol/roundtol. * math/mathcalls.h: Rearrange prototypes according to ISO C9X draft. * sysdeps/generic/mathbits.h: Define FP_ILOGB0 and FP_ILOGBNAN. * sysdeps/i386/mathbits.h: Likewise. * sysdeps/libm-i387/e_scalb.S: Handle special cases correctly. * sysdeps/libm-i387/e_scalbf.S: Likewise. * sysdeps/libm-i387/e_scalbl.S: Likewise. * sysdeps/libm-i387/s_asinh.S: Handle -inf correctly. * sysdeps/libm-i387/s_asinhf.S: Likewise. * sysdeps/libm-i387/s_asinhl.S: Likewise. * sysdeps/libm-i387/s_ilogb.S: Optimize. * sysdeps/libm-i387/s_ilogbf.S: Likewise. * sysdeps/libm-i387/s_ilogbl.S: Likewise. * sysdeps/libm-i387/s_rinttol.S: Rename to... * sysdeps/libm-i387/s_lrint.S: ...this. * sysdeps/libm-i387/s_rinttoll.S: Rename to... * sysdeps/libm-i387/s_llrint.S: ...this. * sysdeps/libm-i387/s_remquo.S: Correctly set sign of remainder. * sysdeps/libm-i387/s_remquof.S: Likewise. * sysdeps/libm-i387/s_remquol.S: Likewise. * sysdeps/libm-i387/e_gamma_r.c: New file. Implementation of gamma function according to ISO C. * sysdeps/libm-i387/e_gammaf_r.c: New file. * sysdeps/libm-i387/e_gammal_r.c: New file. * sysdeps/libm-i387/e_lgamma_r.c: Don't let optimize compile the generation of exceptions away. * sysdeps/libm-i387/e_lgammaf_r.c: Likewise. * sysdeps/libm-i387/k_standard.c: Correct return value for infinity points of gamma function when not SVID mode. * sysdeps/libm-i387/s_rinttoll.c: Renamed to... * sysdeps/libm-i387/s_llrint.c: ...this. * sysdeps/libm-i387/s_rinttol.c: Renamed to... * sysdeps/libm-i387/s_lrint.c: ...this. * sysdeps/libm-i387/s_roundtoll.c: Renamed to... * sysdeps/libm-i387/s_llround.c: ...this. * sysdeps/libm-i387/s_roundtol.c: Renamed to... * sysdeps/libm-i387/s_lround.c: ..this. * sysdeps/libm-i387/s_scalbn.c: Change second parameter according to ISO C. * sysdeps/libm-i387/s_scalbnf.c: Likewise. * sysdeps/libm-i387/s_scalbnl.c: Likewise. * sysdeps/libm-i387/w_gamma.c: Call __ieee754_gamma_r if library mode is not _SVID_. * sysdeps/libm-i387/w_gammaf.c: Likewise. * sysdeps/libm-i387/w_gammal.c: Likewise. * sysdeps/m68k/fpu/__math.h: Rename __rinttol to __lrint and rinttol to lrint. * sysdeps/m68k/fpu/s_rinttol.c: Renamed to... * sysdeps/m68k/fpu/s_lrint.c: ...this. * sysdeps/m68k/fpu/s_rinttoll.c: Renamed to... * sysdeps/m68k/fpu/s_llrint.c: ...this. * md5-crypt/Makefile: Link md5test program with md5.o. * stdio-common/temptest.c: Don't use __stdio_gen_tempname which is not exported by the libc.so. * stdio-common/vfscanf.c: Correct scanning of strings after last change. * sysdeps/unix/sysv/linux/i386/sysdep.S: Use .comm to define errno. 1997-06-19 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * time/tzfile.c (__tzfile_read): Store getc () return in int. 1997-06-13 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (argp_version_parser): Include `(PROGRAM ERROR)' in the no-version error text to indicate that something's fucked. [!_] (N_): New macro. (argp_default_options, argp_version_options): Wrap doc strings in N_(). 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (parser_parse_opt): Detect and report unhandled options here. (parser_parse_arg): Handle ARGP_KEY_ARGS here. Adjust NEXT pointer back if we fail to parse anything. (parser_parse_next): Simplify arg code. Leave state NEXT frobbing to parser_parse_arg. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp.h (ARGP_KEY_ARGS, ARGP_KEY_FINI): New macros. * argp/argp-parse.c (parser_finalize): Do another pass over the parsers with ARGP_KEY_FINI. 1997-06-18 Miles Bader <miles@gnu.ai.mit.edu> * string/Makefile (routines): Add argz-replace. 1997-06-16 00:16 Miles Bader <miles@gnu.ai.mit.edu> * manual/string.texi (Argz Functions): Document argz_replace. 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * string/argz.h (__argz_replace, argz_replace): New declarations. * string/argz-replace.c: New file. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * manual/argp.texi (Argp Special Keys): Document ARGP_KEY_ARGS. 1997-06-16 23:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * Makeconfig (libc-map): Remove definition. * Makerules (libc-map): Define it here, using the full name. (load-map-file): Remove case for empty $(..). ($(common-objpfx)libc.so): Revert last change. 1997-06-17 22:18 Mark Kettenis <kettenis@phys.uva.nl> * login/programs/utmpd.c (main): Improve signal handling. * login/programs/request.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/utmpd.h (setutent_request, updwtmp_request): Get rid of fixed length file field. * login/utmp_daemon.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/request.c (do_pututline): Don't fail if connection->position is -1 on entry. 1997-06-15 16:32 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (updwtmp_file): Use the same method for appending an entry as in pututline_file. 1997-06-11 18:59 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (getutent_r_file): Use read lock instead of write lock. (getutline_r_file, internal_getut_r): Lock utmp file. (updwtmp_file): Use fcntl to lock file instead of flock. 1997-06-18 00:11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * stdio-common/vfscanf.c (inchar, ungetc): Don't count EOF as character read in/put back. * stdio-common/tstscanf.c: Add test case for this. 1997-06-17 22:17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * libc.map: Add more symbols. 1997-06-18 12:01 Ulrich Drepper <drepper@cygnus.com> * manual/Makefile (install): Make sure `dir' file exists if we use install-info. 1997-06-17 19:32 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * manual/Makefile (info): Depend on dir-add.info. 1997-06-17 17:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/ldd.bash.in: Fix spacing in message. 1997-06-17 14:28 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/do-rel.h (elf_dynamic_do_rel): Always use version information if available. 1997-06-17 11:34 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sunrpc/Makefile ($(rpcsvc:%.x=$(objpfx)rpcsvc/%.h)): Make command non-empty to force make to recheck modification time. ($(rpcsvc:%.x=$(objpfx)x%.c)): Likewise. 1997-06-17 00:26 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/stub/e_acoshl.c: Set errno to ENOSYS. * sysdeps/stub/e_acosl.c: Likewise. * sysdeps/stub/e_asinl.c: Likewise. * sysdeps/stub/e_atan2l.c: Likewise. * sysdeps/stub/e_expl.c: Likewise. * sysdeps/stub/e_fmodl.c: Likewise. * sysdeps/stub/e_j0l.c: Likewise. * sysdeps/stub/e_j1l.c: Likewise. * sysdeps/stub/e_jnl.c: Likewise. * sysdeps/stub/e_lgammal_r.c: Likewise. * sysdeps/stub/e_log10l.c: Likewise. * sysdeps/stub/e_logl.c: Likewise. * sysdeps/stub/e_powl.c: Likewise. * sysdeps/stub/e_rem_pio2l.c: Likewise. * sysdeps/stub/e_sqrtl.c: Likewise. * sysdeps/stub/k_cosl.c: Likewise. * sysdeps/stub/k_rem_pio2l.c: Likewise. * sysdeps/stub/k_sinl.c: Likewise. * sysdeps/stub/k_tanl.c: Likewise. * sysdeps/stub/s_atanl.c: Likewise. * sysdeps/stub/s_erfl.c: Likewise. * sysdeps/stub/s_exp2.c: Likewise. * sysdeps/stub/s_exp2f.c: Likewise. * sysdeps/stub/s_exp2l.c: Likewise. * sysdeps/stub/s_expm1l.c: Likewise. * sysdeps/stub/s_log1pl.c: Likewise. * sysdeps/stub/s_log2l.c: Likewise. 1997-06-18 11:46 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/w_gamma.c: If _LIB_VERSION is _SVID_ compute result as before last change. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. 1997-06-16 23:37 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/libm-ieee754/s_remquo.c: Fix off-by-one when computing quotient. * sysdeps/libm-ieee754/s_remquof.c: Likewise. * sysdeps/libm-ieee754/s_remquol.c: Likewise. * sysdeps/m68k/fpu/s_remquo.c: Remove FIXME and special case for quotient. * sysdeps/libm-ieee754/w_gamma.c: Add missing call to exp function. Don't use global signgam. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. * math/Makefile (libm-calls): Remove w_gamma_r. * sysdeps/libm-ieee754/w_gamma_r.c: Remove file. * sysdeps/libm-ieee754/w_gammaf_r.c: Remove file. * sysdeps/libm-ieee754/w_gammal_r.c: Remove file. * math/libm-test.c (atanh_test): Declare x only if needed. (signbit_test): Fix typo. (gamma_test): Check whether function is implemented. Add epsilons. (lgamma_test): Likewise. (fmod_test): Add epsilons. (exp2_test): Use right function for existence test. 1997-06-07 09:20 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/powerpc/Dist: Add fenv_const.c. * sysdeps/unix/sysv/linux/Dist: Add net/if_slip.h. * sysdeps/unix/sysv/linux/powerpc/Dist: Add init-first.h and syscall.h. * sysdeps/unix/sysv/linux/sparc/Dist: Add init-first.h. * string/Makefile (distribute): Add tst-svc.expect. * nis/Makefile (distribute): Add nis_intern.h and Banner. * elf/Makefile (distribute): Add dl-hash.h. * Rules (subdir_echo-distinfo): Add headers from $(distribute). * login/Makefile (others): Add utmpdump. * sysdeps/unix/sysv/linux/Makefile (sysdep_headers): Add net/if_slip.h. * manual/Makefile (dir-add.texi): Also look in indirectly included files. 1997-06-16 23:15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/configure.in: Remove commands to generate stdio_lim.h. * sysdeps/unix/sysv/linux/mk-stdiolim.c: Remove. * sysdeps/unix/sysv/linux/Makefile: Add rules to generate stdio_lim.h here. (common-generated): Add generated files. (inhibit-stdio_lim): Define. * sysdeps/posix/Makefile [$(inhibit-stdio_lim)=yes]: Disable rules to generate stdio_lim.h. * sysdeps/unix/sysv/linux/Makefile: Suppress inclusion of dependecy files if no_deps is set. ($(objpfx)syscall-%.d): Add header file as target to dependency generation. 1997-06-14 19:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/arm/Dist: New file. 1997-06-14 17:59 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * extra-lib.mk (others): Depend on versioned shared library, not the unversioned one. * Makerules (build-shlib): Don't make the version link here. ($(common-objpfx)libc.so$(libc.so-version)): New rule for libc version link. 1997-06-16 03:07 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/k_standard.c: Undo change of Tue Aug 6 01:13:56 1996. * argp/argp-help.c (argp_args_usage): Supply correct argp to filter_doc. * argp/argp-help.c (hol_add_cluster): Initialize CL->depth. * argp/argp-help.c (_help): Supply STATE to argp_args_usage. * argp/argp.h (ARGP_KEY_HELP_ARGS_DOC): New macro. * argp/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp.h (OPTION_NO_USAGE): New macro. * argp/argp-help.c (usage_long_opt, usage_argful_short_opt, * argp/argp-fmtstream.c (__argp_fmtstream_update): Account for case * argp/argp-help.c <stddef.h>: New include. * argp/argp.h (argp_state_help, __argp_state_help, argp_usage, * argp/argp.h (argp_program_bug_address): Make const. * argp/argp-parse.c (argp_default_parser): Set STATE->name for OPT_PROGNAME. * argp/argp-help.c (__argp_error, __argp_failure, __argp_state_help): * argp/argp-parse.c (parser_init): Set PARSER->state.flags.
1997-06-19 21:11:22 +02:00
/* Coefficients B_2k / 2k(2k-1) of x^-(2k-1) inside exp in Stirling's
approximation to gamma function. */
static const double gamma_coeff[] =
{
0x1.5555555555555p-4,
-0xb.60b60b60b60b8p-12,
0x3.4034034034034p-12,
-0x2.7027027027028p-12,
0x3.72a3c5631fe46p-12,
-0x7.daac36664f1f4p-12,
};
#define NCOEFF (sizeof (gamma_coeff) / sizeof (gamma_coeff[0]))
/* Return gamma (X), for positive X less than 184, in the form R *
2^(*EXP2_ADJ), where R is the return value and *EXP2_ADJ is set to
avoid overflow or underflow in intermediate calculations. */
static double
gamma_positive (double x, int *exp2_adj)
{
int local_signgam;
if (x < 0.5)
{
*exp2_adj = 0;
return __ieee754_exp (__ieee754_lgamma_r (x + 1, &local_signgam)) / x;
}
else if (x <= 1.5)
{
*exp2_adj = 0;
return __ieee754_exp (__ieee754_lgamma_r (x, &local_signgam));
}
else if (x < 6.5)
{
/* Adjust into the range for using exp (lgamma). */
*exp2_adj = 0;
Use ceil functions not __ceil functions in glibc libm. Continuing the move to use, within libm, public names for libm functions that can be inlined as built-in functions on many architectures, this patch moves calls to __ceil functions to call the corresponding ceil names instead, with asm redirection to __ceil when the calls are not inlined. Tested for x86_64, and with build-many-glibcs.py. * include/math.h [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (ceil): Redirect using MATH_REDIRECT. * sysdeps/aarch64/fpu/s_ceil.c: Define NO_MATH_REDIRECT before header inclusion. * sysdeps/aarch64/fpu/s_ceilf.c: Likewise. * sysdeps/ieee754/dbl-64/s_ceil.c: Likewise. * sysdeps/ieee754/dbl-64/wordsize-64/s_ceil.c: Likewise. * sysdeps/ieee754/float128/s_ceilf128.c: Likewise. * sysdeps/ieee754/flt-32/s_ceilf.c: Likewise. * sysdeps/ieee754/ldbl-128/s_ceill.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_ceill.c: Likewise. * sysdeps/m68k/m680x0/fpu/s_ceil_template.c: Likewise. * sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_ceil.c: Likewise. * sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_ceilf.c: Likewise. * sysdeps/powerpc/powerpc64/fpu/multiarch/s_ceil.c: Likewise. * sysdeps/powerpc/powerpc64/fpu/multiarch/s_ceilf.c: Likewise. * sysdeps/riscv/rv64/rvd/s_ceil.c: Likewise. * sysdeps/riscv/rvf/s_ceilf.c: Likewise. * sysdeps/sparc/sparc64/fpu/multiarch/s_ceil.c: Likewise. * sysdeps/sparc/sparc64/fpu/multiarch/s_ceilf.c: Likewise. * sysdeps/x86_64/fpu/multiarch/s_ceil.c: Likewise. * sysdeps/x86_64/fpu/multiarch/s_ceilf.c: Likewise. * sysdeps/powerpc/fpu/math_private.h [_ARCH_PWR5X] (__ceil): Remove macro. * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Use ceil functions instead of __ceil variants. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Likewise. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_truncl.c (__truncl): Likewise. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Likewise. * sysdeps/powerpc/power5+/fpu/s_modf.c (__modf): Likewise. * sysdeps/powerpc/power5+/fpu/s_modff.c (__modff): Likewise.
2018-09-17 22:42:06 +02:00
double n = ceil (x - 1.5);
double x_adj = x - n;
double eps;
double prod = __gamma_product (x_adj, 0, n, &eps);
return (__ieee754_exp (__ieee754_lgamma_r (x_adj, &local_signgam))
* prod * (1.0 + eps));
}
else
{
double eps = 0;
double x_eps = 0;
double x_adj = x;
double prod = 1;
if (x < 12.0)
{
/* Adjust into the range for applying Stirling's
approximation. */
Use ceil functions not __ceil functions in glibc libm. Continuing the move to use, within libm, public names for libm functions that can be inlined as built-in functions on many architectures, this patch moves calls to __ceil functions to call the corresponding ceil names instead, with asm redirection to __ceil when the calls are not inlined. Tested for x86_64, and with build-many-glibcs.py. * include/math.h [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (ceil): Redirect using MATH_REDIRECT. * sysdeps/aarch64/fpu/s_ceil.c: Define NO_MATH_REDIRECT before header inclusion. * sysdeps/aarch64/fpu/s_ceilf.c: Likewise. * sysdeps/ieee754/dbl-64/s_ceil.c: Likewise. * sysdeps/ieee754/dbl-64/wordsize-64/s_ceil.c: Likewise. * sysdeps/ieee754/float128/s_ceilf128.c: Likewise. * sysdeps/ieee754/flt-32/s_ceilf.c: Likewise. * sysdeps/ieee754/ldbl-128/s_ceill.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_ceill.c: Likewise. * sysdeps/m68k/m680x0/fpu/s_ceil_template.c: Likewise. * sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_ceil.c: Likewise. * sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_ceilf.c: Likewise. * sysdeps/powerpc/powerpc64/fpu/multiarch/s_ceil.c: Likewise. * sysdeps/powerpc/powerpc64/fpu/multiarch/s_ceilf.c: Likewise. * sysdeps/riscv/rv64/rvd/s_ceil.c: Likewise. * sysdeps/riscv/rvf/s_ceilf.c: Likewise. * sysdeps/sparc/sparc64/fpu/multiarch/s_ceil.c: Likewise. * sysdeps/sparc/sparc64/fpu/multiarch/s_ceilf.c: Likewise. * sysdeps/x86_64/fpu/multiarch/s_ceil.c: Likewise. * sysdeps/x86_64/fpu/multiarch/s_ceilf.c: Likewise. * sysdeps/powerpc/fpu/math_private.h [_ARCH_PWR5X] (__ceil): Remove macro. * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Use ceil functions instead of __ceil variants. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Likewise. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_truncl.c (__truncl): Likewise. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Likewise. * sysdeps/powerpc/power5+/fpu/s_modf.c (__modf): Likewise. * sysdeps/powerpc/power5+/fpu/s_modff.c (__modff): Likewise.
2018-09-17 22:42:06 +02:00
double n = ceil (12.0 - x);
Use math_narrow_eval more consistently. Where glibc code needs to avoid excess range and precision in floating-point arithmetic, code variously uses either asms or volatile to force the results of that arithmetic to memory; mostly this is conditional on FLT_EVAL_METHOD, but in the case of lrint / llrint functions some use of volatile is unconditional (and is present unnecessarily in versions for long double). This patch make such code use the recently-added math_narrow_eval macro consistently, removing the unnecessary uses of volatile in long double lrint / llrint implementations completely. Tested for x86_64, x86, mips64 and powerpc. * math/s_nexttowardf.c (__nexttowardf): Use math_narrow_eval. * stdlib/strtod_l.c: Include <math_private.h>. (overflow_value): Use math_narrow_eval. (underflow_value): Likewise. * sysdeps/i386/fpu/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/i386/fpu/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Likewise. (__ieee754_gamma_r): Likewise. * sysdeps/ieee754/dbl-64/gamma_productf.c (__gamma_productf): Likewise. * sysdeps/ieee754/dbl-64/k_rem_pio2.c (__kernel_rem_pio2): Likewise. * sysdeps/ieee754/dbl-64/lgamma_neg.c (__lgamma_neg): Likewise. * sysdeps/ieee754/dbl-64/s_erf.c (__erfc): Likewise. * sysdeps/ieee754/dbl-64/s_llrint.c (__llrint): Likewise. * sysdeps/ieee754/dbl-64/s_lrint.c (__lrint): Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Likewise. (__ieee754_gammaf_r): Likewise. * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f): Likewise. * sysdeps/ieee754/flt-32/lgamma_negf.c (__lgamma_negf): Likewise. * sysdeps/ieee754/flt-32/s_erff.c (__erfcf): Likewise. * sysdeps/ieee754/flt-32/s_llrintf.c (__llrintf): Likewise. * sysdeps/ieee754/flt-32/s_lrintf.c (__lrintf): Likewise. * sysdeps/ieee754/ldbl-128/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-128/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-128/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-128ibm/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-96/gamma_product.c (__gamma_product): Likewise. * sysdeps/ieee754/ldbl-96/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-96/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-96/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-96/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-opt/s_nexttowardfd.c (__nldbl_nexttowardf): Likewise.
2015-09-23 20:14:57 +02:00
x_adj = math_narrow_eval (x + n);
x_eps = (x - (x_adj - n));
prod = __gamma_product (x_adj - n, x_eps, n, &eps);
}
/* The result is now gamma (X_ADJ + X_EPS) / (PROD * (1 + EPS)).
Compute gamma (X_ADJ + X_EPS) using Stirling's approximation,
starting by computing pow (X_ADJ, X_ADJ) with a power of 2
factored out. */
double exp_adj = -eps;
double x_adj_int = __round (x_adj);
double x_adj_frac = x_adj - x_adj_int;
int x_adj_log2;
double x_adj_mant = __frexp (x_adj, &x_adj_log2);
if (x_adj_mant < M_SQRT1_2)
{
x_adj_log2--;
x_adj_mant *= 2.0;
}
*exp2_adj = x_adj_log2 * (int) x_adj_int;
double ret = (__ieee754_pow (x_adj_mant, x_adj)
* __ieee754_exp2 (x_adj_log2 * x_adj_frac)
* __ieee754_exp (-x_adj)
Rename all __ieee754_sqrt(f/l) calls to sqrt(f/l) Use sqrt(f/l) to enable inlining by GCC - if inlining doesn't happen, the asm redirect ensures we will still call __ieee754_sqrt(f/l). * sysdeps/ieee754/dbl-64/e_acosh.c (__ieee754_acosh): Use sqrt. * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Likewise. * sysdeps/ieee754/dbl-64/e_hypot.c (__ieee754_hypot): Likewise. * sysdeps/ieee754/dbl-64/e_j0.c (__ieee754_j0): Likewise. * sysdeps/ieee754/dbl-64/e_j1.c (__ieee754_j1): Likewise. * sysdeps/ieee754/dbl-64/e_jn.c (__ieee754_jn): Likewise. * sysdeps/ieee754/dbl-64/s_asinh.c (__asinh): Likewise. * sysdeps/ieee754/dbl-64/wordsize-64/e_acosh.c (__ieee754_acosh): Likewise. * sysdeps/ieee754/flt-32/e_acosf.c (__ieee754_acosf): Likewise. * sysdeps/ieee754/flt-32/e_acoshf.c (__ieee754_acoshf): Likewise. * sysdeps/ieee754/flt-32/e_asinf.c (__ieee754_asinf): Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Likewise. * sysdeps/ieee754/flt-32/e_hypotf.c (__ieee754_hypotf): Likewise. * sysdeps/ieee754/flt-32/e_j0f.c (__ieee754_j0f): Likewise. * sysdeps/ieee754/flt-32/e_j1f.c (__ieee754_j1f): Likewise. * sysdeps/ieee754/flt-32/e_powf.c (__ieee754_powf): Likewise. * sysdeps/ieee754/flt-32/s_asinhf.c (__asinhf): Likewise. * sysdeps/ieee754/ldbl-128/e_acoshl.c (__ieee754_acoshl): Use sqrtl. * sysdeps/ieee754/ldbl-128/e_acosl.c (__ieee754_acosl): Likewise. * sysdeps/ieee754/ldbl-128/e_asinl.c (__ieee754_asinl): Likewise. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Likewise. * sysdeps/ieee754/ldbl-128/e_hypotl.c (__ieee754_hypotl): Likewise. * sysdeps/ieee754/ldbl-128/e_j0l.c (__ieee754_j0l): Likewise. * sysdeps/ieee754/ldbl-128/e_j1l.c (__ieee754_j1l): Likewise. * sysdeps/ieee754/ldbl-128/e_jnl.c (__ieee754_jnl): Likewise. * sysdeps/ieee754/ldbl-128/e_powl.c (__ieee754_powl): Likewise. * sysdeps/ieee754/ldbl-128/s_asinhl.c (__ieee754_asinhl): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_acoshl.c (__ieee754_acoshl): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_acosl.c (__ieee754_acosl): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_asinl.c (__ieee754_asinl): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_hypotl.c (__ieee754_hypotl): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_j0l.c (__ieee754_j0l): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_j1l.c (__ieee754_j1l): Likewise * sysdeps/ieee754/ldbl-128ibm/e_jnl.c (__ieee754_jnl): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_powl.c (__ieee754_powl): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_asinhl.c (__ieee754_asinhl): Likewise. * sysdeps/ieee754/ldbl-96/e_acoshl.c (__ieee754_acoshl): Use sqrtl. * sysdeps/ieee754/ldbl-96/e_asinl.c (__ieee754_asinl): Likewise. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Likewise. * sysdeps/ieee754/ldbl-96/e_hypotl.c (__ieee754_hypotl): Likewise. * sysdeps/ieee754/ldbl-96/e_j0l.c (__ieee754_j0l): Likewise. * sysdeps/ieee754/ldbl-96/e_j1l.c (__ieee754_j1l): Likewise. * sysdeps/ieee754/ldbl-96/e_jnl.c (__ieee754_jnl): Likewise. * sysdeps/ieee754/ldbl-96/s_asinhl.c (__ieee754_asinhl): Likewise. * sysdeps/m68k/m680x0/fpu/e_pow.c (__ieee754_pow): Likewise. * sysdeps/powerpc/fpu/e_hypot.c (__ieee754_hypot): Likewise. * sysdeps/powerpc/fpu/e_hypotf.c (__ieee754_hypotf): Likewise.
2018-03-15 19:05:03 +01:00
* sqrt (2 * M_PI / x_adj)
/ prod);
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
exp_adj += x_eps * __ieee754_log (x_adj);
double bsum = gamma_coeff[NCOEFF - 1];
double x_adj2 = x_adj * x_adj;
for (size_t i = 1; i <= NCOEFF - 1; i++)
bsum = bsum / x_adj2 + gamma_coeff[NCOEFF - 1 - i];
exp_adj += bsum / x_adj;
return ret + ret * __expm1 (exp_adj);
}
}
Update. 1997-06-19 19:38 Ulrich Drepper <drepper@cygnus.com> * features.h: Define __STDC_IEC_559__ and _STDC_IEC_559_COMPLEX__. * elf/dl-minimal.c (__dcgettext): Remove assertion. * inet/rcmd.c: Correct a few typos. Reported by Eric Troan. * manual/Makefile (distribute): Add dir. * manual/dir: New file. * math/Makefile (libm-support): Rename s_rinttol, s_rinttoll, s_roundtol, and s_roundtoll to s_lrint, s_llrint, s_lround, and s_llround respectively. (libm-calls): Add e_gamma_r. * math/libm-test.c (check_int_exc): New function. (signbit_test): Remove test for sign of NaN. (gamma_test): Clear exception after test of existence. Correct tests and and epsilons. (lgamma_test): Likewise. (ilogb_test): Correct all tests. (scalb_test): Rewrite. (rinttol_test): Rename to lrint_test and correct tests. (rinttoll_test): Likewise. (roundtol_test): Likewise. (roundtoll_test): Likewise. (main): Call lrint/lround functions instead of rinttol/roundtol. * math/math.h: Change prototypes for rinttol/roundtol. * math/mathcalls.h: Rearrange prototypes according to ISO C9X draft. * sysdeps/generic/mathbits.h: Define FP_ILOGB0 and FP_ILOGBNAN. * sysdeps/i386/mathbits.h: Likewise. * sysdeps/libm-i387/e_scalb.S: Handle special cases correctly. * sysdeps/libm-i387/e_scalbf.S: Likewise. * sysdeps/libm-i387/e_scalbl.S: Likewise. * sysdeps/libm-i387/s_asinh.S: Handle -inf correctly. * sysdeps/libm-i387/s_asinhf.S: Likewise. * sysdeps/libm-i387/s_asinhl.S: Likewise. * sysdeps/libm-i387/s_ilogb.S: Optimize. * sysdeps/libm-i387/s_ilogbf.S: Likewise. * sysdeps/libm-i387/s_ilogbl.S: Likewise. * sysdeps/libm-i387/s_rinttol.S: Rename to... * sysdeps/libm-i387/s_lrint.S: ...this. * sysdeps/libm-i387/s_rinttoll.S: Rename to... * sysdeps/libm-i387/s_llrint.S: ...this. * sysdeps/libm-i387/s_remquo.S: Correctly set sign of remainder. * sysdeps/libm-i387/s_remquof.S: Likewise. * sysdeps/libm-i387/s_remquol.S: Likewise. * sysdeps/libm-i387/e_gamma_r.c: New file. Implementation of gamma function according to ISO C. * sysdeps/libm-i387/e_gammaf_r.c: New file. * sysdeps/libm-i387/e_gammal_r.c: New file. * sysdeps/libm-i387/e_lgamma_r.c: Don't let optimize compile the generation of exceptions away. * sysdeps/libm-i387/e_lgammaf_r.c: Likewise. * sysdeps/libm-i387/k_standard.c: Correct return value for infinity points of gamma function when not SVID mode. * sysdeps/libm-i387/s_rinttoll.c: Renamed to... * sysdeps/libm-i387/s_llrint.c: ...this. * sysdeps/libm-i387/s_rinttol.c: Renamed to... * sysdeps/libm-i387/s_lrint.c: ...this. * sysdeps/libm-i387/s_roundtoll.c: Renamed to... * sysdeps/libm-i387/s_llround.c: ...this. * sysdeps/libm-i387/s_roundtol.c: Renamed to... * sysdeps/libm-i387/s_lround.c: ..this. * sysdeps/libm-i387/s_scalbn.c: Change second parameter according to ISO C. * sysdeps/libm-i387/s_scalbnf.c: Likewise. * sysdeps/libm-i387/s_scalbnl.c: Likewise. * sysdeps/libm-i387/w_gamma.c: Call __ieee754_gamma_r if library mode is not _SVID_. * sysdeps/libm-i387/w_gammaf.c: Likewise. * sysdeps/libm-i387/w_gammal.c: Likewise. * sysdeps/m68k/fpu/__math.h: Rename __rinttol to __lrint and rinttol to lrint. * sysdeps/m68k/fpu/s_rinttol.c: Renamed to... * sysdeps/m68k/fpu/s_lrint.c: ...this. * sysdeps/m68k/fpu/s_rinttoll.c: Renamed to... * sysdeps/m68k/fpu/s_llrint.c: ...this. * md5-crypt/Makefile: Link md5test program with md5.o. * stdio-common/temptest.c: Don't use __stdio_gen_tempname which is not exported by the libc.so. * stdio-common/vfscanf.c: Correct scanning of strings after last change. * sysdeps/unix/sysv/linux/i386/sysdep.S: Use .comm to define errno. 1997-06-19 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * time/tzfile.c (__tzfile_read): Store getc () return in int. 1997-06-13 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (argp_version_parser): Include `(PROGRAM ERROR)' in the no-version error text to indicate that something's fucked. [!_] (N_): New macro. (argp_default_options, argp_version_options): Wrap doc strings in N_(). 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (parser_parse_opt): Detect and report unhandled options here. (parser_parse_arg): Handle ARGP_KEY_ARGS here. Adjust NEXT pointer back if we fail to parse anything. (parser_parse_next): Simplify arg code. Leave state NEXT frobbing to parser_parse_arg. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp.h (ARGP_KEY_ARGS, ARGP_KEY_FINI): New macros. * argp/argp-parse.c (parser_finalize): Do another pass over the parsers with ARGP_KEY_FINI. 1997-06-18 Miles Bader <miles@gnu.ai.mit.edu> * string/Makefile (routines): Add argz-replace. 1997-06-16 00:16 Miles Bader <miles@gnu.ai.mit.edu> * manual/string.texi (Argz Functions): Document argz_replace. 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * string/argz.h (__argz_replace, argz_replace): New declarations. * string/argz-replace.c: New file. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * manual/argp.texi (Argp Special Keys): Document ARGP_KEY_ARGS. 1997-06-16 23:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * Makeconfig (libc-map): Remove definition. * Makerules (libc-map): Define it here, using the full name. (load-map-file): Remove case for empty $(..). ($(common-objpfx)libc.so): Revert last change. 1997-06-17 22:18 Mark Kettenis <kettenis@phys.uva.nl> * login/programs/utmpd.c (main): Improve signal handling. * login/programs/request.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/utmpd.h (setutent_request, updwtmp_request): Get rid of fixed length file field. * login/utmp_daemon.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/request.c (do_pututline): Don't fail if connection->position is -1 on entry. 1997-06-15 16:32 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (updwtmp_file): Use the same method for appending an entry as in pututline_file. 1997-06-11 18:59 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (getutent_r_file): Use read lock instead of write lock. (getutline_r_file, internal_getut_r): Lock utmp file. (updwtmp_file): Use fcntl to lock file instead of flock. 1997-06-18 00:11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * stdio-common/vfscanf.c (inchar, ungetc): Don't count EOF as character read in/put back. * stdio-common/tstscanf.c: Add test case for this. 1997-06-17 22:17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * libc.map: Add more symbols. 1997-06-18 12:01 Ulrich Drepper <drepper@cygnus.com> * manual/Makefile (install): Make sure `dir' file exists if we use install-info. 1997-06-17 19:32 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * manual/Makefile (info): Depend on dir-add.info. 1997-06-17 17:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/ldd.bash.in: Fix spacing in message. 1997-06-17 14:28 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/do-rel.h (elf_dynamic_do_rel): Always use version information if available. 1997-06-17 11:34 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sunrpc/Makefile ($(rpcsvc:%.x=$(objpfx)rpcsvc/%.h)): Make command non-empty to force make to recheck modification time. ($(rpcsvc:%.x=$(objpfx)x%.c)): Likewise. 1997-06-17 00:26 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/stub/e_acoshl.c: Set errno to ENOSYS. * sysdeps/stub/e_acosl.c: Likewise. * sysdeps/stub/e_asinl.c: Likewise. * sysdeps/stub/e_atan2l.c: Likewise. * sysdeps/stub/e_expl.c: Likewise. * sysdeps/stub/e_fmodl.c: Likewise. * sysdeps/stub/e_j0l.c: Likewise. * sysdeps/stub/e_j1l.c: Likewise. * sysdeps/stub/e_jnl.c: Likewise. * sysdeps/stub/e_lgammal_r.c: Likewise. * sysdeps/stub/e_log10l.c: Likewise. * sysdeps/stub/e_logl.c: Likewise. * sysdeps/stub/e_powl.c: Likewise. * sysdeps/stub/e_rem_pio2l.c: Likewise. * sysdeps/stub/e_sqrtl.c: Likewise. * sysdeps/stub/k_cosl.c: Likewise. * sysdeps/stub/k_rem_pio2l.c: Likewise. * sysdeps/stub/k_sinl.c: Likewise. * sysdeps/stub/k_tanl.c: Likewise. * sysdeps/stub/s_atanl.c: Likewise. * sysdeps/stub/s_erfl.c: Likewise. * sysdeps/stub/s_exp2.c: Likewise. * sysdeps/stub/s_exp2f.c: Likewise. * sysdeps/stub/s_exp2l.c: Likewise. * sysdeps/stub/s_expm1l.c: Likewise. * sysdeps/stub/s_log1pl.c: Likewise. * sysdeps/stub/s_log2l.c: Likewise. 1997-06-18 11:46 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/w_gamma.c: If _LIB_VERSION is _SVID_ compute result as before last change. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. 1997-06-16 23:37 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/libm-ieee754/s_remquo.c: Fix off-by-one when computing quotient. * sysdeps/libm-ieee754/s_remquof.c: Likewise. * sysdeps/libm-ieee754/s_remquol.c: Likewise. * sysdeps/m68k/fpu/s_remquo.c: Remove FIXME and special case for quotient. * sysdeps/libm-ieee754/w_gamma.c: Add missing call to exp function. Don't use global signgam. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. * math/Makefile (libm-calls): Remove w_gamma_r. * sysdeps/libm-ieee754/w_gamma_r.c: Remove file. * sysdeps/libm-ieee754/w_gammaf_r.c: Remove file. * sysdeps/libm-ieee754/w_gammal_r.c: Remove file. * math/libm-test.c (atanh_test): Declare x only if needed. (signbit_test): Fix typo. (gamma_test): Check whether function is implemented. Add epsilons. (lgamma_test): Likewise. (fmod_test): Add epsilons. (exp2_test): Use right function for existence test. 1997-06-07 09:20 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/powerpc/Dist: Add fenv_const.c. * sysdeps/unix/sysv/linux/Dist: Add net/if_slip.h. * sysdeps/unix/sysv/linux/powerpc/Dist: Add init-first.h and syscall.h. * sysdeps/unix/sysv/linux/sparc/Dist: Add init-first.h. * string/Makefile (distribute): Add tst-svc.expect. * nis/Makefile (distribute): Add nis_intern.h and Banner. * elf/Makefile (distribute): Add dl-hash.h. * Rules (subdir_echo-distinfo): Add headers from $(distribute). * login/Makefile (others): Add utmpdump. * sysdeps/unix/sysv/linux/Makefile (sysdep_headers): Add net/if_slip.h. * manual/Makefile (dir-add.texi): Also look in indirectly included files. 1997-06-16 23:15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/configure.in: Remove commands to generate stdio_lim.h. * sysdeps/unix/sysv/linux/mk-stdiolim.c: Remove. * sysdeps/unix/sysv/linux/Makefile: Add rules to generate stdio_lim.h here. (common-generated): Add generated files. (inhibit-stdio_lim): Define. * sysdeps/posix/Makefile [$(inhibit-stdio_lim)=yes]: Disable rules to generate stdio_lim.h. * sysdeps/unix/sysv/linux/Makefile: Suppress inclusion of dependecy files if no_deps is set. ($(objpfx)syscall-%.d): Add header file as target to dependency generation. 1997-06-14 19:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/arm/Dist: New file. 1997-06-14 17:59 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * extra-lib.mk (others): Depend on versioned shared library, not the unversioned one. * Makerules (build-shlib): Don't make the version link here. ($(common-objpfx)libc.so$(libc.so-version)): New rule for libc version link. 1997-06-16 03:07 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/k_standard.c: Undo change of Tue Aug 6 01:13:56 1996. * argp/argp-help.c (argp_args_usage): Supply correct argp to filter_doc. * argp/argp-help.c (hol_add_cluster): Initialize CL->depth. * argp/argp-help.c (_help): Supply STATE to argp_args_usage. * argp/argp.h (ARGP_KEY_HELP_ARGS_DOC): New macro. * argp/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp.h (OPTION_NO_USAGE): New macro. * argp/argp-help.c (usage_long_opt, usage_argful_short_opt, * argp/argp-fmtstream.c (__argp_fmtstream_update): Account for case * argp/argp-help.c <stddef.h>: New include. * argp/argp.h (argp_state_help, __argp_state_help, argp_usage, * argp/argp.h (argp_program_bug_address): Make const. * argp/argp-parse.c (argp_default_parser): Set STATE->name for OPT_PROGNAME. * argp/argp-help.c (__argp_error, __argp_failure, __argp_state_help): * argp/argp-parse.c (parser_init): Set PARSER->state.flags.
1997-06-19 21:11:22 +02:00
double
__ieee754_gamma_r (double x, int *signgamp)
{
int32_t hx;
Consistently use uintN_t not u_intN_t in libm. This patch changes libm code to make consistent use of C99 uintN_t types instead of sometimes using those and sometimes using the older nonstandard u_intN_t names. This makes sense as a cleanup in its own right, and also facilitates merges to GCC's libquadmath (which gets the types from stdint.h and so may not have u_intN_t available at all). Tested for x86_64, and with build-many-glibcs.py. * math/s_nextafter.c (__nextafter): Use uintN_t instead of u_intN_t. * math/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/generic/math_private.h (ieee_double_shape_type): Likewise. (ieee_float_shape_type): Likewise. * sysdeps/i386/fpu/s_fpclassifyl.c (__fpclassifyl): Likewise. * sysdeps/i386/fpu/s_isnanl.c (__isnanl): Likewise. * sysdeps/i386/fpu/s_nextafterl.c (__nextafterl): Likewise. * sysdeps/i386/fpu/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/i386/fpu/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/dbl-64/e_acosh.c (__ieee754_acosh): Likewise. * sysdeps/ieee754/dbl-64/e_cosh.c (__ieee754_cosh): Likewise. * sysdeps/ieee754/dbl-64/e_fmod.c (__ieee754_fmod): Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c (__ieee754_gamma_r): Likewise. * sysdeps/ieee754/dbl-64/e_hypot.c (__ieee754_hypot): Likewise. * sysdeps/ieee754/dbl-64/e_jn.c (__ieee754_jn): Likewise. (__ieee754_yn): Likewise. * sysdeps/ieee754/dbl-64/e_log10.c (__ieee754_log10): Likewise. * sysdeps/ieee754/dbl-64/e_log2.c (__ieee754_log2): Likewise. * sysdeps/ieee754/dbl-64/e_rem_pio2.c (__ieee754_rem_pio2): Likewise. * sysdeps/ieee754/dbl-64/e_sinh.c (__ieee754_sinh): Likewise. * sysdeps/ieee754/dbl-64/s_ceil.c (__ceil): Likewise. * sysdeps/ieee754/dbl-64/s_copysign.c (__copysign): Likewise. * sysdeps/ieee754/dbl-64/s_erf.c (__erf): Likewise. (__erfc): Likewise. * sysdeps/ieee754/dbl-64/s_expm1.c (__expm1): Likewise. * sysdeps/ieee754/dbl-64/s_finite.c (FINITE): Likewise. * sysdeps/ieee754/dbl-64/s_floor.c (__floor): Likewise. * sysdeps/ieee754/dbl-64/s_fpclassify.c (__fpclassify): Likewise. * sysdeps/ieee754/dbl-64/s_isnan.c (__isnan): Likewise. * sysdeps/ieee754/dbl-64/s_issignaling.c (__issignaling): Likewise. * sysdeps/ieee754/dbl-64/s_llrint.c (__llrint): Likewise. * sysdeps/ieee754/dbl-64/s_llround.c (__llround): Likewise. * sysdeps/ieee754/dbl-64/s_lrint.c (__lrint): Likewise. * sysdeps/ieee754/dbl-64/s_lround.c (__lround): Likewise. * sysdeps/ieee754/dbl-64/s_modf.c (__modf): Likewise. * sysdeps/ieee754/dbl-64/s_nextup.c (__nextup): Likewise. * sysdeps/ieee754/dbl-64/s_remquo.c (__remquo): Likewise. * sysdeps/ieee754/dbl-64/s_round.c (__round): Likewise. * sysdeps/ieee754/dbl-64/s_trunc.c (__trunc): Likewise. * sysdeps/ieee754/dbl-64/wordsize-64/s_issignaling.c (__issignaling): Likewise. * sysdeps/ieee754/flt-32/e_atan2f.c (__ieee754_atan2f): Likewise. * sysdeps/ieee754/flt-32/e_fmodf.c (__ieee754_fmodf): Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c (__ieee754_gammaf_r): Likewise. * sysdeps/ieee754/flt-32/e_jnf.c (__ieee754_ynf): Likewise. * sysdeps/ieee754/flt-32/e_log10f.c (__ieee754_log10f): Likewise. * sysdeps/ieee754/flt-32/e_powf.c (__ieee754_powf): Likewise. * sysdeps/ieee754/flt-32/e_rem_pio2f.c (__ieee754_rem_pio2f): Likewise. * sysdeps/ieee754/flt-32/e_remainderf.c (__ieee754_remainderf): Likewise. * sysdeps/ieee754/flt-32/e_sqrtf.c (__ieee754_sqrtf): Likewise. * sysdeps/ieee754/flt-32/s_ceilf.c (__ceilf): Likewise. * sysdeps/ieee754/flt-32/s_copysignf.c (__copysignf): Likewise. * sysdeps/ieee754/flt-32/s_erff.c (__erff): Likewise. (__erfcf): Likewise. * sysdeps/ieee754/flt-32/s_expm1f.c (__expm1f): Likewise. * sysdeps/ieee754/flt-32/s_finitef.c (FINITEF): Likewise. * sysdeps/ieee754/flt-32/s_floorf.c (__floorf): Likewise. * sysdeps/ieee754/flt-32/s_fpclassifyf.c (__fpclassifyf): Likewise. * sysdeps/ieee754/flt-32/s_isnanf.c (__isnanf): Likewise. * sysdeps/ieee754/flt-32/s_issignalingf.c (__issignalingf): Likewise. * sysdeps/ieee754/flt-32/s_llrintf.c (__llrintf): Likewise. * sysdeps/ieee754/flt-32/s_llroundf.c (__llroundf): Likewise. * sysdeps/ieee754/flt-32/s_lrintf.c (__lrintf): Likewise. * sysdeps/ieee754/flt-32/s_lroundf.c (__lroundf): Likewise. * sysdeps/ieee754/flt-32/s_modff.c (__modff): Likewise. * sysdeps/ieee754/flt-32/s_remquof.c (__remquof): Likewise. * sysdeps/ieee754/flt-32/s_roundf.c (__roundf): Likewise. * sysdeps/ieee754/ldbl-128/e_acoshl.c (__ieee754_acoshl): Likewise. * sysdeps/ieee754/ldbl-128/e_atan2l.c (__ieee754_atan2l): Likewise. * sysdeps/ieee754/ldbl-128/e_atanhl.c (__ieee754_atanhl): Likewise. * sysdeps/ieee754/ldbl-128/e_fmodl.c (__ieee754_fmodl): Likewise. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (__ieee754_gammal_r): Likewise. * sysdeps/ieee754/ldbl-128/e_hypotl.c (__ieee754_hypotl): Likewise. * sysdeps/ieee754/ldbl-128/e_jnl.c (__ieee754_jnl): Likewise. (__ieee754_ynl): Likewise. * sysdeps/ieee754/ldbl-128/e_powl.c (__ieee754_powl): Likewise. * sysdeps/ieee754/ldbl-128/e_rem_pio2l.c (__ieee754_rem_pio2l): Likewise. * sysdeps/ieee754/ldbl-128/e_remainderl.c (__ieee754_remainderl): Likewise. * sysdeps/ieee754/ldbl-128/e_sinhl.c (__ieee754_sinhl): Likewise. * sysdeps/ieee754/ldbl-128/k_cosl.c (__kernel_cosl): Likewise. * sysdeps/ieee754/ldbl-128/k_sincosl.c (__kernel_sincosl): Likewise. * sysdeps/ieee754/ldbl-128/k_sinl.c (__kernel_sinl): Likewise. * sysdeps/ieee754/ldbl-128/s_ceill.c (__ceill): Likewise. * sysdeps/ieee754/ldbl-128/s_copysignl.c (__copysignl): Likewise. * sysdeps/ieee754/ldbl-128/s_erfl.c (__erfcl): Likewise. * sysdeps/ieee754/ldbl-128/s_fabsl.c (__fabsl): Likewise. * sysdeps/ieee754/ldbl-128/s_finitel.c (__finitel): Likewise. * sysdeps/ieee754/ldbl-128/s_floorl.c (__floorl): Likewise. * sysdeps/ieee754/ldbl-128/s_fpclassifyl.c (__fpclassifyl): Likewise. * sysdeps/ieee754/ldbl-128/s_frexpl.c (__frexpl): Likewise. * sysdeps/ieee754/ldbl-128/s_isnanl.c (__isnanl): Likewise. * sysdeps/ieee754/ldbl-128/s_issignalingl.c (__issignalingl): Likewise. * sysdeps/ieee754/ldbl-128/s_llrintl.c (__llrintl): Likewise. * sysdeps/ieee754/ldbl-128/s_llroundl.c (__llroundl): Likewise. * sysdeps/ieee754/ldbl-128/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-128/s_lroundl.c (__lroundl): Likewise. * sysdeps/ieee754/ldbl-128/s_modfl.c (__modfl): Likewise. * sysdeps/ieee754/ldbl-128/s_nearbyintl.c (__nearbyintl): Likewise. * sysdeps/ieee754/ldbl-128/s_nextafterl.c (__nextafterl): Likewise. * sysdeps/ieee754/ldbl-128/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/ieee754/ldbl-128/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-128/s_nextupl.c (__nextupl): Likewise. * sysdeps/ieee754/ldbl-128/s_remquol.c (__remquol): Likewise. * sysdeps/ieee754/ldbl-128/s_rintl.c (__rintl): Likewise. * sysdeps/ieee754/ldbl-128/s_roundl.c (__roundl): Likewise. * sysdeps/ieee754/ldbl-128/s_tanhl.c (__tanhl): Likewise. * sysdeps/ieee754/ldbl-128/s_truncl.c (__truncl): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_fmodl.c (__ieee754_fmodl): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (__ieee754_gammal_r): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_powl.c (__ieee754_powl): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_rem_pio2l.c (__ieee754_rem_pio2l): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_remainderl.c (__ieee754_remainderl): Likewise. * sysdeps/ieee754/ldbl-128ibm/k_cosl.c (__kernel_cosl): Likewise. * sysdeps/ieee754/ldbl-128ibm/k_sinl.c (__kernel_sinl): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_fabsl.c (__fabsl): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_fpclassifyl.c (___fpclassifyl): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_modfl.c (__modfl): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_remquol.c (__remquol): Likewise. * sysdeps/ieee754/ldbl-96/e_acoshl.c (__ieee754_acoshl): Likewise. * sysdeps/ieee754/ldbl-96/e_asinl.c (__ieee754_asinl): Likewise. * sysdeps/ieee754/ldbl-96/e_atanhl.c (__ieee754_atanhl): Likewise. * sysdeps/ieee754/ldbl-96/e_coshl.c (__ieee754_coshl): Likewise. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (__ieee754_gammal_r): Likewise. * sysdeps/ieee754/ldbl-96/e_hypotl.c (__ieee754_hypotl): Likewise. * sysdeps/ieee754/ldbl-96/e_j0l.c (__ieee754_j0l): Likewise. (__ieee754_y0l): Likewise. (pzero): Likewise. (qzero): Likewise. * sysdeps/ieee754/ldbl-96/e_j1l.c (__ieee754_j1l): Likewise. (__ieee754_y1l): Likewise. (pone): Likewise. (qone): Likewise. * sysdeps/ieee754/ldbl-96/e_jnl.c (__ieee754_jnl): Likewise. (__ieee754_ynl): Likewise. * sysdeps/ieee754/ldbl-96/e_lgammal_r.c (sin_pi): Likewise. (__ieee754_lgammal_r): Likewise. * sysdeps/ieee754/ldbl-96/e_rem_pio2l.c (__ieee754_rem_pio2l): Likewise. * sysdeps/ieee754/ldbl-96/e_sinhl.c (__ieee754_sinhl): Likewise. * sysdeps/ieee754/ldbl-96/s_copysignl.c (__copysignl): Likewise. * sysdeps/ieee754/ldbl-96/s_erfl.c (__erfl): Likewise. (__erfcl): Likewise. * sysdeps/ieee754/ldbl-96/s_frexpl.c (__frexpl): Likewise. * sysdeps/ieee754/ldbl-96/s_issignalingl.c (__issignalingl): Likewise. * sysdeps/ieee754/ldbl-96/s_llrintl.c (__llrintl): Likewise. * sysdeps/ieee754/ldbl-96/s_llroundl.c (__llroundl): Likewise. * sysdeps/ieee754/ldbl-96/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-96/s_lroundl.c (__lroundl): Likewise. * sysdeps/ieee754/ldbl-96/s_modfl.c (__modfl): Likewise. * sysdeps/ieee754/ldbl-96/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/ieee754/ldbl-96/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-96/s_nextupl.c (__nextupl): Likewise. * sysdeps/ieee754/ldbl-96/s_remquol.c (__remquol): Likewise. * sysdeps/ieee754/ldbl-96/s_roundl.c (__roundl): Likewise. * sysdeps/ieee754/ldbl-96/s_tanhl.c (__tanhl): Likewise. * sysdeps/ieee754/ldbl-opt/s_nexttowardfd.c (__nldbl_nexttowardf): Likewise. * sysdeps/m68k/m680x0/fpu/e_pow.c (s(__ieee754_pow)): Likewise. * sysdeps/m68k/m680x0/fpu/s_fpclassifyl.c (__fpclassifyl): Likewise. * sysdeps/m68k/m680x0/fpu/s_llrint.c (__llrint): Likewise. * sysdeps/m68k/m680x0/fpu/s_llrintf.c (__llrintf): Likewise. * sysdeps/m68k/m680x0/fpu/s_llrintl.c (__llrintl): Likewise. * sysdeps/m68k/m680x0/fpu/s_nextafterl.c (__nextafterl): Likewise. * sysdeps/x86/fpu/powl_helper.c (__powl_helper): Likewise.
2017-08-03 21:55:04 +02:00
uint32_t lx;
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
double ret;
Update. 1997-06-19 19:38 Ulrich Drepper <drepper@cygnus.com> * features.h: Define __STDC_IEC_559__ and _STDC_IEC_559_COMPLEX__. * elf/dl-minimal.c (__dcgettext): Remove assertion. * inet/rcmd.c: Correct a few typos. Reported by Eric Troan. * manual/Makefile (distribute): Add dir. * manual/dir: New file. * math/Makefile (libm-support): Rename s_rinttol, s_rinttoll, s_roundtol, and s_roundtoll to s_lrint, s_llrint, s_lround, and s_llround respectively. (libm-calls): Add e_gamma_r. * math/libm-test.c (check_int_exc): New function. (signbit_test): Remove test for sign of NaN. (gamma_test): Clear exception after test of existence. Correct tests and and epsilons. (lgamma_test): Likewise. (ilogb_test): Correct all tests. (scalb_test): Rewrite. (rinttol_test): Rename to lrint_test and correct tests. (rinttoll_test): Likewise. (roundtol_test): Likewise. (roundtoll_test): Likewise. (main): Call lrint/lround functions instead of rinttol/roundtol. * math/math.h: Change prototypes for rinttol/roundtol. * math/mathcalls.h: Rearrange prototypes according to ISO C9X draft. * sysdeps/generic/mathbits.h: Define FP_ILOGB0 and FP_ILOGBNAN. * sysdeps/i386/mathbits.h: Likewise. * sysdeps/libm-i387/e_scalb.S: Handle special cases correctly. * sysdeps/libm-i387/e_scalbf.S: Likewise. * sysdeps/libm-i387/e_scalbl.S: Likewise. * sysdeps/libm-i387/s_asinh.S: Handle -inf correctly. * sysdeps/libm-i387/s_asinhf.S: Likewise. * sysdeps/libm-i387/s_asinhl.S: Likewise. * sysdeps/libm-i387/s_ilogb.S: Optimize. * sysdeps/libm-i387/s_ilogbf.S: Likewise. * sysdeps/libm-i387/s_ilogbl.S: Likewise. * sysdeps/libm-i387/s_rinttol.S: Rename to... * sysdeps/libm-i387/s_lrint.S: ...this. * sysdeps/libm-i387/s_rinttoll.S: Rename to... * sysdeps/libm-i387/s_llrint.S: ...this. * sysdeps/libm-i387/s_remquo.S: Correctly set sign of remainder. * sysdeps/libm-i387/s_remquof.S: Likewise. * sysdeps/libm-i387/s_remquol.S: Likewise. * sysdeps/libm-i387/e_gamma_r.c: New file. Implementation of gamma function according to ISO C. * sysdeps/libm-i387/e_gammaf_r.c: New file. * sysdeps/libm-i387/e_gammal_r.c: New file. * sysdeps/libm-i387/e_lgamma_r.c: Don't let optimize compile the generation of exceptions away. * sysdeps/libm-i387/e_lgammaf_r.c: Likewise. * sysdeps/libm-i387/k_standard.c: Correct return value for infinity points of gamma function when not SVID mode. * sysdeps/libm-i387/s_rinttoll.c: Renamed to... * sysdeps/libm-i387/s_llrint.c: ...this. * sysdeps/libm-i387/s_rinttol.c: Renamed to... * sysdeps/libm-i387/s_lrint.c: ...this. * sysdeps/libm-i387/s_roundtoll.c: Renamed to... * sysdeps/libm-i387/s_llround.c: ...this. * sysdeps/libm-i387/s_roundtol.c: Renamed to... * sysdeps/libm-i387/s_lround.c: ..this. * sysdeps/libm-i387/s_scalbn.c: Change second parameter according to ISO C. * sysdeps/libm-i387/s_scalbnf.c: Likewise. * sysdeps/libm-i387/s_scalbnl.c: Likewise. * sysdeps/libm-i387/w_gamma.c: Call __ieee754_gamma_r if library mode is not _SVID_. * sysdeps/libm-i387/w_gammaf.c: Likewise. * sysdeps/libm-i387/w_gammal.c: Likewise. * sysdeps/m68k/fpu/__math.h: Rename __rinttol to __lrint and rinttol to lrint. * sysdeps/m68k/fpu/s_rinttol.c: Renamed to... * sysdeps/m68k/fpu/s_lrint.c: ...this. * sysdeps/m68k/fpu/s_rinttoll.c: Renamed to... * sysdeps/m68k/fpu/s_llrint.c: ...this. * md5-crypt/Makefile: Link md5test program with md5.o. * stdio-common/temptest.c: Don't use __stdio_gen_tempname which is not exported by the libc.so. * stdio-common/vfscanf.c: Correct scanning of strings after last change. * sysdeps/unix/sysv/linux/i386/sysdep.S: Use .comm to define errno. 1997-06-19 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * time/tzfile.c (__tzfile_read): Store getc () return in int. 1997-06-13 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (argp_version_parser): Include `(PROGRAM ERROR)' in the no-version error text to indicate that something's fucked. [!_] (N_): New macro. (argp_default_options, argp_version_options): Wrap doc strings in N_(). 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (parser_parse_opt): Detect and report unhandled options here. (parser_parse_arg): Handle ARGP_KEY_ARGS here. Adjust NEXT pointer back if we fail to parse anything. (parser_parse_next): Simplify arg code. Leave state NEXT frobbing to parser_parse_arg. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp.h (ARGP_KEY_ARGS, ARGP_KEY_FINI): New macros. * argp/argp-parse.c (parser_finalize): Do another pass over the parsers with ARGP_KEY_FINI. 1997-06-18 Miles Bader <miles@gnu.ai.mit.edu> * string/Makefile (routines): Add argz-replace. 1997-06-16 00:16 Miles Bader <miles@gnu.ai.mit.edu> * manual/string.texi (Argz Functions): Document argz_replace. 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * string/argz.h (__argz_replace, argz_replace): New declarations. * string/argz-replace.c: New file. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * manual/argp.texi (Argp Special Keys): Document ARGP_KEY_ARGS. 1997-06-16 23:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * Makeconfig (libc-map): Remove definition. * Makerules (libc-map): Define it here, using the full name. (load-map-file): Remove case for empty $(..). ($(common-objpfx)libc.so): Revert last change. 1997-06-17 22:18 Mark Kettenis <kettenis@phys.uva.nl> * login/programs/utmpd.c (main): Improve signal handling. * login/programs/request.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/utmpd.h (setutent_request, updwtmp_request): Get rid of fixed length file field. * login/utmp_daemon.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/request.c (do_pututline): Don't fail if connection->position is -1 on entry. 1997-06-15 16:32 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (updwtmp_file): Use the same method for appending an entry as in pututline_file. 1997-06-11 18:59 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (getutent_r_file): Use read lock instead of write lock. (getutline_r_file, internal_getut_r): Lock utmp file. (updwtmp_file): Use fcntl to lock file instead of flock. 1997-06-18 00:11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * stdio-common/vfscanf.c (inchar, ungetc): Don't count EOF as character read in/put back. * stdio-common/tstscanf.c: Add test case for this. 1997-06-17 22:17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * libc.map: Add more symbols. 1997-06-18 12:01 Ulrich Drepper <drepper@cygnus.com> * manual/Makefile (install): Make sure `dir' file exists if we use install-info. 1997-06-17 19:32 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * manual/Makefile (info): Depend on dir-add.info. 1997-06-17 17:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/ldd.bash.in: Fix spacing in message. 1997-06-17 14:28 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/do-rel.h (elf_dynamic_do_rel): Always use version information if available. 1997-06-17 11:34 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sunrpc/Makefile ($(rpcsvc:%.x=$(objpfx)rpcsvc/%.h)): Make command non-empty to force make to recheck modification time. ($(rpcsvc:%.x=$(objpfx)x%.c)): Likewise. 1997-06-17 00:26 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/stub/e_acoshl.c: Set errno to ENOSYS. * sysdeps/stub/e_acosl.c: Likewise. * sysdeps/stub/e_asinl.c: Likewise. * sysdeps/stub/e_atan2l.c: Likewise. * sysdeps/stub/e_expl.c: Likewise. * sysdeps/stub/e_fmodl.c: Likewise. * sysdeps/stub/e_j0l.c: Likewise. * sysdeps/stub/e_j1l.c: Likewise. * sysdeps/stub/e_jnl.c: Likewise. * sysdeps/stub/e_lgammal_r.c: Likewise. * sysdeps/stub/e_log10l.c: Likewise. * sysdeps/stub/e_logl.c: Likewise. * sysdeps/stub/e_powl.c: Likewise. * sysdeps/stub/e_rem_pio2l.c: Likewise. * sysdeps/stub/e_sqrtl.c: Likewise. * sysdeps/stub/k_cosl.c: Likewise. * sysdeps/stub/k_rem_pio2l.c: Likewise. * sysdeps/stub/k_sinl.c: Likewise. * sysdeps/stub/k_tanl.c: Likewise. * sysdeps/stub/s_atanl.c: Likewise. * sysdeps/stub/s_erfl.c: Likewise. * sysdeps/stub/s_exp2.c: Likewise. * sysdeps/stub/s_exp2f.c: Likewise. * sysdeps/stub/s_exp2l.c: Likewise. * sysdeps/stub/s_expm1l.c: Likewise. * sysdeps/stub/s_log1pl.c: Likewise. * sysdeps/stub/s_log2l.c: Likewise. 1997-06-18 11:46 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/w_gamma.c: If _LIB_VERSION is _SVID_ compute result as before last change. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. 1997-06-16 23:37 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/libm-ieee754/s_remquo.c: Fix off-by-one when computing quotient. * sysdeps/libm-ieee754/s_remquof.c: Likewise. * sysdeps/libm-ieee754/s_remquol.c: Likewise. * sysdeps/m68k/fpu/s_remquo.c: Remove FIXME and special case for quotient. * sysdeps/libm-ieee754/w_gamma.c: Add missing call to exp function. Don't use global signgam. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. * math/Makefile (libm-calls): Remove w_gamma_r. * sysdeps/libm-ieee754/w_gamma_r.c: Remove file. * sysdeps/libm-ieee754/w_gammaf_r.c: Remove file. * sysdeps/libm-ieee754/w_gammal_r.c: Remove file. * math/libm-test.c (atanh_test): Declare x only if needed. (signbit_test): Fix typo. (gamma_test): Check whether function is implemented. Add epsilons. (lgamma_test): Likewise. (fmod_test): Add epsilons. (exp2_test): Use right function for existence test. 1997-06-07 09:20 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/powerpc/Dist: Add fenv_const.c. * sysdeps/unix/sysv/linux/Dist: Add net/if_slip.h. * sysdeps/unix/sysv/linux/powerpc/Dist: Add init-first.h and syscall.h. * sysdeps/unix/sysv/linux/sparc/Dist: Add init-first.h. * string/Makefile (distribute): Add tst-svc.expect. * nis/Makefile (distribute): Add nis_intern.h and Banner. * elf/Makefile (distribute): Add dl-hash.h. * Rules (subdir_echo-distinfo): Add headers from $(distribute). * login/Makefile (others): Add utmpdump. * sysdeps/unix/sysv/linux/Makefile (sysdep_headers): Add net/if_slip.h. * manual/Makefile (dir-add.texi): Also look in indirectly included files. 1997-06-16 23:15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/configure.in: Remove commands to generate stdio_lim.h. * sysdeps/unix/sysv/linux/mk-stdiolim.c: Remove. * sysdeps/unix/sysv/linux/Makefile: Add rules to generate stdio_lim.h here. (common-generated): Add generated files. (inhibit-stdio_lim): Define. * sysdeps/posix/Makefile [$(inhibit-stdio_lim)=yes]: Disable rules to generate stdio_lim.h. * sysdeps/unix/sysv/linux/Makefile: Suppress inclusion of dependecy files if no_deps is set. ($(objpfx)syscall-%.d): Add header file as target to dependency generation. 1997-06-14 19:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/arm/Dist: New file. 1997-06-14 17:59 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * extra-lib.mk (others): Depend on versioned shared library, not the unversioned one. * Makerules (build-shlib): Don't make the version link here. ($(common-objpfx)libc.so$(libc.so-version)): New rule for libc version link. 1997-06-16 03:07 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/k_standard.c: Undo change of Tue Aug 6 01:13:56 1996. * argp/argp-help.c (argp_args_usage): Supply correct argp to filter_doc. * argp/argp-help.c (hol_add_cluster): Initialize CL->depth. * argp/argp-help.c (_help): Supply STATE to argp_args_usage. * argp/argp.h (ARGP_KEY_HELP_ARGS_DOC): New macro. * argp/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp.h (OPTION_NO_USAGE): New macro. * argp/argp-help.c (usage_long_opt, usage_argful_short_opt, * argp/argp-fmtstream.c (__argp_fmtstream_update): Account for case * argp/argp-help.c <stddef.h>: New include. * argp/argp.h (argp_state_help, __argp_state_help, argp_usage, * argp/argp.h (argp_program_bug_address): Make const. * argp/argp-parse.c (argp_default_parser): Set STATE->name for OPT_PROGNAME. * argp/argp-help.c (__argp_error, __argp_failure, __argp_state_help): * argp/argp-parse.c (parser_init): Set PARSER->state.flags.
1997-06-19 21:11:22 +02:00
EXTRACT_WORDS (hx, lx, x);
if (__glibc_unlikely (((hx & 0x7fffffff) | lx) == 0))
{
/* Return value for x == 0 is Inf with divide by zero exception. */
*signgamp = 0;
return 1.0 / x;
}
if (__builtin_expect (hx < 0, 0)
Use rint functions not __rint functions in glibc libm. Continuing the move to use, within libm, public names for libm functions that can be inlined as built-in functions on many architectures, this patch moves calls to __rint functions to call the corresponding rint names instead, with asm redirection to __rint when the calls are not inlined. The x86_64 math_private.h is removed as no longer useful after this patch. This patch is relative to a tree with my floor patch <https://sourceware.org/ml/libc-alpha/2018-09/msg00148.html> applied, and much the same considerations arise regarding possibly replacing an IFUNC call with a direct inline expansion. Tested for x86_64, and with build-many-glibcs.py. * include/math.h [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (rint): Redirect using MATH_REDIRECT. * sysdeps/aarch64/fpu/s_rint.c: Define NO_MATH_REDIRECT before header inclusion. * sysdeps/aarch64/fpu/s_rintf.c: Likewise. * sysdeps/alpha/fpu/s_rint.c: Likewise. * sysdeps/alpha/fpu/s_rintf.c: Likewise. * sysdeps/i386/fpu/s_rintl.c: Likewise. * sysdeps/ieee754/dbl-64/s_rint.c: Likewise. * sysdeps/ieee754/dbl-64/wordsize-64/s_rint.c: Likewise. * sysdeps/ieee754/float128/s_rintf128.c: Likewise. * sysdeps/ieee754/flt-32/s_rintf.c: Likewise. * sysdeps/ieee754/ldbl-128/s_rintl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_rintl.c: Likewise. * sysdeps/m68k/coldfire/fpu/s_rint.c: Likewise. * sysdeps/m68k/coldfire/fpu/s_rintf.c: Likewise. * sysdeps/m68k/m680x0/fpu/s_rint.c: Likewise. * sysdeps/m68k/m680x0/fpu/s_rintf.c: Likewise. * sysdeps/m68k/m680x0/fpu/s_rintl.c: Likewise. * sysdeps/powerpc/fpu/s_rint.c: Likewise. * sysdeps/powerpc/fpu/s_rintf.c: Likewise. * sysdeps/riscv/rv64/rvd/s_rint.c: Likewise. * sysdeps/riscv/rvf/s_rintf.c: Likewise. * sysdeps/sparc/sparc32/sparcv9/fpu/multiarch/s_rint.c: Likewise. * sysdeps/sparc/sparc32/sparcv9/fpu/multiarch/s_rintf.c: Likewise. * sysdeps/sparc/sparc64/fpu/multiarch/s_rint.c: Likewise. * sysdeps/sparc/sparc64/fpu/multiarch/s_rintf.c: Likewise. * sysdeps/x86_64/fpu/multiarch/s_rint.c: Likewise. * sysdeps/x86_64/fpu/multiarch/s_rintf.c: Likewise. * sysdeps/x86_64/fpu/math_private.h: Remove file. * math/e_scalb.c (invalid_fn): Use rint functions instead of __rint variants. * math/e_scalbf.c (invalid_fn): Likewise. * math/e_scalbl.c (invalid_fn): Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c (__ieee754_gamma_r): Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c (__ieee754_gammaf_r): Likewise. * sysdeps/ieee754/k_standard.c (__kernel_standard): Likewise. * sysdeps/ieee754/k_standardl.c (__kernel_standard_l): Likewise. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (__ieee754_gammal_r): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (__ieee754_gammal_r): Likewise. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (__ieee754_gammal_r): Likewise. * sysdeps/powerpc/powerpc32/fpu/s_llrint.c (__llrint): Likewise. * sysdeps/powerpc/powerpc32/fpu/s_llrintf.c (__llrintf): Likewise.
2018-09-14 15:10:39 +02:00
&& (uint32_t) hx < 0xfff00000 && rint (x) == x)
Update. 1997-06-19 19:38 Ulrich Drepper <drepper@cygnus.com> * features.h: Define __STDC_IEC_559__ and _STDC_IEC_559_COMPLEX__. * elf/dl-minimal.c (__dcgettext): Remove assertion. * inet/rcmd.c: Correct a few typos. Reported by Eric Troan. * manual/Makefile (distribute): Add dir. * manual/dir: New file. * math/Makefile (libm-support): Rename s_rinttol, s_rinttoll, s_roundtol, and s_roundtoll to s_lrint, s_llrint, s_lround, and s_llround respectively. (libm-calls): Add e_gamma_r. * math/libm-test.c (check_int_exc): New function. (signbit_test): Remove test for sign of NaN. (gamma_test): Clear exception after test of existence. Correct tests and and epsilons. (lgamma_test): Likewise. (ilogb_test): Correct all tests. (scalb_test): Rewrite. (rinttol_test): Rename to lrint_test and correct tests. (rinttoll_test): Likewise. (roundtol_test): Likewise. (roundtoll_test): Likewise. (main): Call lrint/lround functions instead of rinttol/roundtol. * math/math.h: Change prototypes for rinttol/roundtol. * math/mathcalls.h: Rearrange prototypes according to ISO C9X draft. * sysdeps/generic/mathbits.h: Define FP_ILOGB0 and FP_ILOGBNAN. * sysdeps/i386/mathbits.h: Likewise. * sysdeps/libm-i387/e_scalb.S: Handle special cases correctly. * sysdeps/libm-i387/e_scalbf.S: Likewise. * sysdeps/libm-i387/e_scalbl.S: Likewise. * sysdeps/libm-i387/s_asinh.S: Handle -inf correctly. * sysdeps/libm-i387/s_asinhf.S: Likewise. * sysdeps/libm-i387/s_asinhl.S: Likewise. * sysdeps/libm-i387/s_ilogb.S: Optimize. * sysdeps/libm-i387/s_ilogbf.S: Likewise. * sysdeps/libm-i387/s_ilogbl.S: Likewise. * sysdeps/libm-i387/s_rinttol.S: Rename to... * sysdeps/libm-i387/s_lrint.S: ...this. * sysdeps/libm-i387/s_rinttoll.S: Rename to... * sysdeps/libm-i387/s_llrint.S: ...this. * sysdeps/libm-i387/s_remquo.S: Correctly set sign of remainder. * sysdeps/libm-i387/s_remquof.S: Likewise. * sysdeps/libm-i387/s_remquol.S: Likewise. * sysdeps/libm-i387/e_gamma_r.c: New file. Implementation of gamma function according to ISO C. * sysdeps/libm-i387/e_gammaf_r.c: New file. * sysdeps/libm-i387/e_gammal_r.c: New file. * sysdeps/libm-i387/e_lgamma_r.c: Don't let optimize compile the generation of exceptions away. * sysdeps/libm-i387/e_lgammaf_r.c: Likewise. * sysdeps/libm-i387/k_standard.c: Correct return value for infinity points of gamma function when not SVID mode. * sysdeps/libm-i387/s_rinttoll.c: Renamed to... * sysdeps/libm-i387/s_llrint.c: ...this. * sysdeps/libm-i387/s_rinttol.c: Renamed to... * sysdeps/libm-i387/s_lrint.c: ...this. * sysdeps/libm-i387/s_roundtoll.c: Renamed to... * sysdeps/libm-i387/s_llround.c: ...this. * sysdeps/libm-i387/s_roundtol.c: Renamed to... * sysdeps/libm-i387/s_lround.c: ..this. * sysdeps/libm-i387/s_scalbn.c: Change second parameter according to ISO C. * sysdeps/libm-i387/s_scalbnf.c: Likewise. * sysdeps/libm-i387/s_scalbnl.c: Likewise. * sysdeps/libm-i387/w_gamma.c: Call __ieee754_gamma_r if library mode is not _SVID_. * sysdeps/libm-i387/w_gammaf.c: Likewise. * sysdeps/libm-i387/w_gammal.c: Likewise. * sysdeps/m68k/fpu/__math.h: Rename __rinttol to __lrint and rinttol to lrint. * sysdeps/m68k/fpu/s_rinttol.c: Renamed to... * sysdeps/m68k/fpu/s_lrint.c: ...this. * sysdeps/m68k/fpu/s_rinttoll.c: Renamed to... * sysdeps/m68k/fpu/s_llrint.c: ...this. * md5-crypt/Makefile: Link md5test program with md5.o. * stdio-common/temptest.c: Don't use __stdio_gen_tempname which is not exported by the libc.so. * stdio-common/vfscanf.c: Correct scanning of strings after last change. * sysdeps/unix/sysv/linux/i386/sysdep.S: Use .comm to define errno. 1997-06-19 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * time/tzfile.c (__tzfile_read): Store getc () return in int. 1997-06-13 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (argp_version_parser): Include `(PROGRAM ERROR)' in the no-version error text to indicate that something's fucked. [!_] (N_): New macro. (argp_default_options, argp_version_options): Wrap doc strings in N_(). 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (parser_parse_opt): Detect and report unhandled options here. (parser_parse_arg): Handle ARGP_KEY_ARGS here. Adjust NEXT pointer back if we fail to parse anything. (parser_parse_next): Simplify arg code. Leave state NEXT frobbing to parser_parse_arg. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp.h (ARGP_KEY_ARGS, ARGP_KEY_FINI): New macros. * argp/argp-parse.c (parser_finalize): Do another pass over the parsers with ARGP_KEY_FINI. 1997-06-18 Miles Bader <miles@gnu.ai.mit.edu> * string/Makefile (routines): Add argz-replace. 1997-06-16 00:16 Miles Bader <miles@gnu.ai.mit.edu> * manual/string.texi (Argz Functions): Document argz_replace. 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * string/argz.h (__argz_replace, argz_replace): New declarations. * string/argz-replace.c: New file. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * manual/argp.texi (Argp Special Keys): Document ARGP_KEY_ARGS. 1997-06-16 23:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * Makeconfig (libc-map): Remove definition. * Makerules (libc-map): Define it here, using the full name. (load-map-file): Remove case for empty $(..). ($(common-objpfx)libc.so): Revert last change. 1997-06-17 22:18 Mark Kettenis <kettenis@phys.uva.nl> * login/programs/utmpd.c (main): Improve signal handling. * login/programs/request.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/utmpd.h (setutent_request, updwtmp_request): Get rid of fixed length file field. * login/utmp_daemon.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/request.c (do_pututline): Don't fail if connection->position is -1 on entry. 1997-06-15 16:32 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (updwtmp_file): Use the same method for appending an entry as in pututline_file. 1997-06-11 18:59 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (getutent_r_file): Use read lock instead of write lock. (getutline_r_file, internal_getut_r): Lock utmp file. (updwtmp_file): Use fcntl to lock file instead of flock. 1997-06-18 00:11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * stdio-common/vfscanf.c (inchar, ungetc): Don't count EOF as character read in/put back. * stdio-common/tstscanf.c: Add test case for this. 1997-06-17 22:17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * libc.map: Add more symbols. 1997-06-18 12:01 Ulrich Drepper <drepper@cygnus.com> * manual/Makefile (install): Make sure `dir' file exists if we use install-info. 1997-06-17 19:32 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * manual/Makefile (info): Depend on dir-add.info. 1997-06-17 17:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/ldd.bash.in: Fix spacing in message. 1997-06-17 14:28 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/do-rel.h (elf_dynamic_do_rel): Always use version information if available. 1997-06-17 11:34 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sunrpc/Makefile ($(rpcsvc:%.x=$(objpfx)rpcsvc/%.h)): Make command non-empty to force make to recheck modification time. ($(rpcsvc:%.x=$(objpfx)x%.c)): Likewise. 1997-06-17 00:26 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/stub/e_acoshl.c: Set errno to ENOSYS. * sysdeps/stub/e_acosl.c: Likewise. * sysdeps/stub/e_asinl.c: Likewise. * sysdeps/stub/e_atan2l.c: Likewise. * sysdeps/stub/e_expl.c: Likewise. * sysdeps/stub/e_fmodl.c: Likewise. * sysdeps/stub/e_j0l.c: Likewise. * sysdeps/stub/e_j1l.c: Likewise. * sysdeps/stub/e_jnl.c: Likewise. * sysdeps/stub/e_lgammal_r.c: Likewise. * sysdeps/stub/e_log10l.c: Likewise. * sysdeps/stub/e_logl.c: Likewise. * sysdeps/stub/e_powl.c: Likewise. * sysdeps/stub/e_rem_pio2l.c: Likewise. * sysdeps/stub/e_sqrtl.c: Likewise. * sysdeps/stub/k_cosl.c: Likewise. * sysdeps/stub/k_rem_pio2l.c: Likewise. * sysdeps/stub/k_sinl.c: Likewise. * sysdeps/stub/k_tanl.c: Likewise. * sysdeps/stub/s_atanl.c: Likewise. * sysdeps/stub/s_erfl.c: Likewise. * sysdeps/stub/s_exp2.c: Likewise. * sysdeps/stub/s_exp2f.c: Likewise. * sysdeps/stub/s_exp2l.c: Likewise. * sysdeps/stub/s_expm1l.c: Likewise. * sysdeps/stub/s_log1pl.c: Likewise. * sysdeps/stub/s_log2l.c: Likewise. 1997-06-18 11:46 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/w_gamma.c: If _LIB_VERSION is _SVID_ compute result as before last change. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. 1997-06-16 23:37 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/libm-ieee754/s_remquo.c: Fix off-by-one when computing quotient. * sysdeps/libm-ieee754/s_remquof.c: Likewise. * sysdeps/libm-ieee754/s_remquol.c: Likewise. * sysdeps/m68k/fpu/s_remquo.c: Remove FIXME and special case for quotient. * sysdeps/libm-ieee754/w_gamma.c: Add missing call to exp function. Don't use global signgam. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. * math/Makefile (libm-calls): Remove w_gamma_r. * sysdeps/libm-ieee754/w_gamma_r.c: Remove file. * sysdeps/libm-ieee754/w_gammaf_r.c: Remove file. * sysdeps/libm-ieee754/w_gammal_r.c: Remove file. * math/libm-test.c (atanh_test): Declare x only if needed. (signbit_test): Fix typo. (gamma_test): Check whether function is implemented. Add epsilons. (lgamma_test): Likewise. (fmod_test): Add epsilons. (exp2_test): Use right function for existence test. 1997-06-07 09:20 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/powerpc/Dist: Add fenv_const.c. * sysdeps/unix/sysv/linux/Dist: Add net/if_slip.h. * sysdeps/unix/sysv/linux/powerpc/Dist: Add init-first.h and syscall.h. * sysdeps/unix/sysv/linux/sparc/Dist: Add init-first.h. * string/Makefile (distribute): Add tst-svc.expect. * nis/Makefile (distribute): Add nis_intern.h and Banner. * elf/Makefile (distribute): Add dl-hash.h. * Rules (subdir_echo-distinfo): Add headers from $(distribute). * login/Makefile (others): Add utmpdump. * sysdeps/unix/sysv/linux/Makefile (sysdep_headers): Add net/if_slip.h. * manual/Makefile (dir-add.texi): Also look in indirectly included files. 1997-06-16 23:15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/configure.in: Remove commands to generate stdio_lim.h. * sysdeps/unix/sysv/linux/mk-stdiolim.c: Remove. * sysdeps/unix/sysv/linux/Makefile: Add rules to generate stdio_lim.h here. (common-generated): Add generated files. (inhibit-stdio_lim): Define. * sysdeps/posix/Makefile [$(inhibit-stdio_lim)=yes]: Disable rules to generate stdio_lim.h. * sysdeps/unix/sysv/linux/Makefile: Suppress inclusion of dependecy files if no_deps is set. ($(objpfx)syscall-%.d): Add header file as target to dependency generation. 1997-06-14 19:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/arm/Dist: New file. 1997-06-14 17:59 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * extra-lib.mk (others): Depend on versioned shared library, not the unversioned one. * Makerules (build-shlib): Don't make the version link here. ($(common-objpfx)libc.so$(libc.so-version)): New rule for libc version link. 1997-06-16 03:07 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/k_standard.c: Undo change of Tue Aug 6 01:13:56 1996. * argp/argp-help.c (argp_args_usage): Supply correct argp to filter_doc. * argp/argp-help.c (hol_add_cluster): Initialize CL->depth. * argp/argp-help.c (_help): Supply STATE to argp_args_usage. * argp/argp.h (ARGP_KEY_HELP_ARGS_DOC): New macro. * argp/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp.h (OPTION_NO_USAGE): New macro. * argp/argp-help.c (usage_long_opt, usage_argful_short_opt, * argp/argp-fmtstream.c (__argp_fmtstream_update): Account for case * argp/argp-help.c <stddef.h>: New include. * argp/argp.h (argp_state_help, __argp_state_help, argp_usage, * argp/argp.h (argp_program_bug_address): Make const. * argp/argp-parse.c (argp_default_parser): Set STATE->name for OPT_PROGNAME. * argp/argp-help.c (__argp_error, __argp_failure, __argp_state_help): * argp/argp-parse.c (parser_init): Set PARSER->state.flags.
1997-06-19 21:11:22 +02:00
{
/* Return value for integer x < 0 is NaN with invalid exception. */
*signgamp = 0;
Update. 1997-06-19 19:38 Ulrich Drepper <drepper@cygnus.com> * features.h: Define __STDC_IEC_559__ and _STDC_IEC_559_COMPLEX__. * elf/dl-minimal.c (__dcgettext): Remove assertion. * inet/rcmd.c: Correct a few typos. Reported by Eric Troan. * manual/Makefile (distribute): Add dir. * manual/dir: New file. * math/Makefile (libm-support): Rename s_rinttol, s_rinttoll, s_roundtol, and s_roundtoll to s_lrint, s_llrint, s_lround, and s_llround respectively. (libm-calls): Add e_gamma_r. * math/libm-test.c (check_int_exc): New function. (signbit_test): Remove test for sign of NaN. (gamma_test): Clear exception after test of existence. Correct tests and and epsilons. (lgamma_test): Likewise. (ilogb_test): Correct all tests. (scalb_test): Rewrite. (rinttol_test): Rename to lrint_test and correct tests. (rinttoll_test): Likewise. (roundtol_test): Likewise. (roundtoll_test): Likewise. (main): Call lrint/lround functions instead of rinttol/roundtol. * math/math.h: Change prototypes for rinttol/roundtol. * math/mathcalls.h: Rearrange prototypes according to ISO C9X draft. * sysdeps/generic/mathbits.h: Define FP_ILOGB0 and FP_ILOGBNAN. * sysdeps/i386/mathbits.h: Likewise. * sysdeps/libm-i387/e_scalb.S: Handle special cases correctly. * sysdeps/libm-i387/e_scalbf.S: Likewise. * sysdeps/libm-i387/e_scalbl.S: Likewise. * sysdeps/libm-i387/s_asinh.S: Handle -inf correctly. * sysdeps/libm-i387/s_asinhf.S: Likewise. * sysdeps/libm-i387/s_asinhl.S: Likewise. * sysdeps/libm-i387/s_ilogb.S: Optimize. * sysdeps/libm-i387/s_ilogbf.S: Likewise. * sysdeps/libm-i387/s_ilogbl.S: Likewise. * sysdeps/libm-i387/s_rinttol.S: Rename to... * sysdeps/libm-i387/s_lrint.S: ...this. * sysdeps/libm-i387/s_rinttoll.S: Rename to... * sysdeps/libm-i387/s_llrint.S: ...this. * sysdeps/libm-i387/s_remquo.S: Correctly set sign of remainder. * sysdeps/libm-i387/s_remquof.S: Likewise. * sysdeps/libm-i387/s_remquol.S: Likewise. * sysdeps/libm-i387/e_gamma_r.c: New file. Implementation of gamma function according to ISO C. * sysdeps/libm-i387/e_gammaf_r.c: New file. * sysdeps/libm-i387/e_gammal_r.c: New file. * sysdeps/libm-i387/e_lgamma_r.c: Don't let optimize compile the generation of exceptions away. * sysdeps/libm-i387/e_lgammaf_r.c: Likewise. * sysdeps/libm-i387/k_standard.c: Correct return value for infinity points of gamma function when not SVID mode. * sysdeps/libm-i387/s_rinttoll.c: Renamed to... * sysdeps/libm-i387/s_llrint.c: ...this. * sysdeps/libm-i387/s_rinttol.c: Renamed to... * sysdeps/libm-i387/s_lrint.c: ...this. * sysdeps/libm-i387/s_roundtoll.c: Renamed to... * sysdeps/libm-i387/s_llround.c: ...this. * sysdeps/libm-i387/s_roundtol.c: Renamed to... * sysdeps/libm-i387/s_lround.c: ..this. * sysdeps/libm-i387/s_scalbn.c: Change second parameter according to ISO C. * sysdeps/libm-i387/s_scalbnf.c: Likewise. * sysdeps/libm-i387/s_scalbnl.c: Likewise. * sysdeps/libm-i387/w_gamma.c: Call __ieee754_gamma_r if library mode is not _SVID_. * sysdeps/libm-i387/w_gammaf.c: Likewise. * sysdeps/libm-i387/w_gammal.c: Likewise. * sysdeps/m68k/fpu/__math.h: Rename __rinttol to __lrint and rinttol to lrint. * sysdeps/m68k/fpu/s_rinttol.c: Renamed to... * sysdeps/m68k/fpu/s_lrint.c: ...this. * sysdeps/m68k/fpu/s_rinttoll.c: Renamed to... * sysdeps/m68k/fpu/s_llrint.c: ...this. * md5-crypt/Makefile: Link md5test program with md5.o. * stdio-common/temptest.c: Don't use __stdio_gen_tempname which is not exported by the libc.so. * stdio-common/vfscanf.c: Correct scanning of strings after last change. * sysdeps/unix/sysv/linux/i386/sysdep.S: Use .comm to define errno. 1997-06-19 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * time/tzfile.c (__tzfile_read): Store getc () return in int. 1997-06-13 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (argp_version_parser): Include `(PROGRAM ERROR)' in the no-version error text to indicate that something's fucked. [!_] (N_): New macro. (argp_default_options, argp_version_options): Wrap doc strings in N_(). 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (parser_parse_opt): Detect and report unhandled options here. (parser_parse_arg): Handle ARGP_KEY_ARGS here. Adjust NEXT pointer back if we fail to parse anything. (parser_parse_next): Simplify arg code. Leave state NEXT frobbing to parser_parse_arg. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp.h (ARGP_KEY_ARGS, ARGP_KEY_FINI): New macros. * argp/argp-parse.c (parser_finalize): Do another pass over the parsers with ARGP_KEY_FINI. 1997-06-18 Miles Bader <miles@gnu.ai.mit.edu> * string/Makefile (routines): Add argz-replace. 1997-06-16 00:16 Miles Bader <miles@gnu.ai.mit.edu> * manual/string.texi (Argz Functions): Document argz_replace. 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * string/argz.h (__argz_replace, argz_replace): New declarations. * string/argz-replace.c: New file. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * manual/argp.texi (Argp Special Keys): Document ARGP_KEY_ARGS. 1997-06-16 23:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * Makeconfig (libc-map): Remove definition. * Makerules (libc-map): Define it here, using the full name. (load-map-file): Remove case for empty $(..). ($(common-objpfx)libc.so): Revert last change. 1997-06-17 22:18 Mark Kettenis <kettenis@phys.uva.nl> * login/programs/utmpd.c (main): Improve signal handling. * login/programs/request.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/utmpd.h (setutent_request, updwtmp_request): Get rid of fixed length file field. * login/utmp_daemon.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/request.c (do_pututline): Don't fail if connection->position is -1 on entry. 1997-06-15 16:32 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (updwtmp_file): Use the same method for appending an entry as in pututline_file. 1997-06-11 18:59 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (getutent_r_file): Use read lock instead of write lock. (getutline_r_file, internal_getut_r): Lock utmp file. (updwtmp_file): Use fcntl to lock file instead of flock. 1997-06-18 00:11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * stdio-common/vfscanf.c (inchar, ungetc): Don't count EOF as character read in/put back. * stdio-common/tstscanf.c: Add test case for this. 1997-06-17 22:17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * libc.map: Add more symbols. 1997-06-18 12:01 Ulrich Drepper <drepper@cygnus.com> * manual/Makefile (install): Make sure `dir' file exists if we use install-info. 1997-06-17 19:32 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * manual/Makefile (info): Depend on dir-add.info. 1997-06-17 17:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/ldd.bash.in: Fix spacing in message. 1997-06-17 14:28 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/do-rel.h (elf_dynamic_do_rel): Always use version information if available. 1997-06-17 11:34 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sunrpc/Makefile ($(rpcsvc:%.x=$(objpfx)rpcsvc/%.h)): Make command non-empty to force make to recheck modification time. ($(rpcsvc:%.x=$(objpfx)x%.c)): Likewise. 1997-06-17 00:26 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/stub/e_acoshl.c: Set errno to ENOSYS. * sysdeps/stub/e_acosl.c: Likewise. * sysdeps/stub/e_asinl.c: Likewise. * sysdeps/stub/e_atan2l.c: Likewise. * sysdeps/stub/e_expl.c: Likewise. * sysdeps/stub/e_fmodl.c: Likewise. * sysdeps/stub/e_j0l.c: Likewise. * sysdeps/stub/e_j1l.c: Likewise. * sysdeps/stub/e_jnl.c: Likewise. * sysdeps/stub/e_lgammal_r.c: Likewise. * sysdeps/stub/e_log10l.c: Likewise. * sysdeps/stub/e_logl.c: Likewise. * sysdeps/stub/e_powl.c: Likewise. * sysdeps/stub/e_rem_pio2l.c: Likewise. * sysdeps/stub/e_sqrtl.c: Likewise. * sysdeps/stub/k_cosl.c: Likewise. * sysdeps/stub/k_rem_pio2l.c: Likewise. * sysdeps/stub/k_sinl.c: Likewise. * sysdeps/stub/k_tanl.c: Likewise. * sysdeps/stub/s_atanl.c: Likewise. * sysdeps/stub/s_erfl.c: Likewise. * sysdeps/stub/s_exp2.c: Likewise. * sysdeps/stub/s_exp2f.c: Likewise. * sysdeps/stub/s_exp2l.c: Likewise. * sysdeps/stub/s_expm1l.c: Likewise. * sysdeps/stub/s_log1pl.c: Likewise. * sysdeps/stub/s_log2l.c: Likewise. 1997-06-18 11:46 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/w_gamma.c: If _LIB_VERSION is _SVID_ compute result as before last change. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. 1997-06-16 23:37 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/libm-ieee754/s_remquo.c: Fix off-by-one when computing quotient. * sysdeps/libm-ieee754/s_remquof.c: Likewise. * sysdeps/libm-ieee754/s_remquol.c: Likewise. * sysdeps/m68k/fpu/s_remquo.c: Remove FIXME and special case for quotient. * sysdeps/libm-ieee754/w_gamma.c: Add missing call to exp function. Don't use global signgam. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. * math/Makefile (libm-calls): Remove w_gamma_r. * sysdeps/libm-ieee754/w_gamma_r.c: Remove file. * sysdeps/libm-ieee754/w_gammaf_r.c: Remove file. * sysdeps/libm-ieee754/w_gammal_r.c: Remove file. * math/libm-test.c (atanh_test): Declare x only if needed. (signbit_test): Fix typo. (gamma_test): Check whether function is implemented. Add epsilons. (lgamma_test): Likewise. (fmod_test): Add epsilons. (exp2_test): Use right function for existence test. 1997-06-07 09:20 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/powerpc/Dist: Add fenv_const.c. * sysdeps/unix/sysv/linux/Dist: Add net/if_slip.h. * sysdeps/unix/sysv/linux/powerpc/Dist: Add init-first.h and syscall.h. * sysdeps/unix/sysv/linux/sparc/Dist: Add init-first.h. * string/Makefile (distribute): Add tst-svc.expect. * nis/Makefile (distribute): Add nis_intern.h and Banner. * elf/Makefile (distribute): Add dl-hash.h. * Rules (subdir_echo-distinfo): Add headers from $(distribute). * login/Makefile (others): Add utmpdump. * sysdeps/unix/sysv/linux/Makefile (sysdep_headers): Add net/if_slip.h. * manual/Makefile (dir-add.texi): Also look in indirectly included files. 1997-06-16 23:15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/configure.in: Remove commands to generate stdio_lim.h. * sysdeps/unix/sysv/linux/mk-stdiolim.c: Remove. * sysdeps/unix/sysv/linux/Makefile: Add rules to generate stdio_lim.h here. (common-generated): Add generated files. (inhibit-stdio_lim): Define. * sysdeps/posix/Makefile [$(inhibit-stdio_lim)=yes]: Disable rules to generate stdio_lim.h. * sysdeps/unix/sysv/linux/Makefile: Suppress inclusion of dependecy files if no_deps is set. ($(objpfx)syscall-%.d): Add header file as target to dependency generation. 1997-06-14 19:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/arm/Dist: New file. 1997-06-14 17:59 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * extra-lib.mk (others): Depend on versioned shared library, not the unversioned one. * Makerules (build-shlib): Don't make the version link here. ($(common-objpfx)libc.so$(libc.so-version)): New rule for libc version link. 1997-06-16 03:07 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/k_standard.c: Undo change of Tue Aug 6 01:13:56 1996. * argp/argp-help.c (argp_args_usage): Supply correct argp to filter_doc. * argp/argp-help.c (hol_add_cluster): Initialize CL->depth. * argp/argp-help.c (_help): Supply STATE to argp_args_usage. * argp/argp.h (ARGP_KEY_HELP_ARGS_DOC): New macro. * argp/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp.h (OPTION_NO_USAGE): New macro. * argp/argp-help.c (usage_long_opt, usage_argful_short_opt, * argp/argp-fmtstream.c (__argp_fmtstream_update): Account for case * argp/argp-help.c <stddef.h>: New include. * argp/argp.h (argp_state_help, __argp_state_help, argp_usage, * argp/argp.h (argp_program_bug_address): Make const. * argp/argp-parse.c (argp_default_parser): Set STATE->name for OPT_PROGNAME. * argp/argp-help.c (__argp_error, __argp_failure, __argp_state_help): * argp/argp-parse.c (parser_init): Set PARSER->state.flags.
1997-06-19 21:11:22 +02:00
return (x - x) / (x - x);
}
if (__glibc_unlikely ((unsigned int) hx == 0xfff00000 && lx == 0))
{
/* x == -Inf. According to ISO this is NaN. */
*signgamp = 0;
return x - x;
}
if (__glibc_unlikely ((hx & 0x7ff00000) == 0x7ff00000))
{
/* Positive infinity (return positive infinity) or NaN (return
NaN). */
*signgamp = 0;
return x + x;
}
Update. 1997-06-19 19:38 Ulrich Drepper <drepper@cygnus.com> * features.h: Define __STDC_IEC_559__ and _STDC_IEC_559_COMPLEX__. * elf/dl-minimal.c (__dcgettext): Remove assertion. * inet/rcmd.c: Correct a few typos. Reported by Eric Troan. * manual/Makefile (distribute): Add dir. * manual/dir: New file. * math/Makefile (libm-support): Rename s_rinttol, s_rinttoll, s_roundtol, and s_roundtoll to s_lrint, s_llrint, s_lround, and s_llround respectively. (libm-calls): Add e_gamma_r. * math/libm-test.c (check_int_exc): New function. (signbit_test): Remove test for sign of NaN. (gamma_test): Clear exception after test of existence. Correct tests and and epsilons. (lgamma_test): Likewise. (ilogb_test): Correct all tests. (scalb_test): Rewrite. (rinttol_test): Rename to lrint_test and correct tests. (rinttoll_test): Likewise. (roundtol_test): Likewise. (roundtoll_test): Likewise. (main): Call lrint/lround functions instead of rinttol/roundtol. * math/math.h: Change prototypes for rinttol/roundtol. * math/mathcalls.h: Rearrange prototypes according to ISO C9X draft. * sysdeps/generic/mathbits.h: Define FP_ILOGB0 and FP_ILOGBNAN. * sysdeps/i386/mathbits.h: Likewise. * sysdeps/libm-i387/e_scalb.S: Handle special cases correctly. * sysdeps/libm-i387/e_scalbf.S: Likewise. * sysdeps/libm-i387/e_scalbl.S: Likewise. * sysdeps/libm-i387/s_asinh.S: Handle -inf correctly. * sysdeps/libm-i387/s_asinhf.S: Likewise. * sysdeps/libm-i387/s_asinhl.S: Likewise. * sysdeps/libm-i387/s_ilogb.S: Optimize. * sysdeps/libm-i387/s_ilogbf.S: Likewise. * sysdeps/libm-i387/s_ilogbl.S: Likewise. * sysdeps/libm-i387/s_rinttol.S: Rename to... * sysdeps/libm-i387/s_lrint.S: ...this. * sysdeps/libm-i387/s_rinttoll.S: Rename to... * sysdeps/libm-i387/s_llrint.S: ...this. * sysdeps/libm-i387/s_remquo.S: Correctly set sign of remainder. * sysdeps/libm-i387/s_remquof.S: Likewise. * sysdeps/libm-i387/s_remquol.S: Likewise. * sysdeps/libm-i387/e_gamma_r.c: New file. Implementation of gamma function according to ISO C. * sysdeps/libm-i387/e_gammaf_r.c: New file. * sysdeps/libm-i387/e_gammal_r.c: New file. * sysdeps/libm-i387/e_lgamma_r.c: Don't let optimize compile the generation of exceptions away. * sysdeps/libm-i387/e_lgammaf_r.c: Likewise. * sysdeps/libm-i387/k_standard.c: Correct return value for infinity points of gamma function when not SVID mode. * sysdeps/libm-i387/s_rinttoll.c: Renamed to... * sysdeps/libm-i387/s_llrint.c: ...this. * sysdeps/libm-i387/s_rinttol.c: Renamed to... * sysdeps/libm-i387/s_lrint.c: ...this. * sysdeps/libm-i387/s_roundtoll.c: Renamed to... * sysdeps/libm-i387/s_llround.c: ...this. * sysdeps/libm-i387/s_roundtol.c: Renamed to... * sysdeps/libm-i387/s_lround.c: ..this. * sysdeps/libm-i387/s_scalbn.c: Change second parameter according to ISO C. * sysdeps/libm-i387/s_scalbnf.c: Likewise. * sysdeps/libm-i387/s_scalbnl.c: Likewise. * sysdeps/libm-i387/w_gamma.c: Call __ieee754_gamma_r if library mode is not _SVID_. * sysdeps/libm-i387/w_gammaf.c: Likewise. * sysdeps/libm-i387/w_gammal.c: Likewise. * sysdeps/m68k/fpu/__math.h: Rename __rinttol to __lrint and rinttol to lrint. * sysdeps/m68k/fpu/s_rinttol.c: Renamed to... * sysdeps/m68k/fpu/s_lrint.c: ...this. * sysdeps/m68k/fpu/s_rinttoll.c: Renamed to... * sysdeps/m68k/fpu/s_llrint.c: ...this. * md5-crypt/Makefile: Link md5test program with md5.o. * stdio-common/temptest.c: Don't use __stdio_gen_tempname which is not exported by the libc.so. * stdio-common/vfscanf.c: Correct scanning of strings after last change. * sysdeps/unix/sysv/linux/i386/sysdep.S: Use .comm to define errno. 1997-06-19 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * time/tzfile.c (__tzfile_read): Store getc () return in int. 1997-06-13 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (argp_version_parser): Include `(PROGRAM ERROR)' in the no-version error text to indicate that something's fucked. [!_] (N_): New macro. (argp_default_options, argp_version_options): Wrap doc strings in N_(). 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (parser_parse_opt): Detect and report unhandled options here. (parser_parse_arg): Handle ARGP_KEY_ARGS here. Adjust NEXT pointer back if we fail to parse anything. (parser_parse_next): Simplify arg code. Leave state NEXT frobbing to parser_parse_arg. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp.h (ARGP_KEY_ARGS, ARGP_KEY_FINI): New macros. * argp/argp-parse.c (parser_finalize): Do another pass over the parsers with ARGP_KEY_FINI. 1997-06-18 Miles Bader <miles@gnu.ai.mit.edu> * string/Makefile (routines): Add argz-replace. 1997-06-16 00:16 Miles Bader <miles@gnu.ai.mit.edu> * manual/string.texi (Argz Functions): Document argz_replace. 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * string/argz.h (__argz_replace, argz_replace): New declarations. * string/argz-replace.c: New file. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * manual/argp.texi (Argp Special Keys): Document ARGP_KEY_ARGS. 1997-06-16 23:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * Makeconfig (libc-map): Remove definition. * Makerules (libc-map): Define it here, using the full name. (load-map-file): Remove case for empty $(..). ($(common-objpfx)libc.so): Revert last change. 1997-06-17 22:18 Mark Kettenis <kettenis@phys.uva.nl> * login/programs/utmpd.c (main): Improve signal handling. * login/programs/request.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/utmpd.h (setutent_request, updwtmp_request): Get rid of fixed length file field. * login/utmp_daemon.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/request.c (do_pututline): Don't fail if connection->position is -1 on entry. 1997-06-15 16:32 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (updwtmp_file): Use the same method for appending an entry as in pututline_file. 1997-06-11 18:59 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (getutent_r_file): Use read lock instead of write lock. (getutline_r_file, internal_getut_r): Lock utmp file. (updwtmp_file): Use fcntl to lock file instead of flock. 1997-06-18 00:11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * stdio-common/vfscanf.c (inchar, ungetc): Don't count EOF as character read in/put back. * stdio-common/tstscanf.c: Add test case for this. 1997-06-17 22:17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * libc.map: Add more symbols. 1997-06-18 12:01 Ulrich Drepper <drepper@cygnus.com> * manual/Makefile (install): Make sure `dir' file exists if we use install-info. 1997-06-17 19:32 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * manual/Makefile (info): Depend on dir-add.info. 1997-06-17 17:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/ldd.bash.in: Fix spacing in message. 1997-06-17 14:28 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/do-rel.h (elf_dynamic_do_rel): Always use version information if available. 1997-06-17 11:34 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sunrpc/Makefile ($(rpcsvc:%.x=$(objpfx)rpcsvc/%.h)): Make command non-empty to force make to recheck modification time. ($(rpcsvc:%.x=$(objpfx)x%.c)): Likewise. 1997-06-17 00:26 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/stub/e_acoshl.c: Set errno to ENOSYS. * sysdeps/stub/e_acosl.c: Likewise. * sysdeps/stub/e_asinl.c: Likewise. * sysdeps/stub/e_atan2l.c: Likewise. * sysdeps/stub/e_expl.c: Likewise. * sysdeps/stub/e_fmodl.c: Likewise. * sysdeps/stub/e_j0l.c: Likewise. * sysdeps/stub/e_j1l.c: Likewise. * sysdeps/stub/e_jnl.c: Likewise. * sysdeps/stub/e_lgammal_r.c: Likewise. * sysdeps/stub/e_log10l.c: Likewise. * sysdeps/stub/e_logl.c: Likewise. * sysdeps/stub/e_powl.c: Likewise. * sysdeps/stub/e_rem_pio2l.c: Likewise. * sysdeps/stub/e_sqrtl.c: Likewise. * sysdeps/stub/k_cosl.c: Likewise. * sysdeps/stub/k_rem_pio2l.c: Likewise. * sysdeps/stub/k_sinl.c: Likewise. * sysdeps/stub/k_tanl.c: Likewise. * sysdeps/stub/s_atanl.c: Likewise. * sysdeps/stub/s_erfl.c: Likewise. * sysdeps/stub/s_exp2.c: Likewise. * sysdeps/stub/s_exp2f.c: Likewise. * sysdeps/stub/s_exp2l.c: Likewise. * sysdeps/stub/s_expm1l.c: Likewise. * sysdeps/stub/s_log1pl.c: Likewise. * sysdeps/stub/s_log2l.c: Likewise. 1997-06-18 11:46 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/w_gamma.c: If _LIB_VERSION is _SVID_ compute result as before last change. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. 1997-06-16 23:37 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/libm-ieee754/s_remquo.c: Fix off-by-one when computing quotient. * sysdeps/libm-ieee754/s_remquof.c: Likewise. * sysdeps/libm-ieee754/s_remquol.c: Likewise. * sysdeps/m68k/fpu/s_remquo.c: Remove FIXME and special case for quotient. * sysdeps/libm-ieee754/w_gamma.c: Add missing call to exp function. Don't use global signgam. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. * math/Makefile (libm-calls): Remove w_gamma_r. * sysdeps/libm-ieee754/w_gamma_r.c: Remove file. * sysdeps/libm-ieee754/w_gammaf_r.c: Remove file. * sysdeps/libm-ieee754/w_gammal_r.c: Remove file. * math/libm-test.c (atanh_test): Declare x only if needed. (signbit_test): Fix typo. (gamma_test): Check whether function is implemented. Add epsilons. (lgamma_test): Likewise. (fmod_test): Add epsilons. (exp2_test): Use right function for existence test. 1997-06-07 09:20 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/powerpc/Dist: Add fenv_const.c. * sysdeps/unix/sysv/linux/Dist: Add net/if_slip.h. * sysdeps/unix/sysv/linux/powerpc/Dist: Add init-first.h and syscall.h. * sysdeps/unix/sysv/linux/sparc/Dist: Add init-first.h. * string/Makefile (distribute): Add tst-svc.expect. * nis/Makefile (distribute): Add nis_intern.h and Banner. * elf/Makefile (distribute): Add dl-hash.h. * Rules (subdir_echo-distinfo): Add headers from $(distribute). * login/Makefile (others): Add utmpdump. * sysdeps/unix/sysv/linux/Makefile (sysdep_headers): Add net/if_slip.h. * manual/Makefile (dir-add.texi): Also look in indirectly included files. 1997-06-16 23:15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/configure.in: Remove commands to generate stdio_lim.h. * sysdeps/unix/sysv/linux/mk-stdiolim.c: Remove. * sysdeps/unix/sysv/linux/Makefile: Add rules to generate stdio_lim.h here. (common-generated): Add generated files. (inhibit-stdio_lim): Define. * sysdeps/posix/Makefile [$(inhibit-stdio_lim)=yes]: Disable rules to generate stdio_lim.h. * sysdeps/unix/sysv/linux/Makefile: Suppress inclusion of dependecy files if no_deps is set. ($(objpfx)syscall-%.d): Add header file as target to dependency generation. 1997-06-14 19:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/arm/Dist: New file. 1997-06-14 17:59 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * extra-lib.mk (others): Depend on versioned shared library, not the unversioned one. * Makerules (build-shlib): Don't make the version link here. ($(common-objpfx)libc.so$(libc.so-version)): New rule for libc version link. 1997-06-16 03:07 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/k_standard.c: Undo change of Tue Aug 6 01:13:56 1996. * argp/argp-help.c (argp_args_usage): Supply correct argp to filter_doc. * argp/argp-help.c (hol_add_cluster): Initialize CL->depth. * argp/argp-help.c (_help): Supply STATE to argp_args_usage. * argp/argp.h (ARGP_KEY_HELP_ARGS_DOC): New macro. * argp/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp.h (OPTION_NO_USAGE): New macro. * argp/argp-help.c (usage_long_opt, usage_argful_short_opt, * argp/argp-fmtstream.c (__argp_fmtstream_update): Account for case * argp/argp-help.c <stddef.h>: New include. * argp/argp.h (argp_state_help, __argp_state_help, argp_usage, * argp/argp.h (argp_program_bug_address): Make const. * argp/argp-parse.c (argp_default_parser): Set STATE->name for OPT_PROGNAME. * argp/argp-help.c (__argp_error, __argp_failure, __argp_state_help): * argp/argp-parse.c (parser_init): Set PARSER->state.flags.
1997-06-19 21:11:22 +02:00
if (x >= 172.0)
{
/* Overflow. */
*signgamp = 0;
Use math_narrow_eval more consistently. Where glibc code needs to avoid excess range and precision in floating-point arithmetic, code variously uses either asms or volatile to force the results of that arithmetic to memory; mostly this is conditional on FLT_EVAL_METHOD, but in the case of lrint / llrint functions some use of volatile is unconditional (and is present unnecessarily in versions for long double). This patch make such code use the recently-added math_narrow_eval macro consistently, removing the unnecessary uses of volatile in long double lrint / llrint implementations completely. Tested for x86_64, x86, mips64 and powerpc. * math/s_nexttowardf.c (__nexttowardf): Use math_narrow_eval. * stdlib/strtod_l.c: Include <math_private.h>. (overflow_value): Use math_narrow_eval. (underflow_value): Likewise. * sysdeps/i386/fpu/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/i386/fpu/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Likewise. (__ieee754_gamma_r): Likewise. * sysdeps/ieee754/dbl-64/gamma_productf.c (__gamma_productf): Likewise. * sysdeps/ieee754/dbl-64/k_rem_pio2.c (__kernel_rem_pio2): Likewise. * sysdeps/ieee754/dbl-64/lgamma_neg.c (__lgamma_neg): Likewise. * sysdeps/ieee754/dbl-64/s_erf.c (__erfc): Likewise. * sysdeps/ieee754/dbl-64/s_llrint.c (__llrint): Likewise. * sysdeps/ieee754/dbl-64/s_lrint.c (__lrint): Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Likewise. (__ieee754_gammaf_r): Likewise. * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f): Likewise. * sysdeps/ieee754/flt-32/lgamma_negf.c (__lgamma_negf): Likewise. * sysdeps/ieee754/flt-32/s_erff.c (__erfcf): Likewise. * sysdeps/ieee754/flt-32/s_llrintf.c (__llrintf): Likewise. * sysdeps/ieee754/flt-32/s_lrintf.c (__lrintf): Likewise. * sysdeps/ieee754/ldbl-128/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-128/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-128/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-128ibm/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-96/gamma_product.c (__gamma_product): Likewise. * sysdeps/ieee754/ldbl-96/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-96/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-96/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-96/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-opt/s_nexttowardfd.c (__nldbl_nexttowardf): Likewise.
2015-09-23 20:14:57 +02:00
ret = math_narrow_eval (DBL_MAX * DBL_MAX);
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
return ret;
}
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
else
{
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
SET_RESTORE_ROUND (FE_TONEAREST);
if (x > 0.0)
{
*signgamp = 0;
int exp2_adj;
double tret = gamma_positive (x, &exp2_adj);
ret = __scalbn (tret, exp2_adj);
}
else if (x >= -DBL_EPSILON / 4.0)
{
*signgamp = 0;
ret = 1.0 / x;
}
else
{
double tx = __trunc (x);
*signgamp = (tx == 2.0 * __trunc (tx / 2.0)) ? -1 : 1;
if (x <= -184.0)
/* Underflow. */
ret = DBL_MIN * DBL_MIN;
else
{
double frac = tx - x;
if (frac > 0.5)
frac = 1.0 - frac;
double sinpix = (frac <= 0.25
? __sin (M_PI * frac)
: __cos (M_PI * (0.5 - frac)));
int exp2_adj;
double tret = M_PI / (-x * sinpix
* gamma_positive (-x, &exp2_adj));
ret = __scalbn (tret, -exp2_adj);
Refactor code forcing underflow exceptions. Various floating-point functions have code to force underflow exceptions if a tiny result was computed in a way that might not have resulted in such exceptions even though the result is inexact. This typically uses math_force_eval to ensure that the underflowing expression is evaluated, but sometimes uses volatile. This patch refactors such code to use three new macros math_check_force_underflow, math_check_force_underflow_nonneg and math_check_force_underflow_complex (which in turn use math_force_eval). In the limited number of cases not suited to a simple conversion to these macros, existing uses of volatile are changed to use math_force_eval instead. The converted code does not always execute exactly the same sequence of operations as the original code, but the overall effects should be the same. Tested for x86_64, x86, mips64 and powerpc. * sysdeps/generic/math_private.h (fabs_tg): New macro. (min_of_type): Likewise. (math_check_force_underflow): Likewise. (math_check_force_underflow_nonneg): Likewise. (math_check_force_underflow_complex): Likewise. * math/e_exp2l.c (__ieee754_exp2l): Use math_check_force_underflow_nonneg. * math/k_casinh.c (__kernel_casinh): Likewise. * math/k_casinhf.c (__kernel_casinhf): Likewise. * math/k_casinhl.c (__kernel_casinhl): Likewise. * math/s_catan.c (__catan): Use math_check_force_underflow_complex. * math/s_catanf.c (__catanf): Likewise. * math/s_catanh.c (__catanh): Likewise. * math/s_catanhf.c (__catanhf): Likewise. * math/s_catanhl.c (__catanhl): Likewise. * math/s_catanl.c (__catanl): Likewise. * math/s_ccosh.c (__ccosh): Likewise. * math/s_ccoshf.c (__ccoshf): Likewise. * math/s_ccoshl.c (__ccoshl): Likewise. * math/s_cexp.c (__cexp): Likewise. * math/s_cexpf.c (__cexpf): Likewise. * math/s_cexpl.c (__cexpl): Likewise. * math/s_clog.c (__clog): Use math_check_force_underflow_nonneg. * math/s_clog10.c (__clog10): Likewise. * math/s_clog10f.c (__clog10f): Likewise. * math/s_clog10l.c (__clog10l): Likewise. * math/s_clogf.c (__clogf): Likewise. * math/s_clogl.c (__clogl): Likewise. * math/s_csin.c (__csin): Use math_check_force_underflow_complex. * math/s_csinf.c (__csinf): Likewise. * math/s_csinh.c (__csinh): Likewise. * math/s_csinhf.c (__csinhf): Likewise. * math/s_csinhl.c (__csinhl): Likewise. * math/s_csinl.c (__csinl): Likewise. * math/s_csqrt.c (__csqrt): Use math_check_force_underflow. * math/s_csqrtf.c (__csqrtf): Likewise. * math/s_csqrtl.c (__csqrtl): Likewise. * math/s_ctan.c (__ctan): Use math_check_force_underflow_complex. * math/s_ctanf.c (__ctanf): Likewise. * math/s_ctanh.c (__ctanh): Likewise. * math/s_ctanhf.c (__ctanhf): Likewise. * math/s_ctanhl.c (__ctanhl): Likewise. * math/s_ctanl.c (__ctanl): Likewise. * stdlib/strtod_l.c (round_and_return): Use math_force_eval instead of volatile. * sysdeps/ieee754/dbl-64/e_asin.c (__ieee754_asin): Use math_check_force_underflow. * sysdeps/ieee754/dbl-64/e_atanh.c (__ieee754_atanh): Likewise. * sysdeps/ieee754/dbl-64/e_exp.c (__ieee754_exp): Do not use volatile when forcing underflow. * sysdeps/ieee754/dbl-64/e_exp2.c (__ieee754_exp2): Use math_check_force_underflow_nonneg. * sysdeps/ieee754/dbl-64/e_gamma_r.c (__ieee754_gamma_r): Likewise. * sysdeps/ieee754/dbl-64/e_j1.c (__ieee754_j1): Use math_check_force_underflow. * sysdeps/ieee754/dbl-64/e_jn.c (__ieee754_jn): Likewise. * sysdeps/ieee754/dbl-64/e_sinh.c (__ieee754_sinh): Likewise. * sysdeps/ieee754/dbl-64/s_asinh.c (__asinh): Likewise. * sysdeps/ieee754/dbl-64/s_atan.c (atan): Use math_check_force_underflow_nonneg. * sysdeps/ieee754/dbl-64/s_erf.c (__erf): Use math_check_force_underflow. * sysdeps/ieee754/dbl-64/s_expm1.c (__expm1): Likewise. * sysdeps/ieee754/dbl-64/s_fma.c (__fma): Use math_force_eval instead of volatile. * sysdeps/ieee754/dbl-64/s_log1p.c (__log1p): Use math_check_force_underflow. * sysdeps/ieee754/dbl-64/s_sin.c (__sin): Likewise. * sysdeps/ieee754/dbl-64/s_tan.c (tan): Use math_check_force_underflow_nonneg. * sysdeps/ieee754/dbl-64/s_tanh.c (__tanh): Use math_check_force_underflow. * sysdeps/ieee754/flt-32/e_asinf.c (__ieee754_asinf): Likewise. * sysdeps/ieee754/flt-32/e_atanhf.c (__ieee754_atanhf): Likewise. * sysdeps/ieee754/flt-32/e_exp2f.c (__ieee754_exp2f): Use math_check_force_underflow_nonneg. * sysdeps/ieee754/flt-32/e_gammaf_r.c (__ieee754_gammaf_r): Likewise. * sysdeps/ieee754/flt-32/e_j1f.c (__ieee754_j1f): Use math_check_force_underflow. * sysdeps/ieee754/flt-32/e_jnf.c (__ieee754_jnf): Likewise. * sysdeps/ieee754/flt-32/e_sinhf.c (__ieee754_sinhf): Likewise. * sysdeps/ieee754/flt-32/k_sinf.c (__kernel_sinf): Likewise. * sysdeps/ieee754/flt-32/k_tanf.c (__kernel_tanf): Likewise. * sysdeps/ieee754/flt-32/s_asinhf.c (__asinhf): Likewise. * sysdeps/ieee754/flt-32/s_atanf.c (__atanf): Likewise. * sysdeps/ieee754/flt-32/s_erff.c (__erff): Likewise. * sysdeps/ieee754/flt-32/s_expm1f.c (__expm1f): Likewise. * sysdeps/ieee754/flt-32/s_log1pf.c (__log1pf): Likewise. * sysdeps/ieee754/flt-32/s_tanhf.c (__tanhf): Likewise. * sysdeps/ieee754/ldbl-128/e_asinl.c (__ieee754_asinl): Likewise. * sysdeps/ieee754/ldbl-128/e_atanhl.c (__ieee754_atanhl): Likewise. * sysdeps/ieee754/ldbl-128/e_expl.c (__ieee754_expl): Use math_check_force_underflow_nonneg. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (__ieee754_gammal_r): Likewise. * sysdeps/ieee754/ldbl-128/e_j1l.c (__ieee754_j1l): Use math_check_force_underflow. * sysdeps/ieee754/ldbl-128/e_jnl.c (__ieee754_jnl): Likewise. * sysdeps/ieee754/ldbl-128/e_sinhl.c (__ieee754_sinhl): Likewise. * sysdeps/ieee754/ldbl-128/k_sincosl.c (__kernel_sincosl): Likewise. * sysdeps/ieee754/ldbl-128/k_sinl.c (__kernel_sinl): Likewise. * sysdeps/ieee754/ldbl-128/k_tanl.c (__kernel_tanl): Likewise. * sysdeps/ieee754/ldbl-128/s_asinhl.c (__asinhl): Likewise. * sysdeps/ieee754/ldbl-128/s_atanl.c (__atanl): Likewise. * sysdeps/ieee754/ldbl-128/s_erfl.c (__erfl): Likewise. * sysdeps/ieee754/ldbl-128/s_expm1l.c (__expm1l): Likewise. * sysdeps/ieee754/ldbl-128/s_fmal.c (__fmal): Use math_force_eval instead of volatile. * sysdeps/ieee754/ldbl-128/s_log1pl.c (__log1pl): Use math_check_force_underflow. * sysdeps/ieee754/ldbl-128/s_tanhl.c (__tanhl): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_asinl.c (__ieee754_asinl): Use math_check_force_underflow. * sysdeps/ieee754/ldbl-128ibm/e_atanhl.c (__ieee754_atanhl): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (__ieee754_gammal_r): Use math_check_force_underflow_nonneg. * sysdeps/ieee754/ldbl-128ibm/e_jnl.c (__ieee754_jnl): Use math_check_force_underflow. * sysdeps/ieee754/ldbl-128ibm/e_sinhl.c (__ieee754_sinhl): Likewise. * sysdeps/ieee754/ldbl-128ibm/k_sincosl.c (__kernel_sincosl): Likewise. * sysdeps/ieee754/ldbl-128ibm/k_sinl.c (__kernel_sinl): Likewise. * sysdeps/ieee754/ldbl-128ibm/k_tanl.c (__kernel_tanl): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_asinhl.c (__asinhl): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_atanl.c (__atanl): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_erfl.c (__erfl): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_tanhl.c (__tanhl): Likewise. * sysdeps/ieee754/ldbl-96/e_asinl.c (__ieee754_asinl): Likewise. * sysdeps/ieee754/ldbl-96/e_atanhl.c (__ieee754_atanhl): Likewise. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (__ieee754_gammal_r): Use math_check_force_underflow_nonneg. * sysdeps/ieee754/ldbl-96/e_j1l.c (__ieee754_j1l): Use math_check_force_underflow. * sysdeps/ieee754/ldbl-96/e_jnl.c (__ieee754_jnl): Likewise. * sysdeps/ieee754/ldbl-96/e_sinhl.c (__ieee754_sinhl): Likewise. * sysdeps/ieee754/ldbl-96/k_sinl.c (__kernel_sinl): Likewise. * sysdeps/ieee754/ldbl-96/k_tanl.c (__kernel_tanl): Use math_check_force_underflow_nonneg. * sysdeps/ieee754/ldbl-96/s_asinhl.c (__asinhl): Use math_check_force_underflow. * sysdeps/ieee754/ldbl-96/s_erfl.c (__erfl): Likewise. * sysdeps/ieee754/ldbl-96/s_fmal.c (__fmal): Use math_force_eval instead of volatile. * sysdeps/ieee754/ldbl-96/s_tanhl.c (__tanhl): Use math_check_force_underflow.
2015-09-24 00:42:30 +02:00
math_check_force_underflow_nonneg (ret);
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
}
}
Use math_narrow_eval more consistently. Where glibc code needs to avoid excess range and precision in floating-point arithmetic, code variously uses either asms or volatile to force the results of that arithmetic to memory; mostly this is conditional on FLT_EVAL_METHOD, but in the case of lrint / llrint functions some use of volatile is unconditional (and is present unnecessarily in versions for long double). This patch make such code use the recently-added math_narrow_eval macro consistently, removing the unnecessary uses of volatile in long double lrint / llrint implementations completely. Tested for x86_64, x86, mips64 and powerpc. * math/s_nexttowardf.c (__nexttowardf): Use math_narrow_eval. * stdlib/strtod_l.c: Include <math_private.h>. (overflow_value): Use math_narrow_eval. (underflow_value): Likewise. * sysdeps/i386/fpu/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/i386/fpu/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Likewise. (__ieee754_gamma_r): Likewise. * sysdeps/ieee754/dbl-64/gamma_productf.c (__gamma_productf): Likewise. * sysdeps/ieee754/dbl-64/k_rem_pio2.c (__kernel_rem_pio2): Likewise. * sysdeps/ieee754/dbl-64/lgamma_neg.c (__lgamma_neg): Likewise. * sysdeps/ieee754/dbl-64/s_erf.c (__erfc): Likewise. * sysdeps/ieee754/dbl-64/s_llrint.c (__llrint): Likewise. * sysdeps/ieee754/dbl-64/s_lrint.c (__lrint): Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Likewise. (__ieee754_gammaf_r): Likewise. * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f): Likewise. * sysdeps/ieee754/flt-32/lgamma_negf.c (__lgamma_negf): Likewise. * sysdeps/ieee754/flt-32/s_erff.c (__erfcf): Likewise. * sysdeps/ieee754/flt-32/s_llrintf.c (__llrintf): Likewise. * sysdeps/ieee754/flt-32/s_lrintf.c (__lrintf): Likewise. * sysdeps/ieee754/ldbl-128/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-128/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-128/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-128ibm/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-96/gamma_product.c (__gamma_product): Likewise. * sysdeps/ieee754/ldbl-96/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-96/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-96/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-96/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-opt/s_nexttowardfd.c (__nldbl_nexttowardf): Likewise.
2015-09-23 20:14:57 +02:00
ret = math_narrow_eval (ret);
}
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
if (isinf (ret) && x != 0)
{
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
if (*signgamp < 0)
{
Use math_narrow_eval more consistently. Where glibc code needs to avoid excess range and precision in floating-point arithmetic, code variously uses either asms or volatile to force the results of that arithmetic to memory; mostly this is conditional on FLT_EVAL_METHOD, but in the case of lrint / llrint functions some use of volatile is unconditional (and is present unnecessarily in versions for long double). This patch make such code use the recently-added math_narrow_eval macro consistently, removing the unnecessary uses of volatile in long double lrint / llrint implementations completely. Tested for x86_64, x86, mips64 and powerpc. * math/s_nexttowardf.c (__nexttowardf): Use math_narrow_eval. * stdlib/strtod_l.c: Include <math_private.h>. (overflow_value): Use math_narrow_eval. (underflow_value): Likewise. * sysdeps/i386/fpu/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/i386/fpu/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Likewise. (__ieee754_gamma_r): Likewise. * sysdeps/ieee754/dbl-64/gamma_productf.c (__gamma_productf): Likewise. * sysdeps/ieee754/dbl-64/k_rem_pio2.c (__kernel_rem_pio2): Likewise. * sysdeps/ieee754/dbl-64/lgamma_neg.c (__lgamma_neg): Likewise. * sysdeps/ieee754/dbl-64/s_erf.c (__erfc): Likewise. * sysdeps/ieee754/dbl-64/s_llrint.c (__llrint): Likewise. * sysdeps/ieee754/dbl-64/s_lrint.c (__lrint): Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Likewise. (__ieee754_gammaf_r): Likewise. * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f): Likewise. * sysdeps/ieee754/flt-32/lgamma_negf.c (__lgamma_negf): Likewise. * sysdeps/ieee754/flt-32/s_erff.c (__erfcf): Likewise. * sysdeps/ieee754/flt-32/s_llrintf.c (__llrintf): Likewise. * sysdeps/ieee754/flt-32/s_lrintf.c (__lrintf): Likewise. * sysdeps/ieee754/ldbl-128/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-128/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-128/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-128ibm/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-96/gamma_product.c (__gamma_product): Likewise. * sysdeps/ieee754/ldbl-96/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-96/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-96/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-96/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-opt/s_nexttowardfd.c (__nldbl_nexttowardf): Likewise.
2015-09-23 20:14:57 +02:00
ret = math_narrow_eval (-__copysign (DBL_MAX, ret) * DBL_MAX);
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
ret = -ret;
}
else
Use math_narrow_eval more consistently. Where glibc code needs to avoid excess range and precision in floating-point arithmetic, code variously uses either asms or volatile to force the results of that arithmetic to memory; mostly this is conditional on FLT_EVAL_METHOD, but in the case of lrint / llrint functions some use of volatile is unconditional (and is present unnecessarily in versions for long double). This patch make such code use the recently-added math_narrow_eval macro consistently, removing the unnecessary uses of volatile in long double lrint / llrint implementations completely. Tested for x86_64, x86, mips64 and powerpc. * math/s_nexttowardf.c (__nexttowardf): Use math_narrow_eval. * stdlib/strtod_l.c: Include <math_private.h>. (overflow_value): Use math_narrow_eval. (underflow_value): Likewise. * sysdeps/i386/fpu/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/i386/fpu/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Likewise. (__ieee754_gamma_r): Likewise. * sysdeps/ieee754/dbl-64/gamma_productf.c (__gamma_productf): Likewise. * sysdeps/ieee754/dbl-64/k_rem_pio2.c (__kernel_rem_pio2): Likewise. * sysdeps/ieee754/dbl-64/lgamma_neg.c (__lgamma_neg): Likewise. * sysdeps/ieee754/dbl-64/s_erf.c (__erfc): Likewise. * sysdeps/ieee754/dbl-64/s_llrint.c (__llrint): Likewise. * sysdeps/ieee754/dbl-64/s_lrint.c (__lrint): Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Likewise. (__ieee754_gammaf_r): Likewise. * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f): Likewise. * sysdeps/ieee754/flt-32/lgamma_negf.c (__lgamma_negf): Likewise. * sysdeps/ieee754/flt-32/s_erff.c (__erfcf): Likewise. * sysdeps/ieee754/flt-32/s_llrintf.c (__llrintf): Likewise. * sysdeps/ieee754/flt-32/s_lrintf.c (__lrintf): Likewise. * sysdeps/ieee754/ldbl-128/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-128/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-128/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-128ibm/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-96/gamma_product.c (__gamma_product): Likewise. * sysdeps/ieee754/ldbl-96/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-96/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-96/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-96/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-opt/s_nexttowardfd.c (__nldbl_nexttowardf): Likewise.
2015-09-23 20:14:57 +02:00
ret = math_narrow_eval (__copysign (DBL_MAX, ret) * DBL_MAX);
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
return ret;
}
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
else if (ret == 0)
{
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
if (*signgamp < 0)
{
Use math_narrow_eval more consistently. Where glibc code needs to avoid excess range and precision in floating-point arithmetic, code variously uses either asms or volatile to force the results of that arithmetic to memory; mostly this is conditional on FLT_EVAL_METHOD, but in the case of lrint / llrint functions some use of volatile is unconditional (and is present unnecessarily in versions for long double). This patch make such code use the recently-added math_narrow_eval macro consistently, removing the unnecessary uses of volatile in long double lrint / llrint implementations completely. Tested for x86_64, x86, mips64 and powerpc. * math/s_nexttowardf.c (__nexttowardf): Use math_narrow_eval. * stdlib/strtod_l.c: Include <math_private.h>. (overflow_value): Use math_narrow_eval. (underflow_value): Likewise. * sysdeps/i386/fpu/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/i386/fpu/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Likewise. (__ieee754_gamma_r): Likewise. * sysdeps/ieee754/dbl-64/gamma_productf.c (__gamma_productf): Likewise. * sysdeps/ieee754/dbl-64/k_rem_pio2.c (__kernel_rem_pio2): Likewise. * sysdeps/ieee754/dbl-64/lgamma_neg.c (__lgamma_neg): Likewise. * sysdeps/ieee754/dbl-64/s_erf.c (__erfc): Likewise. * sysdeps/ieee754/dbl-64/s_llrint.c (__llrint): Likewise. * sysdeps/ieee754/dbl-64/s_lrint.c (__lrint): Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Likewise. (__ieee754_gammaf_r): Likewise. * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f): Likewise. * sysdeps/ieee754/flt-32/lgamma_negf.c (__lgamma_negf): Likewise. * sysdeps/ieee754/flt-32/s_erff.c (__erfcf): Likewise. * sysdeps/ieee754/flt-32/s_llrintf.c (__llrintf): Likewise. * sysdeps/ieee754/flt-32/s_lrintf.c (__lrintf): Likewise. * sysdeps/ieee754/ldbl-128/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-128/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-128/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-128ibm/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-96/gamma_product.c (__gamma_product): Likewise. * sysdeps/ieee754/ldbl-96/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-96/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-96/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-96/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-opt/s_nexttowardfd.c (__nldbl_nexttowardf): Likewise.
2015-09-23 20:14:57 +02:00
ret = math_narrow_eval (-__copysign (DBL_MIN, ret) * DBL_MIN);
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
ret = -ret;
}
else
Use math_narrow_eval more consistently. Where glibc code needs to avoid excess range and precision in floating-point arithmetic, code variously uses either asms or volatile to force the results of that arithmetic to memory; mostly this is conditional on FLT_EVAL_METHOD, but in the case of lrint / llrint functions some use of volatile is unconditional (and is present unnecessarily in versions for long double). This patch make such code use the recently-added math_narrow_eval macro consistently, removing the unnecessary uses of volatile in long double lrint / llrint implementations completely. Tested for x86_64, x86, mips64 and powerpc. * math/s_nexttowardf.c (__nexttowardf): Use math_narrow_eval. * stdlib/strtod_l.c: Include <math_private.h>. (overflow_value): Use math_narrow_eval. (underflow_value): Likewise. * sysdeps/i386/fpu/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/i386/fpu/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Likewise. (__ieee754_gamma_r): Likewise. * sysdeps/ieee754/dbl-64/gamma_productf.c (__gamma_productf): Likewise. * sysdeps/ieee754/dbl-64/k_rem_pio2.c (__kernel_rem_pio2): Likewise. * sysdeps/ieee754/dbl-64/lgamma_neg.c (__lgamma_neg): Likewise. * sysdeps/ieee754/dbl-64/s_erf.c (__erfc): Likewise. * sysdeps/ieee754/dbl-64/s_llrint.c (__llrint): Likewise. * sysdeps/ieee754/dbl-64/s_lrint.c (__lrint): Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Likewise. (__ieee754_gammaf_r): Likewise. * sysdeps/ieee754/flt-32/k_rem_pio2f.c (__kernel_rem_pio2f): Likewise. * sysdeps/ieee754/flt-32/lgamma_negf.c (__lgamma_negf): Likewise. * sysdeps/ieee754/flt-32/s_erff.c (__erfcf): Likewise. * sysdeps/ieee754/flt-32/s_llrintf.c (__llrintf): Likewise. * sysdeps/ieee754/flt-32/s_lrintf.c (__lrintf): Likewise. * sysdeps/ieee754/ldbl-128/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-128/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-128/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-128ibm/s_nexttoward.c (__nexttoward): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-96/gamma_product.c (__gamma_product): Likewise. * sysdeps/ieee754/ldbl-96/s_llrintl.c (__llrintl): Do not use volatile. * sysdeps/ieee754/ldbl-96/s_lrintl.c (__lrintl): Likewise. * sysdeps/ieee754/ldbl-96/s_nexttoward.c (__nexttoward): Use math_narrow_eval. * sysdeps/ieee754/ldbl-96/s_nexttowardf.c (__nexttowardf): Likewise. * sysdeps/ieee754/ldbl-opt/s_nexttowardfd.c (__nldbl_nexttowardf): Likewise.
2015-09-23 20:14:57 +02:00
ret = math_narrow_eval (__copysign (DBL_MIN, ret) * DBL_MIN);
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
return ret;
}
Improve tgamma accuracy (bug 18613). In non-default rounding modes, tgamma can be slightly less accurate than permitted by glibc's accuracy goals. Part of the problem is error accumulation, addressed in this patch by setting round-to-nearest for internal computations. However, there was also a bug in the code dealing with computing pow (x + n, x + n) where x + n is not exactly representable, providing another source of error even in round-to-nearest mode; it was necessary to address both bugs to get errors for all testcases within glibc's accuracy goals. Given this second fix, accuracy in round-to-nearest mode is also improved (hence regeneration of ulps for tgamma should be from scratch - truncate libm-test-ulps or at least remove existing tgamma entries - so that the expected ulps can be reduced). Some additional complications also arose. Certain tgamma tests should strictly, according to IEEE semantics, overflow or not depending on the rounding mode; this is beyond the scope of glibc's accuracy goals for any function without exactly-determined results, but gen-auto-libm-tests doesn't handle being lax there as it does for underflow. (libm-test.inc also doesn't handle being lax about whether the result in cases very close to the overflow threshold is infinity or a finite value close to overflow, but that doesn't cause problems in this case though I've seen it cause problems with random test generation for some functions.) Thus, spurious-overflow markings, with a comment, are added to auto-libm-test-in (no bug in Bugzilla because the issue is with the testsuite, not a user-visible bug in glibc). And on x86, after the patch I saw ERANGE issues as previously reported by Carlos (see my commentary in <https://sourceware.org/ml/libc-alpha/2015-01/msg00485.html>), which needed addressing by ensuring excess range and precision were eliminated at various points if FLT_EVAL_METHOD != 0. I also noticed and fixed a cosmetic issue where 1.0f was used in long double functions and should have been 1.0L. This completes the move of all functions to testing in all rounding modes with ALL_RM_TEST, so gen-libm-have-vector-test.sh is updated to remove the workaround for some functions not using ALL_RM_TEST. Tested for x86_64, x86, mips64 and powerpc. [BZ #18613] * sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gamma_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammaf_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive): Take log of X_ADJ not X when adjusting exponent. (__ieee754_gammal_r): Do intermediate computations in round-to-nearest then adjust overflowing and underflowing results as needed. Use 1.0L not 1.0f as numerator of division. * math/libm-test.inc (tgamma_test_data): Remove one test. Moved to auto-libm-test-in. (tgamma_test): Use ALL_RM_TEST. * math/auto-libm-test-in: Add one test of tgamma. Mark some other tests of tgamma with spurious-overflow. * math/auto-libm-test-out: Regenerated. * math/gen-libm-have-vector-test.sh: Do not check for START. * sysdeps/i386/fpu/libm-test-ulps: Update. * sysdeps/x86_64/fpu/libm-test-ulps: Likewise.
2015-06-30 01:29:35 +02:00
else
return ret;
Update. 1997-06-19 19:38 Ulrich Drepper <drepper@cygnus.com> * features.h: Define __STDC_IEC_559__ and _STDC_IEC_559_COMPLEX__. * elf/dl-minimal.c (__dcgettext): Remove assertion. * inet/rcmd.c: Correct a few typos. Reported by Eric Troan. * manual/Makefile (distribute): Add dir. * manual/dir: New file. * math/Makefile (libm-support): Rename s_rinttol, s_rinttoll, s_roundtol, and s_roundtoll to s_lrint, s_llrint, s_lround, and s_llround respectively. (libm-calls): Add e_gamma_r. * math/libm-test.c (check_int_exc): New function. (signbit_test): Remove test for sign of NaN. (gamma_test): Clear exception after test of existence. Correct tests and and epsilons. (lgamma_test): Likewise. (ilogb_test): Correct all tests. (scalb_test): Rewrite. (rinttol_test): Rename to lrint_test and correct tests. (rinttoll_test): Likewise. (roundtol_test): Likewise. (roundtoll_test): Likewise. (main): Call lrint/lround functions instead of rinttol/roundtol. * math/math.h: Change prototypes for rinttol/roundtol. * math/mathcalls.h: Rearrange prototypes according to ISO C9X draft. * sysdeps/generic/mathbits.h: Define FP_ILOGB0 and FP_ILOGBNAN. * sysdeps/i386/mathbits.h: Likewise. * sysdeps/libm-i387/e_scalb.S: Handle special cases correctly. * sysdeps/libm-i387/e_scalbf.S: Likewise. * sysdeps/libm-i387/e_scalbl.S: Likewise. * sysdeps/libm-i387/s_asinh.S: Handle -inf correctly. * sysdeps/libm-i387/s_asinhf.S: Likewise. * sysdeps/libm-i387/s_asinhl.S: Likewise. * sysdeps/libm-i387/s_ilogb.S: Optimize. * sysdeps/libm-i387/s_ilogbf.S: Likewise. * sysdeps/libm-i387/s_ilogbl.S: Likewise. * sysdeps/libm-i387/s_rinttol.S: Rename to... * sysdeps/libm-i387/s_lrint.S: ...this. * sysdeps/libm-i387/s_rinttoll.S: Rename to... * sysdeps/libm-i387/s_llrint.S: ...this. * sysdeps/libm-i387/s_remquo.S: Correctly set sign of remainder. * sysdeps/libm-i387/s_remquof.S: Likewise. * sysdeps/libm-i387/s_remquol.S: Likewise. * sysdeps/libm-i387/e_gamma_r.c: New file. Implementation of gamma function according to ISO C. * sysdeps/libm-i387/e_gammaf_r.c: New file. * sysdeps/libm-i387/e_gammal_r.c: New file. * sysdeps/libm-i387/e_lgamma_r.c: Don't let optimize compile the generation of exceptions away. * sysdeps/libm-i387/e_lgammaf_r.c: Likewise. * sysdeps/libm-i387/k_standard.c: Correct return value for infinity points of gamma function when not SVID mode. * sysdeps/libm-i387/s_rinttoll.c: Renamed to... * sysdeps/libm-i387/s_llrint.c: ...this. * sysdeps/libm-i387/s_rinttol.c: Renamed to... * sysdeps/libm-i387/s_lrint.c: ...this. * sysdeps/libm-i387/s_roundtoll.c: Renamed to... * sysdeps/libm-i387/s_llround.c: ...this. * sysdeps/libm-i387/s_roundtol.c: Renamed to... * sysdeps/libm-i387/s_lround.c: ..this. * sysdeps/libm-i387/s_scalbn.c: Change second parameter according to ISO C. * sysdeps/libm-i387/s_scalbnf.c: Likewise. * sysdeps/libm-i387/s_scalbnl.c: Likewise. * sysdeps/libm-i387/w_gamma.c: Call __ieee754_gamma_r if library mode is not _SVID_. * sysdeps/libm-i387/w_gammaf.c: Likewise. * sysdeps/libm-i387/w_gammal.c: Likewise. * sysdeps/m68k/fpu/__math.h: Rename __rinttol to __lrint and rinttol to lrint. * sysdeps/m68k/fpu/s_rinttol.c: Renamed to... * sysdeps/m68k/fpu/s_lrint.c: ...this. * sysdeps/m68k/fpu/s_rinttoll.c: Renamed to... * sysdeps/m68k/fpu/s_llrint.c: ...this. * md5-crypt/Makefile: Link md5test program with md5.o. * stdio-common/temptest.c: Don't use __stdio_gen_tempname which is not exported by the libc.so. * stdio-common/vfscanf.c: Correct scanning of strings after last change. * sysdeps/unix/sysv/linux/i386/sysdep.S: Use .comm to define errno. 1997-06-19 07:37 H.J. Lu <hjl@gnu.ai.mit.edu> * time/tzfile.c (__tzfile_read): Store getc () return in int. 1997-06-13 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (argp_version_parser): Include `(PROGRAM ERROR)' in the no-version error text to indicate that something's fucked. [!_] (N_): New macro. (argp_default_options, argp_version_options): Wrap doc strings in N_(). 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp-parse.c (parser_parse_opt): Detect and report unhandled options here. (parser_parse_arg): Handle ARGP_KEY_ARGS here. Adjust NEXT pointer back if we fail to parse anything. (parser_parse_next): Simplify arg code. Leave state NEXT frobbing to parser_parse_arg. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * argp/argp.h (ARGP_KEY_ARGS, ARGP_KEY_FINI): New macros. * argp/argp-parse.c (parser_finalize): Do another pass over the parsers with ARGP_KEY_FINI. 1997-06-18 Miles Bader <miles@gnu.ai.mit.edu> * string/Makefile (routines): Add argz-replace. 1997-06-16 00:16 Miles Bader <miles@gnu.ai.mit.edu> * manual/string.texi (Argz Functions): Document argz_replace. 1997-06-12 Miles Bader <miles@gnu.ai.mit.edu> * string/argz.h (__argz_replace, argz_replace): New declarations. * string/argz-replace.c: New file. 1997-06-11 Miles Bader <miles@gnu.ai.mit.edu> * manual/argp.texi (Argp Special Keys): Document ARGP_KEY_ARGS. 1997-06-16 23:08 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * Makeconfig (libc-map): Remove definition. * Makerules (libc-map): Define it here, using the full name. (load-map-file): Remove case for empty $(..). ($(common-objpfx)libc.so): Revert last change. 1997-06-17 22:18 Mark Kettenis <kettenis@phys.uva.nl> * login/programs/utmpd.c (main): Improve signal handling. * login/programs/request.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/utmpd.h (setutent_request, updwtmp_request): Get rid of fixed length file field. * login/utmp_daemon.c (do_setutent, do_updwtmp): Allow arbitrary length filenames. * login/programs/request.c (do_pututline): Don't fail if connection->position is -1 on entry. 1997-06-15 16:32 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (updwtmp_file): Use the same method for appending an entry as in pututline_file. 1997-06-11 18:59 Mark Kettenis <kettenis@phys.uva.nl> * login/utmp_file.c (getutent_r_file): Use read lock instead of write lock. (getutline_r_file, internal_getut_r): Lock utmp file. (updwtmp_file): Use fcntl to lock file instead of flock. 1997-06-18 00:11 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * stdio-common/vfscanf.c (inchar, ungetc): Don't count EOF as character read in/put back. * stdio-common/tstscanf.c: Add test case for this. 1997-06-17 22:17 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * libc.map: Add more symbols. 1997-06-18 12:01 Ulrich Drepper <drepper@cygnus.com> * manual/Makefile (install): Make sure `dir' file exists if we use install-info. 1997-06-17 19:32 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * manual/Makefile (info): Depend on dir-add.info. 1997-06-17 17:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/ldd.bash.in: Fix spacing in message. 1997-06-17 14:28 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/do-rel.h (elf_dynamic_do_rel): Always use version information if available. 1997-06-17 11:34 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sunrpc/Makefile ($(rpcsvc:%.x=$(objpfx)rpcsvc/%.h)): Make command non-empty to force make to recheck modification time. ($(rpcsvc:%.x=$(objpfx)x%.c)): Likewise. 1997-06-17 00:26 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/stub/e_acoshl.c: Set errno to ENOSYS. * sysdeps/stub/e_acosl.c: Likewise. * sysdeps/stub/e_asinl.c: Likewise. * sysdeps/stub/e_atan2l.c: Likewise. * sysdeps/stub/e_expl.c: Likewise. * sysdeps/stub/e_fmodl.c: Likewise. * sysdeps/stub/e_j0l.c: Likewise. * sysdeps/stub/e_j1l.c: Likewise. * sysdeps/stub/e_jnl.c: Likewise. * sysdeps/stub/e_lgammal_r.c: Likewise. * sysdeps/stub/e_log10l.c: Likewise. * sysdeps/stub/e_logl.c: Likewise. * sysdeps/stub/e_powl.c: Likewise. * sysdeps/stub/e_rem_pio2l.c: Likewise. * sysdeps/stub/e_sqrtl.c: Likewise. * sysdeps/stub/k_cosl.c: Likewise. * sysdeps/stub/k_rem_pio2l.c: Likewise. * sysdeps/stub/k_sinl.c: Likewise. * sysdeps/stub/k_tanl.c: Likewise. * sysdeps/stub/s_atanl.c: Likewise. * sysdeps/stub/s_erfl.c: Likewise. * sysdeps/stub/s_exp2.c: Likewise. * sysdeps/stub/s_exp2f.c: Likewise. * sysdeps/stub/s_exp2l.c: Likewise. * sysdeps/stub/s_expm1l.c: Likewise. * sysdeps/stub/s_log1pl.c: Likewise. * sysdeps/stub/s_log2l.c: Likewise. 1997-06-18 11:46 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/w_gamma.c: If _LIB_VERSION is _SVID_ compute result as before last change. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. 1997-06-16 23:37 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/libm-ieee754/s_remquo.c: Fix off-by-one when computing quotient. * sysdeps/libm-ieee754/s_remquof.c: Likewise. * sysdeps/libm-ieee754/s_remquol.c: Likewise. * sysdeps/m68k/fpu/s_remquo.c: Remove FIXME and special case for quotient. * sysdeps/libm-ieee754/w_gamma.c: Add missing call to exp function. Don't use global signgam. * sysdeps/libm-ieee754/w_gammaf.c: Likewise. * sysdeps/libm-ieee754/w_gammal.c: Likewise. * math/Makefile (libm-calls): Remove w_gamma_r. * sysdeps/libm-ieee754/w_gamma_r.c: Remove file. * sysdeps/libm-ieee754/w_gammaf_r.c: Remove file. * sysdeps/libm-ieee754/w_gammal_r.c: Remove file. * math/libm-test.c (atanh_test): Declare x only if needed. (signbit_test): Fix typo. (gamma_test): Check whether function is implemented. Add epsilons. (lgamma_test): Likewise. (fmod_test): Add epsilons. (exp2_test): Use right function for existence test. 1997-06-07 09:20 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/powerpc/Dist: Add fenv_const.c. * sysdeps/unix/sysv/linux/Dist: Add net/if_slip.h. * sysdeps/unix/sysv/linux/powerpc/Dist: Add init-first.h and syscall.h. * sysdeps/unix/sysv/linux/sparc/Dist: Add init-first.h. * string/Makefile (distribute): Add tst-svc.expect. * nis/Makefile (distribute): Add nis_intern.h and Banner. * elf/Makefile (distribute): Add dl-hash.h. * Rules (subdir_echo-distinfo): Add headers from $(distribute). * login/Makefile (others): Add utmpdump. * sysdeps/unix/sysv/linux/Makefile (sysdep_headers): Add net/if_slip.h. * manual/Makefile (dir-add.texi): Also look in indirectly included files. 1997-06-16 23:15 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/configure.in: Remove commands to generate stdio_lim.h. * sysdeps/unix/sysv/linux/mk-stdiolim.c: Remove. * sysdeps/unix/sysv/linux/Makefile: Add rules to generate stdio_lim.h here. (common-generated): Add generated files. (inhibit-stdio_lim): Define. * sysdeps/posix/Makefile [$(inhibit-stdio_lim)=yes]: Disable rules to generate stdio_lim.h. * sysdeps/unix/sysv/linux/Makefile: Suppress inclusion of dependecy files if no_deps is set. ($(objpfx)syscall-%.d): Add header file as target to dependency generation. 1997-06-14 19:19 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/sysv/linux/arm/Dist: New file. 1997-06-14 17:59 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * extra-lib.mk (others): Depend on versioned shared library, not the unversioned one. * Makerules (build-shlib): Don't make the version link here. ($(common-objpfx)libc.so$(libc.so-version)): New rule for libc version link. 1997-06-16 03:07 Ulrich Drepper <drepper@cygnus.com> * sysdeps/libm-ieee754/k_standard.c: Undo change of Tue Aug 6 01:13:56 1996. * argp/argp-help.c (argp_args_usage): Supply correct argp to filter_doc. * argp/argp-help.c (hol_add_cluster): Initialize CL->depth. * argp/argp-help.c (_help): Supply STATE to argp_args_usage. * argp/argp.h (ARGP_KEY_HELP_ARGS_DOC): New macro. * argp/argp-fmtstream.c: Add casts to prevent warnings. * argp/argp.h (OPTION_NO_USAGE): New macro. * argp/argp-help.c (usage_long_opt, usage_argful_short_opt, * argp/argp-fmtstream.c (__argp_fmtstream_update): Account for case * argp/argp-help.c <stddef.h>: New include. * argp/argp.h (argp_state_help, __argp_state_help, argp_usage, * argp/argp.h (argp_program_bug_address): Make const. * argp/argp-parse.c (argp_default_parser): Set STATE->name for OPT_PROGNAME. * argp/argp-help.c (__argp_error, __argp_failure, __argp_state_help): * argp/argp-parse.c (parser_init): Set PARSER->state.flags.
1997-06-19 21:11:22 +02:00
}
strong_alias (__ieee754_gamma_r, __gamma_r_finite)