diff options
author | Mahesh Ravishankar <ravishankarm@google.com> | 2022-03-08 18:22:19 +0000 |
---|---|---|
committer | Mahesh Ravishankar <ravishankarm@google.com> | 2022-03-08 18:26:55 +0000 |
commit | 589eac6524d6ba080a51107757c1f356c365d047 (patch) | |
tree | 226494447788ec7b4f32fd5485521558e515ac80 /flang/lib/Frontend/CompilerInvocation.cpp | |
parent | 60d719b462a136a75610bf1d1c9f4e043d394eea (diff) | |
download | llvm-589eac6524d6ba080a51107757c1f356c365d047.zip llvm-589eac6524d6ba080a51107757c1f356c365d047.tar.gz llvm-589eac6524d6ba080a51107757c1f356c365d047.tar.bz2 |
[mlir] Add canonicalizations for op -> tensor.cast folding.
A `tensor.cast` consumer can be folded with its producer. This is
beneficial only if the result of the tensor cast is more static than
the source. This patch adds a utility function to check that this is
the case, and adds a couple of canonicalizations patterns that fold an
operation with `tensor.cast` conusmers.
Reviewed By: gysit
Differential Revision: https://reviews.llvm.org/D120950
Diffstat (limited to 'flang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions