[PATCH] D55798: [LAA] Avoid generating RT checks for known deps preventing vectorization.

Ayal Zaks via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Dec 18 12:31:27 PST 2018


Ayal added inline comments.


================
Comment at: include/llvm/Analysis/LoopAccessAnalysis.h:223
     return ShouldRetryWithRuntimeCheck &&
-           Status == VectorizationSafetyStatus::Unsafe;
+           Status == VectorizationSafetyStatus::SafeWithRtChecks;
   }
----------------
> When SafeWithRtChecks is added, in next patch, consider renaming the flag or method (slightly), as they will no longer mean exactly the same thing. 

Consider renaming `ShouldRetryWithRuntimeCheck` to something like `FoundDependenceForRuntimeCheck`; or keep the original name but fold SafeWithRtChecks into the flag, i.e., when turning the flag on check if Status is not Unsafe, and when setting Status to Unsafe turn the flag off.

On second thought, now that Status includes SafeWithRtChecks, this flag seems redundant, and suffice to have

```
bool shouldRetryWithRuntimeCheck() const {
  return Status == VectorizationSafetyStatus::SafeWithRtChecks;
}

```
?


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D55798/new/

https://reviews.llvm.org/D55798





More information about the llvm-commits mailing list