aboutsummaryrefslogtreecommitdiff
path: root/gcc/tree-vect-patterns.cc
diff options
context:
space:
mode:
authorManolis Tsamis <manolis.tsamis@vrull.eu>2024-06-25 08:00:04 -0700
committerChristoph Müllner <christoph.muellner@vrull.eu>2024-08-08 14:47:07 +0200
commitab18785840d7b8afd9f716bab9d1eab415bc4fe9 (patch)
treef573e9e5b8dd818e0b88788dedca4dc9a6841b78 /gcc/tree-vect-patterns.cc
parent71aebb36174c194231da5f9c7c23f81dbb082ca4 (diff)
downloadgcc-ab18785840d7b8afd9f716bab9d1eab415bc4fe9.zip
gcc-ab18785840d7b8afd9f716bab9d1eab415bc4fe9.tar.gz
gcc-ab18785840d7b8afd9f716bab9d1eab415bc4fe9.tar.bz2
Rearrange SLP nodes with duplicate statements [PR98138]
This change checks when a two_operators SLP node has multiple occurrences of the same statement (e.g. {A, B, A, B, ...}) and tries to rearrange the operands so that there are no duplicates. Two vec_perm expressions are then introduced to recreate the original ordering. These duplicates can appear due to how two_operators nodes are handled, and they prevent vectorization in some cases. This targets the vectorization of the SPEC2017 x264 pixel_satd functions. In some processors a larger than 10% improvement on x264 has been observed. PR tree-optimization/98138 gcc/ChangeLog: * tree-vect-slp.cc: Avoid duplicates in two_operators nodes. gcc/testsuite/ChangeLog: * gcc.target/aarch64/vect-slp-two-operator.c: New test.
Diffstat (limited to 'gcc/tree-vect-patterns.cc')
0 files changed, 0 insertions, 0 deletions