Fix powerpc-nofpu remainderl wrong sign of zero result (bug 22688) [committed]

Message ID alpine.DEB.2.20.1801092315470.21425@digraph.polyomino.org.uk
State New
Headers show
Series
  • Fix powerpc-nofpu remainderl wrong sign of zero result (bug 22688) [committed]
Related show

Commit Message

Joseph Myers Jan. 9, 2018, 11:16 p.m.
For soft-float powerpc, the remainderl function produces zero results
with the wrong sign for various inputs.  This is another instance of
the problem with incorrect built-in fabsl expansion, so is fixed by
this patch using -fno-builtin-fabsl for this function.

Tested for powerpc (soft-float).  Committed.

2018-01-09  Joseph Myers  <joseph@codesourcery.com>

	[BZ #22688]
	* sysdeps/powerpc/nofpu/Makefile [$(subdir) = math]
	(CFLAGS-e_remainderl.c): New variable.

Patch

diff --git a/sysdeps/powerpc/nofpu/Makefile b/sysdeps/powerpc/nofpu/Makefile
index 09ecdf1..75b116c 100644
--- a/sysdeps/powerpc/nofpu/Makefile
+++ b/sysdeps/powerpc/nofpu/Makefile
@@ -46,4 +46,5 @@  CFLAGS-w_j1l_compat.c += -fno-builtin-fabsl
 CFLAGS-e_lgammal_r.c += -fno-builtin-fabsl
 CFLAGS-e_log10l.c += -fno-builtin-fabsl
 CFLAGS-e_log2l.c += -fno-builtin-fabsl
+CFLAGS-e_remainderl.c += -fno-builtin-fabsl
 endif