This is the mail archive of the libc-alpha@sourceware.cygnus.com mailing list for the glibc project.


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

Re: Stuff dragged in by crt1 (was Re: Announce: initrd-tftp 0.1)


> A remaining annoyance is that if you add a call to malloc() to the above,
> it bloats back up to 237k.  This is because the MALLOC_CHECK stuff refers
> to stdio.  I would personally like to see all that ripped out to a preload
> library, or even scrapped, but I doubt I'll get my wish.

Well, I think MALLOC_CHECK_ is really immensely useful :), so I won't
scrap it.  A move of all the malloc stuff that uses stdio into a
preload library would certainly be OK with me, but then MALLOC_CHECK_
wouldn't work with statically linked executables, which are the topic
at hand.

Anyway, I am considering putting it on my TODO to at least move all
the malloc stuff that uses stdio into a separate source file (the
single malloc source file has become way too large in any case).  Then
when linking statically stdio wouldn't be pulled in unless you would
call __malloc_check_init or malloc_stats directly.

The two places where __malloc_check_init are called internally could
be protected with a MALLOC_USE_CHECK test that would need to be `off'
for static compilation.

I'm not sure yet whether all this is worth it.  Comments?

Regards,
Wolfram.

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