[Bug tree-optimization/90316] large compile time increase in opt / alias stmt walking for Go example

rguenth at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri May 3 09:12:00 GMT 2019


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90316

--- Comment #2 from Richard Biener <rguenth at gcc dot gnu.org> ---
So with just _E0 to _E175 assigns we are calling get_continuation_for_phi 1400
times through translate_vuses_through_block (part of PHI translation) and
that recurses ~80000 times.

The CFG is "interesting" indeed.

Part of the slowness is due to DOM fast queries not available during VN,
that's easy to fix, bringing levels down to to GCC 8 state:

Index: gcc/tree-ssa-pre.c
===================================================================
--- gcc/tree-ssa-pre.c  (revision 270833)
+++ gcc/tree-ssa-pre.c  (working copy)
@@ -4197,6 +4202,7 @@ pass_pre::execute (function *fun)
   loop_optimizer_init (LOOPS_NORMAL);
   split_critical_edges ();
   scev_initialize ();
+  calculate_dominance_info (CDI_DOMINATORS);

   run_rpo_vn (VN_WALK);


More information about the Gcc-bugs mailing list