This is the mail archive of the gcc-bugs@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]
Other format: [Raw text]

[Bug tree-optimization/40436] [4.5 regression] 0.5% code size regression caused by r147852



------- Comment #6 from hubicka at gcc dot gnu dot org  2009-06-30 12:44 -------
Created an attachment (id=18100)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=18100&action=view)
Proposed patch

The problem is that early inliner allows to increase code size estimate by
inlining single function by up to 12 instructions.  This is higher than on
pretty-ipa branch still, since we are not that good on early optimizing yet and
some C++ benchmarks (tramp/botan/boost) degrade when reduced to 7 as used by
tramp3d. In tramp3d it is mostly caused by dead loops in constructors, and I
hope that merging IPA-SRA and CD-DCE improvements will care this on all three
benchmarks. At -O2 early inliner needs to be somewhat speculative since it
don't know the function profiles yet. It however seems stupid to allow code
size growth at -Os in general.

This patch changes it reducing compress.o from 14k to 9k on i386. I guess I
will need to give it full CSiBE run since it is question whether little
speculative inlining won't result in better overall score.

Honza


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40436


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