GCC Middle and Back End API Reference
ipa-prop.c File Reference

Data Structures

struct  param_analysis_info
struct  ipa_cst_ref_desc
struct  type_change_info
struct  ipa_known_agg_contents_list

Functions

static bool ipa_func_spec_opts_forbid_analysis_p ()
static int ipa_get_param_decl_index_1 ()
int ipa_get_param_decl_index ()
static void ipa_populate_param_decls (struct cgraph_node *node, vec< ipa_param_descriptor_t > &descriptors)
static int count_formal_params ()
void ipa_dump_param ()
void ipa_alloc_node_params ()
void ipa_initialize_node_params ()
static void ipa_print_node_jump_functions_for_edge ()
void ipa_print_node_jump_functions ()
void ipa_print_all_jump_functions ()
static void ipa_set_jf_known_type (struct ipa_jump_func *jfunc, HOST_WIDE_INT offset, tree base_type, tree component_type)
static void ipa_set_jf_constant (struct ipa_jump_func *jfunc, tree constant, struct cgraph_edge *cs)
static void ipa_set_jf_simple_pass_through (struct ipa_jump_func *jfunc, int formal_id, bool agg_preserved)
static void ipa_set_jf_arith_pass_through (struct ipa_jump_func *jfunc, int formal_id, tree operand, enum tree_code operation)
static void ipa_set_ancestor_jf (struct ipa_jump_func *jfunc, HOST_WIDE_INT offset, tree type, int formal_id, bool agg_preserved)
tree ipa_binfo_from_known_type_jfunc ()
static bool stmt_may_be_vtbl_ptr_store ()
static tree extr_type_from_vtbl_ptr_store ()
static bool check_stmt_for_type_change ()
static bool detect_type_change_1 (tree arg, tree base, tree comp_type, gimple call, struct ipa_jump_func *jfunc, HOST_WIDE_INT offset)
static bool detect_type_change (tree arg, tree base, gimple call, struct ipa_jump_func *jfunc, HOST_WIDE_INT offset)
static bool detect_type_change_ssa ()
static bool mark_modified (ao_ref *ao, tree vdef, void *data)
static bool parm_preserved_before_stmt_p (struct param_analysis_info *parm_ainfo, gimple stmt, tree parm_load)
static int load_from_unmodified_param (vec< ipa_param_descriptor_t > descriptors, struct param_analysis_info *parms_ainfo, gimple stmt)
static bool parm_ref_data_preserved_p (struct param_analysis_info *parm_ainfo, gimple stmt, tree ref)
static bool parm_ref_data_pass_through_p (struct param_analysis_info *parm_ainfo, gimple call, tree parm)
static bool ipa_load_from_parm_agg_1 (vec< ipa_param_descriptor_t > descriptors, struct param_analysis_info *parms_ainfo, gimple stmt, tree op, int *index_p, HOST_WIDE_INT *offset_p, bool *by_ref_p)
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)
static void compute_complex_assign_jump_func (struct ipa_node_params *info, struct param_analysis_info *parms_ainfo, struct ipa_jump_func *jfunc, gimple call, gimple stmt, tree name)
static tree get_ancestor_addr_info ()
static void compute_complex_ancestor_jump_func (struct ipa_node_params *info, struct param_analysis_info *parms_ainfo, struct ipa_jump_func *jfunc, gimple call, gimple phi)
static void compute_known_type_jump_func (tree op, struct ipa_jump_func *jfunc, gimple call)
static bool type_like_member_ptr_p ()
static tree get_ssa_def_if_simple_copy ()
static void determine_known_aggregate_parts (gimple call, tree arg, struct ipa_jump_func *jfunc)
static void ipa_compute_jump_functions_for_edge (struct param_analysis_info *parms_ainfo, struct cgraph_edge *cs)
static void ipa_compute_jump_functions (struct cgraph_node *node, struct param_analysis_info *parms_ainfo)
static tree ipa_get_stmt_member_ptr_load_param (gimple stmt, bool use_delta, HOST_WIDE_INT *offset_p)
static bool ipa_is_ssa_with_stmt_def ()
static struct cgraph_edgeipa_note_param_call ()
static void ipa_analyze_indirect_call_uses (struct cgraph_node *node, struct ipa_node_params *info, struct param_analysis_info *parms_ainfo, gimple call, tree target)
static void ipa_analyze_virtual_call_uses (struct cgraph_node *node, struct ipa_node_params *info, gimple call, tree target)
static void ipa_analyze_call_uses (struct cgraph_node *node, struct ipa_node_params *info, struct param_analysis_info *parms_ainfo, gimple call)
static void ipa_analyze_stmt_uses (struct cgraph_node *node, struct ipa_node_params *info, struct param_analysis_info *parms_ainfo, gimple stmt)
static bool visit_ref_for_mod_analysis (gimple stmt, tree op, void *data)
static void ipa_analyze_params_uses (struct cgraph_node *node, struct param_analysis_info *parms_ainfo)
static void free_parms_ainfo ()
void ipa_analyze_node ()
tree ipa_intraprocedural_devirtualization ()
static void combine_known_type_and_ancestor_jfs (struct ipa_jump_func *src, struct ipa_jump_func *dst)
static void update_jump_functions_after_inlining (struct cgraph_edge *cs, struct cgraph_edge *e)
struct cgraph_edgeipa_make_edge_direct_to_target ()
tree ipa_find_agg_cst_for_param (struct ipa_agg_jump_function *agg, HOST_WIDE_INT offset, bool by_ref)
static void remove_described_reference ()
static struct ipa_cst_ref_descjfunc_rdesc_usable ()
static struct cgraph_edgetry_make_edge_direct_simple_call (struct cgraph_edge *ie, struct ipa_jump_func *jfunc, struct ipa_node_params *new_root_info)
static struct cgraph_edgetry_make_edge_direct_virtual_call (struct cgraph_edge *ie, struct ipa_jump_func *jfunc, struct ipa_node_params *new_root_info)
static bool update_indirect_edges_after_inlining (struct cgraph_edge *cs, struct cgraph_node *node, vec< cgraph_edge_p > *new_edges)
static bool propagate_info_to_inlined_callees (struct cgraph_edge *cs, struct cgraph_node *node, vec< cgraph_edge_p > *new_edges)
static int combine_controlled_uses_counters ()
static void propagate_controlled_uses ()
bool ipa_propagate_indirect_call_infos (struct cgraph_edge *cs, vec< cgraph_edge_p > *new_edges)
void ipa_free_edge_args_substructures ()
void ipa_free_all_edge_args ()
void ipa_free_node_params_substructures ()
void ipa_free_all_node_params ()
void ipa_set_node_agg_value_chain (struct cgraph_node *node, struct ipa_agg_replacement_value *aggvals)
static void ipa_edge_removal_hook ()
static void ipa_node_removal_hook ()
static void ipa_edge_duplication_hook (struct cgraph_edge *src, struct cgraph_edge *dst, __attribute__((unused)) void *data)
static void ipa_node_duplication_hook (struct cgraph_node *src, struct cgraph_node *dst, void *data)
static void ipa_add_new_function ()
void ipa_register_cgraph_hooks ()
static void ipa_unregister_cgraph_hooks ()
void ipa_free_all_structures_after_ipa_cp ()
void ipa_free_all_structures_after_iinln ()
void ipa_print_node_params ()
void ipa_print_all_params ()
vec< treeipa_get_vector_of_formal_parms ()
static vec< treeget_vector_of_formal_parm_types ()
void ipa_modify_formal_parameters (tree fndecl, ipa_parm_adjustment_vec adjustments, const char *synth_parm_prefix)
void ipa_modify_call_arguments (struct cgraph_edge *cs, gimple stmt, ipa_parm_adjustment_vec adjustments)
static bool index_in_adjustments_multiple_times_p (int base_index, ipa_parm_adjustment_vec adjustments)
ipa_parm_adjustment_vec ipa_combine_adjustments (ipa_parm_adjustment_vec inner, ipa_parm_adjustment_vec outer)
void ipa_dump_param_adjustments (FILE *file, ipa_parm_adjustment_vec adjustments, tree fndecl)
void ipa_dump_agg_replacement_values ()
static void ipa_write_jump_function (struct output_block *ob, struct ipa_jump_func *jump_func)
static void ipa_read_jump_function (struct lto_input_block *ib, struct ipa_jump_func *jump_func, struct cgraph_edge *cs, struct data_in *data_in)
static void ipa_write_indirect_edge_info (struct output_block *ob, struct cgraph_edge *cs)
static void ipa_read_indirect_edge_info (struct lto_input_block *ib, struct data_in *data_in, struct cgraph_edge *cs)
static void ipa_write_node_info ()
static void ipa_read_node_info (struct lto_input_block *ib, struct cgraph_node *node, struct data_in *data_in)
void ipa_prop_write_jump_functions ()
static void ipa_prop_read_section (struct lto_file_decl_data *file_data, const char *data, size_t len)
void ipa_prop_read_jump_functions ()
void ipa_update_after_lto_read ()
void write_agg_replacement_chain ()
static void read_agg_replacement_chain (struct lto_input_block *ib, struct cgraph_node *node, struct data_in *data_in)
void ipa_prop_write_all_agg_replacement ()
static void read_replacements_section (struct lto_file_decl_data *file_data, const char *data, size_t len)
void ipa_prop_read_all_agg_replacement ()
static void adjust_agg_replacement_values (struct cgraph_node *node, struct ipa_agg_replacement_value *aggval)
unsigned int ipcp_transform_function ()

