tree-optimization/97760 - reduction paths with unhandled live stmt
authorRichard Biener <rguenther@suse.de>
Mon, 9 Nov 2020 14:19:56 +0000 (15:19 +0100)
committerRichard Biener <rguenther@suse.de>
Tue, 10 Nov 2020 08:31:46 +0000 (09:31 +0100)
commit2686de5617bfb572343933be2883e8274c9735b5
tree68d5ec7cb26efbdcfa29457e2d1185de0878c177
parent3d3470e239e8040f642a8852721b4962b4ed36f2
tree-optimization/97760 - reduction paths with unhandled live stmt

This makes sure we reject reduction paths with a live stmt that
is not the last one altering the value.  This is because we do not
handle this in the epilogue unless there's a scalar epilogue loop.

2020-11-09  Richard Biener  <rguenther@suse.de>

PR tree-optimization/97760
* tree-vect-loop.c (check_reduction_path): Reject
reduction paths we do not handle in epilogue generation.

* gcc.dg/vect/pr97760.c: New testcase.
gcc/testsuite/gcc.dg/vect/pr97760.c [new file with mode: 0644]
gcc/tree-vect-loop.c