GCC Middle and Back End API Reference
|
Data Structures | |
struct | df_rd_problem_data |
struct | df_lr_problem_data |
struct | df_live_problem_data |
struct | df_word_lr_problem_data |
struct | df_md_problem_data |
Variables | |
static bitmap_head | seen_in_block |
static bitmap_head | seen_in_insn |
static struct df_problem | problem_RD |
static struct df_problem | problem_LR |
static bitmap_head | df_live_scratch |
static struct df_problem | problem_LIVE |
static struct df_problem | problem_CHAIN |
static struct df_problem | problem_WORD_LR |
static struct df_problem | problem_NOTE |
static bitmap_head | df_md_scratch |
static struct df_problem | problem_MD |
bool can_move_insns_across | ( | rtx | from, |
rtx | to, | ||
rtx | across_from, | ||
rtx | across_to, | ||
basic_block | merge_bb, | ||
regset | merge_live, | ||
regset | other_branch_live, | ||
rtx * | pmove_upto | ||
) |
Return true if it is safe to move a group of insns, described by the range FROM to TO, backwards across another group of insns, described by ACROSS_FROM to ACROSS_TO. It is assumed that there are no insns between ACROSS_TO and FROM, but they may be in different basic blocks; MERGE_BB is the block from which the insns will be moved. The caller must pass in a regset MERGE_LIVE which specifies the registers live after TO. This function may be called in one of two cases: either we try to move identical instructions from all successor blocks into their predecessor, or we try to move from only one successor block. If OTHER_BRANCH_LIVE is nonnull, it indicates that we're dealing with the second case. It should contain a set of registers live at the end of ACROSS_TO which must not be clobbered by moving the insns. In that case, we're also more careful about moving memory references and trapping insns. We return false if it is not safe to move the entire group, but it may still be possible to move a subgroup. PMOVE_UPTO, if nonnull, is set to point at the last moveable insn in such a case.
References bitmap_and_compl_into(), bitmap_and_into(), bitmap_copy(), bitmap_intersect_p(), df_simulate_defs(), df_simulate_find_defs(), df_simulate_find_uses(), df_simulate_initialize_backwards(), df_simulate_one_insn_backwards(), df_simulate_uses(), find_memory(), find_memory_stores(), for_each_rtx(), global_regs, may_trap_or_fault_p(), may_trap_p(), note_stores(), reg_obstack, reload_completed, sets_cc0_p(), targetm, and volatile_insn_p().
Referenced by dead_or_predicable(), and try_head_merge_bb().
void df_chain_add_problem | ( | ) |
Create a new DATAFLOW instance and add it to an existing instance of DF. The returned structure is what is used to get at the solution.
References df_add_problem(), and df_bitmap_obstack.
Referenced by find_and_remove_re(), find_defs(), init_dce(), iv_analysis_loop_init(), sched_init(), and web_main().
|
static |
Create def-use or use-def chains.
References create_alloc_pool(), and df_chain_remove_problem().
|
static |
Debugging info.
References df_d::changeable_flags, df, df_chain_dump(), DF_DU_CHAIN, df_get_artificial_defs(), df_get_artificial_uses(), DF_NO_HARD_REGS, DF_REF_AT_TOP, DF_UD_CHAIN, and basic_block_def::index.
Referenced by df_chain_bottom_dump(), and df_chain_top_dump().
|
static |
References df_chain_bb_dump().
Copy the du or ud chain starting at FROM_REF and attach it to TO_REF.
References df_chain_create(), df_link::next, and df_link::ref.
|
read |
Create a du or ud chain from SRC to DST and link it into SRC.
References df_link::next, pool_alloc(), and df_link::ref.
Referenced by df_chain_copy(), and df_chain_create_bb_process_use().
|
static |
Create chains from reaching defs bitmaps for basic block BB.
References bitmap_clear(), bitmap_copy(), bitmap_default_obstack, bitmap_set_bit(), df_d::changeable_flags, df, df_chain_create_bb_process_use(), DF_EQ_NOTES, df_get_artificial_uses(), DF_NO_HARD_REGS, df_rd_get_bb_info(), df_rd_simulate_artificial_defs_at_top(), df_rd_simulate_one_insn(), DF_REF_AT_TOP, df_rd_bb_info::in, and basic_block_def::index.
Referenced by df_chain_finalize().
|
static |
Create the chains for a list of USEs.
References df_d::changeable_flags, count, df, df_chain_create(), DF_DU_CHAIN, DF_NO_HARD_REGS, DF_REF_AT_TOP, and DF_UD_CHAIN.
Referenced by df_chain_create_bb().
void df_chain_dump | ( | ) |
Generic versions to get the void* version of the block info. Only used inside the problem instance vectors.
Dump a def-use or use-def chain for REF to FILE.
References DF_REF_IN_NOTE, df_link::next, and df_link::ref.
Referenced by debug_df_chain(), df_chain_bb_dump(), df_chain_insn_bottom_dump(), df_chain_insn_top_dump(), df_ref_debug(), and df_refs_chain_dump().
|
static |
Create def-use chains from reaching use bitmaps for basic blocks in BLOCKS.
References df_chain_create_bb().
|
static |
Free all storage associated with the problem.
References free(), and free_alloc_pool().
|
static |
Remove the chain problem completely.
References df_chain_remove_problem(), and free().
|
static |
References df_d::changeable_flags, df, df_chain_dump(), DF_DU_CHAIN, DF_NO_HARD_REGS, and DF_REF_READ_WRITE.
|
static |
References df_d::changeable_flags, df, df_chain_dump(), DF_NO_HARD_REGS, DF_REF_READ_WRITE, and DF_UD_CHAIN.
|
static |
Remove this problem from the stack of dataflow problems.
References bitmap_clear(), DF_DU_CHAIN, df_get_artificial_defs(), df_get_artificial_uses(), DF_UD_CHAIN, free_alloc_pool(), and basic_block_def::index.
Referenced by df_chain_alloc(), df_chain_fully_remove_problem(), and df_chain_reset().
|
static |
Reset all of the chains when the set of basic blocks changes.
References df_chain_remove_problem().
|
static |
References df_chain_bb_dump().
void df_chain_unlink | ( | ) |
Delete a du or ud chain that leave or point to REF.
References df_chain_unlink_1(), df_link::next, pool_free(), and df_link::ref.
Referenced by df_ref_chain_delete_du_chain(), and df_reg_chain_unlink().
|
static |
Delete any du or ud chains that start at REF and point to TARGET.
References df_link::next, pool_free(), and df_link::ref.
Referenced by df_chain_unlink().
|
static |
Create a REG_UNUSED note if necessary for DEF in INSN updating LIVE. Do not generate notes for registers in ARTIFICIAL_USES.
References bitmap_bit_p(), dead_debug_insert_temp(), DEBUG_TEMP_AFTER_WITH_REG, df_ignore_stack_reg(), df_print_note(), df_ref_debug(), DF_REF_MW_HARDREG, df_set_note(), and dump_file.
Referenced by df_note_bb_compute().
|
inlinestatic |
After reg-stack, the x86 floating point stack regs are difficult to analyze because of all of the pushes, pops and rotations. Thus, we just leave the notes alone.
References regstack_completed.
Referenced by df_create_unused_note(), df_note_bb_compute(), and df_remove_dead_and_unused_notes().
void df_live_add_problem | ( | void | ) |
Create a new DATAFLOW instance and add it to an existing instance of DF. The returned structure is what is used to get at the solution.
References df_add_problem(), and df_bitmap_obstack.
Referenced by do_reload(), if_convert(), initialize_uninitialized_regs(), reorg_loops(), and rest_of_handle_df_initialize().
|
static |
Allocate or reset bitmaps for DF_LIVE blocks. The solution bits are not touched unless the block is new.
References bitmap_obstack_initialize(), df_live_problem_data::in, df_live_problem_data::live_bitmaps, and df_live_problem_data::out.
|
static |
Compute local uninitialized register info for basic block BB.
References bitmap_set_bit(), df_get_artificial_defs(), df_insn_create_insn_record(), df_live_get_bb_info(), DF_REF_CONDITIONAL, DF_REF_MAY_CLOBBER, DF_REF_MUST_CLOBBER, DF_REF_PARTIAL, df_live_bb_info::gen, df_live_bb_info::kill, and df_insn_info::luid.
Referenced by df_live_local_compute(), and df_live_verify_transfer_functions().
|
static |
Debugging info at bottom of bb.
References df_live_get_bb_info(), df_print_regset(), basic_block_def::index, df_live_bb_info::out, and df_live_problem_data::out.
|
static |
Forward confluence function that ignores fake edges.
References bitmap_ior_into(), edge_def::dest, df_live_get_bb_info(), edge_def::flags, df_live_bb_info::in, basic_block_def::index, df_live_bb_info::out, and edge_def::src.
|
static |
And the LR info with the must-initialized registers, to produce the LIVE info.
References bitmap_and_into(), df_live_get_bb_info(), df_lr_get_bb_info(), df_lr_bb_info::in, df_live_bb_info::in, df_lr_bb_info::out, and df_live_bb_info::out.
|
static |
Free all storage associated with the problem.
References bitmap_clear(), bitmap_obstack_release(), free(), and df_live_problem_data::live_bitmaps.
|
static |
Free basic block info.
References bitmap_clear(), df_live_bb_info::gen, df_live_bb_info::in, df_live_bb_info::kill, and df_live_bb_info::out.
|
static |
Initialize the solution vectors.
References bitmap_and(), bitmap_clear(), df_live_get_bb_info(), df_lr_get_bb_info(), df_live_bb_info::gen, df_live_bb_info::in, df_lr_bb_info::out, and df_live_bb_info::out.
|
static |
Compute local uninitialized register info.
References bitmap_clear(), df_grow_insn_info(), and df_live_bb_local_compute().
|
static |
Reset the global solution for recalculation.
References bitmap_clear(), df_live_get_bb_info(), df_live_bb_info::in, and df_live_bb_info::out.
void df_live_set_all_dirty | ( | void | ) |
Set all of the blocks as dirty. This needs to be done if this problem is added after all of the insns have been scanned.
References bitmap_set_bit(), and basic_block_def::index.
Referenced by do_reload(), if_convert(), initialize_uninitialized_regs(), and reorg_loops().
|
static |
Debugging info at top of bb.
References df_live_get_bb_info(), df_print_regset(), df_live_bb_info::gen, df_live_bb_info::in, df_live_problem_data::in, basic_block_def::index, and df_live_bb_info::kill.
|
static |
Transfer function for the forwards must-initialized problem.
References bitmap_and(), bitmap_and_into(), bitmap_ior_and_compl(), df_live_get_bb_info(), df_lr_get_bb_info(), df_live_bb_info::gen, df_lr_bb_info::in, df_live_bb_info::in, df_live_bb_info::kill, df_lr_bb_info::out, and df_live_bb_info::out.
|
static |
Compare the saved datastructure and the new solution to the dataflow equations.
References bitmap_clear(), bitmap_equal_p(), free(), df_live_problem_data::in, basic_block_def::index, and df_live_problem_data::out.
|
static |
Build the datastructure to verify that the solution to the dataflow equations is not dirty.
References bitmap_copy(), df_live_problem_data::in, basic_block_def::index, df_live_problem_data::live_bitmaps, and df_live_problem_data::out.
void df_live_verify_transfer_functions | ( | void | ) |
Verify that all of the lr related info is consistent and correct.
References all_blocks, bitmap_bit_p(), bitmap_clear(), bitmap_copy(), bitmap_default_obstack, bitmap_equal_p(), bitmap_intersect_compl_p(), bitmap_set_bit(), df, df_grow_insn_info(), df_live_bb_local_compute(), df_live_get_bb_info(), df_scan_get_bb_info(), df_live_bb_info::gen, basic_block_def::index, and df_live_bb_info::kill.
Referenced by df_finish_pass(), and df_verify().
void df_lr_add_problem | ( | void | ) |
Create a new DATAFLOW instance and add it to an existing instance of DF. The returned structure is what is used to get at the solution.
References df_add_problem(), and df_bitmap_obstack.
Referenced by rest_of_handle_df_initialize().
|
static |
Allocate or reset bitmaps for DF_LR blocks. The solution bits are not touched unless the block is new.
References bitmap_obstack_initialize(), df_grow_bb_info(), df_lr_problem_data::in, df_lr_problem_data::lr_bitmaps, and df_lr_problem_data::out.
Referenced by df_lr_finalize().
|
static |
Compute local live register info for basic block BB.
References bitmap_clear_bit(), bitmap_set_bit(), df_lr_bb_info::def, df_get_artificial_defs(), df_get_artificial_uses(), df_lr_get_bb_info(), df_recompute_luids(), DF_REF_AT_TOP, DF_REF_CONDITIONAL, DF_REF_PARTIAL, and df_lr_bb_info::use.
Referenced by df_lr_local_compute(), and df_lr_verify_transfer_functions().
|
static |
Debugging info at bottom of bb.
References df_lr_get_bb_info(), df_print_regset(), basic_block_def::index, df_lr_problem_data::out, and df_lr_bb_info::out.
|
static |
Confluence function that processes infinite loops. This might be a noreturn function that throws. And even if it isn't, getting the unwind info right helps debugging.
References bitmap_copy(), df, df_lr_get_bb_info(), df_d::hardware_regs_used, basic_block_def::index, and df_lr_bb_info::out.
|
static |
Confluence function that ignores fake edges.
References bitmap_ior_and_compl_into(), bitmap_ior_into(), changed, edge_def::dest, df, df_lr_get_bb_info(), edge_def::flags, df_d::hardware_regs_used, df_lr_bb_info::in, basic_block_def::index, df_lr_bb_info::out, regs_invalidated_by_call_regset, and edge_def::src.
|
static |
Run the fast dce as a side effect of building LR.
References df_d::changeable_flags, df, df_clear_flags(), df_lr_alloc(), df_lr_local_compute(), DF_LR_RUN_DCE, df_set_flags(), df_worklist_dataflow(), df_d::n_blocks, df_d::postorder, and run_fast_df_dce().
|
static |
Free all storage associated with the problem.
References bitmap_obstack_release(), free(), and df_lr_problem_data::lr_bitmaps.
|
static |
Free basic block info.
References bitmap_clear(), df_lr_bb_info::def, df_lr_bb_info::in, df_lr_bb_info::out, and df_lr_bb_info::use.
|
static |
Initialize the solution vectors.
References bitmap_clear(), bitmap_copy(), df_lr_get_bb_info(), df_lr_bb_info::in, df_lr_bb_info::out, and df_lr_bb_info::use.
|
static |
Compute local live register info for each basic block within BLOCKS.
References bitmap_clear(), bitmap_copy(), bitmap_set_bit(), df, df_lr_bb_local_compute(), df_lr_get_bb_info(), df_d::exit_block_uses, global_regs, df_d::hardware_regs_used, reload_completed, and df_lr_bb_info::use.
Referenced by df_lr_finalize().
|
static |
Reset the global solution for recalculation.
References bitmap_clear(), df_lr_get_bb_info(), df_lr_bb_info::in, and df_lr_bb_info::out.
|
static |
Debugging info at top of bb.
References df_lr_bb_info::def, df_lr_get_bb_info(), df_print_regset(), df_lr_problem_data::in, df_lr_bb_info::in, basic_block_def::index, and df_lr_bb_info::use.
|
static |
Transfer function.
References bitmap_ior_and_compl(), df_lr_bb_info::def, df_lr_get_bb_info(), df_lr_bb_info::in, df_lr_bb_info::out, and df_lr_bb_info::use.
|
static |
Compare the saved datastructure and the new solution to the dataflow equations.
References bitmap_clear(), bitmap_equal_p(), free(), df_lr_problem_data::in, basic_block_def::index, and df_lr_problem_data::out.
|
static |
Build the datastructure to verify that the solution to the dataflow equations is not dirty.
References bitmap_copy(), df_lr_problem_data::in, basic_block_def::index, df_lr_problem_data::lr_bitmaps, and df_lr_problem_data::out.
void df_lr_verify_transfer_functions | ( | void | ) |
Verify that all of the lr related info is consistent and correct.
References all_blocks, bitmap_bit_p(), bitmap_clear(), bitmap_copy(), bitmap_default_obstack, bitmap_equal_p(), bitmap_intersect_compl_p(), bitmap_set_bit(), df_lr_bb_info::def, df, df_lr_bb_local_compute(), df_lr_get_bb_info(), df_scan_get_bb_info(), basic_block_def::index, and df_lr_bb_info::use.
Referenced by df_finish_pass(), and df_verify().
void df_md_add_problem | ( | void | ) |
Create a new MD instance and add it to the existing instance of DF.
References df_add_problem().
Referenced by build_single_def_use_links().
|
static |
Allocate or reset bitmaps for DF_MD. The solution bits are not touched unless the block is new.
References bitmap_obstack_initialize(), df_grow_bb_info(), and df_md_problem_data::md_bitmaps.
|
static |
Compute local multiple def info for basic block BB.
References df_d::changeable_flags, df, df_get_artificial_defs(), df_md_bb_local_compute_process_def(), df_md_get_bb_info(), DF_NO_HARD_REGS, and DF_REF_AT_TOP.
Referenced by df_md_local_compute().
|
static |
|
static |
Debugging info at bottom of bb.
References df_md_get_bb_info(), df_print_regset(), basic_block_def::index, and df_md_bb_info::out.
|
static |
References bitmap_copy(), df_md_get_bb_info(), df_md_bb_info::in, basic_block_def::index, and df_md_bb_info::init.
|
static |
In of target gets or of out of source.
References bitmap_ior_and_compl_into(), bitmap_ior_into(), edge_def::dest, df_md_get_bb_info(), edge_def::flags, df_md_bb_info::in, basic_block_def::index, df_md_bb_info::out, regs_invalidated_by_call_regset, and edge_def::src.
|
static |
Free all storage associated with the problem.
References bitmap_obstack_release(), free(), and df_md_problem_data::md_bitmaps.
|
static |
|
static |
Initialize the solution bit vectors for problem.
References bitmap_copy(), df_md_get_bb_info(), df_md_transfer_function(), df_md_bb_info::in, and df_md_bb_info::init.
|
static |
Compute local reaching def info for each basic block within BLOCKS.
References bitmap_bit_p(), bitmap_clear(), bitmap_default_obstack, bitmap_ior_and_into(), compute_dominance_frontiers(), df_get_live_in(), df_md_bb_local_compute(), df_md_get_bb_info(), free(), basic_block_def::index, df_md_bb_info::init, and df_md_bb_info::kill.
|
static |
Reset the global solution for recalculation.
References bitmap_clear(), df_md_get_bb_info(), df_md_bb_info::in, and df_md_bb_info::out.
void df_md_simulate_artificial_defs_at_top | ( | ) |
Add the effect of the top artificial defs of BB to the multiple definitions bitmap LOCAL_MD.
References bitmap_clear_bit(), bitmap_set_bit(), df_get_artificial_defs(), DF_REF_AT_TOP, DF_REF_CONDITIONAL, DF_REF_MAY_CLOBBER, DF_REF_PARTIAL, and basic_block_def::index.
void df_md_simulate_one_insn | ( | basic_block | bb, |
rtx | insn, | ||
bitmap | local_md | ||
) |
Add the effect of the defs of INSN to the reaching definitions bitmap LOCAL_MD.
References bitmap_clear_bit(), bitmap_set_bit(), df_d::changeable_flags, df, DF_NO_HARD_REGS, DF_REF_CONDITIONAL, DF_REF_MAY_CLOBBER, and DF_REF_PARTIAL.
|
static |
Debugging info at top of bb.
References df_md_get_bb_info(), df_print_regset(), df_md_bb_info::gen, df_md_bb_info::in, basic_block_def::index, df_md_bb_info::init, and df_md_bb_info::kill.
|
static |
References bitmap_and(), bitmap_and_into(), bitmap_ior_and_compl(), df_get_live_in(), df_get_live_out(), df_md_get_bb_info(), df_md_bb_info::gen, df_md_bb_info::in, df_md_bb_info::kill, and df_md_bb_info::out.
Referenced by df_md_init().
void df_note_add_problem | ( | void | ) |
Create a new DATAFLOW instance and add it to an existing instance of DF. The returned structure is what is used to get at the solution.
References df_add_problem().
Referenced by build_single_def_use_links(), cse_main(), ira(), iv_analysis_loop_init(), peephole2_optimize(), reg_to_stack(), regmove_optimize(), regrename_optimize(), rest_of_handle_auto_inc_dec(), rest_of_handle_combine(), rest_of_handle_dse(), rest_of_handle_stack_adjustments(), rest_of_pass_free_cfg(), and sched_init().
|
static |
|
static |
Recompute the REG_DEAD and REG_UNUSED notes and compute register info: lifetime, bb, and number of defs and uses for basic block BB. The three bitvectors are scratch regs used here.
References bitmap_bit_p(), bitmap_clear(), bitmap_clear_bit(), bitmap_copy(), bitmap_set_bit(), dead_debug_add(), dead_debug_insert_temp(), dead_debug_local_finish(), dead_debug_local_init(), debug_insn, DEBUG_TEMP_BEFORE_WITH_REG, df_create_unused_note(), df_get_artificial_defs(), df_get_artificial_uses(), df_get_live_out(), df_ignore_stack_reg(), df_insn_rescan_debug_internal(), df_print_note(), df_print_regset(), DF_REF_AT_TOP, DF_REF_CONDITIONAL, df_ref_debug(), DF_REF_MAY_CLOBBER, DF_REF_MUST_CLOBBER, DF_REF_MW_HARDREG, DF_REF_PARTIAL, DF_REF_READ_WRITE, df_remove_dead_and_unused_notes(), df_remove_dead_eq_notes(), df_set_dead_notes_for_mw(), df_set_note(), df_set_unused_notes_for_mw(), dump_file, and df_mw_hardreg::start_regno.
Referenced by df_note_compute().
|
static |
Compute register info: lifetime, bb, and number of defs and uses.
References bitmap_clear(), df_bitmap_obstack, df_note_bb_compute(), and live.
|
static |
Free all storage associated with the problem.
References free().
void df_print_bb_index | ( | ) |
Print some basic block info as part of df_dump.
References edge_def::dest, edge_def::flags, basic_block_def::index, basic_block_def::preds, edge_def::src, and basic_block_def::succs.
Referenced by df_dump(), and dse_step4().
|
static |
This is only used if REG_DEAD_DEBUGGING is in effect.
References dump_file, and print_rtl().
Referenced by df_create_unused_note(), df_note_bb_compute(), df_remove_dead_and_unused_notes(), df_remove_dead_eq_notes(), df_set_dead_notes_for_mw(), and df_set_unused_notes_for_mw().
void df_rd_add_problem | ( | void | ) |
Create a new RD instance and add it to the existing instance of DF.
References df_add_problem().
Referenced by sched_init().
|
static |
Allocate or reset bitmaps for DF_RD blocks. The solution bits are not touched unless the block is new.
References bitmap_clear(), bitmap_obstack_initialize(), df_rd_problem_data::dense_invalidated_by_call, df_grow_bb_info(), df_rd_get_bb_info(), df_rd_bb_info::gen, df_rd_bb_info::in, df_rd_bb_info::kill, bitmap_head_def::obstack, df_rd_bb_info::out, df_rd_problem_data::rd_bitmaps, df_rd_problem_data::sparse_invalidated_by_call, and df_rd_bb_info::sparse_kill.
|
static |
Compute local reaching def info for basic block BB.
References bitmap_clear(), bitmap_ior_into(), df_d::changeable_flags, df, df_get_artificial_defs(), DF_NO_HARD_REGS, df_rd_bb_local_compute_process_def(), df_rd_get_bb_info(), and DF_REF_AT_TOP.
Referenced by df_rd_local_compute().
|
static |
Process a list of DEFs for df_rd_bb_local_compute. This is a bit more complicated than just simulating, because we must produce the gen and kill sets and hence deal with the two possible representations of kill sets.
References bitmap_bit_p(), bitmap_clear_range(), bitmap_set_bit(), bitmap_set_range(), df_d::changeable_flags, df, DF_NO_HARD_REGS, DF_REF_AT_TOP, DF_REF_CONDITIONAL, DF_REF_MAY_CLOBBER, DF_REF_MUST_CLOBBER, DF_REF_PARTIAL, df_rd_bb_info::gen, df_rd_bb_info::kill, and df_rd_bb_info::sparse_kill.
Referenced by df_rd_bb_local_compute().
|
static |
Debugging info at bottom of bb.
References df_rd_dump_defs_set(), df_rd_get_bb_info(), basic_block_def::index, and df_rd_bb_info::out.
|
static |
In of target gets or of out of source.
References bitmap_and_compl_into(), bitmap_clear(), bitmap_clear_range(), bitmap_copy(), bitmap_ior_into(), changed, df_rd_problem_data::dense_invalidated_by_call, edge_def::dest, df_bitmap_obstack, df_rd_get_bb_info(), edge_def::flags, df_rd_bb_info::in, basic_block_def::index, df_rd_bb_info::out, df_rd_problem_data::sparse_invalidated_by_call, and edge_def::src.
|
static |
References bitmap_and_into(), bitmap_clear(), bitmap_count_bits(), bitmap_empty_p(), bitmap_set_range(), df_d::changeable_flags, df, df_bitmap_obstack, and DF_NO_HARD_REGS.
Referenced by df_rd_bottom_dump(), and df_rd_top_dump().
|
static |
Free all storage associated with the problem.
References bitmap_obstack_release(), free(), and df_rd_problem_data::rd_bitmaps.
|
static |
Free basic block info.
References bitmap_clear(), df_rd_bb_info::gen, df_rd_bb_info::in, df_rd_bb_info::kill, df_rd_bb_info::out, and df_rd_bb_info::sparse_kill.
|
static |
Initialize the solution bit vectors for problem.
References bitmap_clear(), bitmap_copy(), df_rd_get_bb_info(), df_rd_bb_info::gen, df_rd_bb_info::in, and df_rd_bb_info::out.
|
static |
Compute local reaching def info for each basic block within BLOCKS.
References bitmap_clear(), bitmap_set_bit(), bitmap_set_range(), df_d::changeable_flags, df_rd_problem_data::dense_invalidated_by_call, df, df_bitmap_obstack, df_maybe_reorganize_def_refs(), DF_NO_HARD_REGS, df_rd_bb_local_compute(), DF_REF_ORDER_BY_REG, regs_invalidated_by_call_regset, and df_rd_problem_data::sparse_invalidated_by_call.
void df_rd_simulate_artificial_defs_at_top | ( | ) |
Add the effect of the top artificial defs of BB to the reaching definitions bitmap LOCAL_RD.
References bitmap_clear_range(), bitmap_set_bit(), df_get_artificial_defs(), DF_REF_AT_TOP, DF_REF_CONDITIONAL, DF_REF_PARTIAL, and basic_block_def::index.
Referenced by df_chain_create_bb().
void df_rd_simulate_one_insn | ( | basic_block | bb, |
rtx | insn, | ||
bitmap | local_rd | ||
) |
Add the effect of the defs of INSN to the reaching definitions bitmap LOCAL_RD.
References bitmap_clear_range(), bitmap_set_bit(), df_d::changeable_flags, df, DF_NO_HARD_REGS, DF_REF_CONDITIONAL, DF_REF_MAY_CLOBBER, DF_REF_MUST_CLOBBER, and DF_REF_PARTIAL.
Referenced by df_chain_create_bb().
|
static |
Debugging info.
References df_rd_problem_data::dense_invalidated_by_call, df, dump_bitmap(), and df_rd_problem_data::sparse_invalidated_by_call.
|
static |
Debugging info at top of bb.
References df_rd_dump_defs_set(), df_rd_get_bb_info(), df_rd_bb_info::gen, df_rd_bb_info::in, basic_block_def::index, and df_rd_bb_info::kill.
|
static |
Transfer function.
References bitmap_and_compl_into(), bitmap_and_into(), bitmap_clear(), bitmap_clear_range(), bitmap_copy(), bitmap_empty_p(), bitmap_equal_p(), bitmap_ior_and_compl(), bitmap_ior_into(), bitmap_set_range(), df_d::changeable_flags, changed, df, df_bitmap_obstack, df_lr_get_bb_info(), df_rd_get_bb_info(), DF_RD_PRUNE_DEAD_DEFS, df_rd_bb_info::gen, df_rd_bb_info::in, df_rd_bb_info::kill, df_rd_bb_info::out, df_lr_bb_info::out, df_rd_problem_data::rd_bitmaps, and df_rd_bb_info::sparse_kill.
|
static |
Remove all of the REG_DEAD or REG_UNUSED notes from INSN.
References df_ignore_stack_reg(), df_print_note(), and free_EXPR_LIST_node().
Referenced by df_note_bb_compute().
|
static |
Remove REG_EQUAL/REG_EQUIV notes referring to dead pseudos using LIVE as the bitmap of currently live registers.
References bitmap_bit_p(), deleted, df_notes_rescan(), df_print_note(), DF_REF_IN_NOTE, free_EXPR_LIST_node(), and loc_mentioned_in_p().
Referenced by df_note_bb_compute().
|
static |
Set the REG_DEAD notes for the multiword hardreg use in INSN based on the bits in LIVE. DO_NOT_GEN is used to keep REG_DEAD notes from being set if the instruction both reads and writes the register.
References bitmap_bit_p(), df_print_note(), df_print_regset(), df_set_note(), df_whole_mw_reg_dead_p(), dump_file, df_mw_hardreg::end_regno, df_mw_hardreg::mw_reg, regno_reg_rtx, and df_mw_hardreg::start_regno.
Referenced by df_note_bb_compute().
|
inlinestatic |
Set a NOTE_TYPE note for REG in INSN.
References add_reg_note().
Referenced by df_create_unused_note(), df_note_bb_compute(), df_set_dead_notes_for_mw(), and df_set_unused_notes_for_mw().
|
static |
Set the REG_UNUSED notes for the multiword hardreg defs in INSN based on the bits in LIVE. Do not generate notes for registers in artificial uses. DO_NOT_GEN is updated so that REG_DEAD notes are not generated if the reg is both read and written by the instruction.
References bitmap_bit_p(), bitmap_set_bit(), dead_debug_insert_temp(), DEBUG_TEMP_AFTER_WITH_REG, df_print_note(), df_set_note(), df_whole_mw_reg_unused_p(), dump_file, df_mw_hardreg::end_regno, df_mw_hardreg::mw_reg, regno_reg_rtx, and df_mw_hardreg::start_regno.
Referenced by df_note_bb_compute().
void df_simulate_defs | ( | ) |
Simulate the effects of the defs of INSN on LIVE.
References bitmap_clear_bit(), DF_REF_CONDITIONAL, and DF_REF_PARTIAL.
Referenced by can_move_insns_across(), dce_process_block(), and df_simulate_one_insn_backwards().
void df_simulate_finalize_backwards | ( | ) |
Apply the artificial uses and defs at the top of BB in a backwards direction.
References bitmap_clear_bit(), bitmap_set_bit(), df_get_artificial_defs(), df_get_artificial_uses(), DF_REF_AT_TOP, and basic_block_def::index.
Referenced by dce_process_block().
void df_simulate_find_defs | ( | ) |
Find the set of DEFs for INSN.
References bitmap_set_bit().
Referenced by can_move_insns_across(), dead_or_predicable(), and find_comparisons_in_bb().
void df_simulate_find_noclobber_defs | ( | ) |
Find the set of real DEFs, which are not clobbers, for INSN.
References bitmap_set_bit(), DF_REF_MAY_CLOBBER, and DF_REF_MUST_CLOBBER.
Referenced by df_simulate_one_insn_forwards().
|
static |
Find the set of uses for INSN. This includes partial defs.
References bitmap_set_bit(), DF_REF_CONDITIONAL, and DF_REF_PARTIAL.
Referenced by can_move_insns_across().
|
inlinestatic |
Add back the always live regs in BB to LIVE.
References bb_has_eh_pred(), bitmap_ior_into(), df, df_d::eh_block_artificial_uses, and df_d::regular_block_artificial_uses.
Referenced by df_simulate_one_insn_backwards(), and df_simulate_one_insn_forwards().
void df_simulate_initialize_backwards | ( | ) |
Apply the artificial uses and defs at the end of BB in a backwards direction.
References bitmap_clear_bit(), bitmap_set_bit(), df_get_artificial_defs(), df_get_artificial_uses(), DF_REF_AT_TOP, and basic_block_def::index.
Referenced by can_move_insns_across(), dce_process_block(), and simulate_backwards_to_point().
void df_simulate_initialize_forwards | ( | ) |
Initialize the LIVE bitmap, which should be copied from DF_LIVE_IN or DF_LR_IN for basic block BB, for forward scanning by marking artificial defs live.
References bitmap_set_bit(), df_get_artificial_defs(), DF_REF_AT_TOP, and basic_block_def::index.
Referenced by dse_step1(), and peephole2_optimize().
void df_simulate_one_insn_backwards | ( | ) |
Simulate the backwards effects of INSN on the bitmap LIVE.
References df_simulate_defs(), df_simulate_fixup_sets(), and df_simulate_uses().
Referenced by can_move_insns_across(), peep2_update_life(), propagate_lv_set(), simulate_backwards_to_point(), and try_head_merge_bb().
void df_simulate_one_insn_forwards | ( | ) |
Simulate the forwards effects of INSN on the bitmap LIVE.
References bitmap_clear_bit(), bitmap_clear_range(), df_simulate_find_noclobber_defs(), and df_simulate_fixup_sets().
Referenced by dse_step1(), peep2_fill_buffer(), and single_def_use_enter_block().
void df_simulate_uses | ( | ) |
Simulate the effects of the uses of INSN on LIVE.
References bitmap_set_bit().
Referenced by can_move_insns_across(), dce_process_block(), dead_or_predicable(), and df_simulate_one_insn_backwards().
|
static |
A subroutine of df_set_dead_notes_for_mw, with a selection of its arguments. Return true if the register value described by MWS's mw_reg is known to be completely dead, and if mw_reg can therefore be used in a REG_DEAD note.
References bitmap_bit_p(), DF_REF_PARTIAL, df_mw_hardreg::flags, df_mw_hardreg::mw_reg, and df_mw_hardreg::start_regno.
Referenced by df_set_dead_notes_for_mw().
|
static |
A subroutine of df_set_unused_notes_for_mw, with a selection of its arguments. Return true if the register value described by MWS's mw_reg is known to be completely unused, and if mw_reg can therefore be used in a REG_UNUSED note.
References bitmap_bit_p(), DF_REF_PARTIAL, df_mw_hardreg::flags, df_mw_hardreg::mw_reg, and df_mw_hardreg::start_regno.
Referenced by df_set_unused_notes_for_mw().
void df_word_lr_add_problem | ( | void | ) |
Create a new DATAFLOW instance and add it to an existing instance of DF. The returned structure is what is used to get at the solution.
References df_add_problem(), and df_bitmap_obstack.
Referenced by run_word_dce().
|
static |
Allocate or reset bitmaps for DF_WORD_LR blocks. The solution bits are not touched unless the block is new.
References bitmap_clear(), bitmap_obstack_initialize(), bitmap_set_bit(), df_word_lr_bb_info::def, df_grow_bb_info(), df_word_lr_get_bb_info(), df_word_lr_bb_info::in, basic_block_def::index, bitmap_head_def::obstack, df_word_lr_bb_info::out, df_word_lr_bb_info::use, and df_word_lr_problem_data::word_lr_bitmaps.
|
static |
Compute local live register info for basic block BB.
References df_word_lr_bb_info::def, df_get_artificial_defs(), df_get_artificial_uses(), DF_REF_CONDITIONAL, df_word_lr_get_bb_info(), df_word_lr_mark_ref(), and df_word_lr_bb_info::use.
Referenced by df_word_lr_local_compute().
|
static |
Debugging info at bottom of bb.
References df_print_word_regset(), df_word_lr_get_bb_info(), basic_block_def::index, and df_word_lr_bb_info::out.
|
static |
Confluence function that ignores fake edges.
References bitmap_ior_into(), edge_def::dest, df_word_lr_get_bb_info(), df_word_lr_bb_info::in, basic_block_def::index, df_word_lr_bb_info::out, and edge_def::src.
|
static |
Free all storage associated with the problem.
References bitmap_obstack_release(), free(), and df_word_lr_problem_data::word_lr_bitmaps.
|
static |
Free basic block info.
References bitmap_clear(), df_word_lr_bb_info::def, df_word_lr_bb_info::in, df_word_lr_bb_info::out, and df_word_lr_bb_info::use.
|
static |
Initialize the solution vectors.
References bitmap_clear(), bitmap_copy(), df_word_lr_get_bb_info(), df_word_lr_bb_info::in, df_word_lr_bb_info::out, and df_word_lr_bb_info::use.
|
static |
Compute local live register info for each basic block within BLOCKS.
References bitmap_clear(), df, df_word_lr_bb_local_compute(), and df_d::exit_block_uses.
bool df_word_lr_mark_ref | ( | ) |
Examine REF, and if it is for a reg we're interested in, set or clear the bits corresponding to its subwords from the bitmap according to IS_SET. LIVE is the bitmap we should update. We do not track hard regs or pseudos of any size other than 2 * UNITS_PER_WORD. We return true if we changed the bitmap, or if we encountered a register we're not tracking.
References bitmap_clear_bit(), bitmap_set_bit(), changed, df_read_modify_subreg_p(), DF_REF_PARTIAL, reg_mode, and subreg_lowpart_p().
Referenced by df_word_lr_bb_local_compute(), df_word_lr_simulate_defs(), and df_word_lr_simulate_uses().
|
static |
Reset the global solution for recalculation.
References bitmap_clear(), df_word_lr_get_bb_info(), df_word_lr_bb_info::in, and df_word_lr_bb_info::out.
bool df_word_lr_simulate_defs | ( | ) |
Simulate the effects of the defs of INSN on LIVE. Return true if we changed any bits, which is used by the caller to determine whether a set is necessary. We also return true if there are other reasons not to delete an insn.
References changed, DF_REF_CONDITIONAL, and df_word_lr_mark_ref().
Referenced by word_dce_process_block().
void df_word_lr_simulate_uses | ( | ) |
Simulate the effects of the uses of INSN on LIVE.
References df_word_lr_mark_ref().
Referenced by word_dce_process_block().
|
static |
Debugging info at top of bb.
References df_word_lr_bb_info::def, df_print_word_regset(), df_word_lr_get_bb_info(), df_word_lr_bb_info::in, basic_block_def::index, and df_word_lr_bb_info::use.
|
static |
Transfer function.
References bitmap_ior_and_compl(), df_word_lr_bb_info::def, df_word_lr_get_bb_info(), df_word_lr_bb_info::in, df_word_lr_bb_info::out, and df_word_lr_bb_info::use.
|
static |
A subroutine of can_move_insns_across_p called through for_each_rtx. Return either MEMREF_NORMAL or MEMREF_VOLATILE if a memory is found.
Referenced by can_move_insns_across().
A subroutine of can_move_insns_across_p called through note_stores. DATA points to an integer in which we set either the bit for MEMREF_NORMAL or the bit for MEMREF_VOLATILE if we find a MEM of either kind.
References pflags.
Referenced by can_move_insns_across().
void simulate_backwards_to_point | ( | ) |
Scan BB backwards, using df_simulate functions to keep track of lifetimes, up to insn POINT. The result is stored in LIVE.
References bitmap_copy(), df_get_live_out(), df_simulate_initialize_backwards(), and df_simulate_one_insn_backwards().
Referenced by dead_or_predicable(), and try_head_merge_bb().
|
static |
Scratch var used by transfer functions. This is used to implement an optimization to reduce the amount of space used to compute the combined lr and live analysis.
|
static |
Scratch var used by transfer functions. This is used to do md analysis only for live registers.
|
static |
|
static |
All of the information associated with every instance of the problem.
|
static |
All of the information associated with every instance of the problem.
|
static |
|
static |
All of the information associated every instance of the problem.
|
static |
All of the information associated with every instance of the problem.
|
static |
All of the information associated with every instance of the problem.
|
static |
|
static |