PR tree-optimization/57330
* cgraph.c (cgraph_redirect_edge_call_stmt_to_callee): Properly
preserve the call stmts fntype.
* gcc.dg/torture/pr57330.c: New testcase.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@199139
138bc75d-0d04-0410-961f-
82ee72b054a4
2013-05-21 Richard Biener <rguenther@suse.de>
+ PR tree-optimization/57330
+ * cgraph.c (cgraph_redirect_edge_call_stmt_to_callee): Properly
+ preserve the call stmts fntype.
+
+2013-05-21 Richard Biener <rguenther@suse.de>
+
PR tree-optimization/57303
* tree-ssa-sink.c (statement_sink_location): Improve killing
stmt detection and properly handle self-assignments.
= gimple_call_copy_skip_args (e->call_stmt,
e->callee->clone.combined_args_to_skip);
gimple_call_set_fndecl (new_stmt, e->callee->symbol.decl);
+ gimple_call_set_fntype (new_stmt, gimple_call_fntype (e->call_stmt));
if (gimple_vdef (new_stmt)
&& TREE_CODE (gimple_vdef (new_stmt)) == SSA_NAME)
2013-05-21 Richard Biener <rguenther@suse.de>
+ PR tree-optimization/57330
+ * gcc.dg/torture/pr57330.c: New testcase.
+
+2013-05-21 Richard Biener <rguenther@suse.de>
+
PR tree-optimization/57303
* gcc.dg/torture/pr57303.c: New testcase.
--- /dev/null
+/* { dg-do compile } */
+
+void foo (int a)
+{}
+
+void *a;
+void bar ()
+{
+ void **( *b ) ( ) = (void**(*)()) foo;
+ a = b (0);
+}