diff --git a/mlir/include/mlir/Dialect/Linalg/IR/LinalgInterfaces.td b/mlir/include/mlir/Dialect/Linalg/IR/LinalgInterfaces.td --- a/mlir/include/mlir/Dialect/Linalg/IR/LinalgInterfaces.td +++ b/mlir/include/mlir/Dialect/Linalg/IR/LinalgInterfaces.td @@ -589,7 +589,9 @@ /*methodBody=*/"", /*defaultImplementation=*/[{ assert(opOperand->getOwner() == this->getOperation()); - return getIndexingMaps()[opOperand->getOperandNumber()]; + auto indexingMaps = + $_op.indexing_maps().template getAsValueRange(); + return *(indexingMaps.begin() + opOperand->getOperandNumber()); }] >, InterfaceMethod<