[cpp-threads] Re: Review comments on N2176 WRT dependency ordering
Paul E. McKenney
paulmck at linux.vnet.ibm.com
Fri Apr 13 14:18:08 BST 2007
On Wed, Apr 11, 2007 at 11:54:34PM -0000, Boehm, Hans wrote:
> > -----Original Message-----
> > From: Paul E. McKenney [mailto:paulmck at linux.vnet.ibm.com]
> > What is your reaction to the notion of dependency defined in
> > the Itanium and the POWER architecture documents? Page 384
> > of my copy of volume 2 of the Itanium Architecture manual
> > defines a dependency from A to B as follows:
> >
> > "A precedes B in program order and A produces a value that
> > B consumes."
> >
> I think that especially at the programming language level, this
> introduces a large number of unclear corner cases:
>
> 1) When do library functions propagate dependencies? Is there a
> dependency from a character inserted into a string to the resulting
> string size? To the output of search for a certain substring?
When the formal parameters are marked as propogating dependencies.
> 2) What if the type involved has only one corresponding valid value?
C and C++ being what they are, the dependency should remain -- if
the head of the dependency chain was marked, and if any function calls
were also appropriately marked.
> 3) In what sense is a value produced in a switch statement dependent on
> the switch expression?
> Etc.
Via control dependency -- and it may be useful to have a primitive that
terminates a dependency chain, as noted in the paper.
> It may be that this can be addressed. But I don't think it's easy. The
> topic is certainly on my list of things to be discussed in Oxford.
If it were easy, it would have been done long ago, right?
I do look forward to the discussion!!!
Thanx, Paul
More information about the cpp-threads
mailing list