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]
Other format: [Raw text]

Re: Size of binaries.


[ larger C++ executables when -g is used ]

> /u/sbin/faxgetty:	ELF 32-bit LSB executable 80386, dynamically linked, stripped, debug
> /u/sbin/faxgetty.old:	ELF 32-bit LSB executable 80386, dynamically linked, stripped, debug
> 	
> What might be causing this increase in binary size of about 350% (I see
> for all of Hylafax's binaries)?

The main source of the size increase is almost certainly the size of the
debug info for the classes from the standard library.  libstc++ v3 is
substantially larger, because it's a complete (ISO C++) implementation,
while the old library was missing many features, and used plain classes
in many places where templates are now required.

I don't know how much redundancy may exist in the debug info, I suspect
that there are opportunies for reducing the file size. But the priority
up to this point has been on getting a complete and correct C++
implementation, not on size optimization.

> I tried recompiling smail and tcsh, which were both last compiled almost
> a year ago.  The smail binary came out trivially different, while the
> tcsh binary was in fact a bit smaller.

They are C.


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