Fix ICE in get_initial_defs_for_reduction (PR 88567)
The use of "j" in:
init = permute_results[number_of_vectors - j - 1];
was out-of-sync with the new flat loop structure. Now that all that
reversing is gone, we can just use the result of duplicate_and_interleave
directly.
The other cases shouldn't be affected by postponing the insertion
of ctor_seq, since gimple_build* appends to the seq without clearing
it first (unlike some of the gimplify routines).
The ICE is already covered by gcc.dg/vect/pr63379.c.
2019-01-07 Richard Sandiford <richard.sandiford@arm.com>
gcc/
PR middle-end/88567
* tree-vect-loop.c (get_initial_defs_for_reduction): Pass the
output vector directly to duplicate_and_interleave instead of
going through a temporary. Postpone insertion of ctor_seq to
the end of the loop.
From-SVN: r267652