[llvm] [LV] Autovectorization for the all-in-one histogram intrinsic (PR #91458)

Florian Hahn via llvm-commits llvm-commits at lists.llvm.org
Thu Jul 11 08:03:07 PDT 2024


================
@@ -732,6 +735,23 @@ class AccessAnalysis {
     return UnderlyingObjects;
   }
 
+  /// Find Histogram counts that match high-level code in loops:
+  /// \code
+  /// buckets[indices[i]]+=step;
+  /// \endcode
+  ///
+  /// It matches a pattern starting from \p HSt, which Stores to the 'buckets'
+  /// array the computed histogram. It uses a BinOp to sum all counts, storing
+  /// them using a loop-variant index Load from the 'indices' input array.
----------------
fhahn wrote:

Would be good to also document the restrictions w.r.t. to other accesses.

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


More information about the llvm-commits mailing list