re PR c/56113 (out of memory when compiling a function with many goto labels (50k...
authorSteven Bosscher <steven@gcc.gnu.org>
Thu, 31 Jan 2013 20:16:07 +0000 (20:16 +0000)
committerSteven Bosscher <steven@gcc.gnu.org>
Thu, 31 Jan 2013 20:16:07 +0000 (20:16 +0000)
PR middle-end/56113
* fwprop.c (fwprop_init): Set up loops without CFG modifications.

From-SVN: r195632

gcc/ChangeLog
gcc/fwprop.c

index 341e9aa434bbb97651eaae187fbc79696eaa7199..b8b116a1a0f834ec44789cd7a15bbd4442063b32 100644 (file)
@@ -1,3 +1,8 @@
+2013-01-31  Steven Bosscher  <steven@gcc.gnu.org>
+
+       PR middle-end/56113
+       * fwprop.c (fwprop_init): Set up loops without CFG modifications.
+
 2013-01-31  Hiroyuki Ono  <hiroyuki.ono.jc@renesas.com>
            Nick Clifton  <nickc@redhat.com>
 
index a055fd041e062ad5db7caf4a444661e8069c5074..6a82deabfd10a0a9a828664331117b4e4e44eb0d 100644 (file)
@@ -1404,10 +1404,10 @@ fwprop_init (void)
   calculate_dominance_info (CDI_DOMINATORS);
 
   /* We do not always want to propagate into loops, so we have to find
-     loops and be careful about them.  But we have to call flow_loops_find
-     before df_analyze, because flow_loops_find may introduce new jump
-     insns (sadly) if we are not working in cfglayout mode.  */
-  loop_optimizer_init (0);
+     loops and be careful about them.  Avoid CFG modifications so that
+     we don't have to update dominance information afterwards for
+     build_single_def_use_links.  */
+  loop_optimizer_init (AVOID_CFG_MODIFICATIONS);
 
   build_single_def_use_links ();
   df_set_flags (DF_DEFER_INSN_RESCAN);