glibc/sysdeps/ieee754/flt-32
Joseph Myers 01f2881245 Make more libm functions into weak aliases.
Many libm functions define the function as __<func> and then define
<func> as a weak alias.  This is not at all limited to cases where
there is an internal call that has namespace reasons to need to call
__<func> instead of <func>.

The common macros for creating libm function aliases work on the basis
of public function names all being aliases; that is, they define
aliases for functions using the above pattern.  Thus, where a function
just defines the public name <func> directly, changing that to be a
weak alias enables a subsequent conversion to the common macros to
retain the exact existing symbols (and so be testable by comparison of
stripped binaries).

This patch converts many existing functions to use the weak alias
pattern, as preparation for subsequent conversions to common macros.
I do expect that _FloatN/_FloatNx function aliases will end up needing
new variants of the common macros that do *not* create the original
float / double / long double name of a function - for cases where that
name is created specially to give it a particular symbol version, for
example - but for functions that can use the most common macros to
create all the public names as aliases, it makes sense for them to do
so.

Regarding the Bessel function wrappers in this patch: only float and
double wrappers are changed because the long double wrappers already
used the weak alias pattern.

Tested for x86_64, and with build-many-glibcs.py.

	* include/math.h (roundeven): Change hidden_proto call to
	__roundeven.
	* math/w_j0_compat.c (j0): Rename to __j0 and define as weak
	alias.
	[NO_LONG_DOUBLE] (__j0l): New strong alias.
	(y0): Rename to __y0 and define as weak alias.
	[NO_LONG_DOUBLE] (__y0l): New strong alias.
	* math/w_j0f_compat.c (j0f): Rename to __j0f and define as weak
	alias.
	(y0f): Rename to __y0f and define as weak alias.
	* math/w_j1_compat.c (j1): Rename to __j1 and define as weak
	alias.
	[NO_LONG_DOUBLE] (__j1l): New strong alias.
	(y1): Rename to __y1 and define as weak alias.
	[NO_LONG_DOUBLE] (__y1l): New strong alias.
	* math/w_j1f_compat.c (j1f): Rename to __j1f and define as weak
	alias.
	(y1f): Rename to __y1f and define as weak alias.
	* math/w_jn_compat.c (jn): Rename to __jn and define as weak
	alias.
	[NO_LONG_DOUBLE] (__jnl): New strong alias.
	(yn): Rename to __yn and define as weak alias.
	[NO_LONG_DOUBLE] (__ynl): New strong alias.
	* math/w_jnf_compat.c (jnf): Rename to __jnf and define as weak
	alias.
	(ynf): Rename to __ynf and define as weak alias.
	* sysdeps/ieee754/dbl-64/s_fromfp.c (FUNC): Define to __fromfp.
	(fromfp): Define as weak alias.
	[NO_LONG_DOUBLE] (__fromfpl): New strong alias.
	* sysdeps/ieee754/dbl-64/s_fromfpx.c (FUNC): Define to __fromfpx.
	(fromfpx): Define as weak alias.
	[NO_LONG_DOUBLE] (__fromfpxl): New strong alias.
	* sysdeps/ieee754/dbl-64/s_getpayload.c (getpayload): Rename to
	__getpayload and define as weak alias.
	[NO_LONG_DOUBLE] (__getpayloadl): New strong alias.
	* sysdeps/ieee754/dbl-64/s_roundeven.c (roundeven): Rename to
	__roundeven and define as weak alias.
	[NO_LONG_DOUBLE] (__roundevenl): New strong alias.
	* sysdeps/ieee754/dbl-64/s_setpayload.c (FUNC): Define to
	__setpayload.
	(setpayload): Define as weak alias.
	[NO_LONG_DOUBLE] (__setpayloadl): New strong alias.
	* sysdeps/ieee754/dbl-64/s_setpayloadsig.c (FUNC): Define to
	__setpayloadsig.
	(setpayloadsig): Define as weak alias.
	[NO_LONG_DOUBLE] (__setpayloadsigl): New strong alias.
	* sysdeps/ieee754/dbl-64/s_totalorder.c (totalorder): Rename to
	__totalorder and define as weak alias.
	[NO_LONG_DOUBLE] (__totalorderl): New strong alias.
	* sysdeps/ieee754/dbl-64/s_totalordermag.c (totalordermag): Rename
	to __totalordermag and define as weak alias.
	[NO_LONG_DOUBLE] (__totalordermagl): New strong alias.
	* sysdeps/ieee754/dbl-64/s_ufromfp.c (FUNC): Define to __ufromfp.
	(ufromfp): Define as weak alias.
	[NO_LONG_DOUBLE] (__ufromfpl): New strong alias.
	* sysdeps/ieee754/dbl-64/s_ufromfpx.c (FUNC): Define to
	__ufromfpx.
	(ufromfpx): Define as weak alias.
	[NO_LONG_DOUBLE] (__ufromfpxl): New strong alias.
	* sysdeps/ieee754/dbl-64/wordsize-64/s_getpayload.c (getpayload):
	Rename to __getpayload and define as weak alias.
	[NO_LONG_DOUBLE] (__getpayloadl): New strong alias.
	* sysdeps/ieee754/dbl-64/wordsize-64/s_roundeven.c (roundeven):
	Rename to __roundeven and define as weak alias.
	[NO_LONG_DOUBLE] (__roundevenl): New strong alias.
	* sysdeps/ieee754/dbl-64/wordsize-64/s_totalorder.c (totalorder):
	Rename to __totalorder and define as weak alias.
	[NO_LONG_DOUBLE] (__totalorderl): New strong alias.
	* sysdeps/ieee754/dbl-64/wordsize-64/s_totalordermag.c
	(totalordermag): Rename to __totalordermag and define as weak
	alias.
	[NO_LONG_DOUBLE] (__totalordermagl): New strong alias.
	* sysdeps/ieee754/float128/float128_private.h (__getpayloadl): New
	macro.
	(__roundevenl): Likewise.
	(__totalorderl): Likewise.
	(__totalordermagl): Likewise
	* sysdeps/ieee754/float128/s_fromfpf128.c (FUNC): Define to
	__fromfpf128.
	(fromfpf128): Define as weak alias.
	* sysdeps/ieee754/float128/s_fromfpxf128.c (FUNC): Define to
	__fromfpxf128.
	(fromfpxf128): Define as weak alias.
	* sysdeps/ieee754/float128/s_setpayloadf128.c (FUNC): Define to
	__setpayloadf128.
	(setpayloadf128): Define as weak alias.
	* sysdeps/ieee754/float128/s_setpayloadsigf128.c (FUNC): Define to
	__setpayloadsigf128.
	(setpayloadsigf128): Define as weak alias.
	* sysdeps/ieee754/float128/s_ufromfpf128.c (FUNC): Define to
	__ufromfpf128.
	(ufromfpf128): Define as weak alias.
	* sysdeps/ieee754/float128/s_ufromfpxf128.c (FUNC): Define to
	__ufromfpxf128.
	(ufromfpxf128): Define as weak alias.
	* sysdeps/ieee754/flt-32/s_fromfpf.c (FUNC): Define to __fromfpf.
	(fromfpf): Define as weak alias.
	* sysdeps/ieee754/flt-32/s_fromfpxf.c (FUNC): Define to
	__fromfpxf.
	(fromfpxf): Define as weak alias.
	* sysdeps/ieee754/flt-32/s_getpayloadf.c (getpayloadf): Rename to
	__getpayloadf and define as weak alias.
	* sysdeps/ieee754/flt-32/s_roundevenf.c (roundevenf): Rename to
	__roundevenf and define as weak alias.
	* sysdeps/ieee754/flt-32/s_setpayloadf.c (FUNC): Define to
	__setpayloadf.
	(setpayloadf): Define as weak alias.
	* sysdeps/ieee754/flt-32/s_setpayloadsigf.c (FUNC): Define to
	__setpayloadsigf.
	(setpayloadsigf): Define as weak alias.
	* sysdeps/ieee754/flt-32/s_totalorderf.c (totalorderf): Rename to
	__totalorderf and define as weak alias.
	* sysdeps/ieee754/flt-32/s_totalordermagf.c (totalordermagf):
	Rename to __totalordermagf and define as weak alias.
	* sysdeps/ieee754/flt-32/s_ufromfpf.c (FUNC): Define to
	__ufromfpf.
	(ufromfpf): Define as weak alias.
	* sysdeps/ieee754/flt-32/s_ufromfpxf.c (FUNC): Define to
	__ufromfpxf.
	(ufromfpxf): Define as weak alias.
	* sysdeps/ieee754/ldbl-128/s_fromfpl.c (FUNC): Define to
	__fromfpl.
	(fromfpl): Define as weak alias.
	* sysdeps/ieee754/ldbl-128/s_fromfpxl.c (FUNC): Define to
	__fromfpxl.
	(fromfpxl): Define as weak alias.
	* sysdeps/ieee754/ldbl-128/s_getpayloadl.c (getpayloadl): Rename
	to __getpayloadl and define as weak alias.
	* sysdeps/ieee754/ldbl-128/s_roundevenl.c (roundevenl): Rename to
	__roundevenl and define as weak alias.
	* sysdeps/ieee754/ldbl-128/s_setpayloadl.c (FUNC): Define to
	__setpayloadl.
	(setpayloadl): Define as weak alias.
	* sysdeps/ieee754/ldbl-128/s_setpayloadsigl.c (FUNC): Define to
	__setpayloadsigl.
	(setpayloadsigl): Define as weak alias.
	* sysdeps/ieee754/ldbl-128/s_totalorderl.c (totalorderl): Rename
	to __totalorderl and define as weak alias.
	* sysdeps/ieee754/ldbl-128/s_totalordermagl.c (totalordermagl):
	Rename to __totalordermagl and define as weak alias.
	* sysdeps/ieee754/ldbl-128/s_ufromfpl.c (FUNC): Define to
	__ufromfpl.
	(ufromfpl): Define as weak alias.
	* sysdeps/ieee754/ldbl-128/s_ufromfpxl.c (FUNC): Define to
	__ufromfpxl.
	(ufromfpxl): Define as weak alias.
	* sysdeps/ieee754/ldbl-128ibm/s_fromfpl.c (FUNC): Define to
	__fromfpl.
	(fromfpl): Define as weak alias.
	* sysdeps/ieee754/ldbl-128ibm/s_fromfpxl.c (FUNC): Define to
	__fromfpxl.
	(fromfpxl): Define as weak alias.
	* sysdeps/ieee754/ldbl-128ibm/s_getpayloadl.c (getpayloadl):
	Rename to __getpayloadl and define as weak alias.
	* sysdeps/ieee754/ldbl-128ibm/s_roundevenl.c (roundevenl): Rename
	to __roundevenl and define as weak alias.  Call __roundeven
	instead of roundeven.
	* sysdeps/ieee754/ldbl-128ibm/s_setpayloadl.c (FUNC): Define to
	__setpayloadl.
	(setpayloadl): Define as weak alias.
	* sysdeps/ieee754/ldbl-128ibm/s_setpayloadsigl.c (FUNC): Define to
	__setpayloadsigl.
	(setpayloadsigl): Define as weak alias.
	* sysdeps/ieee754/ldbl-128ibm/s_totalorderl.c (totalorderl):
	Rename to __totalorderl and define as weak alias.
	* sysdeps/ieee754/ldbl-128ibm/s_totalordermagl.c (totalordermagl):
	Rename to __totalordermagl and define as weak alias.
	* sysdeps/ieee754/ldbl-128ibm/s_ufromfpl.c (FUNC): Define to
	__ufromfpl.
	(ufromfpl): Define as weak alias.
	* sysdeps/ieee754/ldbl-128ibm/s_ufromfpxl.c (FUNC): Define to
	__ufromfpxl.
	(ufromfpxl): Define as weak alias.
	* sysdeps/ieee754/ldbl-96/s_fromfpl.c (FUNC): Define to
	__fromfpl.
	(fromfpl): Define as weak alias.
	* sysdeps/ieee754/ldbl-96/s_fromfpxl.c (FUNC): Define to
	__fromfpxl.
	(fromfpxl): Define as weak alias.
	* sysdeps/ieee754/ldbl-96/s_getpayloadl.c (getpayloadl): Rename to
	__getpayloadl and define as weak alias.
	* sysdeps/ieee754/ldbl-96/s_roundevenl.c (roundevenl): Rename to
	__roundevenl and define as weak alias.
	* sysdeps/ieee754/ldbl-96/s_setpayloadl.c (FUNC): Define to
	__setpayloadl.
	(setpayloadl): Define as weak alias.
	* sysdeps/ieee754/ldbl-96/s_setpayloadsigl.c (FUNC): Define to
	__setpayloadsigl.
	(setpayloadsigl): Define as weak alias.
	* sysdeps/ieee754/ldbl-96/s_totalorderl.c (totalorderl): Rename to
	__totalorderl and define as weak alias.
	* sysdeps/ieee754/ldbl-96/s_totalordermagl.c (totalordermagl):
	Rename to __totalordermagl and define as weak alias.
	* sysdeps/ieee754/ldbl-96/s_ufromfpl.c (FUNC): Define to
	__ufromfpl.
	(ufromfpl): Define as weak alias.
	* sysdeps/ieee754/ldbl-96/s_ufromfpxl.c (FUNC): Define to
	__ufromfpxl.
	(ufromfpxl): Define as weak alias.
