tree-optimization/99746 - avoid confusing hybrid code
authorRichard Biener <rguenther@suse.de>
Wed, 24 Mar 2021 11:55:16 +0000 (12:55 +0100)
committerRichard Biener <rguenther@suse.de>
Thu, 25 Mar 2021 08:07:34 +0000 (09:07 +0100)
commita29124d28253cdf603ba1977db2f09c9f233fea5
tree4e4f8ee0bf5a8eec84a69179283cd2410cdbc9f1
parent08103e4d6ada9b57366f2df2a2b745babfab914c
tree-optimization/99746 - avoid confusing hybrid code

This avoids confusing the hybrid vectorization code with SLP
patterns by not marking SLP pattern covered stmts as patterns
(they are marked as SLP patterns already).  This means that loop
vectorization will vectorize the scalar stmt rather than the SLP
pattern stmt (which it can't anyway).

2021-03-24  Richard Biener  <rguenther@suse.de>

PR tree-optimization/99746
* tree-vect-slp-patterns.c (complex_pattern::build): Do not mark
the scalar stmt as patterned.  Instead set up required things
manually.

* gfortran.dg/vect/pr99746.f90: New testcase.
gcc/testsuite/gfortran.dg/vect/pr99746.f90 [new file with mode: 0644]
gcc/tree-vect-slp-patterns.c