Variables

vec< ipa_node_params_tipa_node_params_vector
vec
< ipa_agg_replacement_value_p,
va_gc > * 
ipa_node_agg_replacements
vec< ipa_edge_args_t, va_gc > * ipa_edge_args_vector
static struct
cgraph_edge_hook_list
edge_removal_hook_holder
static struct
cgraph_node_hook_list
node_removal_hook_holder
static struct
cgraph_2edge_hook_list
edge_duplication_hook_holder
static struct
cgraph_2node_hook_list
node_duplication_hook_holder
static struct
cgraph_node_hook_list
function_insertion_hook_holder
static alloc_pool ipa_refdesc_pool

Function Documentation

static void adjust_agg_replacement_values ( struct cgraph_node node,
struct ipa_agg_replacement_value aggval 
)
static
Adjust the aggregate replacements in AGGVAL to reflect parameters skipped in
   NODE.   

References bitmap_bit_p(), cgraph_node::clone, cgraph_clone_info::combined_args_to_skip, ipa_agg_replacement_value::index, and ipa_agg_replacement_value::next.

Referenced by ipcp_transform_function().

static bool check_stmt_for_type_change ( )
static
Callback of walk_aliased_vdefs and a helper function for
   detect_type_change to check whether a particular statement may modify
   the virtual table pointer, and if possible also determine the new type of
   the (sub-)object.  It stores its result into DATA, which points to a
   type_change_info structure.   

References extr_type_from_vtbl_ptr_store(), type_change_info::known_current_type, type_change_info::multiple_types_encountered, stmt_may_be_vtbl_ptr_store(), type(), and type_change_info::type_maybe_changed.

Referenced by detect_type_change_1().

static int combine_controlled_uses_counters ( )
static
Combine two controlled uses counts as done during inlining.   

