[cpp-threads] Comments on D2334

Hans Boehm Hans.Boehm at hp.com
Tue Jul 17 03:23:43 BST 2007



On Mon, 16 Jul 2007, Paul E. McKenney wrote:

> Hello!
>
> Here are comments on D2334 at:
>
> 	http://wiki.dinkumware.com/twiki/pub/Wg21toronto/EvolutionWorkingGroup/D2334.html
>
> 						Thanx, Paul
>
> o	1.10p2: This paragraph describes only atomics, correct?
> 	Non-atomic variables are subject to load/store tearing,
> 	so might see values other than those listed here.
> 	So I believe the modifier "atomic" needs to show up here,
> 	or perhaps "in absence of data races" or some such.
I think this is actually OK, since "the rules below" include undefined
semantics for races.  (see 1.10p11)

Let's discuss this in more detail tomorrow, if you still disagree.

>
> o	1.10p4: I agree with the note here: "We do not include "relaxed"
> 	atomic operations as "synchronization" operations though, like
> 	synchronization operations, they cannot contribute to data races."
> 	As noted in my prior note, N2324 needs to be adjusted to bring
> 	it in agreement.
It looks to me like N2324 is mostly in agreement, but has a few bugs, e.g. 
in the description of swap.  I'm sure we need to look at N3224 wording 
more carefully once we agree that it's basically saying the right thing.

>
> o	1.10p7: This paragraph needs to be brought into agreement with
> 	1.10p4.  One way to do this would be as follows add "non-relaxed"
> 	as follows:
>
> 		An evaluation A that performs a release operation on
> 		an object M synchronizes with  an evaluation B that
> 		performs an acquire operation on M and reads either the
> 		value written by A or, if the following (in modification
> 		order) sequence of updates to M are non-relaxed atomic
> 		read-modify-write operations, a value written by one of
> 		these read-modify-write operations.
Let's discuss this one in person tomorrow.

Hans
>
> (Still need to look at the non-terminating loops and subsequent sections.)
>
> -- 
> cpp-threads mailing list
> cpp-threads at decadentplace.org.uk
> http://www.decadentplace.org.uk/cgi-bin/mailman/listinfo/cpp-threads
>



More information about the cpp-threads mailing list