Commit 028ee614 authored by yb9976's avatar yb9976
Browse files

Removed Tuple nodes hold by End node.

parent b879b3a8
......@@ -57,5 +57,18 @@ static void exchange_tuple_projs(ir_node *node, void *env)
void remove_tuples(ir_graph *irg)
{
irg_walk_graph(irg, exchange_tuple_projs, NULL, NULL);
ir_node *end = get_irg_end(irg);
int n_keepalives = get_End_n_keepalives(end);
int i;
for (i = n_keepalives - 1; i >= 0; --i) {
ir_node *irn = get_End_keepalive(end, i);
if (is_Tuple(irn)) {
remove_End_keepalive(end, irn);
}
}
add_irg_properties(irg, IR_GRAPH_PROPERTY_NO_TUPLES);
}
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