diff --git a/mlir/tools/mlir-reduce/ReductionTreeUtils.cpp b/mlir/tools/mlir-reduce/ReductionTreeUtils.cpp index 5fdb1341f89c8..13d35a258affe 100644 --- a/mlir/tools/mlir-reduce/ReductionTreeUtils.cpp +++ b/mlir/tools/mlir-reduce/ReductionTreeUtils.cpp @@ -32,8 +32,10 @@ void ReductionTreeUtils::updateSmallestNode(ReductionNode *currNode, ReductionNode *&smallestNode, std::vector path) { LLVM_DEBUG(llvm::dbgs() << "\nTree Path: root"); + #ifndef NDEBUG for (int nodeIndex : path) LLVM_DEBUG(llvm::dbgs() << " -> " << nodeIndex); + #endif LLVM_DEBUG(llvm::dbgs() << "\nSize (chars): " << currNode->getSize()); if (currNode->getSize() < smallestNode->getSize()) {