diff options
author | David Green <david.green@arm.com> | 2024-05-08 22:11:18 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-05-08 22:11:18 +0100 |
commit | fcf945f4edbad1f2d82df067c2826baa6165dd3e (patch) | |
tree | 555c2be0ae6a230b3d5e79a55af6644d625fb52c /llvm/lib/Transforms/Utils/InlineFunction.cpp | |
parent | 965f3ca3dc5464892e283e176bf058ae04d8b654 (diff) | |
download | llvm-fcf945f4edbad1f2d82df067c2826baa6165dd3e.zip llvm-fcf945f4edbad1f2d82df067c2826baa6165dd3e.tar.gz llvm-fcf945f4edbad1f2d82df067c2826baa6165dd3e.tar.bz2 |
[DAG] Fold add(mul(add(A, CA), CM), CB) -> add(mul(A, CM), CM*CA+CB) (#90860)
This is useful when the inner add has multiple uses, and so cannot be
canonicalized by pushing the constants down through the mul. This patch
adds patterns for both `add(mul(add(A, CA), CM), CB)` and with an extra add
`add(add(mul(add(A, CA), CM), B) CB)` as the second can come up when
lowering geps.
Diffstat (limited to 'llvm/lib/Transforms/Utils/InlineFunction.cpp')
0 files changed, 0 insertions, 0 deletions