From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 5283 invoked by alias); 2 Nov 2010 15:03:14 -0000 Received: (qmail 5273 invoked by uid 22791); 2 Nov 2010 15:03:13 -0000 X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00,MISSING_MID 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; Tue, 02 Nov 2010 15:03:08 +0000 From: "steven at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug tree-optimization/46183] [4.6 Regression] ICE: in calc_dfs_tree, at dominance.c:396 with -O -fno-dse -fgcse -ftree-pre X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: tree-optimization X-Bugzilla-Keywords: ice-on-valid-code X-Bugzilla-Severity: normal X-Bugzilla-Who: steven at gcc dot gnu.org X-Bugzilla-Status: NEW X-Bugzilla-Priority: P1 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: 4.6.0 X-Bugzilla-Changed-Fields: Status AssignedTo 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 Date: Tue, 02 Nov 2010 15:03:00 -0000 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: 2010-11/txt/msg00136.txt.bz2 Message-ID: <20101102150300.lHDmeyGjnyIl8Ec9LQ8e--hje12GF7WmmI13oN6-ti4@z> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=46183 Steven Bosscher changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |NEW AssignedTo|steven at gcc dot gnu.org |unassigned at gcc dot | |gnu.org --- Comment #6 from Steven Bosscher 2010-11-02 15:02:39 UTC --- Fix would look something like this. No time to finish this, though. Index: gcse.c =================================================================== --- gcse.c (revision 166183) +++ gcse.c (working copy) @@ -5246,11 +5246,13 @@ gate_rtl_cprop (void) static unsigned int execute_rtl_cprop (void) { + int changed; delete_unreachable_blocks (); df_set_flags (DF_LR_RUN_DCE); df_analyze (); - flag_rerun_cse_after_global_opts |= one_cprop_pass (); - return 0; + changed = one_cprop_pass (); + flag_rerun_cse_after_global_opts |= changed; + return changed ? TODO_cleanup_cfg : 0; } static bool @@ -5265,10 +5267,12 @@ gate_rtl_pre (void) static unsigned int execute_rtl_pre (void) { + int changed; delete_unreachable_blocks (); df_analyze (); - flag_rerun_cse_after_global_opts |= one_pre_gcse_pass (); - return 0; + changed = one_pre_gcse_pass (); + flag_rerun_cse_after_global_opts |= changed; + return changed ? TODO_cleanup_cfg : 0; } static bool @@ -5286,10 +5290,12 @@ gate_rtl_hoist (void) static unsigned int execute_rtl_hoist (void) { + int changed; delete_unreachable_blocks (); df_analyze (); - flag_rerun_cse_after_global_opts |= one_code_hoisting_pass (); - return 0; + changed = one_code_hoisting_pass (); + flag_rerun_cse_after_global_opts |= changed; + return changed ? TODO_cleanup_cfg : 0; } struct rtl_opt_pass pass_rtl_cprop =