Commit 5129b43b by Richard Biener Committed by Richard Biener

re PR tree-optimization/78312 (wrong code due to ssa-backprop)

2016-11-14  Richard Biener  <rguenther@suse.de>

	PR tree-optimization/78312
	* gimple-ssa-backprop.c (backprop::prepare_change): Reset
	flow-sensitive info.

	* gcc.dg/torture/pr78312.c: New testcase.

From-SVN: r242380
parent d97cca4a
2016-11-14 Richard Biener <rguenther@suse.de>
PR tree-optimization/78312
* gimple-ssa-backprop.c (backprop::prepare_change): Reset
flow-sensitive info.
2016-11-14 Georg-Johann Lay <avr@gjlay.de>
PR target/78093
......@@ -728,6 +728,7 @@ backprop::prepare_change (tree var)
{
if (MAY_HAVE_DEBUG_STMTS)
insert_debug_temp_for_var_def (NULL, var);
reset_flow_sensitive_info (var);
}
/* STMT has been changed. Give the fold machinery a chance to simplify
......
2016-11-14 Richard Biener <rguenther@suse.de>
PR tree-optimization/78312
* gcc.dg/torture/pr78312.c: New testcase.
2016-11-14 Georg-Johann Lay <avr@gjlay.de>
PR target/78093
......
/* { dg-do run } */
typedef unsigned short u16;
static u16 a;
u16 __attribute__ ((noinline, noclone))
foo (int p1)
{
a = -(p1 > 0);
a *= 0 != a;
a *= (unsigned)a;
return a;
}
int
main ()
{
u16 x = foo (1);
if (x != 1)
__builtin_abort();
return 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