[PATCH] D19984: [LV] Handle RAW dependences in interleaved access analysis
silviu.baranga@arm.com via llvm-commits
llvm-commits at lists.llvm.org
Fri May 13 09:27:47 PDT 2016
sbaranga added a comment.
Matt: thanks for doing this analysis!
> What about moving elements of an interleaved group over other dependent accesses not in the same group?
>
> Adam
We shouldn't be doing that. We should be preserving dependences, and as long as we do that this should be correct.
It does look like things are more complicated then what I previously stated, at least with regard to RAW. And we do need to consider non-zero distance dependences (because we are essentially moving this loads/stores after interleaving). Here is an example:
for (...) {
a[i].a = a[i + 2].a + 1
tmp = a[i - 1].a * 2
a[i].b = tmp
a[i].c = tmp
a[i].d = tmp
}
The problem here is that by moving the store to a[i].a we're breaking the loop-carried dependence from a[i].a to a[i-1].a (which doesn't stop vectorization).
Cheers,
Silviu
http://reviews.llvm.org/D19984
More information about the llvm-commits
mailing list