Threads in the new ISO C Standard from 2011
Threads in the new ISO C Standard from 2011
Threads in the new ISO C Standard from 2011
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
Dependences between Intra-Thread Evaluations<br />
Consider two expression evaluations A and B made by one thread.<br />
When we say that A carries a dependency to B it means A must be<br />
evaluated before B:<br />
v = u + 1; // A<br />
w = v * 2; // B<br />
The order of A and B should not be changed!<br />
Both compilers and hardware must preserve this order — and <strong>the</strong>y do.<br />
A is sequenced before B s<strong>in</strong>ce <strong>the</strong>re is a sequence po<strong>in</strong>t between<br />
A and B.<br />
Jonas Skeppstedt (js@cs.lth.se) Lecture 6 2013 32 / 70