Referenced by propagate_controlled_uses().

static void combine_known_type_and_ancestor_jfs ( struct ipa_jump_func src,
struct ipa_jump_func dst 
)
static
Update the jump function DST when the call graph edge corresponding to SRC is
   is being inlined, knowing that DST is of type ancestor and src of known
   type.   

References HOST_WIDE_INT, ipa_get_jf_ancestor_offset(), ipa_get_jf_ancestor_type(), ipa_get_jf_known_type_base_type(), ipa_get_jf_known_type_offset(), and ipa_set_jf_known_type().

Referenced by update_jump_functions_after_inlining().

static void compute_complex_ancestor_jump_func ( struct ipa_node_params info,
struct param_analysis_info parms_ainfo,
struct ipa_jump_func jfunc,
gimple  call,
gimple  phi 
)
static
Given that an actual argument is an SSA_NAME that is a result of a phi
   statement PHI, try to find out whether NAME is in fact a
   multiple-inheritance typecast from a descendant into an ancestor of a formal
   parameter and thus can be described by an ancestor jump function and if so,
   write the appropriate function into JFUNC.

   Essentially we want to match the following pattern:

     if (obj_2(D) != 0B)
       goto <bb 3>;
     else
       goto <bb 4>;

   <bb 3>:
     iftmp.1_3 = &obj_2(D)->D.1762;

   <bb 4>:
     # iftmp.1_1 = PHI <iftmp.1_3(3), 0B(2)>
     D.1879_6 = middleman_1 (iftmp.1_1, i_5(D));
     return D.1879_6;   

References detect_type_change(), get_ancestor_addr_info(), gimple_bb(), gimple_cond_code(), gimple_cond_lhs(), gimple_cond_rhs(), gimple_phi_num_args(), HOST_WIDE_INT, integer_zerop(), ipa_get_param_decl_index(), ipa_set_ancestor_jf(), last_stmt(), offset, parm_ref_data_pass_through_p(), single_pred(), and single_pred_p().

Referenced by ipa_compute_jump_functions_for_edge().

