This is the mail archive of the
mailing list for the GCC project.
optimizer gives up for large functions
- From: Peter Foelsche <peter dot foelsche at silvaco dot com>
- To: gcc-help at gcc dot gnu dot org
- Date: Wed, 05 Dec 2012 11:53:05 -0800
- Subject: optimizer gives up for large functions
This mail applies to g++ 4.5.2 running on 64bit linux
Linux NAME 2.6.9-89.ELsmp #1 SMP Mon Apr 20 10:33:05 EDT 2009 x86_64
x86_64 x86_64 GNU/Linux
I remember nearly 3 years ago g++ took 1hour and 4GB of memory to
compile some of my functions. And the generated code was exceptionally good!
This is not the case anymore -- I don't know since when.
Today I only get good code for small toy examples.
I used the -Wdisabled-optimization and used some parameter settings to
get around this
-- but without result:
g++ -fPIC -shared -DNDEBUG -O3 -march=native -I
/home/peterf/boost_1_47_0 -std=c++0x --param max-gcse-memory=1073741824
One problem is that the copy constructor is really being expressed.
I was already thinking that some idiot at my company
changed the compiler to default to -fno-elide-constructors.
Another problem is that many operations are done on the stack instead of
I'm talking about floating point operations with double.
Too many of the following operations:
Anybody any clue?