r256133 - in /trunk/gcc: ChangeLog tree-vect-lo...

rsandifo@gcc.gnu.org rsandifo@gcc.gnu.org
Wed Jan 3 07:15:00 GMT 2018


Author: rsandifo
Date: Wed Jan  3 07:15:47 2018
New Revision: 256133

URL: https://gcc.gnu.org/viewcvs?rev=256133&root=gcc&view=rev
Log:
poly_int: vectorizable_reduction

This patch makes vectorizable_reduction cope with variable-length vectors.
We can handle the simple case of an inner loop reduction for which
the target has native support for the epilogue operation.  For now we
punt on other cases, but patches after the main SVE submission allow
SLP and double reductions too.

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

gcc/
	* tree.h (build_index_vector): Declare.
	* tree.c (build_index_vector): New function.
	* tree-vect-loop.c (get_initial_defs_for_reduction): Treat the number
	of units as polynomial, forcibly converting it to a constant if
	vectorizable_reduction has already enforced the condition.
	(vect_create_epilog_for_reduction): Likewise.  Use build_index_vector
	to create a {1,2,3,...} vector.
	(vectorizable_reduction): Treat the number of units as polynomial.
	Choose vectype_in based on the largest scalar element size rather
	than the smallest number of units.  Enforce the restrictions
	relied on above.

Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/tree-vect-loop.c
    trunk/gcc/tree.c
    trunk/gcc/tree.h



More information about the Gcc-cvs mailing list