for (i=1; i<=n; i++) { a[i] = b[i] + 2; c[i] = a[i+1] + d[i]; }
This loop cannot be vectorized or concurrentized directly. An
antidependence on a
exists from the second assignment
statement to the first. If this loop were directly concurrentized,
some executions of the first statement could precede those of
the second, and the antidependence would be violated. The values
a[2]
through a[n]
would be incorrect.
If the two statements were interchanged, the loop could be vectorized directly, or distributed with each new loop concurrentized.