[llvm] [LV] Create in-loop sub reductions (PR #147026)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 17 11:18:50 PDT 2025


================
@@ -644,14 +644,14 @@ define i32 @reduction_sub_lhs(ptr noalias nocapture %A) {
 ; CHECK-NEXT:    [[TMP2:%.*]] = icmp eq i64 [[INDEX_NEXT]], 256
 ; CHECK-NEXT:    br i1 [[TMP2]], label [[MIDDLE_BLOCK:%.*]], label [[VECTOR_BODY]], !llvm.loop [[LOOP26:![0-9]+]]
 ; CHECK:       middle.block:
-; CHECK-NEXT:    [[TMP3:%.*]] = call i32 @llvm.vector.reduce.add.v4i32(<4 x i32> [[TMP1]])
----------------
fhahn wrote:

Here we are now missing the negating the operand in the vector loop?

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


More information about the llvm-commits mailing list