[all-commits] [llvm/llvm-project] b809d7: [mlir][linalg] Replace "string" iterator_types att...
Oleg Shyshkov via All-commits
all-commits at lists.llvm.org
Wed Nov 9 06:48:03 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: b809d73973bb5aeedeb6a18cac2a7b3111d0c8d2
https://github.com/llvm/llvm-project/commit/b809d73973bb5aeedeb6a18cac2a7b3111d0c8d2
Author: Oleg Shyshkov <shyshkov at google.com>
Date: 2022-11-09 (Wed, 09 Nov 2022)
Changed paths:
M mlir/include/mlir/Dialect/Linalg/IR/LinalgBase.td
M mlir/include/mlir/Dialect/Linalg/IR/LinalgInterfaces.h
M mlir/include/mlir/Dialect/Linalg/IR/LinalgInterfaces.td
M mlir/include/mlir/Dialect/Linalg/IR/LinalgStructuredOps.td
M mlir/include/mlir/Dialect/Linalg/Utils/Utils.h
M mlir/include/mlir/Dialect/Tosa/Utils/CoversionUtils.h
M mlir/include/mlir/Dialect/Utils/StructuredOpsUtils.h
M mlir/include/mlir/Dialect/Vector/IR/VectorOps.td
M mlir/lib/Conversion/TosaToLinalg/TosaToLinalg.cpp
M mlir/lib/Dialect/Linalg/IR/LinalgInterfaces.cpp
M mlir/lib/Dialect/Linalg/IR/LinalgOps.cpp
M mlir/lib/Dialect/Linalg/Transforms/ElementwiseOpFusion.cpp
M mlir/lib/Dialect/Linalg/Transforms/ElementwiseToLinalg.cpp
M mlir/lib/Dialect/Linalg/Transforms/Generalization.cpp
M mlir/lib/Dialect/Linalg/Transforms/SplitReduction.cpp
M mlir/lib/Dialect/Linalg/Transforms/Tiling.cpp
M mlir/lib/Dialect/Linalg/Transforms/TilingInterfaceImpl.cpp
M mlir/lib/Dialect/Linalg/Transforms/Transforms.cpp
M mlir/lib/Dialect/Linalg/Transforms/Vectorization.cpp
M mlir/lib/Dialect/Linalg/Utils/Utils.cpp
M mlir/lib/Dialect/SparseTensor/Transforms/Sparsification.cpp
M mlir/lib/Dialect/Tosa/Utils/ConversionUtils.cpp
M mlir/lib/Dialect/Vector/Transforms/VectorTransforms.cpp
M mlir/test/Dialect/Linalg/conv-interface-invalid.mlir
M mlir/test/Dialect/Linalg/invalid.mlir
M mlir/test/Dialect/Linalg/transform-op-match.mlir
M mlir/test/lib/Dialect/Test/CMakeLists.txt
M mlir/test/lib/Dialect/Test/TestAttrDefs.td
M mlir/test/lib/Dialect/Test/TestAttributes.h
A mlir/test/lib/Dialect/Test/TestEnumDefs.td
M mlir/test/lib/Dialect/Test/TestOps.td
M mlir/tools/mlir-linalg-ods-gen/mlir-linalg-ods-yaml-gen.cpp
M utils/bazel/llvm-project-overlay/mlir/test/BUILD.bazel
Log Message:
-----------
[mlir][linalg] Replace "string" iterator_types attr with enums in LinalgInterface.
[RFC: EnumAttr for iterator types in Linalg](https://discourse.llvm.org/t/rfc-enumattr-for-iterator-types-in-linalg/64535)
This affect touches and probably breaks most of the code that creates `linalg.generic`. A fix would be to replace calls to `getParallelIteratorTypeName/getReductionIteratorTypeName` with `mlir::utils::IteratorType::parallel/reduction` and types from `StringRef` to `mlir::utils::IteratorType`.
Due to limitations of tablegen, shared C++ definition of IteratorType enum lives in StructuredOpsUtils.td, but each dialect should have it's own EnumAttr wrapper. To avoid conflict, all enums in a dialect are put into a separate file with a separate tablegen rule.
Test dialect td files are refactored a bit.
Printed format of `linalg.generic` temporarily remains unchanged to avoid breaking code and tests in the same change.
Differential Revision: https://reviews.llvm.org/D137658
More information about the All-commits
mailing list