Commit 89939ff8 by Richard Biener Committed by Richard Biener

re PR c/87953 (asan: stack-buffer-overflow in vectorizable_reduction)

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

	PR tree-optimization/87953
	* tree-vect-loop.c (vectorizable_reduction): For analysis
	always pass ops[0] to vectorizable_condition.

From-SVN: r265964
parent 3965b35f
2018-11-09 Richard Biener <rguenther@suse.de>
PR tree-optimization/87953
* tree-vect-loop.c (vectorizable_reduction): For analysis
always pass ops[0] to vectorizable_condition.
2018-11-09 Stafford Horne <shorne@gmail.com>
Richard Henderson <rth@twiddle.net>
Joel Sherrill <joel@rtems.org>
......@@ -6485,9 +6485,10 @@ vectorizable_reduction (stmt_vec_info stmt_info, gimple_stmt_iterator *gsi,
if (code == COND_EXPR)
{
/* Only call during the analysis stage, otherwise we'll lose
STMT_VINFO_TYPE. */
STMT_VINFO_TYPE. We'll pass ops[0] as reduc_op, it's only
used as a flag during analysis. */
if (!vec_stmt && !vectorizable_condition (stmt_info, gsi, NULL,
ops[reduc_index], 0, NULL,
ops[0], 0, NULL,
cost_vec))
{
if (dump_enabled_p ())
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment