[Mlir-commits] [mlir] 0de60b5 - [mlir] Fix mlir build break due to warning when NDEBUG is not set
Thomas Raoux
llvmlistbot at llvm.org
Mon Aug 10 15:35:43 PDT 2020
Author: Thomas Raoux
Date: 2020-08-10T15:35:02-07:00
New Revision: 0de60b550b727fa3a0202a9ab5ca30520e291dd5
URL: https://github.com/llvm/llvm-project/commit/0de60b550b727fa3a0202a9ab5ca30520e291dd5
DIFF: https://github.com/llvm/llvm-project/commit/0de60b550b727fa3a0202a9ab5ca30520e291dd5.diff
LOG: [mlir] Fix mlir build break due to warning when NDEBUG is not set
Added:
Modified:
mlir/lib/Conversion/VectorToLLVM/ConvertVectorToLLVM.cpp
Removed:
################################################################################
diff --git a/mlir/lib/Conversion/VectorToLLVM/ConvertVectorToLLVM.cpp b/mlir/lib/Conversion/VectorToLLVM/ConvertVectorToLLVM.cpp
index 522a45965722..a68f28fa1289 100644
--- a/mlir/lib/Conversion/VectorToLLVM/ConvertVectorToLLVM.cpp
+++ b/mlir/lib/Conversion/VectorToLLVM/ConvertVectorToLLVM.cpp
@@ -1153,6 +1153,7 @@ class VectorTransferConversion : public ConvertToLLVMPattern {
if (memrefVectorElementType.getElementType() !=
xferOp.getVectorType().getElementType())
return failure();
+#ifndef NDEBUG
// Check that memref vector type is a suffix of 'vectorType.
unsigned memrefVecEltRank = memrefVectorElementType.getRank();
unsigned resultVecRank = xferOp.getVectorType().getRank();
@@ -1165,6 +1166,7 @@ class VectorTransferConversion : public ConvertToLLVMPattern {
assert(memrefVecEltShape[i] != resultVecShape[rankOffset + i] &&
"memref vector element shape should match suffix of vector "
"result shape.");
+#endif // ifndef NDEBUG
}
// 1. Get the source/dst address as an LLVM vector pointer.
More information about the Mlir-commits
mailing list