This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] soft-fp: Fix used without set warning in _FP_MUL and_FP_DIV


From: Richard Henderson <rth@twiddle.net>
Date: Fri,  7 Dec 2012 13:19:45 -0600

> Seen in, e.g. ports/sysdeps/alpha/soft-fp/ots_mul.c.
> 
> The problem here is we have a switch on the class of X*Y, followed by
> a switch on the class of R.  The exponent field of R really is not set
> by the first switch for NaN outputs, because we know it's not going to
> be used.  The compiler is not smart enough to see through this.
> 
> By pulling the exponent computation out of the NORMAL*NORMAL path, we
> will not be pessimizing the most common case, while still providing an
> arbitrary value to satisfy the compiler.
> ---
>  ChangeLog           | 6 ++++++
>  soft-fp/op-common.h | 4 ++--
>  2 files changed, 8 insertions(+), 2 deletions(-)
> 
> Ok to commit?

This is fine, thanks Richard.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]