static void compute_complex_assign_jump_func ( struct ipa_node_params info,
struct param_analysis_info parms_ainfo,
struct ipa_jump_func jfunc,
gimple  call,
gimple  stmt,
tree  name 
)
static
Given that an actual argument is an SSA_NAME (given in NAME) and is a result
   of an assignment statement STMT, try to determine whether we are actually
   handling any of the following cases and construct an appropriate jump
   function into JFUNC if so:

   1) The passed value is loaded from a formal parameter which is not a gimple
   register (most probably because it is addressable, the value has to be
   scalar) and we can guarantee the value has not changed.  This case can
   therefore be described by a simple pass-through jump function.  For example:

      foo (int a)
      {
        int a.0;

        a.0_2 = a;
        bar (a.0_2);

   2) The passed value can be described by a simple arithmetic pass-through
   jump function. E.g.

      foo (int a)
      {
        int D.2064;

        D.2064_4 = a.1(D) + 4;
        bar (D.2064_4);

   This case can also occur in combination of the previous one, e.g.:

      foo (int a, int z)
      {
        int a.0;
        int D.2064;

        a.0_3 = a;
        D.2064_4 = a.0_3 + 4;
        foo (D.2064_4);

   3) The passed value is an address of an object within another one (which
   also passed by reference).  Such situations are described by an ancestor
   jump function and describe situations such as:

     B::foo() (struct B * const this)
     {
       struct A * D.1845;

       D.1845_2 = &this_1(D)->D.1748;
       A::bar (D.1845_2);

   INFO is the structure describing individual parameters access different
   stages of IPA optimizations.  PARMS_AINFO contains the information that is
   only needed for intraprocedural analysis.   

References ipa_node_params::descriptors, detect_type_change(), detect_type_change_ssa(), get_ref_base_and_extent(), gimple_assign_lhs(), gimple_assign_rhs1(), gimple_assign_rhs2(), gimple_assign_rhs_code(), gimple_assign_single_p(), gimple_expr_code(), HOST_WIDE_INT, ipa_get_param_decl_index(), ipa_set_ancestor_jf(), ipa_set_jf_arith_pass_through(), ipa_set_jf_simple_pass_through(), is_gimple_ip_invariant(), load_from_unmodified_param(), double_int::low, mem_ref_offset(), offset, parm_ref_data_pass_through_p(), tcc_comparison, and useless_type_conversion_p().

Referenced by ipa_compute_jump_functions_for_edge().

static void compute_known_type_jump_func ( tree  op,
struct ipa_jump_func jfunc,
gimple  call 
)
static
Given OP which is passed as an actual argument to a called function,
   determine if it is possible to construct a KNOWN_TYPE jump function for it
   and if so, create one and store it to JFUNC.   

References detect_type_change(), get_ref_base_and_extent(), HOST_WIDE_INT, ipa_set_jf_known_type(), is_global_var(), and offset.

Referenced by ipa_compute_jump_functions_for_edge(), and ipa_intraprocedural_devirtualization().

static int count_formal_params ( )
inlinestatic
Return how many formal parameters FNDECL has.   

References count, and gimple_has_body_p().

Referenced by ipa_get_vector_of_formal_parms(), ipa_initialize_node_params(), and ipcp_transform_function().

static bool detect_type_change ( tree  arg,
tree  base,
gimple  call,
struct ipa_jump_func jfunc,
HOST_WIDE_INT  offset 
)
static
Detect whether the dynamic type of ARG has changed (before callsite CALL) by
   looking for assignments to its virtual table pointer.  If it is, return true
   and fill in the jump function JFUNC with relevant type information or set it
   to unknown.  ARG is the object itself (not a pointer to it, unless
   dereferenced).  BASE is the base of the memory access as returned by
   get_ref_base_and_extent, as is the offset.   

References detect_type_change_1().

Referenced by compute_complex_ancestor_jump_func(), compute_complex_assign_jump_func(), compute_known_type_jump_func(), and ipa_analyze_virtual_call_uses().

static bool detect_type_change_1 ( tree  arg,
tree  base,
tree  comp_type,
gimple  call,
struct ipa_jump_func jfunc,
HOST_WIDE_INT  offset 
)
static
static bool detect_type_change_ssa ( )
static
Like detect_type_change but ARG is supposed to be a non-dereferenced pointer
   SSA name (its dereference will become the base and the offset is assumed to
   be zero).   

References build_int_cst(), and detect_type_change_1().

Referenced by compute_complex_assign_jump_func(), ipa_analyze_virtual_call_uses(), and ipa_compute_jump_functions_for_edge().

static tree extr_type_from_vtbl_ptr_store ( )
static
If STMT can be proved to be an assignment to the virtual method table
   pointer of ANALYZED_OBJ and the type associated with the new table
   identified, return the type.  Otherwise return NULL_TREE.   

References get_base_address(), get_ref_base_and_extent(), gimple_assign_lhs(), gimple_assign_rhs1(), gimple_assign_single_p(), HOST_WIDE_INT, type_change_info::object, type_change_info::offset, offset, and tree_int_cst_equal().

Referenced by check_stmt_for_type_change().

static void free_parms_ainfo ( )
static
Free stuff in PARMS_AINFO, assume there are PARAM_COUNT parameters.   

Referenced by ipa_analyze_node(), and ipcp_transform_function().

static tree get_ancestor_addr_info ( )
static
Extract the base, offset and MEM_REF expression from a statement ASSIGN if
   it looks like:

   iftmp.1_3 = &obj_2(D)->D.1762;

   The base of the MEM_REF must be a default definition SSA NAME of a
   parameter.  Return NULL_TREE if it looks otherwise.  If case of success, the
   whole MEM_REF expression is returned and the offset calculated from any
   handled components and the MEM_REF itself is stored into *OFFSET.  The whole
   RHS stripped off the ADDR_EXPR is stored into *OBJ_P.   

References get_ref_base_and_extent(), gimple_assign_rhs1(), gimple_assign_single_p(), HOST_WIDE_INT, double_int::low, and mem_ref_offset().

Referenced by compute_complex_ancestor_jump_func(), and ipa_analyze_virtual_call_uses().

static tree get_ssa_def_if_simple_copy ( )
inlinestatic
If RHS is an SSA_NAME and it is defined by a simple copy assign statement,
   return the rhs of its defining statement.  Otherwise return RHS as it
   is.   

References gimple_assign_rhs1(), and gimple_assign_single_p().

Referenced by determine_known_aggregate_parts().

static vec<tree> get_vector_of_formal_parm_types ( )
inlinestatic
Return a heap allocated vector containing types of formal parameters of
   function type FNTYPE.   

References count.

Referenced by ipa_modify_formal_parameters().

static bool index_in_adjustments_multiple_times_p ( int  base_index,
ipa_parm_adjustment_vec  adjustments 
)
static
Return true iff BASE_INDEX is in ADJUSTMENTS more than once.   

References ipa_parm_adjustment::base_index, and len.

Referenced by ipa_combine_adjustments().

static void ipa_add_new_function ( )
static
Analyze newly added function into callgraph.   

References ipa_analyze_node().

Referenced by ipa_register_cgraph_hooks().

void ipa_alloc_node_params ( )
Initialize the ipa_node_params structure associated with NODE 
   to hold PARAM_COUNT parameters.   

References ipa_node_params::descriptors.

Referenced by ipa_initialize_node_params(), and ipa_read_node_info().

static void ipa_analyze_call_uses ( struct cgraph_node node,
struct ipa_node_params info,
struct param_analysis_info parms_ainfo,
gimple  call 
)
static
Analyze a call statement CALL whether and how it utilizes formal parameters
   of the caller (described by INFO).  PARMS_AINFO is a pointer to a vector
   containing intermediate information about each formal parameter.   

References gimple_call_fn(), ipa_analyze_indirect_call_uses(), ipa_analyze_virtual_call_uses(), and virtual_method_call_p().

Referenced by ipa_analyze_stmt_uses().

static void ipa_analyze_indirect_call_uses ( struct cgraph_node node,
struct ipa_node_params info,
struct param_analysis_info parms_ainfo,
gimple  call,
tree  target 
)
static
Analyze the CALL and examine uses of formal parameters of the caller NODE
   (described by INFO).  PARMS_AINFO is a pointer to a vector containing
   intermediate information about each formal parameter.  Currently it checks
   whether the call calls a pointer that is a formal parameter and if so, the
   parameter is marked with the called flag and an indirect call graph edge
   describing the call is created.  This is very simple for ordinary pointers
   represented in SSA but not-so-nice when it comes to member pointers.  The
   ugly part of this function does nothing more than trying to match the
   pattern of such a call.  An example of such a pattern is the gimple dump
   below, the call is on the last line:

     <bb 2>:
       f$__delta_5 = f.__delta;
       f$__pfn_24 = f.__pfn;

   or
     <bb 2>:
       f$__delta_5 = MEM[(struct  *)&f];
       f$__pfn_24 = MEM[(struct  *)&f + 4B];

   and a few lines below:

     <bb 5>
       D.2496_3 = (int) f$__pfn_24;
       D.2497_4 = D.2496_3 & 1;
       if (D.2497_4 != 0)
         goto <bb 3>;
       else
         goto <bb 4>;

     <bb 6>:
       D.2500_7 = (unsigned int) f$__delta_5;
       D.2501_8 = &S + D.2500_7;
       D.2502_9 = (int (*__vtbl_ptr_type) (void) * *) D.2501_8;
       D.2503_10 = *D.2502_9;
       D.2504_12 = f$__pfn_24 + -1;
       D.2505_13 = (unsigned int) D.2504_12;
       D.2506_14 = D.2503_10 + D.2505_13;
       D.2507_15 = *D.2506_14;
       iftmp.11_16 = (String:: *) D.2507_15;

     <bb 7>:
       # iftmp.11_1 = PHI <iftmp.11_16(3), f$__pfn_24(2)>
       D.2500_19 = (unsigned int) f$__delta_5;
       D.2508_20 = &S + D.2500_19;
       D.2493_21 = iftmp.11_1 (D.2508_20, 4);

   Such patterns are results of simple calls to a member pointer:

     int doprinting (int (MyString::* f)(int) const)
     {
       MyString S ("somestring");

       return (S.*f)(4);
     }

   Moreover, the function also looks for called pointers loaded from aggregates
   passed by value or reference.   

References cgraph_indirect_call_info::agg_contents, cgraph_indirect_call_info::by_ref, d1, d2, ipa_node_params::descriptors, gimple_assign_rhs1(), gimple_assign_rhs2(), gimple_assign_rhs_code(), gimple_assign_single_p(), gimple_bb(), gimple_cond_code(), gimple_cond_lhs(), gimple_cond_rhs(), gimple_phi_num_args(), HOST_WIDE_INT, cgraph_edge::indirect_info, integer_onep(), integer_zerop(), ipa_get_param_decl_index(), ipa_get_stmt_member_ptr_load_param(), ipa_is_ssa_with_stmt_def(), ipa_load_from_parm_agg_1(), ipa_note_param_call(), is_gimple_assign(), last_stmt(), cgraph_indirect_call_info::member_ptr, cgraph_indirect_call_info::offset, offset, parm_preserved_before_stmt_p(), ptrmemfunc_vbit_in_delta, single_pred(), single_pred_p(), single_succ(), and single_succ_p().

Referenced by ipa_analyze_call_uses().

void ipa_analyze_node ( )
Initialize the array describing properties of of formal parameters
   of NODE, analyze their uses and compute jump functions associated
   with actual arguments of calls from within NODE.   

References symtab_node_base::decl, free_parms_ainfo(), ipa_analyze_params_uses(), ipa_check_create_edge_args(), ipa_check_create_node_params(), ipa_compute_jump_functions(), ipa_get_param_count(), ipa_initialize_node_params(), memset(), pop_cfun(), push_cfun(), and cgraph_node::symbol.

Referenced by inline_indirect_intraprocedural_analysis(), ipa_add_new_function(), and ipcp_generate_summary().

static void ipa_analyze_params_uses ( struct cgraph_node node,
struct param_analysis_info parms_ainfo 
)
static
Scan the function body of NODE and inspect the uses of formal parameters.
   Store the findings in various structures of the associated ipa_node_params
   structure, such as parameter flags, notes etc.  PARMS_AINFO is a pointer to a
   vector containing intermediate information about each formal parameter.    

References symtab_node_base::decl, gsi_end_p(), gsi_next(), gsi_start_bb(), gsi_start_phis(), gsi_stmt(), has_zero_uses(), ipa_analyze_stmt_uses(), ipa_func_spec_opts_forbid_analysis_p(), ipa_get_param(), ipa_get_param_count(), ipa_set_controlled_uses(), ipa_set_param_used(), is_gimple_call(), is_gimple_debug(), is_gimple_reg(), ssa_default_def(), cgraph_node::symbol, ipa_node_params::uses_analysis_done, visit_ref_for_mod_analysis(), and walk_stmt_load_store_addr_ops().

Referenced by ipa_analyze_node().

static void ipa_analyze_stmt_uses ( struct cgraph_node node,
struct ipa_node_params info,
struct param_analysis_info parms_ainfo,
gimple  stmt 
)
static
Analyze the call statement STMT with respect to formal parameters (described
   in INFO) of caller given by NODE.  Currently it only checks whether formal
   parameters are called.  PARMS_AINFO is a pointer to a vector containing
   intermediate information about each formal parameter.   

References ipa_analyze_call_uses(), and is_gimple_call().

Referenced by ipa_analyze_params_uses().

static void ipa_analyze_virtual_call_uses ( struct cgraph_node node,
struct ipa_node_params info,
gimple  call,
tree  target 
)
static
Analyze a CALL to an OBJ_TYPE_REF which is passed in TARGET and if the
   object referenced in the expression is a formal parameter of the caller
   (described by INFO), create a call note for the statement.  

References detect_type_change(), detect_type_change_ssa(), get_ancestor_addr_info(), HOST_WIDE_INT, cgraph_edge::indirect_info, ipa_get_param_decl_index(), ipa_note_param_call(), obj_type_ref_class(), cgraph_indirect_call_info::offset, cgraph_indirect_call_info::otr_token, cgraph_indirect_call_info::otr_type, cgraph_indirect_call_info::polymorphic, and tree_low_cst().

Referenced by ipa_analyze_call_uses().

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.

static void ipa_compute_jump_functions ( struct cgraph_node node,
struct param_analysis_info parms_ainfo 
)
static
Compute jump functions for all edges - both direct and indirect - outgoing
   from NODE.  Also count the actual arguments in the process.   

References cgraph_edge::callee, cgraph_node::callees, cgraph_function_or_thunk_node(), symtab_node_base::definition, cgraph_node::indirect_calls, ipa_compute_jump_functions_for_edge(), cgraph_edge::next_callee, and cgraph_node::symbol.

Referenced by ipa_analyze_node().

void ipa_dump_param ( )
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, and print_generic_expr().

Referenced by decide_about_value(), estimate_local_effects(), find_more_scalar_values_for_callers_subset(), get_replacement_map(), and ipa_print_node_params().

void ipa_dump_param_adjustments ( FILE *  file,
ipa_parm_adjustment_vec  adjustments,
tree  fndecl 
)
static void ipa_edge_removal_hook ( )
static
Hook that is called by cgraph.c when an edge is removed.   

References ipa_free_edge_args_substructures(), cgraph_edge::uid, and vec_safe_length().

Referenced by ipa_register_cgraph_hooks().

tree ipa_find_agg_cst_for_param ( struct ipa_agg_jump_function agg,
HOST_WIDE_INT  offset,
bool  by_ref 
)
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  )
void ipa_free_all_node_params ( void  )
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 ( )
Frees all dynamically allocated structures that the argument info points
   to.   

References ipa_edge_args::jump_functions, memset(), and vec_free().

Referenced by ipa_edge_removal_hook(), and ipa_free_all_edge_args().

void ipa_free_node_params_substructures ( )
Frees all dynamically allocated structures that the param info points
   to.   

References ipa_node_params::descriptors, free(), ipa_node_params::known_vals, ipa_node_params::lattices, and memset().

Referenced by ipa_free_all_node_params(), and ipa_node_removal_hook().

static bool ipa_func_spec_opts_forbid_analysis_p ( )
static
Return true if DECL_FUNCTION_SPECIFIC_OPTIMIZATION of the decl associated
   with NODE should prevent us from analyzing it for the purposes of IPA-CP.   

References symtab_node_base::decl, and cgraph_node::symbol.

Referenced by ipa_analyze_params_uses(), and ipa_compute_jump_functions_for_edge().

static int ipa_get_param_decl_index_1 ( )
static
Return index of the formal whose tree is PTREE in function which corresponds
   to INFO.   

References count.

Referenced by ipa_get_param_decl_index(), ipa_load_from_parm_agg_1(), and load_from_unmodified_param().

static tree ipa_get_stmt_member_ptr_load_param ( gimple  stmt,
bool  use_delta,
HOST_WIDE_INT offset_p 
)
static
If STMT looks like a statement loading a value from a member pointer formal
   parameter, return that parameter and store the offset of the field to
   *OFFSET_P, if it is non-NULL.  Otherwise return NULL (but *OFFSET_P still
   might be clobbered).  If USE_DELTA, then we look for a use of the delta
   field rather than the pfn.   

References byte_position(), gimple_assign_rhs1(), gimple_assign_single_p(), int_bit_position(), integer_nonzerop(), tree_int_cst_equal(), and type_like_member_ptr_p().

Referenced by ipa_analyze_indirect_call_uses().

vec<tree> ipa_get_vector_of_formal_parms ( )
Return a heap allocated vector containing formal parameters of FNDECL.   

References count, and count_formal_params().

Referenced by ipa_dump_param_adjustments(), ipa_modify_formal_parameters(), and turn_representatives_into_adjustments().

void ipa_initialize_node_params ( )
Initialize the ipa_node_params structure associated with NODE by counting
   the function parameters, creating the descriptors and populating their
   param_decls.   

References count_formal_params(), symtab_node_base::decl, ipa_node_params::descriptors, ipa_alloc_node_params(), ipa_populate_param_decls(), and cgraph_node::symbol.

Referenced by ipa_analyze_node().

tree ipa_intraprocedural_devirtualization ( )
Given a statement CALL which must be a GIMPLE_CALL calling an OBJ_TYPE_REF
   attempt a type-based devirtualization.  If successful, return the
   target function declaration, otherwise return NULL.   

References compute_known_type_jump_func(), gimple_call_fn(), gimple_get_virt_method_for_binfo(), ipa_binfo_from_known_type_jfunc(), IPA_JF_KNOWN_TYPE, IPA_JF_UNKNOWN, token(), tree_low_cst(), and ipa_jump_func::type.

Referenced by eliminate_bb().

static bool ipa_is_ssa_with_stmt_def ( )
static
Returns true iff T is an SSA_NAME defined by a statement.   

Referenced by ipa_analyze_indirect_call_uses().

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().

static bool ipa_load_from_parm_agg_1 ( vec< ipa_param_descriptor_t descriptors,
struct param_analysis_info parms_ainfo,
gimple  stmt,
tree  op,
int *  index_p,
HOST_WIDE_INT offset_p,
bool *  by_ref_p 
)
static
Return true if we can prove that OP is a memory reference loading unmodified
   data from an aggregate passed as a parameter and if the aggregate is passed
   by reference, that the alias type of the load corresponds to the type of the
   formal parameter (so that we can rely on this type for TBAA in callers).
   INFO and PARMS_AINFO describe parameters of the current function (but the
   latter can be NULL), STMT is the load statement.  If function returns true,
   *INDEX_P, *OFFSET_P and *BY_REF is filled with the parameter index, offset
   within the aggregate and whether it is a load from a value passed by
   reference respectively.   

References get_ref_base_and_extent(), HOST_WIDE_INT, integer_zerop(), ipa_get_param_decl_index_1(), load_from_unmodified_param(), parm_preserved_before_stmt_p(), and parm_ref_data_preserved_p().

Referenced by ipa_analyze_indirect_call_uses(), ipa_load_from_parm_agg(), and ipcp_transform_function().

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().

static void ipa_node_removal_hook ( )
static
Hook that is called by cgraph.c when a node is removed.   

References ipa_free_node_params_substructures(), cgraph_node::uid, and vec_safe_length().

Referenced by ipa_register_cgraph_hooks().

static struct cgraph_edge* ipa_note_param_call ( )
staticread
Find the indirect call graph edge corresponding to STMT and mark it as a
   call to a parameter number PARAM_INDEX.  NODE is the caller.  Return the
   indirect call graph edge.   

References cgraph_indirect_call_info::agg_contents, cgraph_edge(), cgraph_edge::indirect_info, cgraph_indirect_call_info::member_ptr, cgraph_indirect_call_info::offset, cgraph_indirect_call_info::param_index, and cgraph_indirect_call_info::polymorphic.

Referenced by ipa_analyze_indirect_call_uses(), and ipa_analyze_virtual_call_uses().

static void ipa_populate_param_decls ( struct cgraph_node node,
vec< ipa_param_descriptor_t > &  descriptors 
)
static
Populate the param_decl field in parameter DESCRIPTORS that correspond to
   NODE.   

References symtab_node_base::decl, estimate_move_cost(), gimple_has_body_p(), and cgraph_node::symbol.

Referenced by ipa_initialize_node_params(), and ipcp_transform_function().

void ipa_print_all_jump_functions ( )
Print ipa_jump_func data structures of all nodes in the call graph to F.   

References ipa_print_node_jump_functions().

Referenced by ipcp_driver().

void ipa_print_all_params ( )
Print ipa_tree_map data structures of all functions in the
   callgraph to F.   

References ipa_print_node_params().

Referenced by ipcp_driver().

void ipa_print_node_params ( )
void ipa_prop_read_all_agg_replacement ( void  )
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().

static void ipa_set_jf_arith_pass_through ( struct ipa_jump_func jfunc,
int  formal_id,
tree  operand,
enum tree_code  operation 
)
static
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().

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().

static struct ipa_cst_ref_desc* jfunc_rdesc_usable ( )
staticread
If JFUNC has a reference description with refcount different from
   IPA_UNDESCRIBED_USE, return the reference description, otherwise return
   NULL.  JFUNC must be a constant jump function.   

References ipa_get_jf_constant_rdesc(), and ipa_cst_ref_desc::refcount.

Referenced by ipa_edge_duplication_hook(), propagate_controlled_uses(), and try_make_edge_direct_simple_call().

static int load_from_unmodified_param ( vec< ipa_param_descriptor_t descriptors,
struct param_analysis_info parms_ainfo,
gimple  stmt 
)
static
If STMT is an assignment that loads a value from an parameter declaration,
   return the index of the parameter in ipa_node_params which has not been
   modified.  Otherwise return -1.   

References gimple_assign_rhs1(), gimple_assign_single_p(), ipa_get_param_decl_index_1(), and parm_preserved_before_stmt_p().

Referenced by compute_complex_assign_jump_func(), and ipa_load_from_parm_agg_1().

static bool mark_modified ( ao_ref ao,
tree  vdef,
void *  data 
)
static
Callback of walk_aliased_vdefs.  Flags that it has been invoked to the
   boolean variable pointed to by DATA.   

Referenced by parm_preserved_before_stmt_p(), parm_ref_data_pass_through_p(), and parm_ref_data_preserved_p().

static bool parm_preserved_before_stmt_p ( struct param_analysis_info parm_ainfo,
gimple  stmt,
tree  parm_load 
)
static
Return true if a load from a formal parameter PARM_LOAD is known to retrieve
   a value known not to be modified in this function before reaching the
   statement STMT.  PARM_AINFO is a pointer to a structure containing temporary
   information about the parameter.   

References ao_ref_init(), gimple_vuse(), mark_modified(), param_analysis_info::parm_modified, param_analysis_info::parm_visited_statements, and walk_aliased_vdefs().

Referenced by ipa_analyze_indirect_call_uses(), ipa_compute_jump_functions_for_edge(), ipa_load_from_parm_agg_1(), and load_from_unmodified_param().

static bool parm_ref_data_pass_through_p ( struct param_analysis_info parm_ainfo,
gimple  call,
tree  parm 
)
static
Return true if the data pointed to by PARM is known to be unmodified in this
   function before reaching call statement CALL into which it is passed.
   PARM_AINFO is a pointer to a structure containing temporary information
   about PARM.   

References ao_ref_init_from_ptr_and_size(), gimple_vuse(), mark_modified(), param_analysis_info::pt_modified, param_analysis_info::pt_visited_statements, and walk_aliased_vdefs().

Referenced by compute_complex_ancestor_jump_func(), compute_complex_assign_jump_func(), and ipa_compute_jump_functions_for_edge().

static bool parm_ref_data_preserved_p ( struct param_analysis_info parm_ainfo,
gimple  stmt,
tree  ref 
)
static
Return true if memory reference REF loads data that are known to be
   unmodified in this function before reaching statement STMT.  PARM_AINFO, if
   non-NULL, is a pointer to a structure containing temporary information about
   PARM.   

References ao_ref_init(), gimple_vuse(), mark_modified(), param_analysis_info::ref_modified, and walk_aliased_vdefs().

Referenced by ipa_load_from_parm_agg_1().

static bool propagate_info_to_inlined_callees ( struct cgraph_edge cs,
struct cgraph_node node,
vec< cgraph_edge_p > *  new_edges 
)
static
Recursively traverse subtree of NODE (including node) made of inlined
   cgraph_edges when CS has been inlined and invoke
   update_indirect_edges_after_inlining on all nodes and
   update_jump_functions_after_inlining on all non-inlined edges that lead out
   of this subtree.  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, cgraph_node::callees, cgraph_node::indirect_calls, cgraph_edge::inline_failed, cgraph_edge::next_callee, update_indirect_edges_after_inlining(), and update_jump_functions_after_inlining().

Referenced by ipa_propagate_indirect_call_infos().

static void read_agg_replacement_chain ( struct lto_input_block ib,
struct cgraph_node node,
struct data_in data_in 
)
static
Stream in the aggregate value replacement chain for NODE from IB.   

References bp_unpack_value(), count, ipa_set_node_agg_value_chain(), streamer_read_bitpack(), and streamer_read_uhwi().

Referenced by read_replacements_section().

static void remove_described_reference ( )
static
static bool stmt_may_be_vtbl_ptr_store ( )
static
Return true if STMT can modify a virtual method table pointer.

   This function makes special assumptions about both constructors and
   destructors which are all the functions that are allowed to alter the VMT
   pointers.  It assumes that destructors begin with assignment into all VMT
   pointers and that constructors essentially look in the following way:

   1) The very first thing they do is that they call constructors of ancestor
   sub-objects that have them.

   2) Then VMT pointers of this and all its ancestors is set to new values
   corresponding to the type corresponding to the constructor.

   3) Only afterwards, other stuff such as constructor of member sub-objects
   and the code written by the user is run.  Only this may include calling
   virtual functions, directly or indirectly.

   There is no way to call a constructor of an ancestor sub-object in any
   other way.

   This means that we do not have to care whether constructors get the correct
   type information because they will always change it (in fact, if we define
   the type to be given by the VMT pointer, it is undefined).

   The most important fact to derive from the above is that if, for some
   statement in the section 3, we try to detect whether the dynamic type has
   changed, we can safely ignore all calls as we examine the function body
   backwards until we reach statements in section 2 because these calls cannot
   be ancestor constructors or destructors (if the input is not bogus) and so
   do not change the dynamic type (this holds true only for automatically
   allocated objects but at the moment we devirtualize only these).  We then
   must detect that statements in section 2 change the dynamic type and can try
   to derive the new type.  That is enough and we can stop, we will never see
   the calls into constructors of sub-objects in this code.  Therefore we can
   safely ignore all call statements that we traverse.

