bug-gnulib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-gnulib] getline bug?


From: P
Subject: Re: [Bug-gnulib] getline bug?
Date: Tue, 05 Oct 2004 10:11:22 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040124

Paul Eggert wrote:
Jim Meyering <address@hidden> writes:

Simon's solution (of changing the default to be `don't use unlocked-io')
is fine with me.

OK, I installed the following into gnulib, so that the change is done
systematically for all gnulib modules.  I also installed the
coreutils-relevant part of this patch into coreutils.  There are one
or two other coreutils-only changes but I'll note them only on
bug-coreutils.

This got me thinking of work I previously did in this area.
I actually prompted the use of unlocked IO stuff here:
http://www.mail-archive.com/address@hidden/msg00531.html

In general I don't agree with the unlocked versions of the glibc
functions being exposed. Couldn't glibc set a flag whether to
use locking or not when pthread_create is called?
See the inlined message here: http://marc.theaimsgroup.com/?l=linux-kernel&m=103251587403711&w=2
Note it's not feasible to do at compile time as indictated here:
http://www.mail-archive.com/address@hidden/msg02537.html

Also I really think that coreutils/lib/linebuffer.c should use getline
when available, as it's faster than even unlocked IO for any lines
over 2 characters (and only slightly slower in that case).
http://www.pixelbeat.org/linebuffer-2.0.21-getline.diff

Pádraig.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]