static inline tree
ipa_get_param (struct ipa_node_params *info, int i)
{
+ gcc_assert (i >= 0 && i <= info->param_count);
return info->params[i].decl;
}
static inline bool
ipa_is_param_used (struct ipa_node_params *info, int i)
{
+ gcc_assert (i >= 0 && i <= info->param_count);
return info->params[i].used;
}
static inline bool
ipa_param_cannot_devirtualize_p (struct ipa_node_params *info, int i)
{
+ gcc_assert (i >= 0 && i <= info->param_count);
return info->params[i].cannot_devirtualize;
}
static inline bool
ipa_param_types_vec_empty (struct ipa_node_params *info, int i)
{
+ gcc_assert (i >= 0 && i <= info->param_count);
return info->params[i].types == NULL;
}
static inline struct ipa_jump_func *
ipa_get_ith_jump_func (struct ipa_edge_args *args, int i)
{
+ gcc_assert (i >= 0 && i <= args->argument_count);
return &args->jump_functions[i];
}
void ipa_prop_write_jump_functions (cgraph_node_set set);
void ipa_prop_read_jump_functions (void);
void ipa_update_after_lto_read (void);
+int ipa_get_param_decl_index (struct ipa_node_params *, tree);
+void ipa_lattice_from_jfunc (struct ipa_node_params *info,
+ struct ipcp_lattice *lat,
+ struct ipa_jump_func *jfunc);
+tree ipa_cst_from_jfunc (struct ipa_node_params *info,
+ struct ipa_jump_func *jfunc);
+
/* From tree-sra.c: */
tree build_ref_for_offset (location_t, tree, HOST_WIDE_INT, tree,
gimple_stmt_iterator *, bool);
+/* Return the lattice corresponding to the Ith formal parameter of the function
+ described by INFO. */
+static inline struct ipcp_lattice *
+ipa_get_lattice (struct ipa_node_params *info, int i)
+{
+ gcc_assert (i >= 0 && i <= info->param_count);
+ return &(info->params[i].ipcp_lattice);
+}
+
#endif /* IPA_PROP_H */