From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32753 invoked by alias); 29 Jul 2002 17:48:21 -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 32746 invoked from network); 29 Jul 2002 17:48:20 -0000 Received: from unknown (HELO www.eyesopen.com) (12.96.199.11) by sources.redhat.com with SMTP; 29 Jul 2002 17:48:20 -0000 Received: from localhost (roger@localhost) by www.eyesopen.com (8.9.3/8.9.3) with ESMTP id LAA23956; Mon, 29 Jul 2002 11:34:51 -0600 Date: Tue, 30 Jul 2002 03:30:00 -0000 From: Roger Sayle To: John David Anglin cc: Subject: Re: gcc bootstrap broken on i686-linux-gnu In-Reply-To: <200207291708.g6TH8ivR016713@hiauly1.hia.nrc.ca> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-SW-Source: 2002-07/txt/msg01392.txt.bz2 Hi Dave, > > Certainly. Sorry for any inconvenience. The two possible > > changes in behaviour are that -1.0*x is now tranformed into > > -x by default (this previously only happened with -ffast-math), > > This transformation is going to cause a problem on hppa1* machines > because prior to PA2.0 the HP IEEE implementation didn't have a > fneg instruction. So, to get correct behavior we convert -x to > -1.0*x (see for example negsf2 pattern in pa.md) except when > flag_unsafe_math_optimizations is set where we use fsub. Fortunately, the -1.0*x into x transformation is being applied in fold-const.c, so works on the tree representation of the expression. This should be completely safe, and allows things like "x = (y<0)? -1.0*y : y" to be recognized as "x = fabs(y)". If the "-y" survives until RTL generation time, the PA backend will convert it back into the multiplication. I agree there could be an issue if this transformation were to be added to the RTL optimizers. Roger --