[Mlir-commits] [mlir] 86fa21e - [mlir] Fix -Wunused-function in ShardingInterface.cpp (NFC)
Jie Fu
llvmlistbot at llvm.org
Tue Feb 6 22:23:01 PST 2024
Author: Jie Fu
Date: 2024-02-07T14:22:28+08:00
New Revision: 86fa21e93efe6d8079d202bf30e7e8db66cc32a0
URL: https://github.com/llvm/llvm-project/commit/86fa21e93efe6d8079d202bf30e7e8db66cc32a0
DIFF: https://github.com/llvm/llvm-project/commit/86fa21e93efe6d8079d202bf30e7e8db66cc32a0.diff
LOG: [mlir] Fix -Wunused-function in ShardingInterface.cpp (NFC)
llvm-project/mlir/lib/Dialect/Mesh/Interfaces/ShardingInterface.cpp:522:1:
error: unused function 'isValueCompatibleWithFullReplicationSharding' [-Werror,-Wunused-function]
isValueCompatibleWithFullReplicationSharding(Value value,
^
1 error generated.
Added:
Modified:
mlir/lib/Dialect/Mesh/Interfaces/ShardingInterface.cpp
Removed:
################################################################################
diff --git a/mlir/lib/Dialect/Mesh/Interfaces/ShardingInterface.cpp b/mlir/lib/Dialect/Mesh/Interfaces/ShardingInterface.cpp
index a0a573f65a346..b8b3841d947ab 100644
--- a/mlir/lib/Dialect/Mesh/Interfaces/ShardingInterface.cpp
+++ b/mlir/lib/Dialect/Mesh/Interfaces/ShardingInterface.cpp
@@ -518,6 +518,7 @@ LogicalResult mesh::detail::defaultAddShardingAnnotations(
return success();
}
+#ifndef NDEBUG
static bool
isValueCompatibleWithFullReplicationSharding(Value value,
MeshShardingAttr sharding) {
@@ -542,6 +543,7 @@ static bool areValuesCompatibleWithFullReplicationShardings(
std::get<1>(valueAndSharding));
});
}
+#endif // NDEBUG
void mesh::spmdizeFullyReplicatedOperation(
Operation &op, ArrayRef<Value> spmdizedOperands,
More information about the Mlir-commits
mailing list