From 52495f29a2e8519da83cbda0c21ad95405364705 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Sun, 21 Nov 2004 19:58:34 +0000 Subject: [BZ #552] Update. 2004-11-20 Jakub Jelinek * sysdeps/ieee754/k_standard.c: Document code 50. (__kernel_standard) : Avoid raising div-by-zero exception again. 2004-11-19 H.J. Lu [BZ #552] * math/libm-test.inc (tgamma_test): Update tgamma (0) and tgamma (-0). * sysdeps/generic/w_tgamma.c (__tgamma): Properly handle |x| == 0. * sysdeps/generic/w_tgammaf.c (__tgammaf): Likewise. * sysdeps/generic/w_tgammal.c (__tgammal): Likewise. * sysdeps/ieee754/dbl-64/e_gamma_r.c (__ieee754_gamma_r): Likewise. * sysdeps/ieee754/flt-32/e_gammaf_r.c: Likewise. * sysdeps/ieee754/ldbl-128/e_gammal_r.c: Likewise. * sysdeps/ieee754/ldbl-96/e_gammal_r.c: Likewise. * sysdeps/ieee754/k_standard.c (__kernel_standard): Handle tgamma (0) and tgamma (-0). --- sysdeps/ieee754/ldbl-96/e_gammal_r.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'sysdeps/ieee754/ldbl-96') diff --git a/sysdeps/ieee754/ldbl-96/e_gammal_r.c b/sysdeps/ieee754/ldbl-96/e_gammal_r.c index f19a072179..dd956fed95 100644 --- a/sysdeps/ieee754/ldbl-96/e_gammal_r.c +++ b/sysdeps/ieee754/ldbl-96/e_gammal_r.c @@ -1,5 +1,5 @@ /* Implementation of gamma function according to ISO C. - Copyright (C) 1997, 1999, 2001, 2003 Free Software Foundation, Inc. + Copyright (C) 1997, 1999, 2001, 2003, 2004 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper , 1997. @@ -34,9 +34,9 @@ __ieee754_gammal_r (long double x, int *signgamp) if (((es & 0x7fff) | hx | lx) == 0) { - /* Return value for x == 0 is NaN with invalid exception. */ + /* Return value for x == 0 is Inf with divide by zero exception. */ *signgamp = 0; - return x / x; + return 1.0 / x; } if (es == 0xffffffff && ((hx & 0x7fffffff) | lx) == 0) { -- cgit 1.4.1