[llvm] [LV] Move check if any vector insts will be generated to VPlan. (PR #96622)

via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 4 13:03:17 PDT 2024


================
@@ -4929,7 +4970,7 @@ VectorizationFactor LoopVectorizationPlanner::selectVectorizationFactor() {
       LLVM_DEBUG(dbgs() << ".\n");
 #endif
 
-      if (!C.second && !ForceVectorization) {
+      if (!willGenerateVectorInstructions(*P, VF, TTI) && !ForceVectorization) {
----------------
ayalz wrote:

```suggestion
      if (!ForceVectorization && !willGenerateVectorInstructions(*P, VF, TTI)) {
```

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


More information about the llvm-commits mailing list