Date: 2001-09-07 08:00:12
--- In boost_at_y..., "Peter Dimov" <pdimov_at_m...> wrote:
> From: "William Kempf" <williamkempf_at_h...>
> > From: "Peter Dimov" <pdimov_at_m...>
> > >BTW why doesn't boost::mutex use a critical section on win32?
> > To avoid having to either include the windows headers in
> > require dynamic allocation internally. During development I was
> > with research that showed that critical sections often actually
> > worse performance than mutexes (surprised me), so it was easier
> > implement using a Win32 mutex.
> Yes, I see the point now. However this will be, I think,
unacceptable to the
> performance freak types, who will gladly pay the price of #include
> <windows.h> (because they are likely to need it anyway) in return
> increased performance.
Actually, there's other alternatives that will give us the best of
both worlds (check out the OPTEX example in the MSDN). This
implementation is much more difficult, though, so I've initially
> I'll be interested in your research. MS people that know the
> that a critical section is incredibly optimized and should beat a
> any reasonable scenario.
It wasn't my research. It was research that Alexander Terekhov
(spelled from memory, sorry if I buthered it) found on the net. At
some point I'll find the time to find the link and post it here for
everyone to check out. The findings surprised me greatly, because
I've read the MS claims and seen several instances where the
performance boost of critical sections was easily observable.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk