From d208baee65ec15a2ea15ec17e8fe676b07296ad9 Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Mon, 10 Oct 2022 12:57:25 -0700 Subject: [PATCH] [mlir] Fix a warning This patch fixes: mlir/lib/Dialect/Linalg/IR/LinalgOps.cpp:1051:40: error: comparison of integers of different signs: 'int64_t' (aka 'long') and 'std::size_t' (aka 'unsigned long') [-Werror,-Wsign-compare] --- mlir/lib/Dialect/Linalg/IR/LinalgOps.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/mlir/lib/Dialect/Linalg/IR/LinalgOps.cpp b/mlir/lib/Dialect/Linalg/IR/LinalgOps.cpp index 79961b7..eaa1923 100644 --- a/mlir/lib/Dialect/Linalg/IR/LinalgOps.cpp +++ b/mlir/lib/Dialect/Linalg/IR/LinalgOps.cpp @@ -1048,7 +1048,8 @@ private: genericOp.getMatchingIndexingMap(outputOpOperand.value()); auto key = std::make_tuple(outputOpOperand.value()->get(), indexingMap, yieldOp->getOperand(outputOpOperand.index())); - assert(genericOp.getNumOutputs() >= outputOpOperand.index() && + assert(static_cast(genericOp.getNumOutputs()) >= + outputOpOperand.index() && "Output op idx greater than number of outputs."); if (isResultValueDead(genericOp, result)) { // Check if the opoperand can be dropped without affecting loop -- 2.7.4