From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16803 invoked by alias); 23 Aug 2012 07:37:03 -0000 Received: (qmail 16632 invoked by uid 22791); 23 Aug 2012 07:37:01 -0000 X-SWARE-Spam-Status: No, hits=-4.3 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00,KHOP_THREADED X-Spam-Check-By: sourceware.org Received: from localhost (HELO gcc.gnu.org) (127.0.0.1) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 23 Aug 2012 07:36:47 +0000 From: "rguenther at suse dot de" To: gcc-bugs@gcc.gnu.org Subject: [Bug middle-end/53695] [4.8 Regression] ICE: in dfs_enumerate_from, at cfganal.c:1221 with -O2 -ftracer and labels/gotos Date: Thu, 23 Aug 2012 07:37:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: middle-end X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: rguenther at suse dot de X-Bugzilla-Status: ASSIGNED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: rguenth at gcc dot gnu.org X-Bugzilla-Target-Milestone: 4.8.0 X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated Content-Type: text/plain; charset="UTF-8" MIME-Version: 1.0 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: 2012-08/txt/msg01587.txt.bz2 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53695 --- Comment #11 from rguenther at suse dot de 2012-08-23 07:36:46 UTC --- On Wed, 22 Aug 2012, steven at gcc dot gnu.org wrote: > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53695 > > --- Comment #9 from Steven Bosscher 2012-08-22 21:33:18 UTC --- > I think the right fix for this bug is to use disambiguate_multiple_latches in > the loop updating code (fix_loop_structure), but I'm not sure where to put it. Not sure - we can handle multiple latches just fine (loop->latch will be NULL). But I see the loop state does not reflect that. Maybe Index: gcc/cfgloopmanip.c =================================================================== --- gcc/cfgloopmanip.c (revision 190613) +++ gcc/cfgloopmanip.c (working copy) @@ -1715,6 +1716,9 @@ fix_loop_structure (bitmap changed_bbs) } } + if (!loop_state_satisfies_p (LOOPS_MAY_HAVE_MULTIPLE_LATCHES)) + disambiguate_loops_with_multiple_latches (); + if (loops_state_satisfies_p (LOOPS_HAVE_PREHEADERS)) create_preheaders (CP_SIMPLE_PREHEADERS); which matches the order in which loop_optimizer_init calls it. Richard.