[ComprehensiveBufferize] Fix a warning

This patch fixes:

  mlir/lib/Dialect/Linalg/ComprehensiveBufferize/ComprehensiveBufferize.cpp:301:20:
  error: unused function 'printValueInfo' [-Werror,-Wunused-function]
This commit is contained in:
Kazu Hirata 2021-11-10 21:21:32 -08:00
parent 9991f0e40e
commit 839d81862f
1 changed files with 4 additions and 0 deletions

View File

@ -138,8 +138,10 @@ using namespace comprehensive_bufferize;
#define LDBG(X) LLVM_DEBUG(DBGS() << X)
// Forward declarations.
#ifndef NDEBUG
static std::string printOperationInfo(Operation *, bool prefix = true);
static std::string printValueInfo(Value, bool prefix = true);
#endif
//===----------------------------------------------------------------------===//
// Generic helpers.
@ -266,6 +268,7 @@ static void removeBufferizationFuncArguments(BlockArgument bbArg) {
// Printing helpers.
//===----------------------------------------------------------------------===//
#ifndef NDEBUG
/// Helper method printing the bufferization information of a buffer / tensor.
static void printTensorOrBufferInfo(std::string prefix, Value value,
AsmState &state, llvm::raw_ostream &os) {
@ -310,6 +313,7 @@ static std::string printValueInfo(Value value, bool prefix) {
printTensorOrBufferInfo("\n\t - ", value, state, os);
return result;
}
#endif
//===----------------------------------------------------------------------===//
// Bufferization-specific alias analysis.