[mlir][linalg][nfc] Fix signed/unsigned comparison warning in header
authorButygin <ivan.butygin@intel.com>
Wed, 19 May 2021 19:04:29 +0000 (22:04 +0300)
committerButygin <ivan.butygin@intel.com>
Sat, 22 May 2021 14:18:01 +0000 (17:18 +0300)
Differential Revision: https://reviews.llvm.org/D102968

mlir/include/mlir/Dialect/Linalg/IR/LinalgOps.td

index 334cecb..c78624b 100644 (file)
@@ -701,9 +701,9 @@ def Linalg_TiledLoopOp : Linalg_Op<"tiled_loop", [
       int numOutputs = getNumOutputs();
       int numControlOperands = getNumControlOperands();
 
-      auto operandIndex = operand.getOperandNumber();
+      int operandIndex = operand.getOperandNumber();
       assert(operandIndex >= numControlOperands &&
-             operandIndex < getNumOperands() &&
+             operandIndex < static_cast<int>(getNumOperands()) &&
              "Can erase only `input` or `output` operand");
 
       if (operandIndex >= numControlOperands + numInputs)