diff options
author | David Green <david.green@arm.com> | 2021-07-28 12:50:58 +0100 |
---|---|---|
committer | David Green <david.green@arm.com> | 2021-07-28 12:50:58 +0100 |
commit | 41cedb1c9a380628ac162bf76148cbd143f41450 (patch) | |
tree | 57b4b8f635e74ab3aa086f4cb1bcce027aa964c2 /clang/lib/Frontend/CompilerInvocation.cpp | |
parent | 09635dc7bfa42bed2809e3ee4edc96d0decdb9db (diff) | |
download | llvm-41cedb1c9a380628ac162bf76148cbd143f41450.zip llvm-41cedb1c9a380628ac162bf76148cbd143f41450.tar.gz llvm-41cedb1c9a380628ac162bf76148cbd143f41450.tar.bz2 |
[LV][ARM] Tighten up MLA reduction costing
This makes a couple of changes to the costing of MLA reduction patterns,
to more accurately cost various patterns that can come up from
vectorization.
- The Arm implementation of getExtendedAddReductionCost is altered to
only provide costs for legal or smaller types. Larger than legal types
need to be split, which currently does not work very well, especially
for predicated reductions where the predicate may be legal but needs to
be split. Currently we limit it to legal or smaller input types.
- The getReductionPatternCost has learnt that reduce(ext(mul(ext, ext))
is a pattern that can come up, and can be treated the same as
reduce(mul(ext, ext)) providing the extension types match.
- And it has been adjusted to not count the ext in reduce(mul(ext, ext))
as part of a reduce(mul) pattern.
Together these changes help to more accurately cost the mla reductions
in cases such as where the extend types don't match or the extend
opcodes are different, picking better vector factors that don't result
in expanded reductions.
Differential Revision: https://reviews.llvm.org/D106166
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions