Re: libthr and 1:1 threading.

From: Terry Lambert <tlambert2_at_mindspring.com>
Date: Wed, 02 Apr 2003 15:10:13 -0800
Jeff Roberson wrote:
> On Wed, 2 Apr 2003, Terry Lambert wrote:
> > Is the disk I/O really that big of an issue?  All writes will
> > be on underlying non-blocking descriptors; I guess you are
> > saying that the interleaved I/O is more important, further
> > down the system call interface than the top, and this becomes
> > an issue?
> 
> UNIX distinguishes between short term and long term blocking calls.  Non
> blocking io only avoids blocking for indeterminate periods of time.  The
> 20ms or so you're paying per IO on an IDE system is 20ms that no other
> threads can run.  This makes a difference.

See other message.  The fault should be tripped, but the process
should not wait around for the result, if it was tripped as the
result of a read on an async fd.  Instead an EAGAIN should go to
user space, and that 20ms should be used for something else in
user space, while the drive gets busy with the DMA.

This is arguably a bug in FreeBSD's handling of demand faults
on non-blocking fd's, compared to SVR4 and Solaris' handling.


> > It seems to me that maybe the correct fix for this is to use
> > AIO instead of non-blocking I/O, then?
> 
> Our AIO implementation needs some rethinking.  I'm not sure how
> effecient it actually is.

I will guess it suffers from the same "faulting == halting"
problem...


> > Also, any ETA on the per process signal mask handing bug in
> > libthr?  Might not be safe to convert everything up front, in
> > a rush of eager enthusiasm...
> 
> Which bug is that?  I'm not aware of it.

KSE mailing list, starting Monday or so:
] We still haven't heard from jeff with regard to the process
] signal mask removal.

-- Terry
Received on Wed Apr 02 2003 - 13:11:38 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:37:02 UTC