glibc/sysdeps/powerpc/fpu
Paul A. Clarke f1c56cdff0 [powerpc] SET_RESTORE_ROUND optimizations and bug fix
SET_RESTORE_ROUND brackets a block of code, temporarily setting and
restoring the rounding mode and letting everything else, including
exceptions generated within the block, pass through.

On powerpc, the current code clears the exception enables, which will hide
exceptions generated within the block.  This issue was introduced by me
in commit e905212627.

Fix this by not clearing exception enable bits in the prologue.

Also, since we are no longer changing the enable bits in either the
prologue or the epilogue, there is no need to test for entering/exiting
non-stop mode.

Also, optimize the prologue get/save/set rounding mode operations for
POWER9 and later by using 'mffscrn' when possible.

Suggested-by: Paul E. Murphy <murphyp@linux.ibm.com>
Reviewed-by: Paul E. Murphy <murphyp@linux.ibm.com>
Fixes: e905212627

2019-09-19  Paul A. Clarke  <pc@us.ibm.com>

	* sysdeps/powerpc/fpu/fenv_libc.h (fegetenv_and_set_rn): New.
	(__fe_mffscrn): New.
	* sysdeps/powerpc/fpu/fenv_private.h (libc_feholdsetround_ppc_ctx):
	Do not clear enable bits, remove obsolete code, use
	fegetenv_and_set_rn.
	(libc_feresetround_ppc): Remove obsolete code, use
	fegetenv_and_set_rn.
2019-09-19 13:02:30 -05:00
..
Makefile
e_hypot.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
e_hypotf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
e_sqrt.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
e_sqrtf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fclrexcpt.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fe_mask.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fe_nomask.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fedisblxcpt.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
feenablxcpt.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fegetenv.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fegetexcept.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fegetmode.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fegetround.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
feholdexcpt.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fenv_const.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fenv_libc.h [powerpc] SET_RESTORE_ROUND optimizations and bug fix 2019-09-19 13:02:30 -05:00
fenv_private.h [powerpc] SET_RESTORE_ROUND optimizations and bug fix 2019-09-19 13:02:30 -05:00
fesetenv.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fesetexcept.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fesetmode.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fesetround.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
feupdateenv.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fgetexcptflg.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fix-fp-int-compare-invalid.h Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fraiseexcpt.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
fsetexcptflg.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
ftestexcept.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
get-rounding-mode.h Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
libm-test-ulps Add new exp and exp2 implementations 2018-09-05 16:22:00 +01:00
libm-test-ulps-name
math-barriers.h Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
math-tests-trap-force.h Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
math_ldbl.h Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
math_private.h Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
round_to_integer.h Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_ceil.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_ceilf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_copysign.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_copysignf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_floor.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_floorf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_fma.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_fmaf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_logb.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_logbf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_logbl.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_lrintf.c powerpc: Refactor powerpc32 lrint/lrintf/llrint/llrintf 2019-06-17 09:27:02 -03:00
s_modf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_modff.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_nearbyint.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_nearbyintf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_rint.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_rintf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_round.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_roundf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_trunc.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
s_truncf.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00
t_sqrt.c
tst-setcontext-fpscr.c Prefer https to http for gnu.org and fsf.org URLs 2019-09-07 02:43:31 -07:00