Commit 13604927 by Richard Guenther Committed by Richard Biener

re PR regression/52020 (ICE in immed_double_const, at emit-rtl.c:544)

2012-01-27  Richard Guenther  <rguenther@suse.de>

        PR tree-optimization/52020
	* tree-sra.c (sra_modify_assign): Do not transform clobbers.

From-SVN: r183633
parent ace018f9
2012-01-27 Richard Guenther <rguenther@suse.de>
PR tree-optimization/52020
* tree-sra.c (sra_modify_assign): Do not transform clobbers.
2012-01-27 Richard Guenther <rguenther@suse.de>
* ipa-pure-const.c (check_stmt): Clobbers do not make a
function non-const/pure.
......
......@@ -2836,6 +2836,20 @@ sra_modify_constructor_assign (gimple *stmt, gimple_stmt_iterator *gsi)
if (!acc)
return SRA_AM_NONE;
if (gimple_clobber_p (*stmt))
{
/* Remove clobbers of fully scalarized variables, otherwise
do nothing. */
if (acc->grp_covered)
{
unlink_stmt_vdef (*stmt);
gsi_remove (gsi, true);
return SRA_AM_REMOVED;
}
else
return SRA_AM_NONE;
}
loc = gimple_location (*stmt);
if (VEC_length (constructor_elt,
CONSTRUCTOR_ELTS (gimple_assign_rhs1 (*stmt))) > 0)
......
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