This is the mail archive of the libc-alpha@sources.redhat.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]
Other format: [Raw text]

Re: [Bug libc/1005] putc() runs slower


Uttam Pawar <uttamp@us.ibm.com> writes:

> it's time consuming for the users to find and replace
> (assuming they have source access, resources and knowledge of glibc) all
> the putc() calls they used in their application with putc_unlocked().

Users can employ the unlocked-io module of gnulib.  That is what
coreutils, tar, etc. do.  The only change to the C source code is to
add "#include <unlocked-io.h>"; you needn't replace putc, etc.  See:

http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/gnulib/gnulib/MODULES.html?rev=HEAD&content-type=text/html#module=unlocked-io

and for an example of it in use, see:

ftp://ftp.gnu.org/gnu/coreutils/coreutils-5.2.1.tar.gz

I wouldn't object to adding something like <unlocked-io.h> to glibc,
but I wouldn't say it's essential either.


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