From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 31314 invoked by alias); 21 Jun 2007 08:00:03 -0000 Received: (qmail 31122 invoked by alias); 21 Jun 2007 07:59:51 -0000 Date: Thu, 21 Jun 2007 08:00:00 -0000 Message-ID: <20070621075951.31120.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug middle-end/20623] ICE: fold check: original tree changed by fold with --enable-checking=fold In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "rguenther at suse dot de" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2007-06/txt/msg01859.txt.bz2 ------- Comment #20 from rguenther at suse dot de 2007-06-21 07:59 ------- Subject: Re: ICE: fold check: original tree changed by fold with --enable-checking=fold On Thu, 20 Jun 2007, spop at gcc dot gnu dot org wrote: > > > ------- Comment #17 from spop at gcc dot gnu dot org 2007-06-20 22:58 ------- > Subject: Re: ICE: fold check: original tree changed by fold with > --enable-checking=fold > > Hi, > > The following patch fixes a part of the reported testsuite fails. > With this patch we avoid folding the TREE_CHAIN of an SSA_NAME, that > corresponds to its SSA_NAME_DEF_STMT. > > Index: gcc/fold-const.c > =================================================================== > --- gcc/fold-const.c (revision 125883) > +++ gcc/fold-const.c (working copy) > @@ -12775,7 +12775,8 @@ recursive_label: > fold_checksum_tree (TREE_TYPE (expr), ctx, ht); > if (TREE_CODE_CLASS (code) != tcc_type > && TREE_CODE_CLASS (code) != tcc_declaration > - && code != TREE_LIST) > + && code != TREE_LIST > + && code != SSA_NAME) > fold_checksum_tree (TREE_CHAIN (expr), ctx, ht); > switch (TREE_CODE_CLASS (code)) > { > > The only fails that remain when compiling with default languages and > --enable-checking=assert,fold,gc,misc,rtl,rtlflag,runtime,tree > on i686-linux are: > > gcc.c-torture/compile/20021108-1.c > gcc.c-torture/compile/920501-7.c > gcc.c-torture/compile/labels-1.c > gcc.c-torture/compile/labels-2.c > gcc.c-torture/compile/labels-3.c > gcc.c-torture/execute/comp-goto-1.c > gcc.dg/20021029-1.c > gcc.dg/pr16973.c > > Okay for trunk? Yes, this is ok. Richard. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20623