[mlir][linalg] Return tensor::PadOp handle from transform op
authorMatthias Springer <me@m-sp.org>
Tue, 4 Jul 2023 12:18:32 +0000 (14:18 +0200)
committerMatthias Springer <me@m-sp.org>
Tue, 4 Jul 2023 12:24:47 +0000 (14:24 +0200)
commit0e06ec5961325c51ef2fa48a25c9b99038ff2f1b
tree3dde60e422ea2d649a214ce1e1306ea04549c97d
parentcb7bda2ace81226c5b33165411dd0316f93fa57e
[mlir][linalg] Return tensor::PadOp handle from transform op

"transform.structured.pad" now returns all `tensor::PadOp` in addition to the padded ops.

Also add a test case that shows how to force an allocation for "tensor.pad" ops with a custom memory space.

Differential Revision: https://reviews.llvm.org/D153555
mlir/include/mlir/Dialect/Linalg/TransformOps/LinalgTransformOps.td
mlir/include/mlir/Dialect/Linalg/Transforms/Transforms.h
mlir/lib/Dialect/Linalg/TransformOps/LinalgTransformOps.cpp
mlir/lib/Dialect/Linalg/Transforms/Padding.cpp
mlir/python/mlir/dialects/_structured_transform_ops_ext.py
mlir/test/Dialect/Linalg/pad-to-specific-memory-space.mlir [new file with mode: 0644]
mlir/test/Dialect/Linalg/transform-op-hoist-pad-build-packing-loop-nest.mlir
mlir/test/Dialect/Linalg/transform-op-hoist-pad.mlir
mlir/test/Dialect/Linalg/transform-op-pad.mlir
mlir/test/Dialect/Linalg/transform-ops-invalid.mlir
mlir/test/Dialect/Linalg/transform-ops.mlir