Subject: Re: M:N and blocking ops without SA, AIO
To: Jason Thorpe <thorpej@shagadelic.org>
From: Mindaugas R. <rmind@NetBSD.org>
List: tech-kern
Date: 03/01/2007 21:19:56
Jason Thorpe <thorpej@shagadelic.org> wrote:
> 
> On Mar 1, 2007, at 10:22 AM, jonathan@dsg.stanford.edu wrote:
> 
> > Well, the typical way to implement AIO is to have a pool of kernel
> > threads. Grab a kernel thread, issue the i/o, using the kernel thread
> > as the thread which blocks until the I/O is complete.  Then the kernel
> > thread posts completion to the AIO subsystem, which passes appropriate
> > status, signal info, etc. to the requesting thread.  Hmmmm,  
> > continuations :-/.
> 
> ...and that's an awful way to do it considering how all of the  
> underlying primitives that those blocking APIs use are asynchronous.
Well, I am implementing this model, right now. What would you suggest as a
long-time solution?

-- 
Best regards,
Mindaugas
www.NetBSD.org