From: Michael Glassford (glassfordm_at_[hidden])
Date: 2004-07-17 10:42:18
Matt Hurd wrote:
> On Fri, 16 Jul 2004 23:38:43 -0400, Michael Glassford
> <glassfordm_at_[hidden]> wrote:
>>Matt Hurd wrote:
>>>On Fri, 16 Jul 2004 13:54:32 -0400, Michael Glassford
>>>The mutex taxonomy I have in mind would be:
>>> 1. null_mutex
>>> elided ops, atomic ops with interlocking
>>This is a good idea.
> Uh oh, I mistyped that in my rush to go riding with my kids and you
> are agreeing with me....
> I think the null mutex should have inc, dec, exchange and whatever as
> static non-interlocked ops and the other mutexes should have them as
> static interlocked ops.
> That keeps a null mutex to the single threaded case.
> Perhaps interlocked ops should live in a multi_thread:: or
> single_threaded:: struct and the appropriate mutexes should just
> inherit these interfaces.
> That way seems neater as you can still reference the
> multi_threaded::add(...) and the Mutex::add(...) for the appropriate
> context sensitive operations.
Actually, all I meant is that I liked the idea of a null mutex (in the
context of it being substituted for a real mutex in a single-threaded
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk