[llvm] [LAA] Support different strides & non constant dep distances using SCEV. (PR #88039)

Michael Kruse via llvm-commits llvm-commits at lists.llvm.org
Wed Apr 17 16:21:36 PDT 2024


Meinersbur wrote:

> > I would enjoy more textual description of what every condition is meant to check.
> 
> There are multiple places that hand off reasoning to called functions, would you like to have a summary of what the function checks there? Could do as separate patch, as this would be independent of the current patch?

I was not familiar with this code, trying to reduce the impact of this patch doesn't help me to understand it and convince myself that it does not cause miscompilation, it rather makes it even more difficult since conditions are now all over the place.

For instance, the comment
```
// Attempt to prove strided accesses independent.
```
is useless. The entire function tries to prove access independency with a possible stride. Documentation for `areStridedAccessesIndependent` (itself not descriptive) is far away. A better comment could be
```
// If the offset and strides are known constants, check whether the accesses interlace each other.
```

https://github.com/llvm/llvm-project/pull/88039


More information about the llvm-commits mailing list