This is the mail archive of the
fortran@gcc.gnu.org
mailing list for the GNU Fortran project.
Re: Polyhedron tests on Intel Darwin8/9
- From: "Andrew Pinski" <pinskia at gmail dot com>
- To: "Dominique Dhumieres" <dominiq at lps dot ens dot fr>
- Cc: paulthomas2 at wanadoo dot fr, fortran at gcc dot gnu dot org
- Date: Fri, 23 Nov 2007 10:04:24 -0800
- Subject: Re: Polyhedron tests on Intel Darwin8/9
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=uEBdWP8bEHrqPXCq9mZdyZ9bx/zDm7n1M8E/abuSLxY=; b=DwheBBsQlc6y6y2TO++68G7TCKmkJxJPwoJwUI3kLCTDTssirSGnh9mameZi6VGKExTJRaroVfSqDqOLgryngS0BZinySyo5aoRdWUrc1nosdEY5KRpyRCx9HI+b9ejFYUbunn3ElbrounhYbAQX0cR4gE+B2ejIKawugqtMR3M=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=LyyqoTd/BhXcB6Hzc8XE7sTOXEtoiufRY3IgqwrKdn5oVf66bq1oIIkc2lCrvVjvBy5u++bUVg1THtaOJvSIZuFrYa3iXZMJOb9KtSWHcjKV0GFknjihH3MCn/xy2VD7gSbVZ/xkDbwNXCuTSN6kxMjFYSFu1kGWu10SmElsSLA=
- References: <20071120141552.0C95B5BB6C@mailhost.lps.ens.fr> <474367C4.60802@wanadoo.fr> <20071123142613.C70475BB6C@mailhost.lps.ens.fr>
On 11/23/07, Dominique Dhumieres <dominiq@lps.ens.fr> wrote:
> with a fmadds corresponding to 's = s + a1*b1'.
> So even at -O3 the gcc optimizer is unable to see that
> a1*b1 is always zero, even if b1 is a constant (in this case
> a "perfectly" optimized code would reduce to
>
> print *, 0.0
>
> and this is not the case.
Most likely because GCC does not do VRP for floating point values.
a*0.0 still takes the sign of a so the result is not always 0 but can
also be -0.0. Likewise for 0.0 + b.
Thanks,
Andrew Pinski