This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: 3.0 -finline-limit and c++


Gerald Pfeifer wrote:
> 
> Indeed, I should add that part of the motivation for Mark to make this
> change was a (relatively simple though template heavy) code base of mine
> where GCC 2.95 had no problems at all and (then) current snapshots of
> GCC 3.0 crashed after consuming *all* memory -- and we're talking about
> an increase in memory consumption of at least 1000%.
> 
> And, somehow, we are now back in that situation again and GCC 3.0 again
> consumes "infinitely" much memory for that code! :-(

I also noticed that it takes quite a long time to compile with default
settings--that is why I was trying to use -finline-limit to reduce
compile time and object size, with bad results.  By disabling the inline
context check and using limit of 500 or 1000 insns, the compile time is
much faster with reasonable inlining.  In my cases, that is.
 
> One thing I suggested to Mark is performing the inlining (resp. breaking
> of inline chains) bottom-up instead of top-down in the tree, which might
> help performance in some cases.

I think it is prerequisite to get context size working properly. 
Preferably the functions should already be somewhat optimized to see the
real size.

Teemu


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]