summaryrefslogtreecommitdiffhomepage
path: root/ir/be/beinfo.c
diff options
context:
space:
mode:
authorMatthias Braun <matze@braunis.de>2012-11-05 19:54:39 +0100
committerMatthias Braun <matze@braunis.de>2013-10-03 06:06:53 +0200
commit7353f84fb7f820fbf6c0ababb6adf9d53bb719e3 (patch)
treeb0bf81348d2a20ca68d01562c4b967bcf2a3df13 /ir/be/beinfo.c
parent49d1fbddcec18f0bcc60edbf1f4911c0efc127a2 (diff)
be: fix phi attribute copy
Diffstat (limited to 'ir/be/beinfo.c')
-rw-r--r--ir/be/beinfo.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/ir/be/beinfo.c b/ir/be/beinfo.c
index 2e416b6..f5b11fb 100644
--- a/ir/be/beinfo.c
+++ b/ir/be/beinfo.c
@@ -70,7 +70,10 @@ static void new_phi_copy_attr(ir_graph *irg, const ir_node *old_node,
backend_info_t *old_info = be_get_info(old_node);
backend_info_t *new_info = be_get_info(new_node);
- *new_info = *old_info;
+ new_info->in_reqs = old_info->in_reqs;
+ size_t n_outs = arch_get_irn_n_outs(old_node);
+ memcpy(new_info->out_infos, old_info->out_infos,
+ n_outs * sizeof(old_info->out_infos[0]));
old_phi_copy_attr(irg, old_node, new_node);
}