[llvm] [AArch64][SVE] add missing instcombine x+1 -> x (PR #201851)

Tomas Matheson via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 11 03:38:49 PDT 2026


================
@@ -2511,6 +2511,33 @@ instCombineSVEVectorBinOp(InstCombiner &IC, IntrinsicInst &II) {
   return IC.replaceInstUsesWith(II, BinOp);
 }
 
+static std::optional<Instruction *> instCombineSVEVectorMla(InstCombiner &IC,
+                                                            IntrinsicInst &II) {
+  bool InactiveLanesAreUndefined =
+      II.getIntrinsicID() == Intrinsic::aarch64_sve_mla_u;
+  Value *Pred = II.getOperand(0);
+  if (!InactiveLanesAreUndefined && !isAllActivePredicate(Pred))
+    return std::nullopt;
----------------
tommat01 wrote:

Updated it to handle aarch64_sve_mla_u only

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


More information about the llvm-commits mailing list