Commit e31657e8 by Seongbae Park Committed by Seongbae Park

re PR tree-optimization/30590 (tree-nrv optimization clobbers return variable)

2007-03-13  Seongbae Park <seongbae.park@gmail.com>

	PR tree-optimization/30590
	* tree-nrv.c (tree_nrv): Check for the partial update of the
	return value.

From-SVN: r122909
parent 05033949
2007-03-13 Seongbae Park <seongbae.park@gmail.com>
PR tree-optimization/30590
* tree-nrv.c (tree_nrv): Check for the partial update of the
return value.
2007-03-13 Alexandre Oliva <aoliva@redhat.com>
* flags.h (flag_random_seed): Remove declaration, in favor of...
......
......@@ -163,6 +163,14 @@ tree_nrv (void)
result_type))
return 0;
}
else if (TREE_CODE (stmt) == GIMPLE_MODIFY_STMT)
{
tree addr = get_base_address (GIMPLE_STMT_OPERAND (stmt, 0));
/* If there's any MODIFY of component of RESULT,
then bail out. */
if (addr && addr == result)
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