[clang] [llvm] [LV] Support generating masks for switch terminators. (PR #99808)

via llvm-commits llvm-commits at lists.llvm.org
Wed Jul 24 09:14:11 PDT 2024


================
@@ -1348,11 +1348,11 @@ bool LoopVectorizationLegality::canVectorizeWithIfConvert() {
   // Collect the blocks that need predication.
   for (BasicBlock *BB : TheLoop->blocks()) {
     // We don't support switch statements inside loops.
----------------
ayalz wrote:

```suggestion
    // We support only branches and switch statements as terminators inside the loop.
```

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


More information about the llvm-commits mailing list