static executable bloat
Andreas Schwab
schwab@suse.de
Thu Aug 19 05:24:00 GMT 1999
Zack Weinberg <zack@bitmover.com> writes:
|> I spent a lot of time today bashing at this, but there is no easy fix.
|> I guess this is just a "libio should be smaller" whine. Note that an
|> awful lot of places in there know when a stream is wide; it seems to
|> me that this ought to be hidden in the jump table. There's no reason
|> why not to redirect _IO_setb instead of having _IO_setb and _IO_wsetb,
|> for example.
The wide stream stuff isn't actually that big. I was only able to reduce
the size by about 8.3K by leaving out the wide stream support (see the
attached patch for how I did that). The rest from libio is mostly the
printf stuff that is pulled in by malloc.
A much bigger problem is the gconv stuff, which is indirectly referenced
in strtol via btowc. The biggest single object file that is included is
regex.o, which is referenced by gconv_db.c. I don't see a way to reduce
this.
Andreas.
More information about the Libc-hacker
mailing list