[Mlir-commits] [mlir] [mlir][arith][NFC] Remove redundant trait declaration (PR #145007)

Matthias Springer llvmlistbot at llvm.org
Fri Jun 20 02:51:47 PDT 2025


https://github.com/matthias-springer created https://github.com/llvm/llvm-project/pull/145007

`Arith_Op` already declares the `ElementwiseMappable` traits, so they don't have to be declared for `arith.select`.


>From 966968037e2804693e480a17a30e6f4da7d9f74d Mon Sep 17 00:00:00 2001
From: Matthias Springer <me at m-sp.org>
Date: Fri, 20 Jun 2025 09:49:31 +0000
Subject: [PATCH] [mlir][arith][NFC] Remove redundant trait declaration

---
 mlir/include/mlir/Dialect/Arith/IR/ArithOps.td | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/mlir/include/mlir/Dialect/Arith/IR/ArithOps.td b/mlir/include/mlir/Dialect/Arith/IR/ArithOps.td
index 993f36f556e87..9d2b8f3a26238 100644
--- a/mlir/include/mlir/Dialect/Arith/IR/ArithOps.td
+++ b/mlir/include/mlir/Dialect/Arith/IR/ArithOps.td
@@ -1688,8 +1688,7 @@ def SelectOp : Arith_Op<"select", [Pure,
     AllTypesMatch<["true_value", "false_value", "result"]>,
     BooleanConditionOrMatchingShape<"condition", "result">,
     DeclareOpInterfaceMethods<InferIntRangeInterface, ["inferResultRangesFromOptional"]>,
-    DeclareOpInterfaceMethods<SelectLikeOpInterface>,
-  ] # ElementwiseMappable.traits> {
+    DeclareOpInterfaceMethods<SelectLikeOpInterface>]> {
   let summary = "select operation";
   let description = [{
     The `arith.select` operation chooses one value based on a binary condition



More information about the Mlir-commits mailing list