On Tue, May 17, 2011 at 11:03 PM, Ira Rosen <ira.ro...@linaro.org> wrote: > This part adds the actual code for reduction support. > > Bootstrapped and tested on powerpc64-suse-linux. > I am planning to apply it later today. > > Ira > > ChangeLog: > > PR tree-optimization/41881 > * tree-vectorizer.h (struct _loop_vec_info): Add new field > reduction_chains along with a macro for > its access. > * tree-vect-loop.c (new_loop_vec_info): Initialize reduction chains. > (destroy_loop_vec_info): Free reduction chains. > (vect_analyze_loop_2): Return false if vect_analyze_slp() returns > false. > (vect_is_slp_reduction): New function. > (vect_is_simple_reduction_1): Call vect_is_slp_reduction. > (vect_create_epilog_for_reduction): Support SLP reduction chains. > * tree-vect-slp.c (vect_get_and_check_slp_defs): Allow different > definition types for reduction > chains. > (vect_supported_load_permutation_p): Don't allow permutations for > reduction chains. > (vect_analyze_slp_instance): Support reduction chains. > (vect_analyze_slp): Try to build SLP instance from reduction chains. > (vect_get_constant_vectors): Handle reduction chains. > (vect_schedule_slp_instance): Mark the first statement of the > reduction chain as reduction. > > testsuite/ChangeLog: > > PR tree-optimization/41881 > * gcc.dg/vect/O3-pr41881.c: New test. > * gcc.dg/vect/O3-slp-reduc-10.c: New test. >
This caused: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49199 -- H.J.