From 43ead4ecd141b725c54a3015f6465bcfdd36d2d1 Mon Sep 17 00:00:00 2001 From: Jakub Kuderski Date: Wed, 30 Nov 2022 11:06:17 -0500 Subject: [PATCH] [mlir][vector] Use zip_equal instead of size assertions. NFC. --- mlir/lib/Dialect/Vector/IR/VectorOps.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/mlir/lib/Dialect/Vector/IR/VectorOps.cpp b/mlir/lib/Dialect/Vector/IR/VectorOps.cpp index b36206c..c1d0fc3 100644 --- a/mlir/lib/Dialect/Vector/IR/VectorOps.cpp +++ b/mlir/lib/Dialect/Vector/IR/VectorOps.cpp @@ -221,10 +221,8 @@ bool mlir::vector::isDisjointTransferSet(VectorTransferOpInterface transferA, static LogicalResult incSlicePosition(MutableArrayRef position, ArrayRef shape, ArrayRef offsets) { - assert(position.size() == shape.size()); - assert(position.size() == offsets.size()); for (auto [posInDim, dimSize, offsetInDim] : - llvm::reverse(llvm::zip(position, shape, offsets))) { + llvm::reverse(llvm::zip_equal(position, shape, offsets))) { ++posInDim; if (posInDim < dimSize + offsetInDim) return success(); -- 2.7.4