[5/7] Move the fix for PR65518
commitbc691ae410f90875636437691a9b6a6a022ba24a
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 6 Jul 2016 08:14:41 +0000 (6 08:14 +0000)
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 6 Jul 2016 08:14:41 +0000 (6 08:14 +0000)
treebec6504ded7b6f968d307ecd48cfc8553e087464
parentcf60da0791e78eb1cf8816e6e52cf32d6b2aa6f9
[5/7] Move the fix for PR65518

This patch moves the fix for PR65518 to the code that checks whether
load-and-permute operations are supported.   If the group size is
greater than the vectorisation factor, it would still be possible
to fall back to elementwise loads (as for strided groups) rather
than fail vectorisation entirely.

Tested on aarch64-linux-gnu and x86_64-linux-gnu.

gcc/
* tree-vectorizer.h (vect_grouped_load_supported): Add a
single_element_p parameter.
* tree-vect-data-refs.c (vect_grouped_load_supported): Likewise.
Check the PR65518 case here rather than in vectorizable_load.
* tree-vect-loop.c (vect_analyze_loop_2): Update call accordignly.
* tree-vect-stmts.c (vectorizable_load): Likewise.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@238037 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/ChangeLog
gcc/tree-vect-data-refs.c
gcc/tree-vect-loop.c
gcc/tree-vect-stmts.c
gcc/tree-vectorizer.h