From f4d7027e2bee7f2166edd59880caa4c21a51d312 Mon Sep 17 00:00:00 2001 From: Christoph Mallon Date: Sun, 12 Oct 2008 14:27:05 +0000 Subject: [PATCH] Do not qsort() the entries of a Perm in lower_perm_node(), it is pointless. [r22813] --- ir/be/belower.c | 14 -------------- 1 file changed, 14 deletions(-) diff --git a/ir/be/belower.c b/ir/be/belower.c index 1fc5176a4..f927aacd6 100644 --- a/ir/be/belower.c +++ b/ir/be/belower.c @@ -96,17 +96,6 @@ typedef struct _perm_cycle_t { perm_type_t type; /**< type (CHAIN or CYCLE) */ } perm_cycle_t; -/** Compare the in registers of two register pairs. */ -static int compare_reg_pair(const void *a, const void *b) { - const reg_pair_t *pair_a = a; - const reg_pair_t *pair_b = b; - - if (pair_a->in_reg->index > pair_b->in_reg->index) - return 1; - else - return -1; -} - /** returns the number register pairs marked as checked. */ static int get_n_checked_pairs(reg_pair_t *pairs, int n) { int i, n_checked = 0; @@ -329,9 +318,6 @@ static void lower_perm_node(ir_node *irn, void *walk_env) pair->checked = 0; } - /* sort the register pairs by the indices of the in registers */ - qsort(pairs, n, sizeof(pairs[0]), compare_reg_pair); - /* Mark all equal pairs as checked, and exchange the OUT proj with the IN * node. */ for (i = 0; i < n; i++) { -- 2.20.1