summaryrefslogtreecommitdiffhomepage
path: root/ir/be/beutil.c
diff options
context:
space:
mode:
authorChristoph Mallon <mallon@cs.uni-saarland.de>2014-12-29 15:46:38 +0100
committerChristoph Mallon <mallon@cs.uni-saarland.de>2014-12-29 16:58:12 +0100
commitca6d88d96d6aff2af94666295e7ec20335ea5532 (patch)
tree10626aa581c60d16fbd285a3363f19ea2e9c4fd4 /ir/be/beutil.c
parent5b92dd6866b1a4ad3e6ac7db5b99644d55ab0eae (diff)
be: Add and use be_new_Keep_one() to keep a single node.
Diffstat (limited to 'ir/be/beutil.c')
-rw-r--r--ir/be/beutil.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/ir/be/beutil.c b/ir/be/beutil.c
index e368187..8ed22ec 100644
--- a/ir/be/beutil.c
+++ b/ir/be/beutil.c
@@ -171,9 +171,7 @@ void be_remove_dead_nodes_from_schedule(ir_graph *irg)
void be_keep_if_unused(ir_node *node)
{
if (get_irn_n_edges(node) == 0) {
- ir_node *const in[] = { node };
- ir_node *const block = get_nodes_block(node);
- ir_node *const keep = be_new_Keep(block, ARRAY_SIZE(in), in);
+ ir_node *const keep = be_new_Keep_one(node);
sched_add_after(node, keep);
}
}