[llvm] [InstCombine] Transform `vector.reduce.add` and `splat` into multiplication (PR #161020)

Gábor Spaits via llvm-commits llvm-commits at lists.llvm.org
Sun Sep 28 05:31:47 PDT 2025


================
@@ -308,3 +308,93 @@ define i32 @diff_of_sums_type_mismatch2(<8 x i32> %v0, <4 x i32> %v1) {
   %r = sub i32 %r0, %r1
   ret i32 %r
 }
+
----------------
spaits wrote:

I did some research, even if we would have `mul i1 %4, 8`, that wouldn't be a problem.
According to Alive2:
https://alive2.llvm.org/ce/z/HhDbub

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


More information about the llvm-commits mailing list