This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/20742] [4.0/4.1 Regression] Hang in tree_ssa_iv_optimize_loop
- From: "rakdver at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 4 Apr 2005 14:03:14 -0000
- Subject: [Bug tree-optimization/20742] [4.0/4.1 Regression] Hang in tree_ssa_iv_optimize_loop
- References: <20050404113801.20742.jakub@gcc.gnu.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From rakdver at gcc dot gnu dot org 2005-04-04 14:03 -------
This is scev analysis problem. On this testcase, it produces exponentially
large expressions (of form a_5 + b_6 + b_6 - a_5 + b_6 + b_6 - a_5 + b_6 - a_5 ...).
As for possible solutions: more clever folding that would transform this to
c1 * a_5 + c2 * b_6 would help in this particular case, but the possibility that
an exponentially large expression that will not be possible to fold will be produced
by scev would still exist.
Scev probably should keep track of how large expressions it produces, and just give
up if it grows beyond some limit.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20742