[cpp-threads] Implicit Synchronization

Lawrence Crowl lawrence.crowl at gmail.com
Mon Jul 10 23:49:58 BST 2006


One of the things we must make sure we address is the implicit
syncronization that we expect in the data that we guard with
locks.  For example, with double-checked locking for sharing
variable initialization, we cannot define only the
synchronization on the locks, but also on the variable being
initialized.  Likewise, for reference-counted objects, we must
know that on (atomically) decrementing the count to zero,
reading the pointer must result in the value written.

-- 
Lawrence Crowl



More information about the cpp-threads mailing list