This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: Fix tgamma errno setting on domain error (bug 6809)
- From: OndÅej BÃlka <neleai at seznam dot cz>
- To: "Joseph S. Myers" <joseph at codesourcery dot com>
- Cc: libc-alpha at sourceware dot org
- Date: Fri, 10 May 2013 10:51:06 +0200
- Subject: Re: Fix tgamma errno setting on domain error (bug 6809)
- References: <Pine dot LNX dot 4 dot 64 dot 1305092231060 dot 29757 at digraph dot polyomino dot org dot uk>
On Thu, May 09, 2013 at 10:32:26PM +0000, Joseph S. Myers wrote:
> Many of the libm errno-setting bugs have fixes slightly complicated by
> needing to fix .S implementations of functions for various
> architectures, or needing to work out how to handle setting errno to
> ERANGE for finite subnormal results (either don't use
> __kernel_standard for the errno setting in this case, or the nonzero
> underflowed result needs passing to __kernel_standard so that it gets
> preserved) - although they are certainly still worth fixing.
>
> - if(__builtin_expect(!__finite(y), 0)&&__finite(x)
> + if(__builtin_expect(!__finite(y), 0)
> + && (__finite (x) || __isinf (x) < 0)
A nit why expect here is only in part of expression but not whole
expression?