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

Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.


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

Re: where is _IO_cookie_file used?


Ulrich Drepper <drepper@redhat.com> writes:

> Greg McGary <greg@kayak.mcgary.org> writes:
> 
> > _IO_STR_DYNAMIC isn't used internally in the C++ stuff under
> > gcc/libio.  _IO_STR_FROZEN isn't used internally, but is used for C++.
> > I would like to move the _IO_streambuf and _IO_strfile structs to
> > libioP.h and redefine _IO_STR_DYNAMIC/_IO_STR_FROZEN to call internal
> > functions that do the same thing.  That will eliminate the last of the
> > last of the user-visible vtables.
> 
> No functions calls where there were none before.

That's a nice rule of thumb, but I believe this should be an
exception.  _IO_STR_FROZEN is called by strstreambuf::freeze() to
inform the streambuf's destructor about who is responsible for freeing
the buffer storage.  This is hardly an inner-loop operation that needs
to be fast.  Do you have some other non-performance reason to avoid
converting this to a function call?

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