regression in tgamma?

Paul Zimmermann Paul.Zimmermann@inria.fr
Thu Dec 17 07:29:06 GMT 2020


       Hi Jeff,

> From: Jeff Johnston <jjohnstn@redhat.com>
> Date: Wed, 16 Dec 2020 15:31:47 -0500
> 
> Hi Paul,
> 
> I believe I found the problem.
> 
> The __ieee754_tgamma functions are not declared in fdlibm.h so the calls in
> tgamma and tgammaf are using
> default parms and getting things wrong.  My test calling __ieee754_tgamma
> directly only worked after I added
> a declaration to __ieee754_tgamma locally.
> 
> I have pushed a change to master.  Please try it out.
> 
> -- Jeff J.

with revision 865cd30 I now get:

zimmerma@tomate:/tmp/newlib-cygwin$ ./a.out 
x=-0x0p+0 y=inf
x=-0x1.53f198fe3b278p+7 y=0x1.fd6d312572d9cp-1015

The double value is ok, however the float result should be -inf.
This should have been fixed by Keith Packard in commit 4641693.

Paul


More information about the Newlib mailing list