diff options
author | David Green <david.green@arm.com> | 2023-06-30 12:25:07 +0100 |
---|---|---|
committer | David Green <david.green@arm.com> | 2023-06-30 12:25:07 +0100 |
commit | d36c81e7f6f09a46c802d9b64416c24253140e25 (patch) | |
tree | 8215d4561a9471c0bbd288c5035b782511116885 /llvm/lib/Object/COFFObjectFile.cpp | |
parent | 09f4cedd6189a2ab9464b777ecc8e10610a7ff2c (diff) | |
download | llvm-d36c81e7f6f09a46c802d9b64416c24253140e25.zip llvm-d36c81e7f6f09a46c802d9b64416c24253140e25.tar.gz llvm-d36c81e7f6f09a46c802d9b64416c24253140e25.tar.bz2 |
[AArch64] Fold tree of offset loads combine
This attempts to fold trees of add(ext(load p), shl(ext(load p+4)) into a
single load of twice the size, that we extract the bottom part and top part so
that the shl can start to use a shll2 instruction. The two loads in that
example can also be larger trees of instructions, which are identical except
for the leaves which are all loads offset from the LHS, including buildvectors
of multiple loads. For example:
sub(zext(buildvec(load p+4, load q+4)), zext(buildvec(load r+4, load s+4)))
Whilst it can be common for the larger loads to replace LDP instructions (which
doesn't gain anything on its own), the larger loads in buildvectors can help
create more efficient code, and prevent the need for ld1 lane inserts which can
be more expensive than continuous loads.
This creates a fairly niche, fairly large combine that attempts to be fairly
general where it is beneficial. It helps some SLP vectorized code to avoid the
use of the more expensive ld1 lane inserting loads.
Differential Revision: https://reviews.llvm.org/D153972
Diffstat (limited to 'llvm/lib/Object/COFFObjectFile.cpp')
0 files changed, 0 insertions, 0 deletions