This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Avoid FP comparisons against Infinity
- From: Richard Henderson <rth at redhat dot com>
- To: Roger Sayle <roger at www dot eyesopen dot com>
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Thu, 22 May 2003 16:05:25 -0700
- Subject: Re: [PATCH] Avoid FP comparisons against Infinity
- References: <Pine.LNX.4.44.0305180657570.16346-100000@www.eyesopen.com>
On Sun, May 18, 2003 at 07:17:41AM -0600, Roger Sayle wrote:
> * real.c (real_maxval): New function to return the largest finite
> value representable in a given mode (i.e. FLT_MAX and DBL_MAX).
> * real.h (real_maxval): Prototype here.
> * fold-const.c (fold_inf_compare): Transform comparisons against
> +-Infinity into comparisons against DBL_MAX (or equivalent).
>
> * gcc.c-torture/execute/ieee/inf-2.c: New test case.
Ok.
r~