Fix tgamma errno setting on domain error (bug 6809)
Joseph S. Myers
joseph@codesourcery.com
Fri May 10 11:39:00 GMT 2013
On Fri, 10 May 2013, Ondrej Bilka wrote:
> > - 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?
If the return value isn't finite, we're already in the unlikely case and
there isn't really much point optimizing the conditionals that come after
that. It makes sense for the first conditional to be the one that splits
things into likely / unlikely cases, since it's the likely case (finite
result) that's most important to optimize.
--
Joseph S. Myers
joseph@codesourcery.com
More information about the Libc-alpha
mailing list