summaryrefslogtreecommitdiffhomepage
path: root/ir/be/beasm.c
diff options
context:
space:
mode:
authorChristoph Mallon <christoph.mallon@gmx.de>2015-08-31 21:29:49 +0200
committerChristoph Mallon <christoph.mallon@gmx.de>2015-09-08 12:23:08 +0200
commit2fb66e6e1d31c8e88156208077d309eac9020460 (patch)
treeec871170ea1fefcd091c75b97f22c6df0047a8b9 /ir/be/beasm.c
parentd0d34f4769d84df84ed859588b2dc73ca116d663 (diff)
be: Pass the input requirements directly to the constructors of nodes, which have a variable number of arguments.
Diffstat (limited to 'ir/be/beasm.c')
-rw-r--r--ir/be/beasm.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/ir/be/beasm.c b/ir/be/beasm.c
index 4864b78..c1127e8 100644
--- a/ir/be/beasm.c
+++ b/ir/be/beasm.c
@@ -264,11 +264,12 @@ ir_node *be_make_asm(ir_node const *const node, ir_node **in, arch_register_req_
ARR_APP1(arch_register_req_t const*, in_reqs, arch_memory_req);
ARR_APP1(arch_register_req_t const*, out_reqs, arch_memory_req);
- dbg_info *const dbgi = get_irn_dbg_info(node);
- unsigned const n_ins = ARR_LEN(in);
- unsigned const n_outs = ARR_LEN(out_reqs);
- ident *const text = get_ASM_text(node);
- ir_node *const new_node = be_new_Asm(dbgi, block, n_ins, in, n_outs, text, operands);
+ dbg_info *const dbgi = get_irn_dbg_info(node);
+ unsigned const n_ins = ARR_LEN(in);
+ unsigned const n_outs = ARR_LEN(out_reqs);
+ ident *const text = get_ASM_text(node);
+ arch_register_req_t const **const dup_in_reqs = DUP_ARR_D(arch_register_req_t const*, obst, in_reqs);
+ ir_node *const new_node = be_new_Asm(dbgi, block, n_ins, in, dup_in_reqs, n_outs, text, operands);
for (unsigned i = 0, n = isa_if->n_register_classes; i < n; ++i) {
if (add_pressure[i] == 0)
continue;
@@ -280,8 +281,6 @@ ir_node *be_make_asm(ir_node const *const node, ir_node **in, arch_register_req_
for (size_t o = 0; o < n_outs; ++o) {
info->out_infos[o].req = out_reqs[o];
}
- arch_register_req_t const **const dup_in_reqs = DUP_ARR_D(arch_register_req_t const*, obst, in_reqs);
- arch_set_irn_register_reqs_in(new_node, dup_in_reqs);
DEL_ARR_F(in);
DEL_ARR_F(in_reqs);