projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6120bd4
)
Apply clang-tidy fixes for performance-unnecessary-copy-initialization in MathOps...
author
Mehdi Amini
<joker.eph@gmail.com>
Sat, 16 Apr 2022 07:41:39 +0000
(07:41 +0000)
committer
Mehdi Amini
<joker.eph@gmail.com>
Tue, 19 Apr 2022 00:47:58 +0000
(
00:47
+0000)
mlir/lib/Dialect/Math/IR/MathOps.cpp
patch
|
blob
|
history
diff --git
a/mlir/lib/Dialect/Math/IR/MathOps.cpp
b/mlir/lib/Dialect/Math/IR/MathOps.cpp
index
036d8d9
..
f14bb00
100644
(file)
--- a/
mlir/lib/Dialect/Math/IR/MathOps.cpp
+++ b/
mlir/lib/Dialect/Math/IR/MathOps.cpp
@@
-27,7
+27,7
@@
using namespace mlir::math;
OpFoldResult math::AbsOp::fold(ArrayRef<Attribute> operands) {
return constFoldUnaryOp<FloatAttr>(operands, [](const APFloat &a) {
-
APFloat
result(a);
+
const APFloat &
result(a);
return abs(result);
});
}