summaryrefslogtreecommitdiff
path: root/sysdeps/ieee754
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/ieee754')
-rw-r--r--sysdeps/ieee754/flt-32/e_gammaf_r.c12
-rw-r--r--sysdeps/ieee754/flt-32/e_j0f.c4
-rw-r--r--sysdeps/ieee754/flt-32/e_j1f.c4
-rw-r--r--sysdeps/ieee754/flt-32/e_jnf.c2
-rw-r--r--sysdeps/ieee754/flt-32/lgamma_negf.c8
-rw-r--r--sysdeps/ieee754/flt-32/s_log1pf.c2
6 files changed, 16 insertions, 16 deletions
diff --git a/sysdeps/ieee754/flt-32/e_gammaf_r.c b/sysdeps/ieee754/flt-32/e_gammaf_r.c
index 782beaa144..3db8463407 100644
--- a/sysdeps/ieee754/flt-32/e_gammaf_r.c
+++ b/sysdeps/ieee754/flt-32/e_gammaf_r.c
@@ -85,7 +85,7 @@ gammaf_positive (float x, int *exp2_adj)
float x_adj_frac = x_adj - x_adj_int;
int x_adj_log2;
float x_adj_mant = __frexpf (x_adj, &x_adj_log2);
- if (x_adj_mant < (float) M_SQRT1_2)
+ if (x_adj_mant < M_SQRT1_2f)
{
x_adj_log2--;
x_adj_mant *= 2.0f;
@@ -94,7 +94,7 @@ gammaf_positive (float x, int *exp2_adj)
float ret = (__ieee754_powf (x_adj_mant, x_adj)
* __ieee754_exp2f (x_adj_log2 * x_adj_frac)
* __ieee754_expf (-x_adj)
- * sqrtf (2 * (float) M_PI / x_adj)
+ * sqrtf (2 * M_PIf / x_adj)
/ prod);
exp_adj += x_eps * __ieee754_logf (x_adj);
float bsum = gamma_coeff[NCOEFF - 1];
@@ -176,11 +176,11 @@ __ieee754_gammaf_r (float x, int *signgamp)
if (frac > 0.5f)
frac = 1.0f - frac;
float sinpix = (frac <= 0.25f
- ? __sinf ((float) M_PI * frac)
- : __cosf ((float) M_PI * (0.5f - frac)));
+ ? __sinf (M_PIf * frac)
+ : __cosf (M_PIf * (0.5f - frac)));
int exp2_adj;
- float tret = (float) M_PI / (-x * sinpix
- * gammaf_positive (-x, &exp2_adj));
+ float tret = M_PIf / (-x * sinpix
+ * gammaf_positive (-x, &exp2_adj));
ret = __scalbnf (tret, -exp2_adj);
math_check_force_underflow_nonneg (ret);
}
diff --git a/sysdeps/ieee754/flt-32/e_j0f.c b/sysdeps/ieee754/flt-32/e_j0f.c
index 0453a30109..9ae91a9dcc 100644
--- a/sysdeps/ieee754/flt-32/e_j0f.c
+++ b/sysdeps/ieee754/flt-32/e_j0f.c
@@ -233,7 +233,7 @@ j0f_near_root (float x, float z)
float index_f;
int index;
- index_f = roundf ((x - FIRST_ZERO_J0) / (float) M_PI);
+ index_f = roundf ((x - FIRST_ZERO_J0) / M_PIf);
/* j0f_asympt fails to give an error <= 9 ulps for x=0x1.324e92p+7
(index 48) thus we can't reduce SMALL_SIZE below 49. */
if (index_f >= SMALL_SIZE)
@@ -514,7 +514,7 @@ y0f_near_root (float x, float z)
float index_f;
int index;
- index_f = roundf ((x - FIRST_ZERO_Y0) / (float) M_PI);
+ index_f = roundf ((x - FIRST_ZERO_Y0) / M_PIf);
if (index_f >= SMALL_SIZE)
return y0f_asympt (x);
index = (int) index_f;
diff --git a/sysdeps/ieee754/flt-32/e_j1f.c b/sysdeps/ieee754/flt-32/e_j1f.c
index 052c661db9..ade10402fd 100644
--- a/sysdeps/ieee754/flt-32/e_j1f.c
+++ b/sysdeps/ieee754/flt-32/e_j1f.c
@@ -243,7 +243,7 @@ j1f_near_root (float x, float z)
x = -x;
sign = -1.0f;
}
- index_f = roundf ((x - FIRST_ZERO_J1) / (float) M_PI);
+ index_f = roundf ((x - FIRST_ZERO_J1) / M_PIf);
if (index_f >= SMALL_SIZE)
return sign * j1f_asympt (x);
index = (int) index_f;
@@ -525,7 +525,7 @@ y1f_near_root (float x, float z)
float index_f;
int index;
- index_f = roundf ((x - FIRST_ZERO_Y1) / (float) M_PI);
+ index_f = roundf ((x - FIRST_ZERO_Y1) / M_PIf);
if (index_f >= SMALL_SIZE)
return y1f_asympt (x);
index = (int) index_f;
diff --git a/sysdeps/ieee754/flt-32/e_jnf.c b/sysdeps/ieee754/flt-32/e_jnf.c
index 80b684dd97..ff0a9d7c63 100644
--- a/sysdeps/ieee754/flt-32/e_jnf.c
+++ b/sysdeps/ieee754/flt-32/e_jnf.c
@@ -134,7 +134,7 @@ __ieee754_jnf(int n, float x)
tmp = n;
v = two/x;
tmp = tmp*__ieee754_logf(fabsf(v*tmp));
- if(tmp<(float)8.8721679688e+01) {
+ if(tmp<8.8721679688e+01f) {
for(i=n-1,di=(float)(i+i);i>0;i--){
temp = b;
b *= di;
diff --git a/sysdeps/ieee754/flt-32/lgamma_negf.c b/sysdeps/ieee754/flt-32/lgamma_negf.c
index 756742edd8..541b5a3ab1 100644
--- a/sysdeps/ieee754/flt-32/lgamma_negf.c
+++ b/sysdeps/ieee754/flt-32/lgamma_negf.c
@@ -165,9 +165,9 @@ static float
lg_sinpi (float x)
{
if (x <= 0.25f)
- return __sinf ((float) M_PI * x);
+ return __sinf (M_PIf * x);
else
- return __cosf ((float) M_PI * (0.5f - x));
+ return __cosf (M_PIf * (0.5f - x));
}
/* Compute cos (pi * X) for -0.25 <= X <= 0.5. */
@@ -176,9 +176,9 @@ static float
lg_cospi (float x)
{
if (x <= 0.25f)
- return __cosf ((float) M_PI * x);
+ return __cosf (M_PIf * x);
else
- return __sinf ((float) M_PI * (0.5f - x));
+ return __sinf (M_PIf * (0.5f - x));
}
/* Compute cot (pi * X) for -0.25 <= X <= 0.5. */
diff --git a/sysdeps/ieee754/flt-32/s_log1pf.c b/sysdeps/ieee754/flt-32/s_log1pf.c
index 6630f5a78e..555f0f82c8 100644
--- a/sysdeps/ieee754/flt-32/s_log1pf.c
+++ b/sysdeps/ieee754/flt-32/s_log1pf.c
@@ -92,7 +92,7 @@ __log1pf(float x)
if(k==0) return zero;
else {c += k*ln2_lo; return k*ln2_hi+c;}
}
- R = hfsq*((float)1.0-(float)0.66666666666666666*f);
+ R = hfsq*(1.0f-0.66666666666666666f*f);
if(k==0) return f-R; else
return k*ln2_hi-((R-(k*ln2_lo+c))-f);
}