diff --git a/mlir/lib/Dialect/Affine/IR/AffineOps.cpp b/mlir/lib/Dialect/Affine/IR/AffineOps.cpp --- a/mlir/lib/Dialect/Affine/IR/AffineOps.cpp +++ b/mlir/lib/Dialect/Affine/IR/AffineOps.cpp @@ -1738,7 +1738,7 @@ /// induction variable. AffineForOp only has one region, so zero is the only /// valid value for `index`. OperandRange AffineForOp::getSuccessorEntryOperands(Optional index) { - assert(!index || *index == 0 && "invalid region index"); + assert((!index || *index == 0) && "invalid region index"); // The initial operands map to the loop arguments after the induction // variable or are forwarded to the results when the trip count is zero. diff --git a/mlir/lib/ExecutionEngine/OptUtils.cpp b/mlir/lib/ExecutionEngine/OptUtils.cpp --- a/mlir/lib/ExecutionEngine/OptUtils.cpp +++ b/mlir/lib/ExecutionEngine/OptUtils.cpp @@ -43,7 +43,7 @@ case 2: return OptimizationLevel::Oz; } - + break; case 3: return OptimizationLevel::O3; } diff --git a/mlir/lib/ExecutionEngine/SparseTensorUtils.cpp b/mlir/lib/ExecutionEngine/SparseTensorUtils.cpp --- a/mlir/lib/ExecutionEngine/SparseTensorUtils.cpp +++ b/mlir/lib/ExecutionEngine/SparseTensorUtils.cpp @@ -1366,7 +1366,7 @@ if ((valueKind == SparseTensorFile::ValueKind::kReal && tensorIsInteger) || (valueKind == SparseTensorFile::ValueKind::kComplex && tensorIsReal)) { FATAL("Tensor element type %d not compatible with values in file %s\n", - valTp, filename); + static_cast(valTp), filename); } stfile.assertMatchesShape(rank, shape); // Prepare sparse tensor object with per-dimension sizes