diff options
-rw-r--r-- | gcc/ChangeLog | 13 | ||||
-rw-r--r-- | gcc/ira-color.c | 4 | ||||
-rw-r--r-- | gcc/ira-int.h | 4 | ||||
-rw-r--r-- | gcc/ira.c | 21 |
4 files changed, 22 insertions, 20 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 4606969..f493fed 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,16 @@ +2008-09-06 Richard Sandiford <rdsandiford@googlemail.com> + + * ira-int.h (ira_zero_hard_reg_set, ira_one_hard_reg_set): Delete. + * ira-color.c (setup_allocno_left_conflicts_num): Use + hard_reg_set_equal_p instead of a comparison with + ira_zero_hard_reg_set. + * ira.c (setup_reg_subclasses): Likewise. + (setup_cover_and_important_classes): Likewise. + (setup_class_translate): Likewise. + (setup_reg_class_intersect_union): Likewise. + (ira_zero_hard_reg_set, ira_one_hard_reg_set): Delete. + (ira_init_once): Don't initialize them. + 2008-09-05 Vladimir Makarov <vmakarov@redhat.com> * doc/tm.texi (IRA_COVER_CLASSES): Fix a typo. diff --git a/gcc/ira-color.c b/gcc/ira-color.c index 9bda76d..833048e 100644 --- a/gcc/ira-color.c +++ b/gcc/ira-color.c @@ -1274,7 +1274,7 @@ setup_allocno_left_conflicts_num (ira_allocno_t allocno) AND_HARD_REG_SET (temp_set, reg_class_contents[cover_class]); AND_COMPL_HARD_REG_SET (temp_set, ira_no_alloc_regs); conflict_allocnos_size = 0; - if (! hard_reg_set_equal_p (temp_set, ira_zero_hard_reg_set)) + if (! hard_reg_set_empty_p (temp_set)) for (i = 0; i < (int) hard_regs_num; i++) { hard_regno = ira_class_hard_regs[cover_class][i]; @@ -1282,7 +1282,7 @@ setup_allocno_left_conflicts_num (ira_allocno_t allocno) { conflict_allocnos_size++; CLEAR_HARD_REG_BIT (temp_set, hard_regno); - if (hard_reg_set_equal_p (temp_set, ira_zero_hard_reg_set)) + if (hard_reg_set_empty_p (temp_set)) break; } } diff --git a/gcc/ira-int.h b/gcc/ira-int.h index 727eeae..ccd65e6 100644 --- a/gcc/ira-int.h +++ b/gcc/ira-int.h @@ -702,10 +702,6 @@ ira_allocno_set_iter_next (ira_allocno_set_iterator *i) /* ira.c: */ -/* Hard regsets whose all bits are correspondingly zero or one. */ -extern HARD_REG_SET ira_zero_hard_reg_set; -extern HARD_REG_SET ira_one_hard_reg_set; - /* Map: hard regs X modes -> set of hard registers for storing value of given mode starting with given hard register. */ extern HARD_REG_SET ira_reg_mode_hard_regset @@ -670,7 +670,7 @@ setup_reg_subclasses (void) COPY_HARD_REG_SET (temp_hard_regset, reg_class_contents[i]); AND_COMPL_HARD_REG_SET (temp_hard_regset, no_unit_alloc_regs); - if (hard_reg_set_equal_p (temp_hard_regset, ira_zero_hard_reg_set)) + if (hard_reg_set_empty_p (temp_hard_regset)) continue; for (j = 0; j < N_REG_CLASSES; j++) if (i != j) @@ -734,7 +734,7 @@ setup_cover_and_important_classes (void) gcc_unreachable (); COPY_HARD_REG_SET (temp_hard_regset, reg_class_contents[cl]); AND_COMPL_HARD_REG_SET (temp_hard_regset, no_unit_alloc_regs); - if (! hard_reg_set_equal_p (temp_hard_regset, ira_zero_hard_reg_set)) + if (! hard_reg_set_empty_p (temp_hard_regset)) ira_reg_class_cover[ira_reg_class_cover_size++] = cl; } ira_important_classes_num = 0; @@ -742,7 +742,7 @@ setup_cover_and_important_classes (void) { COPY_HARD_REG_SET (temp_hard_regset, reg_class_contents[cl]); AND_COMPL_HARD_REG_SET (temp_hard_regset, no_unit_alloc_regs); - if (! hard_reg_set_equal_p (temp_hard_regset, ira_zero_hard_reg_set)) + if (! hard_reg_set_empty_p (temp_hard_regset)) for (j = 0; j < ira_reg_class_cover_size; j++) { COPY_HARD_REG_SET (temp_hard_regset, reg_class_contents[cl]); @@ -794,8 +794,7 @@ setup_class_translate (void) { COPY_HARD_REG_SET (temp_hard_regset, reg_class_contents[cl]); AND_COMPL_HARD_REG_SET (temp_hard_regset, no_unit_alloc_regs); - if (! hard_reg_set_subset_p (temp_hard_regset, - ira_zero_hard_reg_set)) + if (! hard_reg_set_empty_p (temp_hard_regset)) gcc_unreachable (); } #endif @@ -818,7 +817,7 @@ setup_class_translate (void) reg_class_contents[cover_class]); AND_HARD_REG_SET (temp_hard_regset, reg_class_contents[cl]); AND_COMPL_HARD_REG_SET (temp_hard_regset, no_unit_alloc_regs); - if (! hard_reg_set_equal_p (temp_hard_regset, ira_zero_hard_reg_set)) + if (! hard_reg_set_empty_p (temp_hard_regset)) { min_cost = INT_MAX; for (mode = 0; mode < MAX_MACHINE_MODE; mode++) @@ -875,8 +874,8 @@ setup_reg_class_intersect_union (void) AND_COMPL_HARD_REG_SET (temp_hard_regset, no_unit_alloc_regs); COPY_HARD_REG_SET (temp_set2, reg_class_contents[cl2]); AND_COMPL_HARD_REG_SET (temp_set2, no_unit_alloc_regs); - if (hard_reg_set_equal_p (temp_hard_regset, ira_zero_hard_reg_set) - && hard_reg_set_equal_p (temp_set2, ira_zero_hard_reg_set)) + if (hard_reg_set_empty_p (temp_hard_regset) + && hard_reg_set_empty_p (temp_set2)) { for (i = 0;; i++) { @@ -1081,10 +1080,6 @@ ira_init_register_move_cost (enum machine_mode mode) -/* Hard regsets whose all bits are correspondingly zero or one. */ -HARD_REG_SET ira_zero_hard_reg_set; -HARD_REG_SET ira_one_hard_reg_set; - /* This is called once during compiler work. It sets up different arrays whose values don't depend on the compiled function. */ @@ -1093,8 +1088,6 @@ ira_init_once (void) { enum machine_mode mode; - CLEAR_HARD_REG_SET (ira_zero_hard_reg_set); - SET_HARD_REG_SET (ira_one_hard_reg_set); for (mode = 0; mode < MAX_MACHINE_MODE; mode++) { ira_register_move_cost[mode] = NULL; |