about summary refs log tree commit diff
path: root/sysdeps/ieee754/flt-32
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/ieee754/flt-32')
-rw-r--r--sysdeps/ieee754/flt-32/e_lgammaf_r.c2
-rw-r--r--sysdeps/ieee754/flt-32/e_log10f.c2
-rw-r--r--sysdeps/ieee754/flt-32/e_log2f.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/sysdeps/ieee754/flt-32/e_lgammaf_r.c b/sysdeps/ieee754/flt-32/e_lgammaf_r.c
index 4d8a66bb39..1bd2122663 100644
--- a/sysdeps/ieee754/flt-32/e_lgammaf_r.c
+++ b/sysdeps/ieee754/flt-32/e_lgammaf_r.c
@@ -160,7 +160,7 @@ __ieee754_lgammaf_r(float x, int *signgamp)
 	}
 	if(hx<0) {
 	    if(ix>=0x4b000000)	/* |x|>=2**23, must be -integer */
-		return x/zero;
+		return __fabsf (x)/zero;
 	    if (ix > 0x40000000 /* X < 2.0f.  */
 		&& ix < 0x41700000 /* X > -15.0f.  */)
 		return __lgamma_negf (x, signgamp);
diff --git a/sysdeps/ieee754/flt-32/e_log10f.c b/sysdeps/ieee754/flt-32/e_log10f.c
index 2cd01b4a50..aa21bbc9c5 100644
--- a/sysdeps/ieee754/flt-32/e_log10f.c
+++ b/sysdeps/ieee754/flt-32/e_log10f.c
@@ -34,7 +34,7 @@ __ieee754_log10f(float x)
 	k=0;
 	if (hx < 0x00800000) {			/* x < 2**-126  */
 	    if (__builtin_expect((hx&0x7fffffff)==0, 0))
-		return -two25/(x-x);		/* log(+-0)=-inf */
+	      return -two25/__fabsf (x);	/* log(+-0)=-inf  */
 	    if (__builtin_expect(hx<0, 0))
 		return (x-x)/(x-x);	/* log(-#) = NaN */
 	    k -= 25; x *= two25; /* subnormal number, scale up x */
diff --git a/sysdeps/ieee754/flt-32/e_log2f.c b/sysdeps/ieee754/flt-32/e_log2f.c
index 857d13fb9b..782d901094 100644
--- a/sysdeps/ieee754/flt-32/e_log2f.c
+++ b/sysdeps/ieee754/flt-32/e_log2f.c
@@ -43,7 +43,7 @@ __ieee754_log2f(float x)
 	k=0;
 	if (ix < 0x00800000) {			/* x < 2**-126  */
 	    if (__builtin_expect((ix&0x7fffffff)==0, 0))
-		return -two25/(x-x);		/* log(+-0)=-inf */
+		return -two25/__fabsf (x);	/* log(+-0)=-inf  */
 	    if (__builtin_expect(ix<0, 0))
 		return (x-x)/(x-x);	/* log(-#) = NaN */
 	    k -= 25; x *= two25; /* subnormal number, scale up x */