[Mlir-commits] [mlir] d5a50b0 - Fix warnings
Kazu Hirata
llvmlistbot at llvm.org
Mon Apr 10 10:11:55 PDT 2023
Author: Kazu Hirata
Date: 2023-04-10T10:11:41-07:00
New Revision: d5a50b02e614d97c054c5c1e67922abc911fa5b6
URL: https://github.com/llvm/llvm-project/commit/d5a50b02e614d97c054c5c1e67922abc911fa5b6
DIFF: https://github.com/llvm/llvm-project/commit/d5a50b02e614d97c054c5c1e67922abc911fa5b6.diff
LOG: Fix warnings
This patch fixes:
mlir/lib/Dialect/Linalg/TransformOps/LinalgTransformOps.cpp:1334:51:
warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses]
lld/wasm/Writer.cpp:250:39: warning: suggest parentheses around ‘&&’
within ‘||’ [-Wparentheses]
Added:
Modified:
lld/wasm/Writer.cpp
mlir/lib/Dialect/Linalg/TransformOps/LinalgTransformOps.cpp
Removed:
################################################################################
diff --git a/lld/wasm/Writer.cpp b/lld/wasm/Writer.cpp
index d9e87276b31b0..2ec8848b26d11 100644
--- a/lld/wasm/Writer.cpp
+++ b/lld/wasm/Writer.cpp
@@ -247,7 +247,7 @@ computeHash(llvm::MutableArrayRef<uint8_t> hashBuf,
static void makeUUID(unsigned version, llvm::ArrayRef<uint8_t> fileHash,
llvm::MutableArrayRef<uint8_t> output) {
- assert(version == 4 || version == 5 && "Unknown UUID version");
+ assert((version == 4 || version == 5) && "Unknown UUID version");
assert(output.size() == 16 && "Wrong size for UUID output");
if (version == 5) {
// Build a valid v5 UUID from a hardcoded (randomly-generated) namespace
diff --git a/mlir/lib/Dialect/Linalg/TransformOps/LinalgTransformOps.cpp b/mlir/lib/Dialect/Linalg/TransformOps/LinalgTransformOps.cpp
index e548615ddecbf..d74a603277304 100644
--- a/mlir/lib/Dialect/Linalg/TransformOps/LinalgTransformOps.cpp
+++ b/mlir/lib/Dialect/Linalg/TransformOps/LinalgTransformOps.cpp
@@ -1330,9 +1330,9 @@ packMatmulGreedily(RewriterBase &rewriter, LinalgOp linalgOp,
ArrayRef<int64_t> mnkPaddedSizesNextMultipleOf,
ArrayRef<int64_t> mnkOrder) {
assert(mnkPackedSizes.size() == 3 && "unexpected num of packing sizes");
- assert(mnkPaddedSizesNextMultipleOf.empty() ||
- mnkPaddedSizesNextMultipleOf.size() == 3 &&
- "num of packing sizes next multiple should be empty or of size 3");
+ assert((mnkPaddedSizesNextMultipleOf.empty() ||
+ mnkPaddedSizesNextMultipleOf.size() == 3) &&
+ "num of packing sizes next multiple should be empty or of size 3");
assert(mnkOrder.size() == 3 && "unexpected mnkOrder size");
assert(isPermutationVector(mnkOrder) && "expected a permutation");
More information about the Mlir-commits
mailing list