genmatch.c (dt_simplify::gen_1): For generic wrap all multi-result-use captures in a SAVE_EXPR.

2015-11-26  Richard Biener  <rguenther@suse.de>

	* genmatch.c (dt_simplify::gen_1): For generic wrap all
	multi-result-use captures in a SAVE_EXPR.

From-SVN: r230955
This commit is contained in:
Richard Biener 2015-11-26 13:45:45 +00:00 committed by Richard Biener
parent 3e0fb1a3e3
commit 6be52f624e
2 changed files with 9 additions and 10 deletions

View File

@ -1,3 +1,8 @@
2015-11-26 Richard Biener <rguenther@suse.de>
* genmatch.c (dt_simplify::gen_1): For generic wrap all
multi-result-use captures in a SAVE_EXPR.
2015-11-26 Matthew Wahab <matthew.wahab@arm.com>
* config/aarch64/aarch64.h (AARCH64_ISA_RDMA): New.

View File

@ -3112,16 +3112,10 @@ dt_simplify::gen_1 (FILE *f, int indent, bool gimple, operand *result)
{
if (cinfo.info[i].same_as != (unsigned)i)
continue;
if (!cinfo.info[i].force_no_side_effects_p
&& cinfo.info[i].result_use_count > 1)
{
fprintf_indent (f, indent,
"if (TREE_SIDE_EFFECTS (captures[%d]))\n",
i);
fprintf_indent (f, indent,
" captures[%d] = save_expr (captures[%d]);\n",
i, i);
}
if (cinfo.info[i].result_use_count > 1)
fprintf_indent (f, indent,
"captures[%d] = save_expr (captures[%d]);\n",
i, i);
}
for (unsigned j = 0; j < e->ops.length (); ++j)
{