This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/14179] [3.3/3.4/4.0 Regression] out of memory
- From: "giovannibajo at libero dot it" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 23 Sep 2004 00:02:04 -0000
- Subject: [Bug c++/14179] [3.3/3.4/4.0 Regression] out of memory
- References: <20040217171044.14179.debora.j.estey@lmco.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From giovannibajo at libero dot it 2004-09-23 00:01 -------
Mark: process_init_constructor builds new TREE_LISTs for each new initializer.
This is pretty easy to get rid of, at least for arrays, and will be taken of
with a patch I will be testing soon. The mainline version will likely extract
and cleanup array handling into a separate function.
But process_init_constructor also calls digest_init for each and every
initializer, which makes the initializer goes through the conversion machinery.
For the example in this PR, we build an IDENTITY_CONV and a couple of
STANDARD_CONV for each initializer.
For mainline, I could try to modify the conversion engine to not use trees to
keep track of conversions. I think a specific struct kept in a local Vec would
be good enough.
For 3.4/3.3, is there a way to avoid calling digest_init if we detect that we
can just fold_convert (or similar) the initializer? Or maybe put such a speedup
check within digest_init directly? I am thinking of simple default promotions,
for which building 3-4 trees and throwing them away doesn't look too smart. I
am not expert in this kind of type conversions stuff, so I can't devise what a
correct check for this would be, without making it too specific for the case in
this PR. Can you suggest me something to get me started?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=14179