GCC Middle and Back End API Reference
|
Go to the source code of this file.
Data Structures | |
struct | ipa_known_type_data |
struct | ipa_constant_data |
struct | ipa_pass_through_data |
struct | ipa_ancestor_jf_data |
struct | ipa_agg_jf_item |
struct | ipa_agg_jump_function |
struct | ipa_jump_func |
union | ipa_jump_func::jump_func_value |
struct | ipa_param_descriptor |
struct | ipa_node_params |
struct | ipa_agg_replacement_value |
struct | ipa_edge_args |
struct | ipa_parm_adjustment |
Typedefs | |
typedef struct ipa_agg_jf_item | ipa_agg_jf_item_t |
typedef struct ipa_agg_jump_function * | ipa_agg_jump_function_p |
typedef struct ipa_agg_jump_function | ipa_agg_jump_function_t |
typedef struct ipa_jump_func | ipa_jump_func_t |
typedef struct ipa_param_descriptor | ipa_param_descriptor_t |
typedef struct ipa_agg_replacement_value * | ipa_agg_replacement_value_p |
typedef struct ipa_edge_args | ipa_edge_args_t |
typedef struct ipa_node_params | ipa_node_params_t |
typedef struct ipa_parm_adjustment | ipa_parm_adjustment_t |
typedef vec < ipa_parm_adjustment_t > | ipa_parm_adjustment_vec |
Enumerations | |
enum | jump_func_type { IPA_JF_UNKNOWN = 0, IPA_JF_KNOWN_TYPE, IPA_JF_CONST, IPA_JF_PASS_THROUGH, IPA_JF_ANCESTOR } |
typedef struct ipa_agg_jf_item ipa_agg_jf_item_t |
An element in an aggegate part of a jump function describing a known value at a given offset. When it is part of a pass-through jump function with agg_preserved set or an ancestor jump function with agg_preserved set, all unlisted positions are assumed to be preserved but the value can be a type node, which means that the particular piece (starting at offset and having the size of the type) is clobbered with an unknown value. When agg_preserved is false or the type of the containing jump function is different, all unlisted parts are assumed to be unknown and all values must fulfill is_gimple_ip_invariant.
typedef struct ipa_agg_jump_function* ipa_agg_jump_function_p |
typedef struct ipa_agg_jump_function ipa_agg_jump_function_t |
typedef struct ipa_agg_replacement_value* ipa_agg_replacement_value_p |
typedef struct ipa_edge_args ipa_edge_args_t |
ipa_edge_args stores information related to a callsite and particularly its arguments. It can be accessed by the IPA_EDGE_REF macro.
typedef struct ipa_jump_func ipa_jump_func_t |
A jump function for a callsite represents the values passed as actual arguments of the callsite. See enum jump_func_type for the various types of jump functions supported.
typedef struct ipa_node_params ipa_node_params_t |
Vectors need to have typedefs of structures.
typedef struct ipa_param_descriptor ipa_param_descriptor_t |
typedef struct ipa_parm_adjustment ipa_parm_adjustment_t |
enum jump_func_type |
ipa-prop.c stuff (ipa-cp, indirect inlining):
A jump function for a callsite represents the values passed as actual arguments of the callsite. They were originally proposed in a paper called "Interprocedural Constant Propagation", by David Callahan, Keith D Cooper, Ken Kennedy, Linda Torczon in Comp86, pg 152-161. There are three main types of values : Pass-through - the caller's formal parameter is passed as an actual argument, possibly one simple operation performed on it. Constant - a constant (is_gimple_ip_invariant)is passed as an actual argument. Unknown - neither of the above. IPA_JF_ANCESTOR is a special pass-through jump function, which means that the result is an address of a part of the object pointed to by the formal parameter to which the function refers. It is mainly intended to represent getting addresses of of ancestor fields in C++ (e.g. &this_1(D)->D.1766.D.1756). Note that if the original pointer is NULL, ancestor jump function must behave like a simple pass-through. Other pass-through functions can either simply pass on an unchanged formal parameter or can apply one simple binary operation to it (such jump functions are called polynomial). IPA_JF_KNOWN_TYPE is a special type of an "unknown" function that applies only to pointer parameters. It means that even though we cannot prove that the passed value is an interprocedural constant, we still know the exact type of the containing object which may be valuable for devirtualization. Jump functions are computed in ipa-prop.c by function update_call_notes_after_inlining. Some information can be lost and jump functions degraded accordingly when inlining, see update_call_notes_after_inlining in the same file.
tree build_ref_for_offset | ( | location_t | loc, |
tree | base, | ||
HOST_WIDE_INT | offset, | ||
tree | exp_type, | ||
gimple_stmt_iterator * | gsi, | ||
bool | insert_after | ||
) |
From tree-sra.c:
Construct a MEM_REF that would reference a part of aggregate BASE of type EXP_TYPE at the given OFFSET. If BASE is something for which get_addr_base_and_unit_offset returns NULL, gsi must be non-NULL and is used to insert new statements either before or below the current one as specified by INSERT_AFTER. This function is not capable of handling bitfields. BASE must be either a declaration or a memory reference that has correct alignment ifformation embeded in it (e.g. a pre-existing one in SRA).
References build_aligned_type(), build_int_cst(), build_pointer_type(), get_addr_base_and_unit_offset(), get_object_alignment_1(), gimple_set_location(), gsi_insert_after(), gsi_insert_before(), GSI_NEW_STMT, GSI_SAME_STMT, HOST_WIDE_INT, int_const_binop(), make_ssa_name(), offset, reference_alias_ptr_type(), and unshare_expr().
Referenced by analyze_access_subtree(), build_ref_for_model(), and ipa_get_jf_ancestor_result().
void ipa_analyze_node | ( | struct cgraph_node * | ) |
Functions related to both.
tree ipa_binfo_from_known_type_jfunc | ( | struct ipa_jump_func * | ) |
|
inlinestatic |
This function ensures the array of edge arguments infos is big enough to accommodate a structure for all edges and reallocates it if not.
References cgraph_edge_max_uid, vec_safe_grow_cleared(), and vec_safe_length().
Referenced by ipa_analyze_node(), ipa_edge_duplication_hook(), ipa_prop_read_jump_functions(), ipa_update_after_lto_read(), ipcp_driver(), and update_indirect_edges_after_inlining().
|
inlinestatic |
This function ensures the array of node param infos is big enough to accommodate a structure for all nodes and reallocates it if not.
References cgraph_max_uid, and ipa_node_params_vector.
Referenced by ipa_analyze_node(), ipa_make_edge_direct_to_target(), ipa_node_duplication_hook(), ipa_prop_read_jump_functions(), ipa_update_after_lto_read(), and ipcp_driver().
ipa_parm_adjustment_vec ipa_combine_adjustments | ( | ipa_parm_adjustment_vec | inner, |
ipa_parm_adjustment_vec | outer | ||
) |
Return adjustments that should have the same effect on function parameters and call arguments as if they were first changed according to adjustments in INNER and then by adjustments in OUTER.
References ipa_parm_adjustment::base_index, ipa_parm_adjustment::copy_param, index_in_adjustments_multiple_times_p(), memset(), ipa_parm_adjustment::offset, ipa_parm_adjustment::remove_param, and ipa_parm_adjustment::type.
void ipa_create_all_edge_args | ( | void | ) |
void ipa_create_all_node_params | ( | void | ) |
Creating and freeing ipa_node_params and ipa_edge_args.
void ipa_dump_agg_replacement_values | ( | FILE * | f, |
struct ipa_agg_replacement_value * | av | ||
) |
void ipa_dump_param | ( | FILE * | , |
struct ipa_node_params * | info, | ||
int | i | ||
) |
void ipa_dump_param_adjustments | ( | FILE * | file, |
ipa_parm_adjustment_vec | adjustments, | ||
tree | fndecl | ||
) |
Dump the adjustments in the vector ADJUSTMENTS to dump_file in a human friendly way, assuming they are meant to be applied to FNDECL.
References ipa_parm_adjustment::base, ipa_parm_adjustment::base_index, ipa_parm_adjustment::by_ref, ipa_parm_adjustment::copy_param, first, ipa_get_vector_of_formal_parms(), len, ipa_parm_adjustment::new_ssa_base, ipa_parm_adjustment::offset, print_generic_expr(), print_node_brief(), ipa_parm_adjustment::reduction, ipa_parm_adjustment::remove_param, and ipa_parm_adjustment::type.
Referenced by ipa_early_sra().
|
inlinestatic |
Returns true if the array of edge infos is large enough to accommodate an info for EDGE. The main purpose of this function is that debug dumping function can check info availability without causing reallocations.
References cgraph_edge::uid, and vec_safe_length().
Referenced by ipa_print_node_jump_functions().
tree ipa_find_agg_cst_for_param | ( | struct ipa_agg_jump_function * | agg, |
HOST_WIDE_INT | offset, | ||
bool | by_ref | ||
) |
Aggregate jump function related functions.
Retrieve value from aggregate jump function AGG for the given OFFSET or return NULL if there is not any. BY_REF specifies whether the value has to be passed by reference or by value.
References ipa_agg_jump_function::by_ref, is_gimple_ip_invariant(), ipa_agg_jump_function::items, ipa_agg_jf_item::offset, and ipa_agg_jf_item::value.
Referenced by evaluate_conditions_for_known_args(), ipa_get_indirect_edge_target_1(), and try_make_edge_direct_simple_call().
void ipa_free_all_edge_args | ( | void | ) |
Free all ipa_edge structures.
References ipa_free_edge_args_substructures(), and vec_free().
Referenced by ipa_free_all_structures_after_iinln(), and ipa_free_all_structures_after_ipa_cp().
void ipa_free_all_node_params | ( | void | ) |
Free all ipa_node_params structures.
References ipa_free_node_params_substructures().
Referenced by ipa_free_all_structures_after_iinln(), and ipa_free_all_structures_after_ipa_cp().
void ipa_free_all_structures_after_iinln | ( | void | ) |
Free all ipa_node_params and all ipa_edge_args structures if they are no longer needed after indirect inlining.
References free_alloc_pool(), ipa_free_all_edge_args(), ipa_free_all_node_params(), ipa_unregister_cgraph_hooks(), ipcp_agg_lattice_pool, ipcp_sources_pool, and ipcp_values_pool.
Referenced by ipa_inline().
void ipa_free_all_structures_after_ipa_cp | ( | void | ) |
Free all ipa_node_params and all ipa_edge_args structures if they are no longer needed after ipa-cp.
References free_alloc_pool(), ipa_free_all_edge_args(), ipa_free_all_node_params(), ipa_unregister_cgraph_hooks(), ipcp_agg_lattice_pool, ipcp_sources_pool, and ipcp_values_pool.
Referenced by ipcp_driver().
void ipa_free_edge_args_substructures | ( | struct ipa_edge_args * | ) |
void ipa_free_node_params_substructures | ( | struct ipa_node_params * | ) |
|
staticread |
Return the aggregate replacements for NODE, if there are any.
References cgraph_node::uid, and vec_safe_length().
Referenced by agg_replacements_to_vector(), cgraph_edge_brings_all_agg_vals_for_node(), get_clone_agg_value(), intersect_with_agg_replacements(), ipa_node_duplication_hook(), ipa_prop_write_all_agg_replacement(), ipcp_transform_function(), and write_agg_replacement_chain().
|
inlinestatic |
Return how many uses described by ipa-prop a parameter has or IPA_UNDESCRIBED_USE if there is a use that is not described by these structures.
References ipa_node_params::descriptors.
Referenced by ipa_print_node_params(), ipa_write_node_info(), ipcp_discover_new_direct_edges(), and propagate_controlled_uses().
|
inlinestatic |
ipa_edge_args access functions. Please use these to access fields that are or will be shared among various passes.
Return the number of actual arguments.
References ipa_edge_args::jump_functions, and vec_safe_length().
Referenced by cgraph_edge_brings_all_agg_vals_for_node(), cgraph_edge_brings_all_scalars_for_node(), evaluate_properties_for_edge(), find_aggregate_values_for_callers_subset(), find_more_scalar_values_for_callers_subset(), inline_merge_summary(), ipa_print_node_jump_functions_for_edge(), ipa_read_node_info(), ipa_write_node_info(), propagate_constants_accross_call(), propagate_controlled_uses(), remap_edge_change_prob(), update_indirect_edges_after_inlining(), and update_jump_functions_after_inlining().
tree ipa_get_indirect_edge_target | ( | struct cgraph_edge * | ie, |
vec< tree > | known_vals, | ||
vec< tree > | known_binfos, | ||
vec< ipa_agg_jump_function_p > | known_aggs | ||
) |
Indirect edge and binfo processing.
If an indirect edge IE can be turned into a direct one based on KNOWN_VALS (which can contain both constants and binfos), KNOWN_BINFOS (which can be NULL) or KNOWN_AGGS (which also can be NULL) return the destination.
References ipa_get_indirect_edge_target_1().
Referenced by devirtualization_time_bonus(), and estimate_edge_devirt_benefit().
|
staticread |
Returns a pointer to the jump function for the ith argument. Please note there is no setter function as jump functions are all set up in ipa_compute_jump_functions.
References ipa_edge_args::jump_functions.
Referenced by cgraph_edge_brings_all_scalars_for_node(), evaluate_properties_for_edge(), find_more_scalar_values_for_callers_subset(), inline_merge_summary(), intersect_aggregates_with_edge(), ipa_compute_jump_functions_for_edge(), ipa_edge_duplication_hook(), ipa_print_node_jump_functions_for_edge(), ipa_read_node_info(), ipa_write_node_info(), propagate_constants_accross_call(), propagate_controlled_uses(), remap_edge_change_prob(), update_indirect_edges_after_inlining(), and update_jump_functions_after_inlining().
|
inlinestatic |
Return the agg_preserved flag of an ancestor jump functin JFUNC.
References ipa_ancestor_jf_data::agg_preserved, ipa_jump_func::jump_func_value::ancestor, IPA_JF_ANCESTOR, ipa_jump_func::type, and ipa_jump_func::value.
Referenced by inline_merge_summary(), intersect_aggregates_with_edge(), ipa_compute_jump_functions_for_edge(), propagate_aggs_accross_jump_function(), and update_indirect_edges_after_inlining().
|
inlinestatic |
Return the number of the caller's formal parameter that an ancestor jump function JFUNC refers to.
References ipa_jump_func::jump_func_value::ancestor, ipa_ancestor_jf_data::formal_id, IPA_JF_ANCESTOR, ipa_jump_func::type, and ipa_jump_func::value.
Referenced by inline_merge_summary(), intersect_aggregates_with_edge(), ipa_value_from_jfunc(), propagate_aggs_accross_jump_function(), propagate_scalar_accross_jump_function(), and update_indirect_edges_after_inlining().
|
inlinestatic |
Return the offset of an ancestor jump function JFUNC.
References ipa_jump_func::jump_func_value::ancestor, IPA_JF_ANCESTOR, ipa_ancestor_jf_data::offset, ipa_jump_func::type, and ipa_jump_func::value.
Referenced by combine_known_type_and_ancestor_jfs(), inline_merge_summary(), intersect_aggregates_with_edge(), ipa_get_jf_ancestor_result(), propagate_aggs_accross_jump_function(), and update_indirect_edges_after_inlining().
|
inlinestatic |
Return the result type of an ancestor jump function JFUNC.
References ipa_jump_func::jump_func_value::ancestor, IPA_JF_ANCESTOR, ipa_ancestor_jf_data::type, ipa_jump_func::type, and ipa_jump_func::value.
Referenced by combine_known_type_and_ancestor_jfs(), and ipa_get_jf_ancestor_result().
|
inlinestatic |
Return the constant stored in a constant jump functin JFUNC.
References ipa_jump_func::jump_func_value::constant, IPA_JF_CONST, ipa_jump_func::type, ipa_constant_data::value, and ipa_jump_func::value.
Referenced by ipa_value_from_jfunc(), propagate_controlled_uses(), and propagate_scalar_accross_jump_function().
|
staticread |
References ipa_jump_func::jump_func_value::constant, IPA_JF_CONST, ipa_constant_data::rdesc, ipa_jump_func::type, and ipa_jump_func::value.
Referenced by jfunc_rdesc_usable().
|
inlinestatic |
Return the base type of a known type jump function JFUNC.
References ipa_known_type_data::base_type, IPA_JF_KNOWN_TYPE, ipa_jump_func::jump_func_value::known_type, ipa_jump_func::type, and ipa_jump_func::value.
Referenced by combine_known_type_and_ancestor_jfs().
|
inlinestatic |
Return the component type of a known type jump function JFUNC.
References ipa_known_type_data::component_type, IPA_JF_KNOWN_TYPE, ipa_jump_func::jump_func_value::known_type, ipa_jump_func::type, and ipa_jump_func::value.
|
inlinestatic |
Return the offset of the component that is described by a known type jump function JFUNC.
References IPA_JF_KNOWN_TYPE.
Referenced by combine_known_type_and_ancestor_jfs().
|
inlinestatic |
Return the agg_preserved flag of a pass through jump functin JFUNC.
References ipa_pass_through_data::agg_preserved, IPA_JF_PASS_THROUGH, ipa_jump_func::jump_func_value::pass_through, ipa_jump_func::type, and ipa_jump_func::value.
Referenced by agg_pass_through_permissible_p(), inline_merge_summary(), ipa_compute_jump_functions_for_edge(), and update_indirect_edges_after_inlining().
|
inlinestatic |
Return the number of the caller's formal parameter that a pass through jump function JFUNC refers to.
References ipa_pass_through_data::formal_id, IPA_JF_PASS_THROUGH, ipa_jump_func::jump_func_value::pass_through, ipa_jump_func::type, and ipa_jump_func::value.
Referenced by inline_merge_summary(), intersect_aggregates_with_edge(), ipa_value_from_jfunc(), propagate_aggs_accross_jump_function(), propagate_controlled_uses(), propagate_scalar_accross_jump_function(), remap_edge_change_prob(), and update_indirect_edges_after_inlining().
|
inlinestatic |
Return the operand of a pass through jmp function JFUNC.
References IPA_JF_PASS_THROUGH, ipa_pass_through_data::operand, ipa_jump_func::jump_func_value::pass_through, ipa_jump_func::type, and ipa_jump_func::value.
Referenced by ipa_get_jf_pass_through_result().
|
inlinestatic |
Return operation of a pass through jump function JFUNC.
References IPA_JF_PASS_THROUGH, ipa_pass_through_data::operation, ipa_jump_func::jump_func_value::pass_through, ipa_jump_func::type, and ipa_jump_func::value.
Referenced by inline_merge_summary(), intersect_aggregates_with_edge(), ipa_get_jf_pass_through_result(), propagate_aggs_accross_jump_function(), propagate_controlled_uses(), propagate_vals_accross_pass_through(), and update_indirect_edges_after_inlining().
|
inlinestatic |
Return the declaration of Ith formal parameter of the function corresponding to INFO. Note there is no setter function as this array is built just once using ipa_initialize_node_params.
References ipa_node_params::descriptors.
Referenced by inline_node_duplication_hook(), and ipa_analyze_params_uses().
|
inlinestatic |
ipa_node_params access functions. Please use these to access fields that are or will be shared among various passes.
Return the number of formal parameters.
References ipa_node_params::descriptors.
Referenced by add_all_node_vals_to_toposort(), cgraph_edge_brings_all_agg_vals_for_node(), cgraph_edge_brings_all_scalars_for_node(), create_specialized_node(), decide_whether_version_node(), estimate_local_effects(), find_aggregate_values_for_callers_subset(), find_more_scalar_values_for_callers_subset(), gather_context_independent_values(), initialize_node_lattices(), inline_merge_summary(), inline_node_duplication_hook(), ipa_analyze_node(), ipa_analyze_params_uses(), ipa_get_parm_lattices(), ipa_print_node_params(), ipa_read_node_info(), ipa_write_node_info(), ipcp_propagate_stage(), ipcp_verify_propagated_values(), print_all_lattices(), propagate_constants_accross_call(), and propagate_controlled_uses().
int ipa_get_param_decl_index | ( | struct ipa_node_params * | , |
tree | |||
) |
|
inlinestatic |
Return the move cost of Ith formal parameter of the function corresponding to INFO.
References ipa_node_params::descriptors.
Referenced by gather_context_independent_values(), and ipa_write_node_info().
void ipa_initialize_node_params | ( | struct cgraph_node * | node | ) |
Function formal parameters related computations.
|
inlinestatic |
Return the used flag corresponding to the Ith formal parameter of the function associated with INFO.
References ipa_node_params::descriptors.
Referenced by create_specialized_node(), gather_context_independent_values(), ipa_print_node_params(), and ipa_write_node_info().
bool ipa_load_from_parm_agg | ( | struct ipa_node_params * | info, |
gimple | stmt, | ||
tree | op, | ||
int * | index_p, | ||
HOST_WIDE_INT * | offset_p, | ||
bool * | by_ref_p | ||
) |
Just like the previous function, just without the param_analysis_info pointer, for users outside of this file.
References ipa_node_params::descriptors, and ipa_load_from_parm_agg_1().
Referenced by unmodified_parm_or_parm_agg_item().
|
read |
void ipa_modify_call_arguments | ( | struct cgraph_edge * | cs, |
gimple | stmt, | ||
ipa_parm_adjustment_vec | adjustments | ||
) |
Modify actual arguments of a function call CS as indicated in ADJUSTMENTS. If this is a directly recursive call, CS must be NULL. Otherwise it must contain the corresponding call graph edge.
References ipa_parm_adjustment::alias_ptr_type, ipa_parm_adjustment::base, ipa_parm_adjustment::base_index, build_aligned_type(), build_int_cst(), ipa_parm_adjustment::by_ref, cgraph_edge::callee, CDI_DOMINATORS, cgraph_get_node(), cgraph_set_call_stmt(), ipa_parm_adjustment::copy_param, current_function_decl, symtab_node_base::decl, decl_debug_args_insert(), dump_file, dump_flags, fold_convert_loc(), fold_convertible_p(), force_gimple_operand_gsi(), free_dominance_info(), get_addr_base_and_unit_offset(), get_pointer_alignment_1(), gimple_block(), gimple_build_call_vec(), gimple_call_arg(), gimple_call_chain(), gimple_call_copy_flags(), gimple_call_fndecl(), gimple_call_lhs(), gimple_call_set_chain(), gimple_call_set_lhs(), gimple_has_location(), gimple_location(), gimple_set_block(), gimple_set_location(), gsi_end_p(), gsi_for_stmt(), gsi_insert_before(), gsi_prev(), gsi_replace(), GSI_SAME_STMT, gsi_stmt(), HOST_WIDE_INT, int_const_binop(), ipa_record_stmt_references(), ipa_remove_stmt_references(), is_gimple_reg_type(), len, double_int::low, ipa_parm_adjustment::offset, print_gimple_stmt(), ipa_parm_adjustment::remove_param, double_int::sext(), cgraph_node::symbol, tree_to_double_int(), ipa_parm_adjustment::type, unshare_expr(), update_ssa(), useless_type_conversion_p(), vec_safe_iterate(), and vec_safe_push().
Referenced by convert_callers(), and convert_callers_for_node().
void ipa_modify_formal_parameters | ( | tree | fndecl, |
ipa_parm_adjustment_vec | adjustments, | ||
const char * | synth_parm_prefix | ||
) |
Modify the function declaration FNDECL and its type according to the plan in ADJUSTMENTS. It also sets base fields of individual adjustments structures to reflect the actual parameters being modified which are determined by the base_index field.
References ipa_parm_adjustment::base, ipa_parm_adjustment::base_index, build_distinct_type_copy(), build_function_type(), build_pointer_type(), ipa_parm_adjustment::by_ref, ipa_parm_adjustment::copy_param, create_tmp_var_name(), get_vector_of_formal_parm_types(), ipa_get_vector_of_formal_parms(), layout_decl(), len, NOT_BUILT_IN, nreverse(), ipa_parm_adjustment::reduction, ipa_parm_adjustment::remove_param, tree_last(), and ipa_parm_adjustment::type.
Referenced by modify_function().
void ipa_print_all_jump_functions | ( | FILE * | f | ) |
void ipa_print_all_params | ( | FILE * | ) |
void ipa_print_node_jump_functions | ( | FILE * | f, |
struct cgraph_node * | node | ||
) |
void ipa_print_node_params | ( | FILE * | , |
struct cgraph_node * | node | ||
) |
Debugging interface.
void ipa_prop_read_all_agg_replacement | ( | void | ) |
Read IPA-CP aggregate replacements.
References len, lto_get_file_decl_data(), lto_get_section_data(), LTO_section_ipcp_transform, and read_replacements_section().
void ipa_prop_read_jump_functions | ( | void | ) |
Read ipcp jump functions.
References ipa_check_create_edge_args(), ipa_check_create_node_params(), ipa_prop_read_section(), ipa_register_cgraph_hooks(), len, lto_get_file_decl_data(), lto_get_section_data(), and LTO_section_jump_functions.
Referenced by inline_read_summary(), and ipcp_read_summary().
void ipa_prop_write_all_agg_replacement | ( | void | ) |
Write all aggregate replacement for nodes in set.
References cgraph_function_with_gimple_body_p(), output_block::cgraph_node, count, create_output_block(), output_block::decl_state, destroy_output_block(), ipa_get_agg_replacements_for_node(), lsei_cgraph_node(), lsei_end_p(), lsei_next_function_in_partition(), lsei_start_function_in_partition(), LTO_section_ipcp_transform, output_block::main_stream, produce_asm(), streamer_write_char_stream(), streamer_write_uhwi(), lto_out_decl_state::symtab_node_encoder, and write_agg_replacement_chain().
void ipa_prop_write_jump_functions | ( | void | ) |
Write jump functions for nodes in SET.
References cgraph_function_with_gimple_body_p(), output_block::cgraph_node, count, create_output_block(), output_block::decl_state, destroy_output_block(), ipa_write_node_info(), lsei_cgraph_node(), lsei_end_p(), lsei_next_function_in_partition(), lsei_start_function_in_partition(), LTO_section_jump_functions, output_block::main_stream, produce_asm(), streamer_write_char_stream(), streamer_write_uhwi(), and lto_out_decl_state::symtab_node_encoder.
Referenced by inline_write_summary(), and ipcp_write_summary().
bool ipa_propagate_indirect_call_infos | ( | struct cgraph_edge * | cs, |
vec< cgraph_edge_p > * | new_edges | ||
) |
Update jump functions and call note functions on inlining the call site CS. CS is expected to lead to a node already cloned by cgraph_clone_inline_nodes. Newly discovered indirect edges will be added to *NEW_EDGES, unless NEW_EDGES is NULL. Return true iff a new edge(s) were + created.
References cgraph_edge::callee, changed, propagate_controlled_uses(), and propagate_info_to_inlined_callees().
Referenced by inline_call().
void ipa_register_cgraph_hooks | ( | void | ) |
Register our cgraph hooks if they are not already there.
References cgraph_add_edge_duplication_hook(), cgraph_add_edge_removal_hook(), cgraph_add_function_insertion_hook(), cgraph_add_node_duplication_hook(), cgraph_add_node_removal_hook(), ipa_add_new_function(), ipa_edge_duplication_hook(), ipa_edge_removal_hook(), ipa_node_duplication_hook(), and ipa_node_removal_hook().
Referenced by inline_generate_summary(), inline_read_summary(), ipa_prop_read_jump_functions(), and ipcp_generate_summary().
|
inlinestatic |
Set the controlled counter of a given parameter.
References ipa_node_params::descriptors.
Referenced by ipa_analyze_params_uses(), ipa_read_node_info(), ipcp_discover_new_direct_edges(), and propagate_controlled_uses().
void ipa_set_node_agg_value_chain | ( | struct cgraph_node * | node, |
struct ipa_agg_replacement_value * | aggvals | ||
) |
Set the aggregate replacements of NODE to be AGGVALS.
References cgraph_max_uid, cgraph_node::uid, vec_safe_grow_cleared(), and vec_safe_length().
Referenced by create_specialized_node(), ipa_node_duplication_hook(), and read_agg_replacement_chain().
|
inlinestatic |
Set the used flag corresponding to the Ith formal parameter of the function associated with INFO to VAL.
References ipa_node_params::descriptors.
Referenced by ipa_analyze_params_uses(), ipa_read_node_info(), and visit_ref_for_mod_analysis().
void ipa_update_after_lto_read | ( | void | ) |
After merging units, we can get mismatch in argument counts. Also decl merging might've rendered parameter lists obsolete. Also compute called_with_variable_arg info.
References ipa_check_create_edge_args(), and ipa_check_create_node_params().
Referenced by ipa_inline(), and ipcp_propagate_stage().
tree ipa_value_from_jfunc | ( | struct ipa_node_params * | info, |
struct ipa_jump_func * | jfunc | ||
) |
unsigned int ipcp_transform_function | ( | struct cgraph_node * | node | ) |
void ipcp_verify_propagated_values | ( | void | ) |
If checking is enabled, verify that no lattice is in the TOP state, i.e. not bottom, not containing a variable component and without any known value at the same time.
References ipcp_lattice::bottom, ipcp_lattice::contains_variable, count, dump_file, ipa_get_param_count(), ipa_get_scalar_lat(), print_all_lattices(), and ipcp_lattice::values_count.
Referenced by ipcp_propagate_stage().
vec<ipa_edge_args_t, va_gc>* ipa_edge_args_vector |
Vector where the parameter infos are actually stored.
vec<ipa_agg_replacement_value_p, va_gc>* ipa_node_agg_replacements |
Vector of known aggregate values in cloned nodes.
vec<ipa_node_params_t> ipa_node_params_vector |
Types of vectors holding the infos.
Vector where the parameter infos are actually stored.
Vector where the parameter infos are actually stored.
Referenced by create_specialized_node(), early_inliner(), estimate_function_body_sizes(), evaluate_properties_for_edge(), inline_merge_summary(), inline_node_duplication_hook(), ipa_check_create_node_params(), and remap_edge_change_prob().
alloc_pool ipcp_agg_lattice_pool |
Referenced by ipa_free_all_structures_after_iinln(), and ipa_free_all_structures_after_ipa_cp().
alloc_pool ipcp_sources_pool |
Referenced by ipa_free_all_structures_after_iinln(), and ipa_free_all_structures_after_ipa_cp().
alloc_pool ipcp_values_pool |
Allocation pools for values and their sources in ipa-cp.
Referenced by ipa_free_all_structures_after_iinln(), and ipa_free_all_structures_after_ipa_cp().