[net.unix-wizards] Wanted: event control for UNIX

bobr@chemabs (bobr) (12/18/84)

We are looking for a feature in UNIX which will give event control.  
This feature will allow a program to sleep on multiple queues, and to 
wake up when any one of the queues has something put into it.  The 
queues could be TTY I/O, disk I/O or IPC.  We are currently using System 
V.  If anyone on the net has seen such a feature, or could recommend an 
approach on how we could design it ourselves, please let us know.  

Thanks in advance,

   Bob Richards
   Chemical Abstracts Service
   (614) 421-3600 X2486
   ..!cbosgd!osu-eddie!apr!chemabs!bobr

chris@umcp-cs.UUCP (Chris Torek) (12/24/84)

> We are looking for a feature in UNIX which ... will allow a program to
> sleep on multiple queues, and to wake up when any one of the queues has
> something put into it.  The queues could be TTY I/O, disk I/O or IPC.
> We are currently using System V.

You could always get 4.2BSD.  It already has such a mechanism:  the
select() system call.
-- 
(This line accidently left nonblank.)

In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (301) 454-7690
UUCP:	{seismo,allegra,brl-bmd}!umcp-cs!chris
CSNet:	chris@umcp-cs		ARPA:	chris@maryland

geoff@desint.UUCP (Geoff Kuenning) (12/25/84)

In article <144@chemabs> bobr@chemabs (bobr) writes:

>We are looking for a feature in UNIX which will give event control.  
>This feature will allow a program to sleep on multiple queues, and to 
>wake up when any one of the queues has something put into it.  The 
>queues could be TTY I/O, disk I/O or IPC.  We are currently using System 
>V.

Sounds like the System V semaphores are just the ticket.  See semop(2),
semget(2), and semctl(2).  Or am I missing something?
-- 

	Geoff Kuenning
	...!ihnp4!trwrb!desint!geoff

gnu@sun.uucp (John Gilmore) (12/26/84)

Bob Richards at chemabs asks:
> We are looking for a feature in UNIX which will give event control.  
> This feature will allow a program to sleep on multiple queues, and to 
> wake up when any one of the queues has something put into it.  The 
> queues could be TTY I/O, disk I/O or IPC.  We are currently using System 
> V...

That last sentence gave it all away.  Had you been running 4.2BSD,
you wouldn't have to be asking people how to design and build the feature
yourself.  Berkeley already did it and called it select().

	Unix System V: Consider It Broken

(flames to /dev/kmem, please.)