[Mlir-commits] [mlir] 928c23d - Apply clang-tidy fixes for performance-unnecessary-value-param in TosaCanonicalizations.cpp (NFC)
Mehdi Amini
llvmlistbot at llvm.org
Thu Oct 13 08:56:01 PDT 2022
Author: Mehdi Amini
Date: 2022-10-13T15:55:32Z
New Revision: 928c23ddbfa7111039e030acdf100ccc04108435
URL: https://github.com/llvm/llvm-project/commit/928c23ddbfa7111039e030acdf100ccc04108435
DIFF: https://github.com/llvm/llvm-project/commit/928c23ddbfa7111039e030acdf100ccc04108435.diff
LOG: Apply clang-tidy fixes for performance-unnecessary-value-param in TosaCanonicalizations.cpp (NFC)
Added:
Modified:
mlir/lib/Dialect/Tosa/IR/TosaCanonicalizations.cpp
Removed:
################################################################################
diff --git a/mlir/lib/Dialect/Tosa/IR/TosaCanonicalizations.cpp b/mlir/lib/Dialect/Tosa/IR/TosaCanonicalizations.cpp
index b97672334b71..57519fd8bfd0 100644
--- a/mlir/lib/Dialect/Tosa/IR/TosaCanonicalizations.cpp
+++ b/mlir/lib/Dialect/Tosa/IR/TosaCanonicalizations.cpp
@@ -674,12 +674,16 @@ struct ComparisonFold {
struct APIntFoldGreater {
APIntFoldGreater() = default;
- APInt operator()(APInt l, APInt r) { return APInt(1, l.sgt(r)); }
+ APInt operator()(const APInt &l, const APInt &r) {
+ return APInt(1, l.sgt(r));
+ }
};
struct APIntFoldGreaterEqual {
APIntFoldGreaterEqual() = default;
- APInt operator()(APInt l, APInt r) { return APInt(1, l.sge(r)); }
+ APInt operator()(const APInt &l, const APInt &r) {
+ return APInt(1, l.sge(r));
+ }
};
} // namespace
More information about the Mlir-commits
mailing list