diff options
author | Roger Sayle <roger@nextmovesoftware.com> | 2021-11-22 18:15:36 +0000 |
---|---|---|
committer | Roger Sayle <roger@nextmovesoftware.com> | 2021-11-22 18:15:36 +0000 |
commit | a944b5dec3adb28ed199234d2116145ca9010d6a (patch) | |
tree | aade15bd5db9cca99b081074a5e27fd5abbfd999 /libcpp/macro.c | |
parent | c38c547a708d9f144ba36f54d3d6ab5f5995966f (diff) | |
download | gcc-a944b5dec3adb28ed199234d2116145ca9010d6a.zip gcc-a944b5dec3adb28ed199234d2116145ca9010d6a.tar.gz gcc-a944b5dec3adb28ed199234d2116145ca9010d6a.tar.bz2 |
tree-optimization/103345: Improved load merging.
This patch implements PR tree-optimization/103345 to merge adjacent
loads when combined with addition or bitwise xor. The current code
in gimple-ssa-store-merging.c's find_bswap_or_nop alreay handles ior,
so that all that's required is to treat PLUS_EXPR and BIT_XOR_EXPR in
the same way at BIT_IOR_EXPR. Many thanks to Andrew Pinski for
pointing out that this also resolves PR target/98953.
2021-11-22 Roger Sayle <roger@nextmovesoftware.com>
gcc/ChangeLog
PR tree-optimization/98953
PR tree-optimization/103345
* gimple-ssa-store-merging.c (find_bswap_or_nop_1): Handle
BIT_XOR_EXPR and PLUS_EXPR the same as BIT_IOR_EXPR.
(pass_optimize_bswap::execute): Likewise.
gcc/testsuite/ChangeLog
PR tree-optimization/98953
PR tree-optimization/103345
* gcc.dg/tree-ssa/pr98953.c: New test case.
* gcc.dg/tree-ssa/pr103345.c: New test case.
Diffstat (limited to 'libcpp/macro.c')
0 files changed, 0 insertions, 0 deletions