aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Transforms/Utils/Utils.cpp
diff options
context:
space:
mode:
authorMaheshRavishankar <ravishankarm@google.com>2021-03-29 10:57:23 -0700
committerMaheshRavishankar <ravishankarm@google.com>2021-03-29 11:39:48 -0700
commit9b0517035faee275ce1feabb03d0c7606ea7f819 (patch)
treee636da5db5a7ede09689b6659c96e5251a227f2d /llvm/lib/Transforms/Utils/Utils.cpp
parent742f663705bbf076c2f7f1459182d5928feb1ec8 (diff)
downloadllvm-9b0517035faee275ce1feabb03d0c7606ea7f819.zip
llvm-9b0517035faee275ce1feabb03d0c7606ea7f819.tar.gz
llvm-9b0517035faee275ce1feabb03d0c7606ea7f819.tar.bz2
[mlir] Enhance InferShapedTypeOpInterface and move LinalgOps to use them.
A new `InterfaceMethod` is added to `InferShapedTypeOpInterface` that allows an operation to return the `Value`s for each dim of its results. It is intended for the case where the `Value` returned for each dim is computed using the operands and operation attributes. This interface method is for cases where the result dim of an operation can be computed independently, and it avoids the need to aggregate all dims of a result into a single shape value. This also implies that this is not suitable for cases where the result type is unranked (for which the existing interface methods is to be used). Also added is a canonicalization pattern that uses this interface and resolves the shapes of the output in terms of the shapes of the inputs. Moving Linalg ops to use this interface, so that many canonicalization patterns implemented for individual linalg ops to achieve the same result can be removed in favor of the added canonicalization pattern. Differential Revision: https://reviews.llvm.org/D97887
Diffstat (limited to 'llvm/lib/Transforms/Utils/Utils.cpp')
0 files changed, 0 insertions, 0 deletions