[Mlir-commits] [mlir] [MLIR][Transforms] add eliminate-explicit-rounding pass (PR #93443)
llvmlistbot at llvm.org
llvmlistbot at llvm.org
Wed May 29 19:51:12 PDT 2024
github-actions[bot] wrote:
<!--LLVM CODE FORMAT COMMENT: {clang-format}-->
:warning: C/C++ code formatter, clang-format found issues in your code. :warning:
<details>
<summary>
You can test this locally with the following command:
</summary>
``````````bash
git-clang-format --diff dbfed77a47c59cfca5147d5e62a52df4c597ba10 3bdd46880c88f7a53ec92e4371569925838d1523 -- mlir/lib/Dialect/Arith/Transforms/EliminateExplicitRounding.cpp
``````````
</details>
<details>
<summary>
View the diff from clang-format here.
</summary>
``````````diff
diff --git a/mlir/lib/Dialect/Arith/Transforms/EliminateExplicitRounding.cpp b/mlir/lib/Dialect/Arith/Transforms/EliminateExplicitRounding.cpp
index efac7d002f..8a5f10a6cb 100644
--- a/mlir/lib/Dialect/Arith/Transforms/EliminateExplicitRounding.cpp
+++ b/mlir/lib/Dialect/Arith/Transforms/EliminateExplicitRounding.cpp
@@ -58,7 +58,7 @@ struct EliminateExplicitRoundingRewritePattern final
Type inTy = getElementTypeOrSelf(input.getType());
Type outTy = getElementTypeOrSelf(extFOp.getType());
Type shortTy = getElementTypeOrSelf(truncFOp.getType());
- if (isa<Float32Type>(inTy) && isa<Float32Type>(outTy) &&
+ if (isa<Float32Type>(inTy) && isa<Float32Type>(outTy) &&
(isa<Float16Type>(shortTy) || isa<BFloat16Type>(shortTy))) {
rewriter.replaceOp(extFOp, {input});
return success();
``````````
</details>
https://github.com/llvm/llvm-project/pull/93443
More information about the Mlir-commits
mailing list