References gimple_assign_lhs(), is_gimple_assign(), and is_gimple_call().

Referenced by check_stmt_for_type_change().

static struct cgraph_edge* try_make_edge_direct_simple_call ( struct cgraph_edge ie,
struct ipa_jump_func jfunc,
struct ipa_node_params new_root_info 
)
staticread
Try to find a destination for indirect edge IE that corresponds to a simple
   call or a call of a member function pointer and where the destination is a
   pointer formal parameter described by jump function JFUNC.  If it can be
   determined, return the newly direct edge, otherwise return NULL.
   NEW_ROOT_INFO is the node info that JFUNC lattices are relative to.   

References ipa_jump_func::agg, cgraph_indirect_call_info::agg_contents, cgraph_indirect_call_info::by_ref, cgraph_edge::callee, ipa_cst_ref_desc::cs, cgraph_edge::indirect_info, ipa_find_agg_cst_for_param(), IPA_JF_CONST, ipa_make_edge_direct_to_target(), ipa_value_from_jfunc(), jfunc_rdesc_usable(), cgraph_indirect_call_info::offset, ipa_cst_ref_desc::refcount, remove_described_reference(), cgraph_edge::speculative, and ipa_jump_func::type.

Referenced by update_indirect_edges_after_inlining().

static struct cgraph_edge* try_make_edge_direct_virtual_call ( struct cgraph_edge ie,
struct ipa_jump_func jfunc,
struct ipa_node_params new_root_info 
)
staticread
Try to find a destination for indirect edge IE that corresponds to a virtual
   call based on a formal parameter which is described by jump function JFUNC
   and if it can be determined, make it direct and return the direct edge.
   Otherwise, return NULL.  NEW_ROOT_INFO is the node info that JFUNC lattices
   are relative to.   

