lkml.org 
[lkml]   [1997]   [Jan]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Async IO
On Mon, 27 Jan 1997, Nathan Bryant wrote:

> On Sun, 26 Jan 1997, Greg Alexander wrote:
>
> > You only need to use one signal, then the signal handler will look at some
> > shared memory to see what the signal was for. And there's no really good
> > reason that i know of to not use SIGHUP, SIGCHLD, SIGIO, SIGPWR, etc.
>
> Using shared memory from signal handlers isn't easy. The pthreads
> synchronization routines can't be called from signal handlers, because
> they rely on signals to wake up a task that's blocked on a mutex or
> condition.

aren't you over-complexicating? All you need for threading is clone(2) and
mmap(2).

> Async I/O can be done on linux, but it can't be done portably until Linux
> gets better signal support.

mmap had darn better be portable. :) And you can do it with just fork.

Greg Alexander
http://www.cia-g.com/~sietch/


\
 
 \ /
  Last update: 2005-03-22 13:38    [W:0.055 / U:0.864 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site