[mlir] make remaining memref dialect ops produce strided layouts
authorAlex Zinenko <zinenko@google.com>
Thu, 15 Sep 2022 16:29:38 +0000 (18:29 +0200)
committerAlex Zinenko <zinenko@google.com>
Fri, 16 Sep 2022 08:56:48 +0000 (10:56 +0200)
commit46b90a7b5dcb6fed1cea45b7b9143c73fb561865
tree623f1d45f10530d4b2f1db4f1ef7d7627d6a6de8
parent2791162b01e3199b24f2d18f7b370157e2c57daf
[mlir] make remaining memref dialect ops produce strided layouts

The three following ops in the memref dialect: transpose, expand_shape,
collapse_shape, have been originally designed to operate on memrefs with
strided layouts but had to go through the affine map representation as the type
did not support anything else. Make these ops produce memref values with
StridedLayoutAttr instead now that it is available.

Depends On D133938

Reviewed By: nicolasvasilache

Differential Revision: https://reviews.llvm.org/D133947
13 files changed:
mlir/include/mlir/IR/BuiltinTypes.h
mlir/lib/Conversion/MemRefToLLVM/MemRefToLLVM.cpp
mlir/lib/Dialect/MemRef/IR/MemRefOps.cpp
mlir/lib/Dialect/Tensor/Transforms/BufferizableOpInterfaceImpl.cpp
mlir/lib/IR/AsmPrinter.cpp
mlir/lib/IR/BuiltinTypes.cpp
mlir/test/Conversion/MemRefToLLVM/memref-to-llvm.mlir
mlir/test/Dialect/Bufferization/Transforms/one-shot-bufferize-alloc-tensor-elimination.mlir
mlir/test/Dialect/Linalg/roundtrip.mlir
mlir/test/Dialect/MemRef/invalid.mlir
mlir/test/Dialect/MemRef/ops.mlir
mlir/test/Dialect/Tensor/bufferize.mlir
mlir/test/Dialect/Tensor/one-shot-bufferize.mlir