2017-09-14 22:28:53 +00:00
..
e_acosf.c Fix acosf underflow (bug 14153). 2012-05-25 11:07:07 +00:00
e_acoshf.c Use <> for math.h and math_private.h everywhere. 2012-03-09 16:09:10 -08:00
e_asinf.c Refactor code forcing underflow exceptions. 2015-09-23 22:42:30 +00:00
e_atan2f.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
e_atanhf.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_coshf.c Avoid excess range overflowing results from cosh, sinh, lgamma (bug 18980). 2015-09-18 20:00:48 +00:00
e_exp2f.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_expf.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
e_fmodf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
e_gammaf_r.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
e_hypotf.c Fix hypot sNaN handling (bug 20940). 2016-12-07 01:16:36 +00:00
e_ilogbf.c Remove useless __ilogb*_finite aliases 2012-04-18 00:40:13 +02:00
e_j0f.c Fix y0 and y1 exception handling for zero input [BZ #21134] 2017-02-15 10:30:59 -02:00
e_j1f.c Fix y0 and y1 exception handling for zero input [BZ #21134] 2017-02-15 10:30:59 -02:00
e_jnf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
e_lgammaf_r.c Narrowing the visibility of libc-internal.h even further. 2017-03-01 20:33:46 -05:00
e_log2f.c Fix lgamma*, log10* and log2* results [BZ #21171] 2017-02-17 09:07:57 -02:00
e_log10f.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
e_logf.c Fix catan, catanh, __ieee754_logf in round-downward mode (bug 16799, bug 16800). 2014-04-02 17:41:02 +00:00
e_powf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
e_rem_pio2f.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
e_remainderf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
e_sinhf.c Refactor code forcing underflow exceptions. 2015-09-23 22:42:30 +00:00
e_sqrtf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
k_cosf.c Remove trailing whitespace. 2013-06-05 20:44:03 +00:00
k_rem_pio2f.c Narrowing the visibility of libc-internal.h even further. 2017-03-01 20:33:46 -05:00
k_sinf.c Refactor code forcing underflow exceptions. 2015-09-23 22:42:30 +00:00
k_tanf.c Refactor code forcing underflow exceptions. 2015-09-23 22:42:30 +00:00
lgamma_negf.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
lgamma_productf.c Fix lgamma (negative) inaccuracy (bug 2542, bug 2543, bug 2558). 2015-09-10 22:27:58 +00:00
mpn2flt.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_asinhf.c Refactor code forcing underflow exceptions. 2015-09-23 22:42:30 +00:00
s_atanf.c Refactor code forcing underflow exceptions. 2015-09-23 22:42:30 +00:00
s_cbrtf.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_ceilf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_copysignf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_cosf.c Fix several build failures with GCC6 due to unused static variables. 2015-09-18 20:42:54 +01:00
s_erff.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_expm1f.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_fabsf.c 2015-05-28 Wilco Dijkstra <wdijkstr@arm.com> 2015-05-28 11:42:55 +01:00
s_finitef.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_floorf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_fpclassifyf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_frexpf.c Fix frexp (NaN) (bug 20250). 2016-06-13 17:27:19 +00:00
s_fromfpf_main.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_fromfpf.c Make more libm functions into weak aliases. 2017-09-14 22:28:53 +00:00
s_fromfpxf.c Make more libm functions into weak aliases. 2017-09-14 22:28:53 +00:00
s_getpayloadf.c Make more libm functions into weak aliases. 2017-09-14 22:28:53 +00:00
s_isinff.c Use <> for math.h and math_private.h everywhere. 2012-03-09 16:09:10 -08:00
s_isnanf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_issignalingf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_llrintf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_llroundf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_log1pf.c Refactor code forcing underflow exceptions. 2015-09-23 22:42:30 +00:00
s_logbf.c Work around powerpc32 integer 0 converting to -0 (bug 887, bug 19049, bug 19050). 2015-10-05 17:46:50 +00:00
s_lrintf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_lroundf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_modff.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_nearbyintf.c Fix nearbyint scheduling of arithmetic past fesetenv (bug 15490). 2013-05-19 18:40:25 +00:00
s_nextafterf.c Make nextafter, nexttoward set errno (bug 6799). 2015-11-02 18:54:19 +00:00
s_nextupf.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_remquof.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_rintf.c Use <> for math.h and math_private.h everywhere. 2012-03-09 16:09:10 -08:00
s_roundevenf.c Make more libm functions into weak aliases. 2017-09-14 22:28:53 +00:00
s_roundf.c Consistently use uintN_t not u_intN_t in libm. 2017-08-03 19:55:04 +00:00
s_scalblnf.c [BZ #6803] Set errno for scalbln, scalbn 2014-06-20 07:48:20 +05:30
s_scalbnf.c Make scalbn set errno (bug 6803). 2015-09-16 21:11:00 +00:00
s_setpayloadf_main.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_setpayloadf.c Make more libm functions into weak aliases. 2017-09-14 22:28:53 +00:00
s_setpayloadsigf.c Make more libm functions into weak aliases. 2017-09-14 22:28:53 +00:00
s_signbitf.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_sincosf.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_sinf.c Add optimized sinf and cosf routines for x86 and x86-64 2012-09-03 15:32:13 +02:00
s_tanf.c Use <> for math.h and math_private.h everywhere. 2012-03-09 16:09:10 -08:00
s_tanhf.c Refactor code forcing underflow exceptions. 2015-09-23 22:42:30 +00:00
s_totalorderf.c Make more libm functions into weak aliases. 2017-09-14 22:28:53 +00:00
s_totalordermagf.c Make more libm functions into weak aliases. 2017-09-14 22:28:53 +00:00
s_truncf.c Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00
s_ufromfpf.c Make more libm functions into weak aliases. 2017-09-14 22:28:53 +00:00
s_ufromfpxf.c Make more libm functions into weak aliases. 2017-09-14 22:28:53 +00:00
t_exp2f.h Update copyright dates with scripts/update-copyrights. 2017-01-01 00:14:16 +00:00