help with shriking binary size

Chris Croswhite ccroswhite@get2chip.com
Wed Sep 11 16:06:00 GMT 2002


Hello,

I need some help.  I have been running some comparisons with 2.95.3 and
3.2 and found that with the same machine and same source code, 3.2
produces code that is larger by 25%-51% larger with no run time
improvement (tested across several executables and test cases).  Is
there a way to shrink the size down to the same level as 2.95.3?  Here
are several cases:

2.95.3			3.2
(-g):30560264		6246679(+51%)
(-O):8889831		11198086(+26%)
(-O2):8893383		11458534(+29%)
(-O3):9009271		11252525(+25%)

Both 2.95.3 and 3.2 were compiled on the same machine.  The binaries in
question were also built on the same machine.  All tests were conducted
on the same machine.

The machine is:

Generic
Linux 2.4.18
Athlon build
SMP
2x Athlon 1800 MP
as - GNU assembler 2.11.90.0.8
ld - GNU ld 2.11.90.0.8

Any suggestions on where to begin and how to reduce these exacutables is
greatly appreciated.

BTW, the code base is mixed c and c++.

TIA,
Chris Croswhite




More information about the Gcc-help mailing list