[llvm] [ConstantFolding] Add folding for [de]interleave2, insert and extract (PR #141301)

Luke Lau via llvm-commits llvm-commits at lists.llvm.org
Fri May 30 07:39:42 PDT 2025


================
@@ -3734,6 +3738,98 @@ static Constant *ConstantFoldFixedVectorCall(
     }
     return nullptr;
   }
+  case Intrinsic::vector_extract: {
+    auto *Vec = dyn_cast<Constant>(Operands[0]);
----------------
lukel97 wrote:

```suggestion
    Constant *Vec = Operands[0];
```

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


More information about the llvm-commits mailing list