From bb8a619e12e06104939fac9969dcd07615ee7260 Mon Sep 17 00:00:00 2001 From: Steven Bosscher Date: Wed, 5 May 2004 10:53:00 +0000 Subject: [PATCH] basic-block.h (free_basic_block_vars): Update prototype. * basic-block.h (free_basic_block_vars): Update prototype. * flow.c (free_basic_block_vars): Remove the keep_head_end_p argument. (life_analysis): Update call. * ifcvt.c (if_convert): Likewise. * passes.c (rest_of_handle_final): Likewise. (rest_of_compilation): Likewise. * sibcall.c (optimize_sibling_and_tail_recursive_call): Likewise. * config/sh/sh.c (sh_output_mi_thunk): Likewise. * emit-rtl.c (next_real_insn): Use INSN_P. (prev_real_insn): Likewise. From-SVN: r81520 --- gcc/ChangeLog | 43 +++++++++++++++++++++++++++++-------------- gcc/basic-block.h | 2 +- gcc/config/sh/sh.c | 2 +- gcc/emit-rtl.c | 6 ++---- gcc/flow.c | 31 ++++++++++++------------------- gcc/ifcvt.c | 4 ---- gcc/passes.c | 4 ++-- gcc/sibcall.c | 2 +- 8 files changed, 48 insertions(+), 46 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 7aac8dcd7a5..147f1c7155d 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,18 @@ +2004-05-05 Steven Bosscher + + * basic-block.h (free_basic_block_vars): Update prototype. + * flow.c (free_basic_block_vars): Remove the keep_head_end_p + argument. + (life_analysis): Update call. + * ifcvt.c (if_convert): Likewise. + * sibcall.c (optimize_sibling_and_tail_recursive_call): Likewise. + * passes.c (rest_of_handle_final): Likewise. + (rest_of_compilation): Likewise. + * config/sh/sh.c (sh_output_mi_thunk): Likewise. + + * emit-rtl.c (next_real_insn): Use INSN_P. + (prev_real_insn): Likewise. + 2004-05-05 Eric Christopher * config/mips/mips.md: Update the madd define_split for new mflo/mfhi @@ -133,8 +148,8 @@ * dwarf2out.c (dwarf2out_imported_module_or_decl): Use force_type_die for CONST_DECL. -2004-05-03  Eric Botcazou - Rainer Orth   +2004-05-03 Eric Botcazou + Rainer Orth * config.gcc (sparc64-*-solaris2*, sparcv9-*-solaris2*): Add tm-dwarf2.h to tm_file. @@ -300,20 +315,20 @@ * config/alpha/osf.h (SWITCHES_NEED_SPACES): Define. 2004-04-30 Brian Ford - DJ Delorie + DJ Delorie - * config/i386/cygming.h [HAVE_GAS_PE_SECREL32_RELOC] - (DWARF2_DEBUGGING_INFO): Define to enable. - (DBX_REGISTER_NUMBER): Define to use the svr4 register map for - DWARF2. - * configure.ac (Target-specific assembler checks) - : New test for .secrel32 - relocs. - * configure: Regenerate. - * config.in: Likewise. + * config/i386/cygming.h [HAVE_GAS_PE_SECREL32_RELOC] + (DWARF2_DEBUGGING_INFO): Define to enable. + (DBX_REGISTER_NUMBER): Define to use the svr4 register map for + DWARF2. + * configure.ac (Target-specific assembler checks) + : New test for .secrel32 + relocs. + * configure: Regenerate. + * config.in: Likewise. - * config/i386/cygming.h [HAVE_GAS_PE_SECREL32_RELOC] - (ASM_OUPUT_DWARF_OFFSET): Define. + * config/i386/cygming.h [HAVE_GAS_PE_SECREL32_RELOC] + (ASM_OUPUT_DWARF_OFFSET): Define. 2004-04-29 Andreas Krebbel diff --git a/gcc/basic-block.h b/gcc/basic-block.h index 2c3ef581111..ccbecf1fdc4 100644 --- a/gcc/basic-block.h +++ b/gcc/basic-block.h @@ -363,7 +363,7 @@ extern void compute_bb_for_insn (void); extern void free_bb_for_insn (void); extern void update_bb_for_insn (basic_block); -extern void free_basic_block_vars (int); +extern void free_basic_block_vars (void); extern void insert_insn_on_edge (rtx, edge); bool safe_insert_insn_on_edge (rtx, edge); diff --git a/gcc/config/sh/sh.c b/gcc/config/sh/sh.c index ed4b714ad89..e3d15b9388e 100644 --- a/gcc/config/sh/sh.c +++ b/gcc/config/sh/sh.c @@ -9482,7 +9482,7 @@ sh_output_mi_thunk (FILE *file, tree thunk_fndecl ATTRIBUTE_UNUSED, if (optimize > 0 && flag_schedule_insns_after_reload) { /* Release all memory allocated by flow. */ - free_basic_block_vars (0); + free_basic_block_vars (); /* Release all memory held by regsets now. */ regset_release_memory (); diff --git a/gcc/emit-rtl.c b/gcc/emit-rtl.c index 9a5533ce14e..d7633e5a816 100644 --- a/gcc/emit-rtl.c +++ b/gcc/emit-rtl.c @@ -2960,8 +2960,7 @@ next_real_insn (rtx insn) while (insn) { insn = NEXT_INSN (insn); - if (insn == 0 || GET_CODE (insn) == INSN - || GET_CODE (insn) == CALL_INSN || GET_CODE (insn) == JUMP_INSN) + if (insn == 0 || INSN_P (insn)) break; } @@ -2978,8 +2977,7 @@ prev_real_insn (rtx insn) while (insn) { insn = PREV_INSN (insn); - if (insn == 0 || GET_CODE (insn) == INSN || GET_CODE (insn) == CALL_INSN - || GET_CODE (insn) == JUMP_INSN) + if (insn == 0 || INSN_P (insn)) break; } diff --git a/gcc/flow.c b/gcc/flow.c index 1cd08230c8e..49729bb538e 100644 --- a/gcc/flow.c +++ b/gcc/flow.c @@ -488,8 +488,6 @@ life_analysis (rtx f, FILE *file, int flags) if (file) dump_flow_info (file); - free_basic_block_vars (1); - /* Removing dead insns should have made jumptables really dead. */ delete_dead_jumptables (); } @@ -809,28 +807,23 @@ update_life_info_in_dirty_blocks (enum update_life_extent extent, int prop_flags return retval; } -/* Free the variables allocated by find_basic_blocks. - - KEEP_HEAD_END_P is nonzero if basic_block_info is not to be freed. */ +/* Free the variables allocated by find_basic_blocks. */ void -free_basic_block_vars (int keep_head_end_p) +free_basic_block_vars (void) { - if (! keep_head_end_p) + if (basic_block_info) { - if (basic_block_info) - { - clear_edges (); - VARRAY_FREE (basic_block_info); - } - n_basic_blocks = 0; - last_basic_block = 0; - - ENTRY_BLOCK_PTR->aux = NULL; - ENTRY_BLOCK_PTR->global_live_at_end = NULL; - EXIT_BLOCK_PTR->aux = NULL; - EXIT_BLOCK_PTR->global_live_at_start = NULL; + clear_edges (); + VARRAY_FREE (basic_block_info); } + n_basic_blocks = 0; + last_basic_block = 0; + + ENTRY_BLOCK_PTR->aux = NULL; + ENTRY_BLOCK_PTR->global_live_at_end = NULL; + EXIT_BLOCK_PTR->aux = NULL; + EXIT_BLOCK_PTR->global_live_at_start = NULL; } /* Delete any insns that copy a register to itself. */ diff --git a/gcc/ifcvt.c b/gcc/ifcvt.c index f0802372f7b..7968b2b764b 100644 --- a/gcc/ifcvt.c +++ b/gcc/ifcvt.c @@ -3291,10 +3291,6 @@ if_convert (int x_life_data_ok) && (!flag_reorder_blocks_and_partition || !no_new_pseudos)) mark_loop_exit_edges (); - /* Free up basic_block_for_insn so that we don't have to keep it - up to date, either here or in merge_blocks. */ - free_basic_block_vars (1); - /* Compute postdominators if we think we'll use them. */ if (HAVE_conditional_execution || life_data_ok) calculate_dominance_info (CDI_POST_DOMINATORS); diff --git a/gcc/passes.c b/gcc/passes.c index 2453c748dc3..eaf4de5df41 100644 --- a/gcc/passes.c +++ b/gcc/passes.c @@ -465,7 +465,7 @@ rest_of_handle_final (tree decl, rtx insns) fflush (asm_out_file); /* Release all memory allocated by flow. */ - free_basic_block_vars (0); + free_basic_block_vars (); /* Release all memory held by regsets now. */ regset_release_memory (); @@ -2095,7 +2095,7 @@ rest_of_compilation (tree decl) /* Show no temporary slots allocated. */ init_temp_slots (); - free_basic_block_vars (0); + free_basic_block_vars (); free_bb_for_insn (); timevar_pop (TV_FINAL); diff --git a/gcc/sibcall.c b/gcc/sibcall.c index facc9ac7291..cfd1a629c62 100644 --- a/gcc/sibcall.c +++ b/gcc/sibcall.c @@ -748,6 +748,6 @@ optimize_sibling_and_tail_recursive_calls (void) reorder_blocks (); /* This information will be invalid after inline expansion. Kill it now. */ - free_basic_block_vars (0); + free_basic_block_vars (); free_EXPR_LIST_list (&tail_recursion_label_list); }