poly_int: tree-vect-generic.c
authorRichard Sandiford <richard.sandiford@linaro.org>
Wed, 3 Jan 2018 07:16:53 +0000 (07:16 +0000)
committerRichard Sandiford <rsandifo@gcc.gnu.org>
Wed, 3 Jan 2018 07:16:53 +0000 (07:16 +0000)
commit22afc2b31b75fa61b9558a9be8c8dbb7d4193b8a
tree0b189771ad60bc0f5069ef36328f3b9926bc9177
parentb064d4f9d6cb163da32d19cb172cbc4a5fffb39a
poly_int: tree-vect-generic.c

This patch makes tree-vect-generic.c cope with variable-length vectors.
Decomposition is only supported for constant-length vectors, since we
should never generate unsupported variable-length operations.

2018-01-03  Richard Sandiford  <richard.sandiford@linaro.org>
    Alan Hayward  <alan.hayward@arm.com>
    David Sherwood  <david.sherwood@arm.com>

gcc/
* tree-vect-generic.c (nunits_for_known_piecewise_op): New function.
(expand_vector_piecewise): Use it instead of TYPE_VECTOR_SUBPARTS.
(expand_vector_addition, add_rshift, expand_vector_divmod): Likewise.
(expand_vector_condition, vector_element): Likewise.
(subparts_gt): New function.
(get_compute_type): Use subparts_gt.
(count_type_subparts): Delete.
(expand_vector_operations_1): Use subparts_gt instead of
count_type_subparts.

Co-Authored-By: Alan Hayward <alan.hayward@arm.com>
Co-Authored-By: David Sherwood <david.sherwood@arm.com>
From-SVN: r256143
gcc/ChangeLog
gcc/tree-vect-generic.c