Skip to content

[mlir] Use llvm::any_of (NFC) #141317

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

kazutakahirata
Copy link
Contributor

No description provided.

@llvmbot
Copy link
Member

llvmbot commented May 24, 2025

@llvm/pr-subscribers-mlir

Author: Kazu Hirata (kazutakahirata)

Changes

Full diff: https://github.com/llvm/llvm-project/pull/141317.diff

1 Files Affected:

  • (modified) mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp (+4-5)
diff --git a/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp b/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
index ccba2e2806862..f4f32e9339870 100644
--- a/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
+++ b/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
@@ -887,11 +887,10 @@ isNotLinearizableBecauseLargeInnerDimension(Operation *op,
   // Check on bitwidths.
   SmallVector<std::pair<Type, unsigned>> toCheck =
       getTypeBitWidthBoundPairs(op, targetBitWidth);
-  return std::any_of(toCheck.begin(), toCheck.end(),
-                     [&](std::pair<Type, unsigned> typeWidth) {
-                       return isNotLinearizableBecauseLargeInnerDimension(
-                           typeWidth.first, typeWidth.second);
-                     });
+  return llvm::any_of(toCheck, [&](std::pair<Type, unsigned> typeWidth) {
+    return isNotLinearizableBecauseLargeInnerDimension(typeWidth.first,
+                                                       typeWidth.second);
+  });
 }
 
 void populateWithBitWidthConstraints(TypeConverter &typeConverter,

@llvmbot
Copy link
Member

llvmbot commented May 24, 2025

@llvm/pr-subscribers-mlir-vector

Author: Kazu Hirata (kazutakahirata)

Changes

Full diff: https://github.com/llvm/llvm-project/pull/141317.diff

1 Files Affected:

  • (modified) mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp (+4-5)
diff --git a/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp b/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
index ccba2e2806862..f4f32e9339870 100644
--- a/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
+++ b/mlir/test/lib/Dialect/Vector/TestVectorTransforms.cpp
@@ -887,11 +887,10 @@ isNotLinearizableBecauseLargeInnerDimension(Operation *op,
   // Check on bitwidths.
   SmallVector<std::pair<Type, unsigned>> toCheck =
       getTypeBitWidthBoundPairs(op, targetBitWidth);
-  return std::any_of(toCheck.begin(), toCheck.end(),
-                     [&](std::pair<Type, unsigned> typeWidth) {
-                       return isNotLinearizableBecauseLargeInnerDimension(
-                           typeWidth.first, typeWidth.second);
-                     });
+  return llvm::any_of(toCheck, [&](std::pair<Type, unsigned> typeWidth) {
+    return isNotLinearizableBecauseLargeInnerDimension(typeWidth.first,
+                                                       typeWidth.second);
+  });
 }
 
 void populateWithBitWidthConstraints(TypeConverter &typeConverter,

@kazutakahirata kazutakahirata merged commit c180d0c into llvm:main May 24, 2025
15 checks passed
@kazutakahirata kazutakahirata deleted the cleanup_20250523_llvm_any_of_mlir branch May 24, 2025 07:00
sivan-shani pushed a commit to sivan-shani/llvm-project that referenced this pull request Jun 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants