tree-optimization/97428 - split SLP groups for loop vectorization
authorRichard Biener <rguenther@suse.de>
Thu, 15 Oct 2020 09:55:53 +0000 (11:55 +0200)
committerRichard Biener <rguenther@suse.de>
Fri, 16 Oct 2020 06:28:37 +0000 (08:28 +0200)
commit429ad0bb0d3dc77e44f95620341da4938d49168e
tree345c1f41c854325692c2a9e1b6b6c8cb40dd8dd9
parentb85d5dc58359ba6f12407861bb50af5e503f89e4
tree-optimization/97428 - split SLP groups for loop vectorization

This enables SLP store group splitting also for loop vectorization.
For the existing testcase gcc.dg/vect/vect-complex-5.c this then
generates much better code, likewise for the PR97428 testcase.

Both of those have a splitting opportunity splitting the group
into two equal (vector-sized) halves, still the patch enables
quite arbitrary splitting since generally the interleaving scheme
results in quite awkward code for even small groups.  If any
problems surface with this it's easy to restrict the splitting
to known-good cases.

2020-10-15  Richard Biener  <rguenther@suse.de>

PR tree-optimization/97428
* tree-vect-slp.c (vect_analyze_slp_instance): Split store
groups also for loop vectorization.

* gcc.dg/vect/vect-complex-5.c: Expect to SLP.
* gcc.dg/vect/pr97428.c: Likewise.
gcc/testsuite/gcc.dg/vect/pr97428.c
gcc/testsuite/gcc.dg/vect/vect-complex-5.c
gcc/tree-vect-slp.c