glibc/sysdeps/powerpc
Joseph Myers 9755bc4686 Use round functions not __round functions in glibc libm.
Continuing the move to use, within libm, public names for libm
functions that can be inlined as built-in functions on many
architectures, this patch moves calls to __round functions to call the
corresponding round names instead, with asm redirection to __round
when the calls are not inlined.

An additional complication arises in
sysdeps/ieee754/ldbl-128ibm/e_expl.c, where a call to roundl, with the
result converted to int, gets converted by the compiler to call
lroundl in the case of 32-bit long, so resulting in localplt test
failures.  It's logically correct to let the compiler make such an
optimization; an appropriate asm redirection of lroundl to __lroundl
is thus added to that file (it's not needed anywhere else).

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

	* include/math.h [!_ISOMAC && !(__FINITE_MATH_ONLY__ &&
	__FINITE_MATH_ONLY__ > 0) && !NO_MATH_REDIRECT] (round): Redirect
	using MATH_REDIRECT.
	* sysdeps/aarch64/fpu/s_round.c: Define NO_MATH_REDIRECT before
	header inclusion.
	* sysdeps/aarch64/fpu/s_roundf.c: Likewise.
	* sysdeps/ieee754/dbl-64/s_round.c: Likewise.
	* sysdeps/ieee754/dbl-64/wordsize-64/s_round.c: Likewise.
	* sysdeps/ieee754/float128/s_roundf128.c: Likewise.
	* sysdeps/ieee754/flt-32/s_roundf.c: Likewise.
	* sysdeps/ieee754/ldbl-128/s_roundl.c: Likewise.
	* sysdeps/ieee754/ldbl-96/s_roundl.c: Likewise.
	* sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_round.c: Likewise.
	* sysdeps/powerpc/powerpc32/power4/fpu/multiarch/s_roundf.c: Likewise.
	* sysdeps/powerpc/powerpc64/fpu/multiarch/s_round.c: Likewise.
	* sysdeps/powerpc/powerpc64/fpu/multiarch/s_roundf.c: Likewise.
	* sysdeps/riscv/rv64/rvd/s_round.c: Likewise.
	* sysdeps/riscv/rvf/s_roundf.c: Likewise.
	* sysdeps/ieee754/ldbl-128ibm/s_roundl.c: Likewise.
	(round): Redirect to __round.
	(__roundl): Call round instead of __round.
	* sysdeps/powerpc/fpu/math_private.h [_ARCH_PWR5X] (__round):
	Remove macro.
	[_ARCH_PWR5X] (__roundf): Likewise.
	* sysdeps/ieee754/dbl-64/e_gamma_r.c (gamma_positive): Use round
	functions instead of __round variants.
	* sysdeps/ieee754/flt-32/e_gammaf_r.c (gammaf_positive): Likewise.
	* sysdeps/ieee754/ldbl-128/e_gammal_r.c (gammal_positive):
	Likewise.
	* sysdeps/ieee754/ldbl-128ibm/e_gammal_r.c (gammal_positive):
	Likewise.
	* sysdeps/ieee754/ldbl-96/e_gammal_r.c (gammal_positive):
	Likewise.
	* sysdeps/x86/fpu/powl_helper.c (__powl_helper): Likewise.
	* sysdeps/ieee754/ldbl-128ibm/e_expl.c (lroundl): Redirect to
	__lroundl.
	(__ieee754_expl): Call roundl instead of __roundl.
2018-09-27 12:35:23 +00:00
..
bits powerpc: Fix the compiler type used with C++ when -mabi=ieeelongdouble 2018-05-11 18:05:03 -03:00
fpu Use round functions not __round functions in glibc libm. 2018-09-27 12:35:23 +00:00
nofpu Update powerpc-nofpu ulps. 2018-07-26 22:51:06 +00:00
nptl powerpc: Only enable TLE with PPC_FEATURE2_HTM_NOSC 2018-09-21 10:18:03 -07:00
power4 Remove slow paths from exp 2018-02-12 11:33:33 +00:00
power5+/fpu Use ceil functions not __ceil functions in glibc libm. 2018-09-17 20:42:06 +00:00
power6 Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
power7/fpu Don't include math.h/math_private.h in math_ldbl_opt.h. 2018-03-10 15:18:08 -05:00
powerpc32 Use round functions not __round functions in glibc libm. 2018-09-27 12:35:23 +00:00
powerpc64 Use round functions not __round functions in glibc libm. 2018-09-27 12:35:23 +00:00
sys/platform Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
Makefile tst-tlsopt-powerpc as a shared lib 2017-08-03 15:39:21 +09:30
Versions Add femode_t functions. 2016-09-07 16:40:09 +00:00
abort-instr.h Update. 2002-09-15 18:31:23 +00:00
atomic-machine.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
cpu-features.c Rename the glibc.tune namespace to glibc.cpu 2018-08-02 23:49:19 +05:30
cpu-features.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
dl-procinfo.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
dl-procinfo.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
dl-tls.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
dl-tls.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
dl-tunables.list Rename the glibc.tune namespace to glibc.cpu 2018-08-02 23:49:19 +05:30
ffs.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
fpu_control.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
gccframe.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
hwcapinfo.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
hwcapinfo.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
ifunc-sel.h Fix powerpc ifunc-sel.h build for -Os. 2018-03-02 22:27:56 +00:00
jmpbuf-offsets.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
jmpbuf-unwind.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
ldsodefs.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
libc-tls.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
locale-defines.sym powerpc: strcasestr optmization for power8 2016-04-22 19:23:13 +05:30
longjmp.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
machine-gmon.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
math-tests-snan-cast.h Move SNAN_TESTS_TYPE_CAST out of math-tests.h. 2018-08-01 11:18:57 +00:00
memusage.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
mod-tlsopt-powerpc.c tst-tlsopt-powerpc as a shared lib 2017-08-03 15:39:21 +09:30
mp_clz_tab.c Update. 2002-03-14 20:48:50 +00:00
novmx-longjmp.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
novmx-sigjmp.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
novmxsetjmp.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
preconfigure powerpc64*: fix the order of implied sysdeps directories 2018-04-27 16:32:01 -03:00
rtld-global-offsets.sym PowerPC: Define AT_HWCAP2 bits and AT_HWCAP2 handling for POWER8. 2013-06-28 16:52:49 -05:00
sched_cpucount.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
sigjmp.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
sotruss-lib.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
stackinfo.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
sysdep.h powerpc: Only enable TLE with PPC_FEATURE2_HTM_NOSC 2018-09-21 10:18:03 -07:00
test-arith.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
test-arithf.c Update. 1997-08-10 18:37:15 +00:00
test-get_hwcap-static.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
test-get_hwcap.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
test-gettimebase.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
tls-macros.h Split tls-macros.h in sysdeps directories. 2012-07-19 17:04:04 -03:00
tst-set_ppr.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
tst-stack-align.h Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
tst-tlsifunc-static.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
tst-tlsifunc.c Update copyright dates with scripts/update-copyrights. 2018-01-01 00:32:25 +00:00
tst-tlsopt-powerpc.c tst-tlsopt-powerpc as a shared lib 2017-08-03 15:39:21 +09:30