[cpp-threads] Yet another visibility question

Alexander Terekhov alexander.terekhov at gmail.com
Fri Jan 12 20:03:50 GMT 2007


On 1/12/07, Paul E. McKenney <paulmck at linux.vnet.ibm.com> wrote:
[...]
> > Think of implementing SC  with per-variable locks on a large x86/IA32
> > NUMA configuration with multiple FSBs or whatever. It won't be any
> > better than cmpxchg for loads and xchg for stores (both locked).
>
> My understanding is that locking is only guaranteed to force SC execution
> of critical sections when all of the critical sections of interest
> are guarded by the same lock.  Therefore, per-variable locks will not
> necessarily force SC execution of all accesses.

Give an example (for x86/IA32).

regards,
alexander.



More information about the cpp-threads mailing list