public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "rguenth at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug tree-optimization/61515] [4.10 Regression] Extremely long compile time for generated code
Date: Tue, 17 Jun 2014 11:11:00 -0000	[thread overview]
Message-ID: <bug-61515-4-PQD3drxFwy@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-61515-4@http.gcc.gnu.org/bugzilla/>

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

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|memory-hog                  |
             Blocks|                            |47344

--- Comment #8 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to Richard Biener from comment #7)
> (In reply to Richard Biener from comment #6)
> > 4.9 at -Os takes 5min and ~2.2GB of ram (points-to takes 20%, DF 33%)
> 
> trunk at -Os takes 15min and ~2.1GB of ram (dominator optimization takes 67%)
> 
> trunk at -O1 takes 14min and ~2GB of ram (still DOM at 62%)
> 
> So it seems that on trunk DOM regressed a lot.  Confirmed as 4.10 regression.

With -O1 -fno-tree-dominator-opts behavior is sane:

 df reaching defs        :  86.99 (28%) usr  36.53 (66%) sys 124.04 (34%) wall 
     0 kB ( 0%) ggc
 tree PTA                :  10.31 ( 3%) usr   0.15 ( 0%) sys  10.47 ( 3%) wall 
  1948 kB ( 0%) ggc
 tree SSA incremental    :  98.24 (31%) usr   8.39 (15%) sys 106.63 (29%) wall 
 13570 kB ( 1%) ggc
 tree loop invariant motion:  14.46 ( 5%) usr   0.10 ( 0%) sys  14.54 ( 4%)
wall   14421 kB ( 1%) ggc
 scev constant prop      :  11.14 ( 4%) usr   0.02 ( 0%) sys  11.18 ( 3%) wall 
 28795 kB ( 2%) ggc
 TOTAL                 : 312.10            55.72           368.92           
1523092 kB
312.10user 55.84system 6:09.34elapsed 99%CPU (0avgtext+0avgdata
2073876maxresident)k
19664inputs+13880outputs (130major+38202143minor)pagefaults 0swaps

(well, sane apart from DF and SSA incremental), but with DOM not disabled
we get

 df reaching defs        : 108.63 (11%) usr   8.83 (38%) sys 117.08 (12%) wall 
     0 kB ( 0%) ggc
 tree PTA                :  10.51 ( 1%) usr   0.09 ( 0%) sys  10.60 ( 1%) wall 
  1948 kB ( 0%) ggc
 tree SSA incremental    :  99.41 (10%) usr   9.17 (39%) sys 108.93 (11%) wall 
 13474 kB ( 1%) ggc
 dominator optimization  : 617.08 (63%) usr   0.32 ( 1%) sys 618.97 (61%) wall 
 56878 kB ( 3%) ggc
 tree loop invariant motion:   2.15 ( 0%) usr   0.11 ( 0%) sys   2.25 ( 0%)
wall   12012 kB ( 1%) ggc
 scev constant prop      :  13.31 ( 1%) usr   0.02 ( 0%) sys  13.36 ( 1%) wall 
 28348 kB ( 2%) ggc
 TOTAL                 : 981.98            23.25          1007.67           
1625119 kB
981.98user 23.34system 16:47.79elapsed 99%CPU (0avgtext+0avgdata
2071112maxresident)k
184inputs+66416outputs (5major+18571554minor)pagefaults 0swaps

(yes, this is with release checking)

The testcase has _lots_ of loops (~11000), inside a big
outer one, the maximum nesting isn't too big (<10 from what I can see).
SSA incremental is likely loop-closed SSA rewrite - didn't check.

It should be possible to reduce the testcase somewhat if needed.

Eventually the soulution for DOM is to disable the new path-based
threading (if that turns out to be the issue) for -fno-expensive-optimizations
(that is, optimize < 2).


  parent reply	other threads:[~2014-06-17 11:11 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-15 23:23 [Bug tree-optimization/61515] New: " astrange at ithinksw dot com
2014-06-15 23:24 ` [Bug tree-optimization/61515] " astrange at ithinksw dot com
2014-06-16  2:40 ` pinskia at gcc dot gnu.org
2014-06-16  6:44 ` astrange at ithinksw dot com
2014-06-16  8:28 ` rguenth at gcc dot gnu.org
2014-06-16  9:45 ` rguenth at gcc dot gnu.org
2014-06-16  9:47 ` rguenth at gcc dot gnu.org
2014-06-16 11:19 ` [Bug tree-optimization/61515] [4.10 Regression] " rguenth at gcc dot gnu.org
2014-06-17 11:11 ` rguenth at gcc dot gnu.org [this message]
2014-06-17 11:23 ` rguenth at gcc dot gnu.org
2014-06-17 11:48 ` rguenth at gcc dot gnu.org
2014-06-17 12:00 ` [Bug tree-optimization/61515] [4.9/4.10 " rguenth at gcc dot gnu.org
2014-06-17 19:34 ` law at redhat dot com
2014-06-18  7:45 ` rguenther at suse dot de
2014-06-26 12:50 ` rguenth at gcc dot gnu.org
2014-07-16 13:28 ` jakub at gcc dot gnu.org
2014-10-21  9:39 ` [Bug tree-optimization/61515] [4.9/5 " rguenth at gcc dot gnu.org
2014-10-21  9:46 ` rguenth at gcc dot gnu.org
2014-10-21  9:52 ` rguenth at gcc dot gnu.org
2014-10-21  9:55 ` rguenth at gcc dot gnu.org
2014-10-21 10:05 ` rguenth at gcc dot gnu.org
2014-10-21 11:19 ` rguenth at gcc dot gnu.org
2014-10-21 11:59 ` rguenth at gcc dot gnu.org
2014-10-30 10:38 ` jakub at gcc dot gnu.org
2014-11-04 23:03 ` law at redhat dot com
2014-11-05 12:35 ` rguenth at gcc dot gnu.org
2014-11-06 21:45 ` law at redhat dot com
2014-11-07  8:33 ` rguenth at gcc dot gnu.org
2014-11-07 16:47 ` law at redhat dot com
2014-11-07 22:55 ` law at gcc dot gnu.org
2015-06-26 20:04 ` [Bug tree-optimization/61515] [4.9 " jakub at gcc dot gnu.org
2015-06-26 20:34 ` jakub at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-61515-4-PQD3drxFwy@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).