This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/27809] inefficient gimplification of globals
- 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: 13 Jun 2006 14:09:28 -0000
- Subject: [Bug tree-optimization/27809] inefficient gimplification of globals
- References: <bug-27809-1008@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #2 from rakdver at gcc dot gnu dot org 2006-06-13 14:09 -------
(In reply to comment #1)
> Hmm, it should have produced G.3, G.n, at least I would have thought.
>
No, we intentionally use the same variable for the lexically identical
expressions, see internal_get_tmp_var/lookup_tmp_var. Original intention was
to make PRE and other redundancy elimination optimization passes more efficient
(this was essential especially for the old SSAPRE pass that used lexical
equality of expressions to check for redundancies). These reasons are no
longer relevant, but keeping the code saves a significant amount of memory and
compile time (I tried removing the code a few months ago, but since it slows
down compilation by some 1-2%, I never bothered with posting the patch).
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27809