glibc/math/w_tgamma_compat.c

47 lines
1.3 KiB
C
Raw Permalink Normal View History

/* @(#)w_gamma.c 5.1 93/09/24 */
/*
* ====================================================
* Copyright (C) 1993 by Sun Microsystems, Inc. All rights reserved.
*
* Developed at SunPro, a Sun Microsystems, Inc. business.
* Permission to use, copy, modify, and distribute this
Mon Apr 1 13:34:55 1996 Roland McGrath <roland@whiz-bang.gnu.ai.mit.edu> * stdio-common/tst-printf.c (main): Add new test case. * sysdeps/generic/setenv.c (unsetenv): Use old-style definition. Mon Apr 1 11:39:10 Ulrich Drepper <drepper@gnu.ai.mit.edu> * stdlib/strtod.c (STRTOD): Fix handling of American style FP numbers. * stdio-common/vfprintf.c (vfprintf): Don't increment format string pointer twice after seeing `*'. Sun Mar 31 17:31:54 1996 Roland McGrath <roland@whiz-bang.gnu.ai.mit.edu> * MakeTAGS (po/SYS_libc.pot): Prepend header processed from po/header.pot. Sun Mar 31 18:07:32 1996 Ulrich Drepper <drepper@gnu.ai.mit.edu> * locale/Makefile (others, install-bin): Compiling locale works again. (locale-modules): locale has no --dump option anymore. Remove ctypedump. * locale/programs/config.h: Don't declare euidaccess. Use #include_next to get libc's config.h. * locale/programs/ctypedump.c: Not needed anymore. Dump option of locale is removed. * locale/programs/locale.c: Adapt for new locale implementation. * stdio-common/_itoa.h (_itoa_word): Define as inline function. * stdio-common/_itoa.c (_itoa_lower_digits, _itoa_upper_digits): Don't declare static because used in _itoa_word inline function. * stdio-common/printf-parse.h: Prepare for use in wide-char stdio implementation. (find_spec): Take additional argument to work with mbrlen instead of mblen. (parse_one_spec): Ditto. * stdio-common/printf-prs.c: Prepare for use in wide-char stdio implementation. * stdio-common/printf.h: Mark change for wide-char handling. Changing it now would result in incompatibilities. * stdio-common/vfprintf.c: New and fast implementation. * wcsmbs/Makefile (routines): Remove pre-ISO C multibyte functions mbsadvance, mbscat, mbschr, mbscmp, mbscpy, mbsdup, mbslen, mbsncat, mbsncmp, mbsncpy, mbsrchr, mbstomb. Change wcswcs to wcsstr. Add wmemchr, wmemcmp, wmemcpy, wmemmove, wmemset, btowc, wctob, mbsinit, mbrlen, mbrtowc, wcrtomb, mbsrtowcs, wcsrtombs. * wcsmbs/btowc.c, wcsmbs/mbrlen.c, wcsmbs/mbrtowc.c, wcsmbs/mbsinit.c, wcsmbs/mbsrtowcs.c, wcsmbs/wchar.h, wcsmbs/wcrtomb.c, wcsmbs/wcsrtombs.c, wcsmbs/wcsstr.c, wcsmbs/wctob.c, wcsmbs/wmemchr.c, wcsmbs/wmemcmp.c, wcsmbs/wmemcpy.c, wcsmbs/wmemmove.c, wcsmbs/wmemset.c: New function according to ISO C amendment 1. * wchar.h: Wrapper around "wcsmbs/wchar.h". * wcsmbs/wcscat.c, wcsmbs/wcschr.c, wcsmbs/wcscmp.c, wcsmbs/wcscpy.c, wcsmbs/wcscspn.c, wcsmbs/wcsdup.c, wcsmbs/wcslen.c, wcsmbs/wcsncat.c, wcsmbs/wcsncmp.c, wcsmbs/wcsncpy.c, wcsmbs/wcspbrk.c, wcsmbs/wcsrchr.c, wcsmbs/wcsspn.c, wcsmbs/wcstok.c: Changed to conform with ISO C amendment 1. * wcsmbs/mbsadvance.c, wcsmbs/mbscat.c, wcsmbs/mbschr.c, wcsmbs/mbscmp.c, wcsmbs/mbscpy.c, wcsmbs/mbsdup.c, wcsmbs/mbslen.c, wcsmbs/mbsncat.c, wcsmbs/mbsncmp.c, wcsmbs/mbsncpy.c, wcsmbs/mbsrchr.c, wcsmbs/mbstomb.c, wcsmbs/mbstr.h, wcsmbs/wcstr.h, wcsmbs/wcswcs.c: Removed. Implement functions from early drafts, not part of final standard. Sun Mar 31 16:50:41 1996 Roland McGrath <roland@whiz-bang.gnu.ai.mit.edu> * setjmp/setjmp.h (jmp_buf): Change gratuitous struct tag name to __jmp_bug_tag so its C++ implicit typedef does not conflict with the __jmp_buf typedef. * Makerules (BUILD_CFLAGS) [! objdir]: Use $(..)config.h when compiling in the source directories. Fri Mar 29 16:26:35 1996 Roland McGrath <roland@whiz-bang.gnu.ai.mit.edu> * sysdeps/libm-ieee754/w_gamma.c: Use signgam instead of __signgam. * sysdeps/libm-ieee754/s_signgam.c: Undo last change.
1996-04-02 15:27:17 +02:00
* software is freely granted, provided that this notice
* is preserved.
* ====================================================
*/
/* double gamma(double 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 the logarithm of the Gamma function of x or the Gamma function of x,
* depending on the library mode.
*/
#include <errno.h>
2005-12-14 16:06:39 +01:00
#include <math.h>
#include <math_private.h>
Obsolete matherr, _LIB_VERSION, libieee.a. This patch obsoletes support for SVID libm error handling (the system where a user-defined function matherr is called on a libm function error; only enabled if you also set _LIB_VERSION = _SVID_ or _LIB_VERSION = _XOPEN_) and the use of the _LIB_VERSION global variable to control libm error handling. matherr and _LIB_VERSION are made into compat symbols, not supported for new ports or for static linking. The libieee.a object file (which sets _LIB_VERSION = _IEEE_, so disabling errno setting for some functions) is also removed, and all the related definitions are removed from math.h. The manual already recommends against using matherr, and it's already not supported for _Float128 functions (those use new wrappers that don't support matherr, only errno) - this patch means that it becomes possible to e.g. add sinf32 as an alias to sinf without that resulting in undesired matherr support in sinf32 for existing glibc ports. matherr support is not part of any standard supported by glibc (it was removed in XPG4). Because matherr is a function to be defined by the user, of course user programs defining such a function will still continue to link; it just quietly won't be used. If they try to write to the library's copy of _LIB_VERSION to enable SVID error handling, however, they will get a link error (but if they define their own _LIB_VERSION variable, they won't). I expect the most likely case of build failures from this patch to be programs with unconditional cargo-culted uses of -lieee (based on a notion of "I want IEEE floating point", not any actual requirement for that library). Ideally, the new-port-or-static-linking case would use the new wrappers used for _Float128. This is not implemented in this patch, because of the complication of architecture-specific (powerpc32 and sparc) sqrt wrappers that use _LIB_VERSION and __kernel_standard directly. Thus, the old wrappers and __kernel_standard are still built unconditionally, and _LIB_VERSION still exists in static libm. But when the old wrappers and __kernel_standard are built in the non-compat case, _LIB_VERSION and matherr are defined as macros so code to support those features isn't actually built into static libm or new ports' shared libm after this patch. I intend to move to the new wrappers for static libm and new ports in followup patches. I believe the sqrt wrappers for powerpc32 and sparc can reasonably be removed. GCC already optimizes the normal case of sqrt by generating code that uses a hardware instruction and only calls the sqrt function if the argument was negative (if -fno-math-errno, of course, it just uses the hardware instruction without any check for negative argument being needed). Thus those wrappers will only actually get called in the case of negative arguments, which is not a case it makes sense to optimize for. But even without removing the powerpc32 and sparc wrappers it should still be possible to move to the new wrappers for static libm and new ports, just without having those dubious architecture-specific optimizations in static libm. Everything said about matherr equally applies to matherrf and matherrl (IA64-specific, undocumented), except that the structure of IA64 libm means it won't be converted to using the new wrappers (it doesn't use the old ones either, but its own error-handling code instead). As with other tests of compat symbols, I expect test-matherr and test-matherr-2 to need to become appropriately conditional once we have a system for disabling such tests for ports too new to have the relevant symbols. Tested for x86_64 and x86, and with build-many-glibcs.py. * math/math.h [__USE_MISC] (_LIB_VERSION_TYPE): Remove. [__USE_MISC] (_LIB_VERSION): Likewise. [__USE_MISC] (struct exception): Likewise. [__USE_MISC] (matherr): Likewise. [__USE_MISC] (DOMAIN): Likewise. [__USE_MISC] (SING): Likewise. [__USE_MISC] (OVERFLOW): Likewise. [__USE_MISC] (UNDERFLOW): Likewise. [__USE_MISC] (TLOSS): Likewise. [__USE_MISC] (PLOSS): Likewise. [__USE_MISC] (HUGE): Likewise. [__USE_XOPEN] (MAXFLOAT): Define even if [__USE_MISC]. * math/math-svid-compat.h: New file. * conform/linknamespace.pl (@whitelist): Remove matherr, matherrf and matherrl. * include/math.h [!_ISOMAC] (__matherr): Remove. * manual/arith.texi (FP Exceptions): Do not document matherr. * math/Makefile (tests): Change test-matherr to test-matherr-3. (tests-internal): New variable. (install-lib): Do not add libieee.a. (non-lib.a): Likewise. (extra-objs): Do not add libieee.a and ieee-math.o. (CPPFLAGS-s_lib_version.c): Remove variable. ($(objpfx)libieee.a): Remove rule. ($(addprefix $(objpfx), $(tests-internal)): Depend on $(libm). * math/ieee-math.c: Remove. * math/libm-test-support.c (matherr): Remove. * math/test-matherr.c: Use <support/test-driver.c>. Add copyright and license notices. Include <math-svid-compat.h> and <shlib-compat.h>. (matherr): Undefine as macro. Use compat_symbol_reference. (_LIB_VERSION): Likewise. * math/test-matherr-2.c: New file. * math/test-matherr-3.c: Likewise. * sysdeps/generic/math_private.h (__kernel_standard): Remove declaration. (__kernel_standard_f): Likewise. (__kernel_standard_l): Likewise. * sysdeps/ieee754/s_lib_version.c: Do not include <math.h> or <math_private.h>. Include <math-svid-compat.h>. (_LIB_VERSION): Undefine as macro. (_LIB_VERSION_INTERNAL): Always initialize to _POSIX_. Define only if [LIBM_SVID_COMPAT || !defined SHARED]. If [LIBM_SVID_COMPAT], use compat_symbol. * sysdeps/ieee754/s_matherr.c: Do not include <math.h> or <math_private.h>. Include <math-svid-compat.h>. (matherr): Undefine as macro. (__matherr): Define only if [LIBM_SVID_COMPAT]. Use compat_symbol. * sysdeps/ia64/fpu/libm_error.c: Include <math-svid-compat.h>. [_LIBC && LIBM_SVID_COMPAT] (matherrf): Use compat_symbol_reference. [_LIBC && LIBM_SVID_COMPAT] (matherrl): Likewise. [_LIBC && !LIBM_SVID_COMPAT] (matherrf): Define as macro. [_LIBC && !LIBM_SVID_COMPAT] (matherrl): Likewise. * sysdeps/ia64/fpu/libm_support.h: Include <math-svid-compat.h>. (MATHERR_D): Remove declaration. [!_LIBC] (_LIB_VERSION_TYPE): Likewise [!LIBM_BUILD] (_LIB_VERSIONIMF): Likewise. [LIBM_BUILD] (pmatherrf): Likewise. [LIBM_BUILD] (pmatherr): Likewise. [LIBM_BUILD] (pmatherrl): Likewise. (DOMAIN): Likewise. (SING): Likewise. (OVERFLOW): Likewise. (UNDERFLOW): Likewise. (TLOSS): Likewise. (PLOSS): Likewise. * sysdeps/ia64/fpu/s_matherrf.c: Include <math-svid-compat.h>. (__matherrf): Define only if [LIBM_SVID_COMPAT]. Use compat_symbol. * sysdeps/ia64/fpu/s_matherrl.c: Include <math-svid-compat.h>. (__matherrl): Define only if [LIBM_SVID_COMPAT]. Use compat_symbol. * math/lgamma-compat.h: Include <math-svid-compat.h>. * math/w_acos_compat.c: Likewise. * math/w_acosf_compat.c: Likewise. * math/w_acosh_compat.c: Likewise. * math/w_acoshf_compat.c: Likewise. * math/w_acoshl_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_atan2_compat.c: Likewise. * math/w_atan2f_compat.c: Likewise. * math/w_atan2l_compat.c: Likewise. * math/w_atanh_compat.c: Likewise. * math/w_atanhf_compat.c: Likewise. * math/w_atanhl_compat.c: Likewise. * math/w_cosh_compat.c: Likewise. * math/w_coshf_compat.c: Likewise. * math/w_coshl_compat.c: Likewise. * math/w_exp10_compat.c: Likewise. * math/w_exp10f_compat.c: Likewise. * math/w_exp10l_compat.c: Likewise. * math/w_exp2_compat.c: Likewise. * math/w_exp2f_compat.c: Likewise. * math/w_exp2l_compat.c: Likewise. * math/w_fmod_compat.c: Likewise. * math/w_fmodf_compat.c: Likewise. * math/w_fmodl_compat.c: Likewise. * math/w_hypot_compat.c: Likewise. * math/w_hypotf_compat.c: Likewise. * math/w_hypotl_compat.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_jnl_compat.c: Likewise. * math/w_lgamma_main.c: Likewise. * math/w_lgamma_r_compat.c: Likewise. * math/w_lgammaf_main.c: Likewise. * math/w_lgammaf_r_compat.c: Likewise. * math/w_lgammal_main.c: Likewise. * math/w_lgammal_r_compat.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. * math/w_pow_compat.c: Likewise. * math/w_powf_compat.c: Likewise. * math/w_powl_compat.c: Likewise. * math/w_remainder_compat.c: Likewise. * math/w_remainderf_compat.c: Likewise. * math/w_remainderl_compat.c: Likewise. * math/w_scalb_compat.c: Likewise. * math/w_scalbf_compat.c: Likewise. * math/w_scalbl_compat.c: Likewise. * math/w_sinh_compat.c: Likewise. * math/w_sinhf_compat.c: Likewise. * math/w_sinhl_compat.c: Likewise. * math/w_sqrt_compat.c: Likewise. * math/w_sqrtf_compat.c: Likewise. * math/w_sqrtl_compat.c: Likewise. * math/w_tgamma_compat.c: Likewise. * math/w_tgammaf_compat.c: Likewise. * math/w_tgammal_compat.c: Likewise. * sysdeps/ieee754/dbl-64/w_exp_compat.c: Likewise. * sysdeps/ieee754/flt-32/w_expf_compat.c: Likewise. * sysdeps/ieee754/k_standard.c: Likewise. * sysdeps/ieee754/k_standardf.c: Likewise. * sysdeps/ieee754/k_standardl.c: Likewise. * sysdeps/ieee754/ldbl-128/w_expl_compat.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/w_expl_compat.c: Likewise. * sysdeps/ieee754/ldbl-96/w_expl_compat.c: Likewise. * sysdeps/powerpc/powerpc32/power4/fpu/w_sqrt_compat.S: Likewise. * sysdeps/powerpc/powerpc32/power4/fpu/w_sqrtf_compat.S: Likewise. * sysdeps/powerpc/powerpc32/power5/fpu/w_sqrt_compat.S: Likewise. * sysdeps/powerpc/powerpc32/power5/fpu/w_sqrtf_compat.S: Likewise. * sysdeps/sparc/sparc32/fpu/w_sqrt_compat.S: Likewise. * sysdeps/sparc/sparc32/fpu/w_sqrtf_compat.S: Likewise. * sysdeps/sparc/sparc32/sparcv9/fpu/multiarch/w_sqrt_compat-vis3.S: Likewise. * sysdeps/sparc/sparc32/sparcv9/fpu/multiarch/w_sqrtf_compat-vis3.S: Likewise. * sysdeps/sparc/sparc32/sparcv9/fpu/w_sqrt_compat.S: Likewise. * sysdeps/sparc/sparc32/sparcv9/fpu/w_sqrtf_compat.S: Likewise. * sysdeps/sparc/sparc64/fpu/w_sqrt_compat.S: Likewise. * sysdeps/sparc/sparc64/fpu/w_sqrtf_compat.S: Likewise.
2017-08-21 19:45:10 +02:00
#include <math-svid-compat.h>
Use libm_alias_double in math/. This patch converts libm function implementations in math/ from using weak_alias to using libm_alias_double to define public function names, in cases where it would be appropriate to define _Float64 / _Float32x aliases for those functions as well. This eliminates many NO_LONG_DOUBLE conditionals and ldbl-opt wrappers round these function implementations. Tested for x86_64. Also tested with build-many-glibcs.py. Binary differences seen are that the different order in which remainder and drem symbols get defined as a result of this patch (the same source file defines the same aliases, but in a different order of definition) changes the order of symbols in the final libm.so when long double = double, and for ldbl-opt configurations, the compat symbols for Bessel functions were previously defined by e.g. "compat_symbol (libm, j0, j0l, GLIBC_2_0)", which declares j0l as a compat symbol based on j0 and so makes j0l weak because j0 is weak, and are now defined (indirectly via the relevant macros) based on e.g. __j0, so are no longer weak because __j0 isn't weak. * math/s_fma.c: Include <libm-alias-double.h>. (fma): Define using libm_alias_double. * math/s_nextafter.c: Include <libm-alias-double.h>. (nextafter): Define using libm_alias_double. * math/w_acos_compat.c: Include <libm-alias-double.h>. (acos): Define using libm_alias_double. * math/w_acosh_compat.c: Include <libm-alias-double.h>. (aocsh): Define using libm_alias_double. * math/w_asin_compat.c: Include <libm-alias-double.h>. (asin): Define using libm_alias_double. * math/w_atan2_compat.c: Include <libm-alias-double.h>. (atan2): Define using libm_alias_double. * math/w_atanh_compat.c: Include <libm-alias-double.h>. (atanh): Define using libm_alias_double. * math/w_cosh_compat.c: Include <libm-alias-double.h>. (cosh): Define using libm_alias_double. * math/w_exp10_compat.c: Include <libm-alias-double.h>. (exp10): Define using libm_alias_double. * math/w_exp2_compat.c: Include <libm-alias-double.h>. (exp2): Define using libm_alias_double. * math/w_exp_compat.c: Include <libm-alias-double.h>. (exp): Define using libm_alias_double. * math/w_fmod_compat.c: Include <libm-alias-double.h>. (fmod): Define using libm_alias_double. * math/w_hypot_compat.c: Include <libm-alias-double.h>. (hypot): Define using libm_alias_double. * math/w_j0_compat.c: Include <libm-alias-double.h>. (j0): Define using libm_alias_double. (y0): Likewise. * math/w_j1_compat.c: Include <libm-alias-double.h>. (j1): Define using libm_alias_double. (y1): Likewise. * math/w_jn_compat.c: Include <libm-alias-double.h>. (jn): Define using libm_alias_double. (yn): Likewise. * math/w_log10_compat.c: Include <libm-alias-double.h>. (log10): Define using libm_alias_double. * math/w_log2_compat.c: Include <libm-alias-double.h>. (log2): Define using libm_alias_double. * math/w_log_compat.c: Include <libm-alias-double.h>. (log): Define using libm_alias_double. * math/w_pow_compat.c: Include <libm-alias-double.h>. (pow): Define using libm_alias_double. * math/w_remainder_compat.c: Include <libm-alias-double.h>. (remainder): Define using libm_alias_double. * math/w_sinh_compat.c: Include <libm-alias-double.h>. (sinh): Define using libm_alias_double. * math/w_sqrt_compat.c: Include <libm-alias-double.h>. (sqrt): Define using libm_alias_double. * math/w_tgamma_compat.c: Include <libm-alias-double.h>. (tgamma): Define using libm_alias_double. * sysdeps/ieee754/ldbl-opt/s_nextafter.c [LONG_DOUBLE_COMPAT(libm, GLIBC_2_0)] (nextafterl): Do not define compat symbol here. * sysdeps/ieee754/ldbl-opt/w_exp10_compat.c [LONG_DOUBLE_COMPAT(libm, GLIBC_2_1)] (exp10l): Likewise. * sysdeps/ieee754/ldbl-opt/w_remainder_compat.c [LONG_DOUBLE_COMPAT(libm, GLIBC_2_0)] (remainderl): Likewise. * sysdeps/ieee754/ldbl-opt/w_acos_compat.c: Remove. * sysdeps/ieee754/ldbl-opt/w_acosh_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_asin_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_atan2_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_atanh_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_cosh_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_exp_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_fmod_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_hypot_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_j0_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_j1_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_jn_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_log10_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_log2_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_log_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_pow_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_sinh_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_sqrt_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_tgamma_compat.c: Likewise.
2017-09-16 01:10:02 +02:00
#include <libm-alias-double.h>
Prefer new libm function wrappers for !LIBM_SVID_COMPAT. The initial obsoletion of SVID libm error handling left the old wrappers and __kernel_standard still being used for new ports and static linking, just with macro definitions of _LIB_VERSION and matherr that meant symbols with those names were never actually used and the code for different error handling variants could be optimized out. This patch cleans things up further by eliminating the __kernel_standard use for new ports and static linking. Now, the old wrappers no longer generate any code in the !LIBM_SVID_COMPAT case, while the new errno-only wrappers that were added for float128 support are now also used for float, double and long double in that case. The changes are generally straightforward. The w_scalb*_compat wrappers continue to be used (scalb is obsolescent in the sense of not being supported for float128, but is present in supported standards - the 2001 edition of POSIX and earlier XSI versions - so remains supported for static linking and new ports, as do the float and long double variants that are existing GNU extensions). Those wrappers would only call __kernel_standard in the _LIB_VERSION == _SVID_ case. Since we would like to be able to compile most of glibc without optimization, relying on a static function whose only use is under an if (0) condition being optimized away to avoid an undefined __kernel_standard reference may not be a good idea. Thus, the relevant code in the scalb wrappers has LIBM_SVID_COMPAT conditionals added to guarantee it's not built at all in the case where __kernel_standard does not exist. Just as i386 has its own w_sqrt_compat.c, so w_sqrt.c is also added. ia64 gets dummy w_*.c to prevent those files being built where they would conflict with the ia64 libm, as with its existing w_*_compat.c. Conditions disabling code for !LIBM_SVID_COMPAT are needed in both the math/ wrappers and in the long double wrappers in ldbl-opt (to avoid them setting up aliases and symbol versions for undefined symbols). I hope that future cleanups to how libm function aliases and symbol versioning are done will eliminate the need for most of the ldbl-opt wrappers. Tested for x86_64 and x86, and with build-many-glibcs.py. * sysdeps/generic/math-type-macros-double.h: Include <math-svid-compat.h>. (__USE_WRAPPER_TEMPLATE): Define to !LIBM_SVID_COMPAT. * sysdeps/generic/math-type-macros-float.h: Include <math-svid-compat.h>. (__USE_WRAPPER_TEMPLATE): Define to !LIBM_SVID_COMPAT. * sysdeps/generic/math-type-macros-ldouble.h: Include <math-svid-compat.h>. (__USE_WRAPPER_TEMPLATE): Define to !LIBM_SVID_COMPAT. * math/lgamma-compat.h (BUILD_LGAMMA): Include LIBM_SVID_COMPAT condition. * math/w_acos_compat.c: Condition contents on [LIBM_SVID_COMPAT]. * math/w_acosf_compat.c: Likewise. * math/w_acosh_compat.c: Likewise. * math/w_acoshf_compat.c: Likewise. * math/w_acoshl_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_atan2_compat.c: Likewise. * math/w_atan2f_compat.c: Likewise. * math/w_atan2l_compat.c: Likewise. * math/w_atanh_compat.c: Likewise. * math/w_atanhf_compat.c: Likewise. * math/w_atanhl_compat.c: Likewise. * math/w_cosh_compat.c: Likewise. * math/w_coshf_compat.c: Likewise. * math/w_coshl_compat.c: Likewise. * math/w_exp10_compat.c: Likewise. * math/w_exp10f_compat.c: Likewise. * math/w_exp10l_compat.c: Likewise. * math/w_exp2_compat.c: Likewise. * math/w_exp2f_compat.c: Likewise. * math/w_exp2l_compat.c: Likewise. * math/w_fmod_compat.c: Likewise. * math/w_fmodf_compat.c: Likewise. * math/w_fmodl_compat.c: Likewise. * math/w_hypot_compat.c: Likewise. * math/w_hypotf_compat.c: Likewise. * math/w_hypotl_compat.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_jnl_compat.c: Likewise. * math/w_lgamma_r_compat.c: Likewise. * math/w_lgammaf_r_compat.c: Likewise. * math/w_lgammal_r_compat.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. * math/w_pow_compat.c: Likewise. * math/w_powf_compat.c: Likewise. * math/w_powl_compat.c: Likewise. * math/w_remainder_compat.c: Likewise. * math/w_remainderf_compat.c: Likewise. * math/w_remainderl_compat.c: Likewise. * math/w_sinh_compat.c: Likewise. * math/w_sinhf_compat.c: Likewise. * math/w_sinhl_compat.c: Likewise. * math/w_sqrt_compat.c: Likewise. * math/w_sqrtf_compat.c: Likewise. * math/w_sqrtl_compat.c: Likewise. * math/w_tgamma_compat.c: Likewise. * math/w_tgammaf_compat.c: Likewise. * math/w_tgammal_compat.c: Likewise. * math/w_scalb_compat.c (sysv_scalb): Condition definition on [LIBM_SVID_COMPAT]. (__scalb): Condition call to sysv_scalb on [LIBM_SVID_COMPAT]. * math/w_scalbf_compat.c (sysv_scalbf): Condition definition on [LIBM_SVID_COMPAT]. (__scalbf): Condition call to sysv_scalbf on [LIBM_SVID_COMPAT]. * math/w_scalbl_compat.c (sysv_scalbl): Condition definition on [LIBM_SVID_COMPAT]. (__scalbl): Condition call to sysv_scalbl on [LIBM_SVID_COMPAT]. * sysdeps/i386/fpu/w_sqrt.c: New file. * sysdeps/ia64/fpu/w_acos.c: Likewise. * sysdeps/ia64/fpu/w_acosf.c: Likewise. * sysdeps/ia64/fpu/w_acosh.c: Likewise. * sysdeps/ia64/fpu/w_acoshf.c: Likewise. * sysdeps/ia64/fpu/w_acoshl.c: Likewise. * sysdeps/ia64/fpu/w_acosl.c: Likewise. * sysdeps/ia64/fpu/w_asin.c: Likewise. * sysdeps/ia64/fpu/w_asinf.c: Likewise. * sysdeps/ia64/fpu/w_asinl.c: Likewise. * sysdeps/ia64/fpu/w_atan2.c: Likewise. * sysdeps/ia64/fpu/w_atan2f.c: Likewise. * sysdeps/ia64/fpu/w_atan2l.c: Likewise. * sysdeps/ia64/fpu/w_atanh.c: Likewise. * sysdeps/ia64/fpu/w_atanhf.c: Likewise. * sysdeps/ia64/fpu/w_atanhl.c: Likewise. * sysdeps/ia64/fpu/w_cosh.c: Likewise. * sysdeps/ia64/fpu/w_coshf.c: Likewise. * sysdeps/ia64/fpu/w_coshl.c: Likewise. * sysdeps/ia64/fpu/w_exp.c: Likewise. * sysdeps/ia64/fpu/w_exp10.c: Likewise. * sysdeps/ia64/fpu/w_exp10f.c: Likewise. * sysdeps/ia64/fpu/w_exp10l.c: Likewise. * sysdeps/ia64/fpu/w_exp2.c: Likewise. * sysdeps/ia64/fpu/w_exp2f.c: Likewise. * sysdeps/ia64/fpu/w_exp2l.c: Likewise. * sysdeps/ia64/fpu/w_expf.c: Likewise. * sysdeps/ia64/fpu/w_expl.c: Likewise. * sysdeps/ia64/fpu/w_fmod.c: Likewise. * sysdeps/ia64/fpu/w_fmodf.c: Likewise. * sysdeps/ia64/fpu/w_fmodl.c: Likewise. * sysdeps/ia64/fpu/w_hypot.c: Likewise. * sysdeps/ia64/fpu/w_hypotf.c: Likewise. * sysdeps/ia64/fpu/w_hypotl.c: Likewise. * sysdeps/ia64/fpu/w_lgamma_r.c: Likewise. * sysdeps/ia64/fpu/w_lgammaf_r.c: Likewise. * sysdeps/ia64/fpu/w_lgammal_r.c: Likewise. * sysdeps/ia64/fpu/w_log.c: Likewise. * sysdeps/ia64/fpu/w_log10.c: Likewise. * sysdeps/ia64/fpu/w_log10f.c: Likewise. * sysdeps/ia64/fpu/w_log10l.c: Likewise. * sysdeps/ia64/fpu/w_log2.c: Likewise. * sysdeps/ia64/fpu/w_log2f.c: Likewise. * sysdeps/ia64/fpu/w_log2l.c: Likewise. * sysdeps/ia64/fpu/w_logf.c: Likewise. * sysdeps/ia64/fpu/w_logl.c: Likewise. * sysdeps/ia64/fpu/w_pow.c: Likewise. * sysdeps/ia64/fpu/w_powf.c: Likewise. * sysdeps/ia64/fpu/w_powl.c: Likewise. * sysdeps/ia64/fpu/w_remainder.c: Likewise. * sysdeps/ia64/fpu/w_remainderf.c: Likewise. * sysdeps/ia64/fpu/w_remainderl.c: Likewise. * sysdeps/ia64/fpu/w_sinh.c: Likewise. * sysdeps/ia64/fpu/w_sinhf.c: Likewise. * sysdeps/ia64/fpu/w_sinhl.c: Likewise. * sysdeps/ia64/fpu/w_sqrt.c: Likewise. * sysdeps/ia64/fpu/w_sqrtf.c: Likewise. * sysdeps/ia64/fpu/w_sqrtl.c: Likewise. * sysdeps/ia64/fpu/w_tgamma.c: Likewise. * sysdeps/ia64/fpu/w_tgammaf.c: Likewise. * sysdeps/ia64/fpu/w_tgammal.c: Likewise. * sysdeps/ieee754/dbl-64/w_exp_compat.c: Condition contents on [LIBM_SVID_COMPAT]. * sysdeps/ieee754/flt-32/w_expf_compat.c: Likewise. * sysdeps/ieee754/k_standard.c: Likewise. * sysdeps/ieee754/k_standardf.c: Likewise. * sysdeps/ieee754/k_standardl.c: Likewise. * sysdeps/ieee754/ldbl-128/w_expl_compat.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/w_expl_compat.c: Likewise. * sysdeps/ieee754/ldbl-96/w_expl_compat.c: Likewise. * sysdeps/ieee754/ldbl-64-128/w_expl_compat.c: Condition long_double_symbol call on [LIBM_SVID_COMPAT]. * sysdeps/ieee754/ldbl-opt/w_acoshl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_acosl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_asinl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_atan2l_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_atanhl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_coshl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_fmodl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_hypotl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_j0l_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_j1l_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_jnl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_lgammal_r_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_log10l_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_log2l_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_logl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_powl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_remainderl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_sinhl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_sqrtl_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_tgammal_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_exp10l_compat.c: Condition long_double_symbol and compat_symbol calls on [LIBM_SVID_COMPAT].
2017-09-06 01:35:55 +02:00
#if LIBM_SVID_COMPAT
double
__tgamma(double x)
{
Update. 1998-07-28 Ulrich Drepper <drepper@cygnus.com> * math/libm-test.c (tgamma_test): Remove redundant tests. 1998-07-28 16:20 Ulrich Drepper <drepper@cygnus.com> * sysdeps/generic/glob.c: Correct problems with */foo and GLOB_NOCHECK where foo does not exist in any of the subdirectories. Reported by Paul D. Smith <psmith@BayNetworks.COM>. * posix/globtest.sh: Add test for this bug. 1998-07-28 Mark Kettenis <kettenis@phys.uva.nl> * io/sys/statfs.h: Fix typos. * io/sys/statvfs.h: Fix typos. 1998-07-28 Ulrich Drepper <drepper@cygnus.com> * version.h (VERSION): Bump to 2.0.95. * math/Makefile (libm-calls): Remove w_gamma, add w_tgamma. * math/Versions [GLIBC_2.1]: Add tgamma, tgammaf, and tgammal. * math/libm-test.c: Split old gamma_test and move half of it in new function tgamma_test. * math/bits/mathcalls.h: Add declaration of tgamma. * sysdeps/libm-ieee754/k_standard.c: Change gamma errors into tgamma errors. * sysdeps/libm-ieee754/w_gamma.c: Remove lgamma compatibility code and rename to ... * sysdeps/libm-ieee754/w_tgamma.c: ... this. New file. * sysdeps/libm-ieee754/w_gammaf.c: Remove lgammaf compatibility code and rename to ... * sysdeps/libm-ieee754/w_tgammaf.c: ... this. New file. * sysdeps/libm-ieee754/w_gammal.c: Remove lgammal compatibility code and rename to ... * sysdeps/libm-ieee754/w_tgammal.c: ... this. New file. * sysdeps/libm-ieee754/w_lgamma.c: Add gamma as weak alias. * sysdeps/libm-ieee754/w_lgammaf.c: Likewise. * sysdeps/libm-ieee754/w_lgammal.c: Likewise. * stgdio-common/printf-parse.h: Implement handling of j, t, and z modifiers. * stdio-common/vfprintf.c: Likewise. * stdio-common/vfscanf.c: Likewise. * manual/stdio.texi: Document new printf/scanf modifiers. * sysdeps/unix/sysv/linux/recvmsg.c: Remove alias __recvmsg. * sysdeps/unix/sysv/linux/sendmsg.c: Remove alias __sendmsg. 1998-07-28 Thorsten Kukuk <kukuk@vt.uni-paderborn.de> * sunrpc/Makefile (routines): Add clnt_unix and svc_unix. * sunrpc/Versions: Add new *unix_create functions. * sunrpc/clnt_gen.c: Add support for RPC over AF_UNIX. * sunrpc/clnt_unix.c: New, client side of RPC over AF_UNIX. * sunrpc/key_call.c: Use RPC over AF_UNIX for communication with keyserv daemon. * sunrpc/rpc/clnt.h: Add AF_UNIX based RPC function prototypes. * sunrpc/rpc/svc.h: Likewise. * sunrpc/svc_authux.c: Copy internal auth flavor if none is given. * sunrpc/svc_tcp.c: Fix typos. * sunrpc/svc_unix.c: New, server side of AF_UNIX based RPC. * nis/Makefile: Remove currently not working cache functions. * nis/Versions: Add __nisbind_* functions for rpc.nisd. * nis/nis_call.c: Rewrite binding to a NIS+ server to reuse CLIENT handles. * nis/nis_file.c: Fix memory leaks. * nis/nis_intern.h: Move internal structs from here ... * nis/rpcsvc/nislib.h: ... to here for NIS+ server and tools. * nis/nis_lookup.c: Try at first if last client handle works. * nis/nis_table.c: Likewise. * nis/nis_checkpoint.c: Adjust __do_niscall2 parameters. * nis/nis_mkdir.c: Likewise. * nis/nis_ping.c: Likewise. * nis/nis_rmdir.c: Likewise. * nis/nis_server.c: Likewise. * nis/nis_util.c: Likewise. * nis/nis_findserv.c (__nis_findfastest): Little optimization. 1998-07-28 Andreas Jaeger <aj@arthur.rhein-neckar.de> * stdlib/strtol.c (STRTOL_LONG_MAX): Correct typo in last patch - define as LONG_MAX. 1998-07-28 09:31 Ulrich Drepper <drepper@cygnus.com> * nscd/connections.c (gr_send_answer): Deal with missing UIO_MAXIOV. Correct test whether writev send all data. * nscd/nscd_getgr_r.c (__nscd_getgr_r): Correct test whether readv received all data. 1998-07-28 Mark Kettenis <kettenis@phys.uva.nl> * nscd/nscd_getgr_r.c (__nscd_getgr_r): Deal with missing UIO_MAXIOV. 1998-07-28 Mark Kettenis <kettenis@phys.uva.nl> * sysdeps/mach/hurd/dl-sysdep.c (open_file): Change assert call to allow mode to be 0. (__xstat): New function. (__fxstat): New function. (_dl_sysdep_read_whole_file): Removed. The implementation in `elf/dl-misc.c' now also works for the Hurd.
1998-07-28 18:26:04 +02:00
int local_signgam;
double y = __ieee754_gamma_r(x,&local_signgam);
if(__glibc_unlikely (!isfinite (y) || y == 0)
&& (isfinite (x) || (isinf (x) && x < 0.0))
&& _LIB_VERSION != _IEEE_) {
if (x == 0.0)
return __kernel_standard(x,x,50); /* tgamma pole */
Use floor functions not __floor functions in glibc libm. Similar to the changes that were made to call sqrt functions directly in glibc, instead of __ieee754_sqrt variants, so that the compiler could inline them automatically without needing special inline definitions in lots of math_private.h headers, this patch makes libm code call floor functions directly instead of __floor variants, removing the inlines / macros for x86_64 (SSE4.1) and powerpc (POWER5). The redirection used to ensure that __ieee754_sqrt does still get called when the compiler doesn't inline a built-in function expansion is refactored so it can be applied to other functions; the refactoring is arranged so it's not limited to unary functions either (it would be reasonable to use this mechanism for copysign - removing the inline in math_private_calls.h but also eliminating unnecessary local PLT entry use in the cases (powerpc soft-float and e500v1, for IBM long double) where copysign calls don't get inlined). The point of this change is that more architectures can get floor calls inlined where they weren't previously (AArch64, for example), without needing special inline definitions in their math_private.h, and existing such definitions in math_private.h headers can be removed. Note that it's possible that in some cases an inline may be used where an IFUNC call was previously used - this is the case on x86_64, for example. I think the direct calls to floor are still appropriate; if there's any significant performance cost from inline SSE2 floor instead of an IFUNC call ending up with SSE4.1 floor, that indicates that either the function should be doing something else that's faster than using floor at all, or it should itself have IFUNC variants, or that the compiler choice of inlining for generic tuning should change to allow for the possibility that, by not inlining, an SSE4.1 IFUNC might be called at runtime - but not that glibc should avoid calling floor internally. (After all, all the same considerations would apply to any user program calling floor, where it might either be inlined or left as an out-of-line call allowing for a possible IFUNC.) Tested for x86_64, and with build-many-glibcs.py. * include/math.h [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (MATH_REDIRECT): New macro. [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (MATH_REDIRECT_LDBL): Likewise. [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (MATH_REDIRECT_F128): Likewise. [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (MATH_REDIRECT_UNARY_ARGS): Likewise. [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (sqrt): Redirect using MATH_REDIRECT. [!_ISOMAC && !(__FINITE_MATH_ONLY__ && __FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (floor): Likewise. * sysdeps/aarch64/fpu/s_floor.c: Define NO_MATH_REDIRECT before header inclusion. * sysdeps/aarch64/fpu/s_floorf.c: Likewise. * sysdeps/ieee754/dbl-64/s_floor.c: Likewise. * sysdeps/ieee754/dbl-64/wordsize-64/s_floor.c: Likewise. * sysdeps/ieee754/float128/s_floorf128.c: Likewise. * sysdeps/ieee754/flt-32/s_floorf.c: Likewise. * sysdeps/ieee754/ldbl-128/s_floorl.c: Likewise. * sysdeps/ieee754/ldbl-128ibm/s_floorl.c: Likewise. * sysdeps/m68k/m680x0/fpu/s_floor_template.c: Likewise. * sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_floor.c: Likewise. * sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_floorf.c: Likewise. * sysdeps/powerpc/powerpc64/fpu/multiarch/s_floor.c: Likewise. * sysdeps/powerpc/powerpc64/fpu/multiarch/s_floorf.c: Likewise. * sysdeps/riscv/rv64/rvd/s_floor.c: Likewise. * sysdeps/riscv/rvf/s_floorf.c: Likewise. * sysdeps/sparc/sparc64/fpu/multiarch/s_floor.c: Likewise. * sysdeps/sparc/sparc64/fpu/multiarch/s_floorf.c: Likewise. * sysdeps/x86_64/fpu/multiarch/s_floor.c: Likewise. * sysdeps/x86_64/fpu/multiarch/s_floorf.c: Likewise. * sysdeps/powerpc/fpu/math_private.h [_ARCH_PWR5X] (__floor): Remove macro. [_ARCH_PWR5X] (__floorf): Likewise. * sysdeps/x86_64/fpu/math_private.h [__SSE4_1__] (__floor): Remove inline function. [__SSE4_1__] (__floorf): Likewise. * math/w_lgamma_main.c (LGFUNC (__lgamma)): Use floor functions instead of __floor variants. * math/w_lgamma_r_compat.c (__lgamma_r): Likewise. * math/w_lgammaf_main.c (LGFUNC (__lgammaf)): Likewise. * math/w_lgammaf_r_compat.c (__lgammaf_r): Likewise. * math/w_lgammal_main.c (LGFUNC (__lgammal)): Likewise. * math/w_lgammal_r_compat.c (__lgammal_r): Likewise. * math/w_tgamma_compat.c (__tgamma): Likewise. * math/w_tgamma_template.c (M_DECL_FUNC (__tgamma)): Likewise. * math/w_tgammaf_compat.c (__tgammaf): Likewise. * math/w_tgammal_compat.c (__tgammal): Likewise. * sysdeps/ieee754/dbl-64/e_lgamma_r.c (sin_pi): 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/flt-32/e_lgammaf_r.c (sin_pif): Likewise. * sysdeps/ieee754/flt-32/lgamma_negf.c (__lgamma_negf): Likewise. * sysdeps/ieee754/ldbl-128/e_lgammal_r.c (__ieee754_lgammal_r): Likewise. * sysdeps/ieee754/ldbl-128/e_powl.c (__ieee754_powl): Likewise. * sysdeps/ieee754/ldbl-128/lgamma_negl.c (__lgamma_negl): Likewise. * sysdeps/ieee754/ldbl-128/s_expm1l.c (__expm1l): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_lgammal_r.c (__ieee754_lgammal_r): Likewise. * sysdeps/ieee754/ldbl-128ibm/e_powl.c (__ieee754_powl): Likewise. * sysdeps/ieee754/ldbl-128ibm/lgamma_negl.c (__lgamma_negl): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_expm1l.c (__expm1l): Likewise. * sysdeps/ieee754/ldbl-128ibm/s_truncl.c (__truncl): Likewise. * sysdeps/ieee754/ldbl-96/e_lgammal_r.c (sin_pi): Likewise. * sysdeps/ieee754/ldbl-96/lgamma_negl.c (__lgamma_negl): Likewise. * sysdeps/powerpc/power5+/fpu/s_modf.c (__modf): Likewise. * sysdeps/powerpc/power5+/fpu/s_modff.c (__modff): Likewise.
2018-09-14 15:09:01 +02:00
else if(floor(x)==x&&x<0.0)
return __kernel_standard(x,x,41); /* tgamma domain */
else if (y == 0)
__set_errno (ERANGE); /* tgamma underflow */
Update. 1998-07-28 Ulrich Drepper <drepper@cygnus.com> * math/libm-test.c (tgamma_test): Remove redundant tests. 1998-07-28 16:20 Ulrich Drepper <drepper@cygnus.com> * sysdeps/generic/glob.c: Correct problems with */foo and GLOB_NOCHECK where foo does not exist in any of the subdirectories. Reported by Paul D. Smith <psmith@BayNetworks.COM>. * posix/globtest.sh: Add test for this bug. 1998-07-28 Mark Kettenis <kettenis@phys.uva.nl> * io/sys/statfs.h: Fix typos. * io/sys/statvfs.h: Fix typos. 1998-07-28 Ulrich Drepper <drepper@cygnus.com> * version.h (VERSION): Bump to 2.0.95. * math/Makefile (libm-calls): Remove w_gamma, add w_tgamma. * math/Versions [GLIBC_2.1]: Add tgamma, tgammaf, and tgammal. * math/libm-test.c: Split old gamma_test and move half of it in new function tgamma_test. * math/bits/mathcalls.h: Add declaration of tgamma. * sysdeps/libm-ieee754/k_standard.c: Change gamma errors into tgamma errors. * sysdeps/libm-ieee754/w_gamma.c: Remove lgamma compatibility code and rename to ... * sysdeps/libm-ieee754/w_tgamma.c: ... this. New file. * sysdeps/libm-ieee754/w_gammaf.c: Remove lgammaf compatibility code and rename to ... * sysdeps/libm-ieee754/w_tgammaf.c: ... this. New file. * sysdeps/libm-ieee754/w_gammal.c: Remove lgammal compatibility code and rename to ... * sysdeps/libm-ieee754/w_tgammal.c: ... this. New file. * sysdeps/libm-ieee754/w_lgamma.c: Add gamma as weak alias. * sysdeps/libm-ieee754/w_lgammaf.c: Likewise. * sysdeps/libm-ieee754/w_lgammal.c: Likewise. * stgdio-common/printf-parse.h: Implement handling of j, t, and z modifiers. * stdio-common/vfprintf.c: Likewise. * stdio-common/vfscanf.c: Likewise. * manual/stdio.texi: Document new printf/scanf modifiers. * sysdeps/unix/sysv/linux/recvmsg.c: Remove alias __recvmsg. * sysdeps/unix/sysv/linux/sendmsg.c: Remove alias __sendmsg. 1998-07-28 Thorsten Kukuk <kukuk@vt.uni-paderborn.de> * sunrpc/Makefile (routines): Add clnt_unix and svc_unix. * sunrpc/Versions: Add new *unix_create functions. * sunrpc/clnt_gen.c: Add support for RPC over AF_UNIX. * sunrpc/clnt_unix.c: New, client side of RPC over AF_UNIX. * sunrpc/key_call.c: Use RPC over AF_UNIX for communication with keyserv daemon. * sunrpc/rpc/clnt.h: Add AF_UNIX based RPC function prototypes. * sunrpc/rpc/svc.h: Likewise. * sunrpc/svc_authux.c: Copy internal auth flavor if none is given. * sunrpc/svc_tcp.c: Fix typos. * sunrpc/svc_unix.c: New, server side of AF_UNIX based RPC. * nis/Makefile: Remove currently not working cache functions. * nis/Versions: Add __nisbind_* functions for rpc.nisd. * nis/nis_call.c: Rewrite binding to a NIS+ server to reuse CLIENT handles. * nis/nis_file.c: Fix memory leaks. * nis/nis_intern.h: Move internal structs from here ... * nis/rpcsvc/nislib.h: ... to here for NIS+ server and tools. * nis/nis_lookup.c: Try at first if last client handle works. * nis/nis_table.c: Likewise. * nis/nis_checkpoint.c: Adjust __do_niscall2 parameters. * nis/nis_mkdir.c: Likewise. * nis/nis_ping.c: Likewise. * nis/nis_rmdir.c: Likewise. * nis/nis_server.c: Likewise. * nis/nis_util.c: Likewise. * nis/nis_findserv.c (__nis_findfastest): Little optimization. 1998-07-28 Andreas Jaeger <aj@arthur.rhein-neckar.de> * stdlib/strtol.c (STRTOL_LONG_MAX): Correct typo in last patch - define as LONG_MAX. 1998-07-28 09:31 Ulrich Drepper <drepper@cygnus.com> * nscd/connections.c (gr_send_answer): Deal with missing UIO_MAXIOV. Correct test whether writev send all data. * nscd/nscd_getgr_r.c (__nscd_getgr_r): Correct test whether readv received all data. 1998-07-28 Mark Kettenis <kettenis@phys.uva.nl> * nscd/nscd_getgr_r.c (__nscd_getgr_r): Deal with missing UIO_MAXIOV. 1998-07-28 Mark Kettenis <kettenis@phys.uva.nl> * sysdeps/mach/hurd/dl-sysdep.c (open_file): Change assert call to allow mode to be 0. (__xstat): New function. (__fxstat): New function. (_dl_sysdep_read_whole_file): Removed. The implementation in `elf/dl-misc.c' now also works for the Hurd.
1998-07-28 18:26:04 +02:00
else
return __kernel_standard(x,x,40); /* tgamma overflow */
}
return local_signgam < 0 ? -y : y;
Mon Apr 1 13:34:55 1996 Roland McGrath <roland@whiz-bang.gnu.ai.mit.edu> * stdio-common/tst-printf.c (main): Add new test case. * sysdeps/generic/setenv.c (unsetenv): Use old-style definition. Mon Apr 1 11:39:10 Ulrich Drepper <drepper@gnu.ai.mit.edu> * stdlib/strtod.c (STRTOD): Fix handling of American style FP numbers. * stdio-common/vfprintf.c (vfprintf): Don't increment format string pointer twice after seeing `*'. Sun Mar 31 17:31:54 1996 Roland McGrath <roland@whiz-bang.gnu.ai.mit.edu> * MakeTAGS (po/SYS_libc.pot): Prepend header processed from po/header.pot. Sun Mar 31 18:07:32 1996 Ulrich Drepper <drepper@gnu.ai.mit.edu> * locale/Makefile (others, install-bin): Compiling locale works again. (locale-modules): locale has no --dump option anymore. Remove ctypedump. * locale/programs/config.h: Don't declare euidaccess. Use #include_next to get libc's config.h. * locale/programs/ctypedump.c: Not needed anymore. Dump option of locale is removed. * locale/programs/locale.c: Adapt for new locale implementation. * stdio-common/_itoa.h (_itoa_word): Define as inline function. * stdio-common/_itoa.c (_itoa_lower_digits, _itoa_upper_digits): Don't declare static because used in _itoa_word inline function. * stdio-common/printf-parse.h: Prepare for use in wide-char stdio implementation. (find_spec): Take additional argument to work with mbrlen instead of mblen. (parse_one_spec): Ditto. * stdio-common/printf-prs.c: Prepare for use in wide-char stdio implementation. * stdio-common/printf.h: Mark change for wide-char handling. Changing it now would result in incompatibilities. * stdio-common/vfprintf.c: New and fast implementation. * wcsmbs/Makefile (routines): Remove pre-ISO C multibyte functions mbsadvance, mbscat, mbschr, mbscmp, mbscpy, mbsdup, mbslen, mbsncat, mbsncmp, mbsncpy, mbsrchr, mbstomb. Change wcswcs to wcsstr. Add wmemchr, wmemcmp, wmemcpy, wmemmove, wmemset, btowc, wctob, mbsinit, mbrlen, mbrtowc, wcrtomb, mbsrtowcs, wcsrtombs. * wcsmbs/btowc.c, wcsmbs/mbrlen.c, wcsmbs/mbrtowc.c, wcsmbs/mbsinit.c, wcsmbs/mbsrtowcs.c, wcsmbs/wchar.h, wcsmbs/wcrtomb.c, wcsmbs/wcsrtombs.c, wcsmbs/wcsstr.c, wcsmbs/wctob.c, wcsmbs/wmemchr.c, wcsmbs/wmemcmp.c, wcsmbs/wmemcpy.c, wcsmbs/wmemmove.c, wcsmbs/wmemset.c: New function according to ISO C amendment 1. * wchar.h: Wrapper around "wcsmbs/wchar.h". * wcsmbs/wcscat.c, wcsmbs/wcschr.c, wcsmbs/wcscmp.c, wcsmbs/wcscpy.c, wcsmbs/wcscspn.c, wcsmbs/wcsdup.c, wcsmbs/wcslen.c, wcsmbs/wcsncat.c, wcsmbs/wcsncmp.c, wcsmbs/wcsncpy.c, wcsmbs/wcspbrk.c, wcsmbs/wcsrchr.c, wcsmbs/wcsspn.c, wcsmbs/wcstok.c: Changed to conform with ISO C amendment 1. * wcsmbs/mbsadvance.c, wcsmbs/mbscat.c, wcsmbs/mbschr.c, wcsmbs/mbscmp.c, wcsmbs/mbscpy.c, wcsmbs/mbsdup.c, wcsmbs/mbslen.c, wcsmbs/mbsncat.c, wcsmbs/mbsncmp.c, wcsmbs/mbsncpy.c, wcsmbs/mbsrchr.c, wcsmbs/mbstomb.c, wcsmbs/mbstr.h, wcsmbs/wcstr.h, wcsmbs/wcswcs.c: Removed. Implement functions from early drafts, not part of final standard. Sun Mar 31 16:50:41 1996 Roland McGrath <roland@whiz-bang.gnu.ai.mit.edu> * setjmp/setjmp.h (jmp_buf): Change gratuitous struct tag name to __jmp_bug_tag so its C++ implicit typedef does not conflict with the __jmp_buf typedef. * Makerules (BUILD_CFLAGS) [! objdir]: Use $(..)config.h when compiling in the source directories. Fri Mar 29 16:26:35 1996 Roland McGrath <roland@whiz-bang.gnu.ai.mit.edu> * sysdeps/libm-ieee754/w_gamma.c: Use signgam instead of __signgam. * sysdeps/libm-ieee754/s_signgam.c: Undo last change.
1996-04-02 15:27:17 +02:00
}
Use libm_alias_double in math/. This patch converts libm function implementations in math/ from using weak_alias to using libm_alias_double to define public function names, in cases where it would be appropriate to define _Float64 / _Float32x aliases for those functions as well. This eliminates many NO_LONG_DOUBLE conditionals and ldbl-opt wrappers round these function implementations. Tested for x86_64. Also tested with build-many-glibcs.py. Binary differences seen are that the different order in which remainder and drem symbols get defined as a result of this patch (the same source file defines the same aliases, but in a different order of definition) changes the order of symbols in the final libm.so when long double = double, and for ldbl-opt configurations, the compat symbols for Bessel functions were previously defined by e.g. "compat_symbol (libm, j0, j0l, GLIBC_2_0)", which declares j0l as a compat symbol based on j0 and so makes j0l weak because j0 is weak, and are now defined (indirectly via the relevant macros) based on e.g. __j0, so are no longer weak because __j0 isn't weak. * math/s_fma.c: Include <libm-alias-double.h>. (fma): Define using libm_alias_double. * math/s_nextafter.c: Include <libm-alias-double.h>. (nextafter): Define using libm_alias_double. * math/w_acos_compat.c: Include <libm-alias-double.h>. (acos): Define using libm_alias_double. * math/w_acosh_compat.c: Include <libm-alias-double.h>. (aocsh): Define using libm_alias_double. * math/w_asin_compat.c: Include <libm-alias-double.h>. (asin): Define using libm_alias_double. * math/w_atan2_compat.c: Include <libm-alias-double.h>. (atan2): Define using libm_alias_double. * math/w_atanh_compat.c: Include <libm-alias-double.h>. (atanh): Define using libm_alias_double. * math/w_cosh_compat.c: Include <libm-alias-double.h>. (cosh): Define using libm_alias_double. * math/w_exp10_compat.c: Include <libm-alias-double.h>. (exp10): Define using libm_alias_double. * math/w_exp2_compat.c: Include <libm-alias-double.h>. (exp2): Define using libm_alias_double. * math/w_exp_compat.c: Include <libm-alias-double.h>. (exp): Define using libm_alias_double. * math/w_fmod_compat.c: Include <libm-alias-double.h>. (fmod): Define using libm_alias_double. * math/w_hypot_compat.c: Include <libm-alias-double.h>. (hypot): Define using libm_alias_double. * math/w_j0_compat.c: Include <libm-alias-double.h>. (j0): Define using libm_alias_double. (y0): Likewise. * math/w_j1_compat.c: Include <libm-alias-double.h>. (j1): Define using libm_alias_double. (y1): Likewise. * math/w_jn_compat.c: Include <libm-alias-double.h>. (jn): Define using libm_alias_double. (yn): Likewise. * math/w_log10_compat.c: Include <libm-alias-double.h>. (log10): Define using libm_alias_double. * math/w_log2_compat.c: Include <libm-alias-double.h>. (log2): Define using libm_alias_double. * math/w_log_compat.c: Include <libm-alias-double.h>. (log): Define using libm_alias_double. * math/w_pow_compat.c: Include <libm-alias-double.h>. (pow): Define using libm_alias_double. * math/w_remainder_compat.c: Include <libm-alias-double.h>. (remainder): Define using libm_alias_double. * math/w_sinh_compat.c: Include <libm-alias-double.h>. (sinh): Define using libm_alias_double. * math/w_sqrt_compat.c: Include <libm-alias-double.h>. (sqrt): Define using libm_alias_double. * math/w_tgamma_compat.c: Include <libm-alias-double.h>. (tgamma): Define using libm_alias_double. * sysdeps/ieee754/ldbl-opt/s_nextafter.c [LONG_DOUBLE_COMPAT(libm, GLIBC_2_0)] (nextafterl): Do not define compat symbol here. * sysdeps/ieee754/ldbl-opt/w_exp10_compat.c [LONG_DOUBLE_COMPAT(libm, GLIBC_2_1)] (exp10l): Likewise. * sysdeps/ieee754/ldbl-opt/w_remainder_compat.c [LONG_DOUBLE_COMPAT(libm, GLIBC_2_0)] (remainderl): Likewise. * sysdeps/ieee754/ldbl-opt/w_acos_compat.c: Remove. * sysdeps/ieee754/ldbl-opt/w_acosh_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_asin_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_atan2_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_atanh_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_cosh_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_exp_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_fmod_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_hypot_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_j0_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_j1_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_jn_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_log10_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_log2_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_log_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_pow_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_sinh_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_sqrt_compat.c: Likewise. * sysdeps/ieee754/ldbl-opt/w_tgamma_compat.c: Likewise.
2017-09-16 01:10:02 +02:00
libm_alias_double (__tgamma, tgamma)
update from main archive 961005 Sun Oct 6 02:05:52 1996 Ulrich Drepper <drepper@cygnus.com> * posix/getopt.c: Add casts to prevent warnings. * posix/regex.c: Likewise. * math/Makefile (long-m-routines, long-m-yes): Define to correct values to make `long double' functions available. (distribute): Add $(long-m-yes:=.c). * sysdeps/libm-i387/s_ceill.S: Correct loading of return value. Use long double instruction. * sysdeps/libm-ieee754/e_atanhl.c (huge): Correct constant. * sysdeps/libm-ieee754/e_asinhl.c: Likewise. * sysdeps/libm-ieee754/s_tanhl.c: Likewise. * sysdeps/libm-ieee754/e_coshl.c: New file. * sysdeps/libm-ieee754/s_asinh.c [!NO_LONG_DOUBLE]: Define names for `long double' version as alias. * sysdeps/libm-ieee754/s_atan.c: Likewise. * sysdeps/libm-ieee754/s_cbrt.c: Likewise. * sysdeps/libm-ieee754/s_ceil.c: Likewise. * sysdeps/libm-ieee754/s_copysign.c: Likewise. * sysdeps/libm-ieee754/s_cos.c: Likewise. * sysdeps/libm-ieee754/s_erf.c: Likewise. * sysdeps/libm-ieee754/s_expm1.c: Likewise. * sysdeps/libm-ieee754/s_fabs.c: Likewise. * sysdeps/libm-ieee754/s_finite.c: Likewise. * sysdeps/libm-ieee754/s_floor.c: Likewise. * sysdeps/libm-ieee754/s_frexp.c: Likewise. * sysdeps/libm-ieee754/s_ilogb.c: Likewise. * sysdeps/libm-ieee754/s_ldexp.c: Likewise. * sysdeps/libm-ieee754/s_log1p.c: Likewise. * sysdeps/libm-ieee754/s_logb.c: Likewise. * sysdeps/libm-ieee754/s_modf.c: Likewise. * sysdeps/libm-ieee754/s_nextafter.c: Likewise. * sysdeps/libm-ieee754/s_rint.c: Likewise. * sysdeps/libm-ieee754/s_scalbn.c: Likewise. * sysdeps/libm-ieee754/s_significand.c: Likewise. * sysdeps/libm-ieee754/s_sin.c: Likewise. * sysdeps/libm-ieee754/s_tan.c: Likewise. * sysdeps/libm-ieee754/s_tanh.c: Likewise. * sysdeps/libm-ieee754/w_acos.c: Likewise. * sysdeps/libm-ieee754/w_acosh.c: Likewise. * sysdeps/libm-ieee754/w_sin.c: Likewise. * sysdeps/libm-ieee754/w_atan2.c: Likewise. * sysdeps/libm-ieee754/w_atanh.c: Likewise. * sysdeps/libm-ieee754/w_cabs.c: Likewise. * sysdeps/libm-ieee754/w_cosh.c: Likewise. * sysdeps/libm-ieee754/w_drem.c: Likewise. * sysdeps/libm-ieee754/w_exp.c: Likewise. * sysdeps/libm-ieee754/w_fmod.c: Likewise. * sysdeps/libm-ieee754/w_gamma.c: Likewise. * sysdeps/libm-ieee754/w_gamma_r.c: Likewise. * sysdeps/libm-ieee754/w_hypot.c: Likewise. * sysdeps/libm-ieee754/w_j0.c: Likewise. * sysdeps/libm-ieee754/w_j1.c: Likewise. * sysdeps/libm-ieee754/w_jn.c: Likewise. * sysdeps/libm-ieee754/w_lgamma.c: Likewise. * sysdeps/libm-ieee754/w_lgamma_r.c: Likewise. * sysdeps/libm-ieee754/w_log.c: Likewise. * sysdeps/libm-ieee754/w_log10.c: Likewise. * sysdeps/libm-ieee754/w_pow.c: Likewise. * sysdeps/libm-ieee754/w_remainder.c: Likewise. * sysdeps/libm-ieee754/w_scalb.c: Likewise. * sysdeps/libm-ieee754/w_sinh.c: Likewise. * sysdeps/libm-ieee754/w_sqrt.c: Likewise. Stub files for missing long double math functions. * sysdeps/stub/e_acoshl.c: New file. * sysdeps/stub/e_hypotl.c: New file. * sysdeps/stub/e_j0l.c: New file. * sysdeps/stub/e_j1l.c: New file. * sysdeps/stub/e_jnl.c: New file. * sysdeps/stub/e_lgammal_r.c: New file. * sysdeps/stub/e_powl.c: New file. * sysdeps/stub/e_rem_pio2l.c: New file. * sysdeps/stub/e_sinhl.c: New file. * sysdeps/stub/k_cosl.c: New file. * sysdeps/stub/k_rem_pio2l.c: New file. * sysdeps/stub/k_sinl.c: New file. * sysdeps/stub/k_tanl.c: New file. * sysdeps/stub/s_erfl.c: New file. * sysdeps/stub/s_expm1l.c: New file. * sysdeps/i386/__longjmp.S: Use PSEUDO_END macro to provide .size directive. * sysdeps/i386/bsd-_setjmp.S: Likewise. * sysdeps/i386/bsd-setjmp.S: Likewise. * sysdeps/i386/memchr.S: Likewise. * sysdeps/i386/memcmp.S: Likewise. * sysdeps/i386/setjmp.S: Likewise. * sysdeps/i386/stpcpy.S: Likewise. * sysdeps/i386/stpncpy.S: Likewise. * sysdeps/i386/strchr.S: Likewise. * sysdeps/i386/strcspn.S: Likewise. * sysdeps/i386/strpbrk.S: Likewise. * sysdeps/i386/strrchr.S: Likewise. * sysdeps/i386/strspn.S: Likewise. * sysdeps/i386/strtok.S: Likewise. * sysdeps/i386/i486/strcat.S: Likewise. * sysdeps/i386/i486/strlen.S: Likewise. * sysdeps/i386/i586/memset.S: Likewise. * sysdeps/i386/i586/strchr.S: Likewise. * sysdeps/i386/i586/strlen.S: Likewise. * sysdeps/libm-i387/e_acos.S: Likewise. * sysdeps/libm-i387/e_acosl.S: Likewise. * sysdeps/libm-i387/e_asin.S: Likewise. * sysdeps/libm-i387/e_asinl.S: Likewise. * sysdeps/libm-i387/e_atan2.S: Likewise. * sysdeps/libm-i387/e_atan2l.S: Likewise. * sysdeps/libm-i387/e_exp.S: Likewise. * sysdeps/libm-i387/e_expl.S: Likewise. * sysdeps/libm-i387/e_fmod.S: Likewise. * sysdeps/libm-i387/e_fmodl.S: Likewise. * sysdeps/libm-i387/e_log.S: Likewise. * sysdeps/libm-i387/e_log10.S: Likewise. * sysdeps/libm-i387/e_log10l.S: Likewise. * sysdeps/libm-i387/e_logl.S: Likewise. * sysdeps/libm-i387/e_remainder.S: Likewise. * sysdeps/libm-i387/e_remainderf.S: Likewise. * sysdeps/libm-i387/e_remainderl.S: Likewise. * sysdeps/libm-i387/e_scalb.S: Likewise. * sysdeps/libm-i387/e_scalbl.S: Likewise. * sysdeps/libm-i387/e_sqrt.S: Likewise. * sysdeps/libm-i387/e_sqrtf.S: Likewise. * sysdeps/libm-i387/e_sqrtl.S: Likewise. * sysdeps/libm-i387/s_atan.S: Likewise. * sysdeps/libm-i387/s_atanf.S: Likewise. * sysdeps/libm-i387/s_atanl.S: Likewise. * sysdeps/libm-i387/s_ceil.S: Likewise. * sysdeps/libm-i387/s_ceilf.S: Likewise. * sysdeps/libm-i387/s_ceill.S: Likewise. * sysdeps/libm-i387/s_copysign.S: Likewise. * sysdeps/libm-i387/s_copysignf.S: Likewise. * sysdeps/libm-i387/s_copysignl.S: Likewise. * sysdeps/libm-i387/s_cos.S: Likewise. * sysdeps/libm-i387/s_cosf.S: Likewise. * sysdeps/libm-i387/s_cosl.S: Likewise. * sysdeps/libm-i387/s_finite.S: Likewise. * sysdeps/libm-i387/s_finitef.S: Likewise. * sysdeps/libm-i387/s_finitel.S: Likewise. * sysdeps/libm-i387/s_floor.S: Likewise. * sysdeps/libm-i387/s_floorf.S: Likewise. * sysdeps/libm-i387/s_floorl.S: Likewise. * sysdeps/libm-i387/s_ilogb.S: Likewise. * sysdeps/libm-i387/s_ilogbf.S: Likewise. * sysdeps/libm-i387/s_ilogbl.S: Likewise. * sysdeps/libm-i387/s_log1p.S: Likewise. * sysdeps/libm-i387/s_log1pf.S: Likewise. * sysdeps/libm-i387/s_log1pl.S: Likewise. * sysdeps/libm-i387/s_logb.S: Likewise. * sysdeps/libm-i387/s_logbf.S: Likewise. * sysdeps/libm-i387/s_logbl.S: Likewise. * sysdeps/libm-i387/s_rint.S: Likewise. * sysdeps/libm-i387/s_rintf.S: Likewise. * sysdeps/libm-i387/s_rintl.S: Likewise. * sysdeps/libm-i387/s_scalbn.S: Likewise. * sysdeps/libm-i387/s_scalbnf.S: Likewise. * sysdeps/libm-i387/s_scalbnl.S: Likewise. * sysdeps/libm-i387/s_significand.S: Likewise. * sysdeps/libm-i387/s_significandf.S: Likewise. * sysdeps/libm-i387/s_significandl.S: Likewise. * sysdeps/libm-i387/s_sin.S: Likewise. * sysdeps/libm-i387/s_sinf.S: Likewise. * sysdeps/libm-i387/s_sinl.S: Likewise. * sysdeps/libm-i387/s_tan.S: Likewise. * sysdeps/libm-i387/s_tanf.S: Likewise. * sysdeps/libm-i387/s_tanl.S: Likewise. * sysdeps/unix/sysv/linux/i386/clone.S: Add .size directive. * sysdeps/unix/sysv/linux/i386/mmap.S. Likewise. * sysdeps/unix/sysv/linux/i386/socket.S. Likewise. * sysdeps/unix/sysv/linux/i386/sysdep.S. More compact .size line. * sysdeps/i386/sysdep.h (ASM_SIZE_DIRECTIVE): New macro. Used to provide .size directive on ELF systems. * sysdeps/unix/sysv/linux/i386/profil-counter.h: Include <sigcontext.h> and rename parameter type to sigcontext. * sysdeps/unix/sysv/linux/i386/sigcontext.h New file. * sysdeps/unix/sysv/linux/i386/syscall.S: From Linux 2.1 on negative values might occur as positive results. Test against -125 to decide for error or not. * sysdeps/unix/sysv/linux/i386/sysdep.h: Likewise for system calls. Thu Oct 3 21:07:58 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * elf/dl-open.c: Use _DYNAMIC instead of _dl_start to decide whether this is a statically linked program. The latter is now always defined. Fri Oct 4 02:08:10 1996 Bang Jun-Young <bangjy@nownuri.nowcom.co.kr> * po/ko.po: Update. Fri Oct 4 02:07:46 1996 Michel Robitaille <robitail@IRO.UMontreal.CA> * po/fr.po: New file. Fri Oct 4 05:04:52 1996 Ulrich Drepper <drepper@cygnus.com> * sysdeps/unix/sysv/linux/i386/sigcontext.h: New file. Add support for MD5 crypt replacement. * Makefile (subdirs): Add crypt. * shlib-versions: Add entry for libcrypt. * crypt/md5-crypt.c: New file. * crypt/md5.c: New file. * crypt/md5.h: New file. * sysdeps/generic/crypt-entry.c: New file. * sysdeps/generic/crypt.h: New file. Thu Oct 3 20:53:23 1996 Andreas Jaeger <aj@arthur.pfalz.de> * dirent/tst-seekdir.c: Provide correct prototypes. * io/test-utime.c: Likewise. * malloc/mallocbug.c: Likewise. * posix/testfnm.c: Likewise. * stdio-common/xbug.c: Likewise. * sysdeps/posix/cuserid.c: Likewise. Wed Oct 2 13:33:48 1996 Richard Henderson <rth@tamu.edu> Provide optimized string functions for Alpha processors. * sysdeps/alpha/bzero.S: New file. * sysdeps/alpha/memset.S: New file. * sysdeps/alpha/stpcpy.S: New file. * sysdeps/alpha/stpncpy.S: New file. * sysdeps/alpha/strcat.S: New file. * sysdeps/alpha/strchr.S: New file. * sysdeps/alpha/strcpy.S: New file. * sysdeps/alpha/strncat.S: New file. * sysdeps/alpha/strncpy.S: New file. * sysdeps/alpha/strrchr.S: New file. * sysdeps/alpha/stxcpy.S: New file. * sysdeps/alpha/stxncpy.S: New file. * sysdeps/alpha/Makefile [$(sudir)==string]: Add stxcpy and stxncpy to sysdep_routines. Minor correction. Wed Oct 2 13:41:48 1996 Ulrich Drepper <drepper@cygnus.com> * sysdeps/generic/strtok.c: Don't set stored pointer to NULL when notheing is found. This guarantees all subsequent calls behave the same. * sysdeps/generic/strtok_r.c: Likewise. Mon Sep 30 22:27:36 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/posix/tempname.c (__stdio_gen_tempname): Don't declare `i' as const. Mon Sep 30 22:38:29 1996 Richard Henderson <rth@tamu.edu> * sysdeps/generic/strtok.c: When we hit EOS, don't set olds to NULL immediately; we're going to get called one more time. * sysdeps/generic/strtok_r.c: Likewise. Tue Oct 1 09:12:21 1996 Ulrich Drepper <drepper@cygnus.com> * locale/programs/ld-time.c: Always write some bytes at the end of the file even if no `era's are specified. * stdio-common/tmpname.c (tmpbuf): Don't define as array of pointers. Tue Oct 1 01:43:11 1996 Ulrich Drepper <drepper@cygnus.com> * libio/iofclose.c: Move unlocking to right position. Mon Sep 30 03:08:34 1996 Richard Henderson <rth@tamu.edu> * misc/Makefile: Kill force-wrapper. * misc/force-wrapper.c: Delete. * elf/eval.c: Add <string.h>. * gmon/sys/gmon_out.h: Nonsense like `char foo[sizeof(char*)]' followed by `bcopy(&ptr, &foo, sizeof(foo))' helps portability and binary compatibility not at all. Better to do `char *foo' followed by `foo = ptr' as it is much cleaner. (struct gmon_hdr): Fix version. (struct gmon_hist_hdr): Fix low_pc, high_pc, hist_size, prof_rate. (struct gmon_cg_arc_record): Fix from_pc, self_pc, count. * gmon/gmon.c: De-ansidecl-ify. (write_hist): De-bcopy-fy. (write_call_graph): Likewise. * gmon/mcount.c: Assume _MCOUNT_DECL does the entire declaration. * sysdeps/alpha/machine-gmon.h: Update _MCOUNT_DECL. * sysdeps/generic/machine-gmon.h: Likewise. * resolv/netdb.h: Add __set_h_errno to mimic __set_errno. * nss/getXXent_r.c: Use __set_h_errno to set h_errno in all funcs. * nss/nss_dns/dns-network.c: Likewise. * resolv/getunamaddr.c: Likewise. Also use __set_errno where needed. * resolv/getnetnamadr.c: Likewise. * resolv/res_debug.c: Likewise. * resolv/res_mkquery.c: Likewise. * resolv/res_query.c: Likewise. * libio/clearerr_u.c: It's not necessary to define __ protected function so don't do it. * libio/feof_u.c, libio/ferror_u.c, libio/fputc_u.c, libio/getc_u.c, libio/getchar_u.c, libio/iofflush_u.c: Likewise. * libio/fgetc.c: Avoid a warning by casting _IO_funlockfile for the cleanup registrar. * libio/fputc.c, libio/freopen.c, libio/fseek.c, libio/getc.c, libio/getchar.c, libio/iofclose.c, libio/iofflush.c, libio/iofgetpos.c, libio/iofgets.c, libio/iofputs.c, libio/iofread.c, libio/iofsetpos.c, libio/ioftell.c, libio/iofwrite.c, libio/iogetdelim.c, libio/iogets.c, libio/ioputs.c, libio/iosetbuffer.c, libio/iosetvbuf.c, libio/ioungetc.c, libio/putc.c, libio/putchar.c, libio/rewind.c: Likewise. * locale/programs/ld-ctype.c: Include <alloca.h>. * login/login_tty.c: Get login_tty prototype from <utmp.h>. * posix/sys/types.h: Change #defines to typedefs. This is looking forward to more comprehensive namespace cleanups for C++. * posix/unistd.h: Likewise for ssize_t. * pwd/getpw.c: Prototype and rename getpw -> __getpw and add a weak alias. * resolv/base64.c: Don't do `for (NULL; ...)' as it causes `statement with no effect' warnings. * resolv/inet_neta.c: Include <string.h> for strlen. * stdio-common/getline.c: Undef ssize_t before libio redefinition. * stdio-common/tstgetln.c: Same. De-ansidecl-ify. * stdio-common/vfprintf.c: Same for va_list. * stdio-common/vfscanf.c: Same. * stdio-common/reg-printf.c: Prototype the __ function. * stdio-common/scanf.c [USE_IN_LIBIO]: Include <libioP.h> for _IO_vscanf declaration. * string/tester.c: Tsk, tsk. Don't cast pointers to int, but to unsigned long for the health of 64-bit systems. * sunrpc/svc_udp.c: Define MAX only if we don't have it yet. Many system's <sys/param.h> pulls this in. * sysdeps/generic/dl-cache.c: Kill the bottom half of the patch doubled file. * sysdeps/generic/pty.c (forkpty): Get login_tty decl from <utmp.h> instead of defining it locally. * sysdeps/posix/sigvec.c: Prototype wrapper_handler and convert_mask. * sysdeps/stub/chflags.c: Prototype chflags. * sysdeps/stub/fchflags.c: Prototype fchflags. * sysdeps/stub/sstk.c: Prototype sstk. * sysdeps/unix/alpha/sysdep.S: Add strong alias from errno variable to __errno. Update __syscall_error to store to both the global and per-thread variables. * sysdeps/unix/sysv/linux/init-first.c: Change include of init-first.h from "" to <> as "" does not search the include path. Prototype _dl_start. Sun Sep 29 14:41:17 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/unix/Makefile ($(common-objpfx)s-proto.d): Make it a pattern rule to get the right stem. Sat Sep 28 01:30:06 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * Makefile ($(objpfx)version-info.h): Fix typo in previous change. Sat Sep 28 00:44:38 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/posix/euidaccess.c (__set_errno): Fix typo. Sat Sep 28 00:40:38 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * malloc/free.c (_free_internal): Don't call free recursively, use the internal functions instead. Sat Sep 28 00:23:20 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * sysdeps/posix/tempname.c (__stdio_gen_tempname) [USE_IN_LIBIO && _IO_MTSAFE_IO]: Allocate and initialize the file lock. Fri Sep 27 23:58:17 1996 Andreas Schwab <schwab@issan.informatik.uni-dortmund.de> * catgets/gencat.c (main): Print version information on stdout, not stderr. * db/makedb.c: Likewise. * locale/programs/locale.c: Likewise. * locale/programs/localedef.c: Likewise. Mon Sep 30 00:14:26 1996 Ulrich Drepper <drepper@cygnus.com> Add implementation of netgroup. * inet/Makefile (distributes): Add netgroup.h. (routines): Add getnetgrent.c and getnetgrent_r.c. * inet/getnetgrent.c: New file. * inet/getnetgrent_r.c: New file. * inet/netgroup.h: New file. * netgroup.h: New file. * nsswitch.h: New file. * nss/Makefile (databases): Add getgrp. * nss/databases.def: Add netgroup. * nss/db-Makefile: Add rules for netgroup. * nss/netgrp-lookup.c: New file. * nss/nss.h: Add new status value NSS_STATUS_RETURN which will always return without a check of the transition table. * nss/nsswitch.h (struct service_user): Extend actions array to five elements. * nss/nsswitch.c (__nss_next): Allow NSS_STATUS_RETURN as legal status value. (nss_parse_service_list): Initialize action for NSS_STATUS_RETURN to NSS_ACTION_RETURN. * nss/nss_db/db-netgrp.c: New file. * nss/nss_files/files-netgrp.c: New file. * nss/nsswitch.conf: Add entry for netgroup. * resolv/netdb.h: Add prototypes for netgroup functions. * nss/nss_db/db-XXX.c: Use `enum nss_status' type when status value is used. Sun Sep 29 12:55:58 1996 Ulrich Drepper <drepper@cygnus.com> * sysdeps/unix/sysv/linux/syscalls.list: Change funciton name for _llseek to _llseek (not llseek). Reported by Matthias Urlichs <smurf@smurf.noris.de>. Sun Sep 29 05:34:32 1996 Ulrich Drepper <drepper@cygnus.com> * inet/rcmd.c: Remove definition of MIN. Sat Sep 28 14:22:51 1996 Ulrich Drepper <drepper@cygnus.com> * dirent/readdir_r.c: Removed. We indeed need a real implementation. * sysdeps/unix/readdir_r.c: New file. * sysdeps/unix/readdir.c: Remove check for correct parameter values. Let them simply die. * manual/filesys.texi: Document readdir_r. * sysdeps/gnu/errlist.awk: Define _sys_errlist as `const char* const'. Proposed by Per Abrahamsen <abraham@dina.kvl.dk>.
1996-10-06 04:05:11 +02:00
#endif