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

Sam Tebbs via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 4 04:01:44 PDT 2025


================
@@ -35,6 +35,7 @@ enum class RecurKind {
   // clang-format off
   None,     ///< Not a recurrence.
   Add,      ///< Sum of integers.
+  Sub,      ///< Subtraction of integers
----------------
SamTebbs33 wrote:

Thanks, I've added `RecurKind::Sub` cases to the SLP vectorizer and added a test. I don't think adding proper sub reduction support to SLP is in scope of this PR so haven't added full support.

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


More information about the llvm-commits mailing list