|
Boost : |
From: Ross Smith (ross.s_at_[hidden])
Date: 2001-07-04 17:51:35
Alexander Terekhov wrote:
>
> > > http://www.acm.org/classics/feb96/
> > >
> > > "Monitors: An Operating System Structuring Concept
> > > C.A.R Hoare..."
> >
> > Thanks. This seems to be another case of me reinventing the wheel. :-)
> > What he's describing there seems to be the concept I put in my thread
> > library under the name Flag.
>
> i do not think so.. condition variables are stateless and
> they are working together with mutex providing atomic
> unlock_and_wait semantics (with respect to other threads
> and CV/mutex).
I meant that my Flag == his Monitor, not Flag == CV. If you disagree,
please explain what the difference is.
> note that auto-reset event is simply a binary semaphore.
> manual-reset events also have state. it is really difficult
> to use events due to all sorts of race conditions with
> respect to "program" state and event state.
I keep seeing assertions to that effect, but I've never seen any attempt
to justify the claim. Could you please supply a logical argument instead
of a bare take-my-word-for-it? (Your example using my RWL doesn't count;
I did say it was newly written and poorly tested, I expected it to still
have some bugs.)
-- Ross Smith <ross.s_at_[hidden]> The Internet Group, Auckland, New Zealand ======================================================================== "Unix has always lurked provocatively in the background of the operating system wars, like the Russian Army." -- Neal Stephenson
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk