[Mlir-commits] [mlir] ef99c27 - Apply clang-tidy fixes for llvm-else-after-return in SparseTensorCodegen.cpp (NFC)
Mehdi Amini
llvmlistbot at llvm.org
Tue Nov 15 13:20:56 PST 2022
Author: Mehdi Amini
Date: 2022-11-15T21:20:39Z
New Revision: ef99c27d3b6da807604df779a35b2c5850c94a51
URL: https://github.com/llvm/llvm-project/commit/ef99c27d3b6da807604df779a35b2c5850c94a51
DIFF: https://github.com/llvm/llvm-project/commit/ef99c27d3b6da807604df779a35b2c5850c94a51.diff
LOG: Apply clang-tidy fixes for llvm-else-after-return in SparseTensorCodegen.cpp (NFC)
Added:
Modified:
mlir/lib/Dialect/SparseTensor/Transforms/SparseTensorCodegen.cpp
Removed:
################################################################################
diff --git a/mlir/lib/Dialect/SparseTensor/Transforms/SparseTensorCodegen.cpp b/mlir/lib/Dialect/SparseTensor/Transforms/SparseTensorCodegen.cpp
index d7dd8240a28c..750d2d1f616a 100644
--- a/mlir/lib/Dialect/SparseTensor/Transforms/SparseTensorCodegen.cpp
+++ b/mlir/lib/Dialect/SparseTensor/Transforms/SparseTensorCodegen.cpp
@@ -269,7 +269,8 @@ static void allocSchemeForRank(OpBuilder &builder, Location loc,
Value ptrZero = constantZero(builder, loc, ptrType);
createPushback(builder, loc, fields, field, ptrZero, linear);
return;
- } else if (isSingletonDim(rtp, r)) {
+ }
+ if (isSingletonDim(rtp, r)) {
return; // nothing to do
} else {
// Keep compounding the size, but nothing needs to be initialized
More information about the Mlir-commits
mailing list