[polly] Memory access based dependency analysis
Tobias Grosser
tobias at grosser.es
Tue Jun 24 15:22:26 PDT 2014
On 24/06/2014 23:59, Johannes Doerfert wrote:
> If we allow reductions and other "statements" in one SCoP statement a
> situation as explained below could arise.
>
> Situation:
> Assuming we want to allow more than one reduction in a statement, we still
> do not want to parallelize the last loop as it is not (easily)
> parallelizable.
I can see that we want this.
> However, if we only look at dependences on statement level we see a
> reduction read-write-pair and the corresponding reduction dependences
> template:
> { Stmt_for_body[i0] -> Stmt_for_body[1 + i0] : i0 >= 0 and i0 <= 1022 }
> and might assume we can remove these dependences from the overall set of
> dependences for this statement.
>
>
>
> While this is true for a loop nest with only sum and also for something
> like:
> for (i) {
> A[i] = A[i] + A[i-2];
> *sum += i;
> }
> It is not true/allowed for the last loop nest shown below.
Interesting. So it seems the test cases that show the benefit of
per-access dependence computation all have more than just a single
reduction. Is this right?
Is there any benefit of per-memory-access tracking in the current code
base? Can we show it in a test case?
Tobias
More information about the llvm-commits
mailing list