[Mlir-commits] [mlir] b4b5013 - [mlir] Use llvm::is_contained (NFC) (#139834)

llvmlistbot at llvm.org llvmlistbot at llvm.org
Tue May 13 23:33:45 PDT 2025


Author: Kazu Hirata
Date: 2025-05-13T23:33:41-07:00
New Revision: b4b5013aa3a3f830fc7f52a4a1892049f95875c6

URL: https://github.com/llvm/llvm-project/commit/b4b5013aa3a3f830fc7f52a4a1892049f95875c6
DIFF: https://github.com/llvm/llvm-project/commit/b4b5013aa3a3f830fc7f52a4a1892049f95875c6.diff

LOG: [mlir] Use llvm::is_contained (NFC) (#139834)

Added: 
    

Modified: 
    mlir/lib/Dialect/SparseTensor/Transforms/Sparsification.cpp

Removed: 
    


################################################################################
diff  --git a/mlir/lib/Dialect/SparseTensor/Transforms/Sparsification.cpp b/mlir/lib/Dialect/SparseTensor/Transforms/Sparsification.cpp
index badcc583bbca2..2d604ed7a8ffc 100644
--- a/mlir/lib/Dialect/SparseTensor/Transforms/Sparsification.cpp
+++ b/mlir/lib/Dialect/SparseTensor/Transforms/Sparsification.cpp
@@ -1128,7 +1128,7 @@ static bool startLoopSeq(CodegenEnv &env, OpBuilder &builder, ExprId exp,
     // TODO: remove this! The same tensor level might be added for multiple
     // times due to the special handling for all-dense "sparse" output tensor
     // (see L1038).
-    if (llvm::find(tidLvls, tl) != tidLvls.end())
+    if (llvm::is_contained(tidLvls, tl))
       return;
     tidLvls.emplace_back(tl);
   });


        


More information about the Mlir-commits mailing list