Boost logo

Boost :

From: David Abrahams (dave_at_[hidden])
Date: 2007-08-22 10:11:15


on Mon Aug 20 2007, Howard Hinnant <howard.hinnant-AT-gmail.com> wrote:

> Here is a link to a reference implementation and a FAQ for mutexes,
> locks and condition variables I am currently anticipating proposing
> for C++ standardization (or subsequent TR).
>
> http://home.twcny.rr.com/hinnant/cpp_extensions/concurrency_rationale.html

  "However if the external mutex is (or is layout compatible with) a
  pthread_mutex_t, then there is no need for the internal
  pthread_mutex_t. When one wants to wait, one simply waits on the
  external pthread_mutex_t with the internal pthread_cond_t."

This smells a little fishy. It seems to imply that pthreads can wait
on any old data type that happens to be layout-compatible with
pthread_mutex_t. Is that really true?

-- 
Dave Abrahams
Boost Consulting
http://www.boost-consulting.com
The Astoria Seminar ==> http://www.astoriaseminar.com

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk