Fix e_logl (128ibm) spurious underflow
Carlos O'Donell
carlos@redhat.com
Wed Feb 27 21:17:00 GMT 2013
On 02/27/2013 03:11 PM, Adhemerval Zanella wrote:
> This patch fixes the spurious underflow exceptions triggered by cacos,
> casin, and casinh test for IBM long double. This is in fact an issue with
> __ieee754_logl implementation: in the domain reduction phase, where
> the algorithm transform log(u) -> log(t) + log(u/t) and log(u/t) -> log(1+(u-t)/t),
> if the input is high enough the calculation '1+(u-t)/t' might generate
> subnormal numbers.
>
> The patch I propose tests if the resulting coefficient used in the series
> expansion might trigger a subnormal multiplication and if it is the case,
> just set the expansion to 0. Since it is denormal multiplications and the
> expect result is orders of magnitude higher than the series expansion, I
> believe the loss of precision is acceptable.
>
> I also added the ulps update for remaining cacos tests.
>
> Any tips, comments, advices?
>
> --
>
> 2013-02-27 Adhemerval Zanella <azanella@linux.vnet.ibm.com>
>
> * sysdeps/ieee754/ldbl-128ibm/e_logl.c (__ieee754_logl): Fix spurious
> underflow.
> * sysdeps/powerpc/fpu/libm-test-ulps: Update.
Where is the test case addition that triggers the spurious underflow?
Cheers,
Carlos.
More information about the Libc-alpha
mailing list