References get_binfo_at_offset(), gimple_extract_devirt_binfo_from_cst(), gimple_get_virt_method_for_binfo(), cgraph_edge::indirect_info, ipa_make_edge_direct_to_target(), ipa_value_from_jfunc(), cgraph_indirect_call_info::offset, cgraph_indirect_call_info::otr_token, and cgraph_indirect_call_info::otr_type.

Referenced by update_indirect_edges_after_inlining().

static bool type_like_member_ptr_p ( )
static
Inspect the given TYPE and return true iff it has the same structure (the
   same number of fields of the same types) as a C++ member pointer.  If
   METHOD_PTR and DELTA are non-NULL, store the trees representing the
   corresponding fields there.   

References host_integerp().

Referenced by ipa_get_stmt_member_ptr_load_param().

static bool update_indirect_edges_after_inlining ( struct cgraph_edge cs,
struct cgraph_node node,
vec< cgraph_edge_p > *  new_edges 
)
static
static bool visit_ref_for_mod_analysis ( gimple  stmt,
tree  op,
void *  data 
)
static
Callback of walk_stmt_load_store_addr_ops for the visit_load.
   If OP is a parameter declaration, mark it as used in the info structure
   passed in DATA.   

References get_base_address(), ipa_get_param_decl_index(), and ipa_set_param_used().

Referenced by ipa_analyze_params_uses().


Variable Documentation

struct cgraph_2edge_hook_list* edge_duplication_hook_holder
static
struct cgraph_edge_hook_list* edge_removal_hook_holder
static
Holders of ipa cgraph hooks:  
struct cgraph_node_hook_list* function_insertion_hook_holder
static
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.   
alloc_pool ipa_refdesc_pool
static
Allocation pool for reference descriptions.   
struct cgraph_2node_hook_list* node_duplication_hook_holder
static
struct cgraph_node_hook_list* node_removal_hook_holder
static