From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5795 invoked by alias); 16 Dec 2002 22:39:03 -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 5767 invoked from network); 16 Dec 2002 22:39:02 -0000 Received: from unknown (HELO book.moene.indiv.nluug.nl) (195.109.255.217) by sources.redhat.com with SMTP; 16 Dec 2002 22:39:02 -0000 Received: from local ([127.0.0.1] helo=moene.indiv.nluug.nl) by book.moene.indiv.nluug.nl with esmtp (Exim 3.36 #1 (Debian)) id 18O3qU-0001rI-00; Mon, 16 Dec 2002 23:36:18 +0100 Message-ID: <3DFE5562.6030608@moene.indiv.nluug.nl> Date: Mon, 16 Dec 2002 14:44:00 -0000 From: Toon Moene Organization: Moene Computational Physics, Maartensdijk, The Netherlands User-Agent: Mozilla/5.0 (X11; U; Linux ppc; en-US; rv:1.0.0) Gecko/20020622 Debian/1.0.0-0.woody.1 MIME-Version: 1.0 To: Richard Henderson CC: gcc@gcc.gnu.org Subject: Re: possible gcse failure: not able to eliminate redundant loads References: <20021213093054.GA29293@redhat.com> <3DFA4252.3060309@moene.indiv.nluug.nl> <20021216180441.C3953@redhat.com> <3DFE3FC1.9020802@moene.indiv.nluug.nl> <20021216211245.F4851@redhat.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-SW-Source: 2002-12/txt/msg00949.txt.bz2 Richard Henderson wrote: > On Mon, Dec 16, 2002 at 10:04:01PM +0100, Toon Moene wrote: > >>BTW, I wasn't aware it's legal to dereference NULL C pointers. > It isn't, of course. But that's the whole point. You've > got code that says > > x = (condition ? *p : 0); > > i.e. the dereference is protected by a conditional. Thus > we can't hoist the dereference past the conditional (and > thence out of the loop that started this thread). Oh, Fortran is sooooo much easier in this respect than [some other languages]. Of course you can [syntactically] express "dereferencing" a invalid pointer in Fortran 90/95. That doesn't mean the resulting program has to do something meaningful, however [could start WW III and all that] -- Toon Moene - mailto:toon@moene.indiv.nluug.nl - phoneto: +31 346 214290 Saturnushof 14, 3738 XG Maartensdijk, The Netherlands Maintainer, GNU Fortran 77: http://gcc.gnu.org/onlinedocs/g77_news.html Join GNU Fortran 95: http://g95.sourceforge.net/ (under construction)