From c82e1da2687f8aed6a7ef286b10e4d5ca45d3fca Mon Sep 17 00:00:00 2001 From: Jacques Pienaar Date: Mon, 13 May 2019 12:49:40 -0700 Subject: [PATCH] Remove unused function and avoid unused variable warning. NFC. -- PiperOrigin-RevId: 247991231 --- mlir/lib/Analysis/VectorAnalysis.cpp | 1 + mlir/lib/Transforms/DmaGeneration.cpp | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/mlir/lib/Analysis/VectorAnalysis.cpp b/mlir/lib/Analysis/VectorAnalysis.cpp index 7c0176d94ed8..e1d31ad1d2bf 100644 --- a/mlir/lib/Analysis/VectorAnalysis.cpp +++ b/mlir/lib/Analysis/VectorAnalysis.cpp @@ -197,6 +197,7 @@ bool mlir::matcher::operatesOnSuperVectorsOf(Operation &op, /// TODO(ntv): there should be a single function for all ops to do this so we /// do not have to special case. Maybe a trait, or just a method, unclear atm. bool mustDivide = false; + (void)mustDivide; VectorType superVectorType; if (auto read = dyn_cast(op)) { superVectorType = read.getResultType(); diff --git a/mlir/lib/Transforms/DmaGeneration.cpp b/mlir/lib/Transforms/DmaGeneration.cpp index 00ae92bdbc88..6452346a6d10 100644 --- a/mlir/lib/Transforms/DmaGeneration.cpp +++ b/mlir/lib/Transforms/DmaGeneration.cpp @@ -211,7 +211,8 @@ static bool getFullMemRefAsRegion(Operation *opInst, unsigned numParamLoopIVs, return true; } -static InFlightDiagnostic emitRemarkForBlock(Block &block) { +static InFlightDiagnostic LLVM_ATTRIBUTE_UNUSED +emitRemarkForBlock(Block &block) { auto *op = block.getContainingOp(); return op ? op->emitRemark() : block.getFunction()->emitRemark(); }