[Mlir-commits] [mlir] 1211af7 - Apply clang-tidy fixes for llvm-else-after-return in TensorOps.cpp (NFC)
Mehdi Amini
llvmlistbot at llvm.org
Thu Dec 22 07:33:19 PST 2022
Author: Mehdi Amini
Date: 2022-12-22T15:33:01Z
New Revision: 1211af761fb949372c200bb98fa7075ceeead7a1
URL: https://github.com/llvm/llvm-project/commit/1211af761fb949372c200bb98fa7075ceeead7a1
DIFF: https://github.com/llvm/llvm-project/commit/1211af761fb949372c200bb98fa7075ceeead7a1.diff
LOG: Apply clang-tidy fixes for llvm-else-after-return in TensorOps.cpp (NFC)
Added:
Modified:
mlir/lib/Dialect/Tensor/IR/TensorOps.cpp
Removed:
################################################################################
diff --git a/mlir/lib/Dialect/Tensor/IR/TensorOps.cpp b/mlir/lib/Dialect/Tensor/IR/TensorOps.cpp
index 99898f63e4959..c87a003fab3bb 100644
--- a/mlir/lib/Dialect/Tensor/IR/TensorOps.cpp
+++ b/mlir/lib/Dialect/Tensor/IR/TensorOps.cpp
@@ -3160,16 +3160,16 @@ static LogicalResult commonVerifierPackAndUnPackOp(OpTy packOrUnPack) {
// If specified tile size is dynamic, output shape should
// be dynamic too.
return ShapedType::isDynamic(shape);
- } else {
- if (ShapedType::isDynamic(shape)) {
- // For the shape being dynamic when tile size is
- // specified, return true. In canonical form a constant
- // tile size should lead to constant shape of the tiled
- // dimension, but not needed for verification.
- return true;
- }
- return shape == constTileSize.value();
}
+ if (ShapedType::isDynamic(shape)) {
+ // For the shape being dynamic when tile size is
+ // specified, return true. In canonical form a constant
+ // tile size should lead to constant shape of the tiled
+ // dimension, but not needed for verification.
+ return true;
+ }
+ return shape == constTileSize.value();
+
})) {
return op->emitError("mismatch in inner tile sizes specified and shaped of "
"tiled dimension in the packed type");
More information about the Mlir-commits
mailing list