[cpp-threads] Question about RMW.acquire

Peter Dimov pdimov at mmltd.net
Thu Feb 1 20:58:19 GMT 2007


Anybody? :-)

Peter Dimov wrote:

> Question:
> 
> // x y initially 0
> 
> // thread 1
> 
> fetchadd_acquire( &x, +1 );
> r1 = load_raw( &y );
> 
> // thread 2
> 
> fetchadd_acquire( &y, +1 );
> r2 = load_raw( &x );
> 
> Is r1,r2 == 0,0 possible?




More information about the cpp-threads mailing list