[Mlir-commits] [mlir] [mlir][vector] Fix mask neutral value for masked fmaximum/fminimum reductions (PR #222275)

lorenzo chelini llvmlistbot at llvm.org
Wed Sep 9 04:12:17 PDT 2026


================
@@ -0,0 +1,80 @@
+// RUN: mlir-opt %s -test-lower-to-llvm  | \
+// RUN: mlir-runner -e entry -entry-point-result=void  \
+// RUN:   -shared-libs=%mlir_c_runner_utils | \
+// RUN: FileCheck %s
+
+func.func @entry() {
+  %inf = arith.constant 0x7F800000 : f32
+  %ninf = arith.constant 0xFF800000 : f32
+  %mask = arith.constant dense<[true, true, true, false]> : vector<4xi1>
+
+  // Ordinary negative data. A neutral value anywhere above the active lanes,
+  // such as a negative subnormal, would be returned instead of the maximum.
----------------
chelini wrote:

I was describing what was happening without this MR. Removed the confusing comment.

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


More information about the Mlir-commits mailing list