Re: [linux-audio-dev] sysv semaphores instead of pipes

New Message Reply About this list Date view Thread view Subject view Author view Other groups

Subject: Re: [linux-audio-dev] sysv semaphores instead of pipes
From: Paul Davis (pbd_AT_Op.Net)
Date: Tue Jun 26 2001 - 05:26:58 EEST


>> the problem with semaphores is that Unix/POSIX semantics don't allow
>> integration of a process sleeping on an file descriptor and a
>> semaphore (one of the few areas where Windows definitely improves upon
>> Unix). this would mean adding yet another thread that just sleeps on
>> the semaphore used to drive the "process" callback. Not terrible, but
>> not particularly great either. The code would be a little cleaner, but
>> we'd have an extra thread for every client. Uhm.
>
>Seems like a high price to pay, would the code really be cleaner?

It does seem like a high price to pay. And the code is only cleaner in
the library, where nobody really cares once it works.

It would be so nice if poll(2) worked on semaphores, eh?

--p


New Message Reply About this list Date view Thread view Subject view Author view Other groups

This archive was generated by hypermail 2b28 : Tue Jun 26 2001 - 05:28:51 EEST