summaryrefslogtreecommitdiffhomepage
path: root/ir/be/beprefalloc.c
diff options
context:
space:
mode:
authorChristoph Mallon <mallon@cs.uni-saarland.de>2014-12-27 21:34:24 +0100
committerChristoph Mallon <mallon@cs.uni-saarland.de>2014-12-28 17:46:19 +0100
commit5f702d9e75286df48f3b91c2d043a233344dfd12 (patch)
treeba8cde7a680cbf864e21ba3b4aa30c882c2b4294 /ir/be/beprefalloc.c
parent94ab70c7a8d50289fad1e8b18cd993e79a3d90d9 (diff)
ir: Use ARRAY_SIZE() instead of magic numbers.
Diffstat (limited to 'ir/be/beprefalloc.c')
-rw-r--r--ir/be/beprefalloc.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ir/be/beprefalloc.c b/ir/be/beprefalloc.c
index edd9eec..e69e6b1 100644
--- a/ir/be/beprefalloc.c
+++ b/ir/be/beprefalloc.c
@@ -863,8 +863,8 @@ static void permute_values(ir_nodeset_t *live_nodes, ir_node *before,
/* exchange old_r and r2; after that old_r is a fixed point */
unsigned r2 = permutation[old_r];
- ir_node *in[2] = { assignments[r2], assignments[old_r] };
- ir_node *perm = be_new_Perm(cls, block, 2, in);
+ ir_node *const in[] = { assignments[r2], assignments[old_r] };
+ ir_node *const perm = be_new_Perm(cls, block, ARRAY_SIZE(in), in);
sched_add_before(before, perm);
DB((dbg, LEVEL_2, "Perm %+F (perm %+F,%+F, before %+F)\n",
perm, in[0], in[1], before));