From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6338 invoked by alias); 26 Mar 2004 16:40:33 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 6330 invoked from network); 26 Mar 2004 16:40:33 -0000 Received: from unknown (HELO nile.gnat.com) (205.232.38.5) by sources.redhat.com with SMTP; 26 Mar 2004 16:40:33 -0000 Received: from localhost (localhost [127.0.0.1]) by nile.gnat.com (Postfix) with ESMTP id C5EAEF2824; Fri, 26 Mar 2004 11:40:32 -0500 (EST) Received: from nile.gnat.com ([127.0.0.1]) by localhost (nile.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 02685-01-3; Fri, 26 Mar 2004 11:40:32 -0500 (EST) Received: by nile.gnat.com (Postfix, from userid 338) id 89F7BF2DA7; Fri, 26 Mar 2004 11:40:32 -0500 (EST) To: Joe.Buck@synopsys.COM, law@redhat.com Subject: Re: -ffast-math and floating point reordering Cc: gcc@gcc.gnu.org Message-Id: <20040326164032.89F7BF2DA7@nile.gnat.com> Date: Fri, 26 Mar 2004 18:33:00 -0000 From: dewar@gnat.com (Robert Dewar) X-Virus-Scanned: by amavisd-new at nile.gnat.com X-SW-Source: 2004-03/txt/msg01562.txt.bz2 > No. The front-ends don't pass enough information around in the tree nodes > to know when such changes are safe/unsafe. Even if the information existed > none of the optimizers would know how to use it (at least initially). It's a significant goof for a Fortran compiler not to remember whether parens are used. GNAT remembers not only if parens were used, but how many levels, but that's required due to obscure requirements in conformance rules, and of course it is not passed on to the back end since (a) that's not necessary, it does not affect semantics in Ada and in any case (b) there is no way to do that. > First I'd like to come out in favor of having a flag to turn on FP > reassociation. Note that there are two levels here. One is about what the Fortran standard allows in the absence of parens, which is rearrangement within an expression. The more extensive permission is to rearrange over a series of separately computed expressions.