From 52e1b618f4a5a161b16d2d14bac74b685097eccb Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Thu, 11 Jul 2002 05:55:13 +0000 Subject: Update. 2002-07-03 Jakub Jelinek * stdio-common/printf_fp.c (__printf_fp.c): If _FPIO_CONST_SHIFT is non-zero, adjust exponent. * sysdeps/ieee754/ldbl-128/s_erfl.c (__erfl, erfl, __erfcl, erfcl): Remove NO_LONG_DOUBLE aliases. * sysdeps/ieee754/ldbl-128/s_expm1l.c (__expm1l, expm1l): Likewise. * sysdeps/ieee754/ldbl-128/s_log1pl.c (__log1pl, log1pl): Likewise. (__log1pl): Raise divide by zero and invalid exceptions when needed. * sysdeps/ieee754/ldbl-128/e_powl.c (__ieee754_powl): Special case 1**y and -1**+-Inf. * sysdeps/ieee754/ldbl-128/ldbl2mpn.c (__mpn_extract_long_double): Fix BITS_PER_MP_LIMB 32 extraction. * sysdeps/ieee754/ldbl-128/e_log2l.c (__ieee754_log2l): Don't raise exceptions for qNaNs. * sysdeps/ieee754/ldbl-128/e_log10l.c (__ieee754_log10l): Likewise. * sysdeps/ieee754/ldbl-128/e_lgammal_r.c (__ieee754_lgamma_r): Raise exceptions when needed. Don't recurse unnecessarily. Special case 1.0L and 2.0L arguments to avoid -0.0L as result. * sysdeps/ieee754/ldbl-128/e_j0l.c (__ieee754_y0l): Don't raise exceptions for qNaNs. * sysdeps/ieee754/ldbl-128/s_remquol.c (__remquol): Make qs 64-bit to fix *quo return value sign. * sysdeps/ieee754/ldbl-128/e_gammal_r.c (__ieee754_gamma_r): Special case -Inf argument. * soft-fp/op-4.h (_FP_FRAC_CLZ_4): Fix a pasto. 2002-07-01 Jakub Jelinek * libio/tst-eof.c (do_test): Remove unused ch and tm variables. * iconvdata/iso-2022-jp-3.c (EMIT_SHIFT_TO_INIT): Kill warnings if -DNDEBUG. --- sysdeps/ieee754/ldbl-128/s_log1pl.c | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) (limited to 'sysdeps/ieee754/ldbl-128/s_log1pl.c') diff --git a/sysdeps/ieee754/ldbl-128/s_log1pl.c b/sysdeps/ieee754/ldbl-128/s_log1pl.c index 73e9501330..9adc786034 100644 --- a/sysdeps/ieee754/ldbl-128/s_log1pl.c +++ b/sysdeps/ieee754/ldbl-128/s_log1pl.c @@ -117,17 +117,18 @@ __log1pl (long double xm1) { long double x, y, z, r, s; ieee854_long_double_shape_type u; - int32_t ix; + int32_t hx; int e; /* Test for NaN or infinity input. */ u.value = xm1; - ix = u.parts32.w0 & 0x7fffffff; - if (ix >= 0x7fff0000) + hx = u.parts32.w0; + if (hx >= 0x7fff0000) return xm1; /* log1p(+- 0) = +- 0. */ - if ((ix == 0) && (u.parts32.w1 | u.parts32.w2 | u.parts32.w3) == 0) + if (((hx & 0x7fffffff) == 0) + && (u.parts32.w1 | u.parts32.w2 | u.parts32.w3) == 0) return xm1; x = xm1 + 1.0L; @@ -136,9 +137,9 @@ __log1pl (long double xm1) if (x <= 0.0L) { if (x == 0.0L) - return (-1.0L / zero); + return (-1.0L / (x - x)); else - return (zero / zero); + return (zero / (x - x)); } /* Separate mantissa from exponent. */ @@ -238,7 +239,3 @@ __log1pl (long double xm1) } weak_alias (__log1pl, log1pl) -#ifdef NO_LONG_DOUBLE -strong_alias (__log1p, __log1pl) -weak_alias (__log1p, log1pl) -#endif -- cgit 1.4.1