aboutsummaryrefslogtreecommitdiff
path: root/gcc/cgraphclones.c
diff options
context:
space:
mode:
authorMartin Liska <mliska@suse.cz>2019-10-30 08:56:22 +0100
committerMartin Liska <marxin@gcc.gnu.org>2019-10-30 07:56:22 +0000
commit87f94429feeb72587549fdafd3106f1d799607ff (patch)
tree08ffc5d297681144170e188457770e59e6573fe1 /gcc/cgraphclones.c
parenta62bfab5d2a332925fcf10c45b4c5d8ca499439d (diff)
downloadgcc-87f94429feeb72587549fdafd3106f1d799607ff.zip
gcc-87f94429feeb72587549fdafd3106f1d799607ff.tar.gz
gcc-87f94429feeb72587549fdafd3106f1d799607ff.tar.bz2
Remove cgraph_local_info structure.
2019-10-30 Martin Liska <mliska@suse.cz> * cgraph.c (cgraph_node::local_info): Transform to ... (cgraph_node::local_info_node): ... this. (cgraph_node::dump): Remove cgraph_local_info and put its fields directly into cgraph_node. (cgraph_node::get_availability): Likewise. (cgraph_node::make_local): Likewise. (cgraph_node::verify_node): Likewise. * cgraph.h (struct GTY): Likewise. * cgraphclones.c (set_new_clone_decl_and_node_flags): Likewise. (duplicate_thunk_for_node): Likewise. (cgraph_node::create_clone): Likewise. (cgraph_node::create_virtual_clone): Likewise. (cgraph_node::create_version_clone): Likewise. * cgraphunit.c (cgraph_node::reset): Likewise. (cgraph_node::finalize_function): Likewise. (cgraph_node::add_new_function): Likewise. (analyze_functions): Likewise. * combine.c (setup_incoming_promotions): Likewise. * config/i386/i386.c (ix86_function_regparm): Likewise. (ix86_function_sseregparm): Likewise. (init_cumulative_args): Likewise. * ipa-cp.c (determine_versionability): Likewise. (count_callers): Likewise. (set_single_call_flag): Likewise. (initialize_node_lattices): Likewise. (estimate_local_effects): Likewise. (create_specialized_node): Likewise. (identify_dead_nodes): Likewise. * ipa-fnsummary.c (compute_fn_summary): Likewise. (ipa_fn_summary_generate): Likewise. * ipa-hsa.c (check_warn_node_versionable): Likewise. (process_hsa_functions): Likewise. * ipa-icf.c (set_local): Likewise. * ipa-inline-analysis.c (initialize_inline_failed): Likewise. * ipa-inline.c (speculation_useful_p): Likewise. * ipa-profile.c (ipa_propagate_frequency): Likewise. (ipa_profile): Likewise. * ipa-split.c (split_function): Likewise. (execute_split_functions): Likewise. * ipa-sra.c (ipa_sra_preliminary_function_checks): Likewise. (ipa_sra_ipa_function_checks): Likewise. * ipa-visibility.c (function_and_variable_visibility): Likewise. * ipa.c (symbol_table::remove_unreachable_nodes): Likewise. * lto-cgraph.c (lto_output_node): Likewise. (input_overwrite_node): Likewise. * multiple_target.c (expand_target_clones): Likewise. * omp-simd-clone.c (simd_clone_create): Likewise. * trans-mem.c (expand_call_tm): Likewise. (ipa_tm_mayenterirr_function): Likewise. (ipa_tm_diagnose_tm_safe): Likewise. (ipa_tm_diagnose_transaction): Likewise. (ipa_tm_create_version): Likewise. (ipa_tm_transform_calls_redirect): Likewise. (ipa_tm_execute): Likewise. * tree-inline.c (expand_call_inline): Likewise. From-SVN: r277601
Diffstat (limited to 'gcc/cgraphclones.c')
-rw-r--r--gcc/cgraphclones.c21
1 files changed, 12 insertions, 9 deletions
diff --git a/gcc/cgraphclones.c b/gcc/cgraphclones.c
index fcf9cd5..84d6e71 100644
--- a/gcc/cgraphclones.c
+++ b/gcc/cgraphclones.c
@@ -159,7 +159,7 @@ set_new_clone_decl_and_node_flags (cgraph_node *new_node)
DECL_SET_IS_OPERATOR_DELETE (new_node->decl, 0);
new_node->externally_visible = 0;
- new_node->local.local = 1;
+ new_node->local = 1;
new_node->lowered = true;
}
@@ -223,7 +223,7 @@ duplicate_thunk_for_node (cgraph_node *thunk, cgraph_node *node)
new_thunk = cgraph_node::create (new_decl);
set_new_clone_decl_and_node_flags (new_thunk);
new_thunk->definition = true;
- new_thunk->local.can_change_signature = node->local.can_change_signature;
+ new_thunk->can_change_signature = node->can_change_signature;
new_thunk->thunk = thunk->thunk;
new_thunk->unique_name = in_lto_p;
new_thunk->former_clone_of = thunk->decl;
@@ -353,10 +353,13 @@ cgraph_node::create_clone (tree new_decl, profile_count prof_count,
}
new_node->analyzed = analyzed;
new_node->definition = definition;
- new_node->local = local;
+ new_node->versionable = versionable;
+ new_node->can_change_signature = can_change_signature;
+ new_node->redefined_extern_inline = redefined_extern_inline;
+ new_node->tm_may_enter_irr = tm_may_enter_irr;
new_node->externally_visible = false;
new_node->no_reorder = no_reorder;
- new_node->local.local = true;
+ new_node->local = true;
new_node->inlined_to = new_inlined_to;
new_node->rtl = rtl;
new_node->frequency = frequency;
@@ -524,11 +527,11 @@ cgraph_node::create_virtual_clone (vec<cgraph_edge *> redirect_callers,
ipa_replace_map *map;
char *name;
- gcc_checking_assert (local.versionable);
+ gcc_checking_assert (versionable);
/* TODO: It would be nice if we could recognize that param_adjustments do not
actually perform any changes, but at the moment let's require it simply
does not exist. */
- gcc_assert (local.can_change_signature || !param_adjustments);
+ gcc_assert (can_change_signature || !param_adjustments);
/* Make a new FUNCTION_DECL tree node */
if (!param_adjustments)
@@ -860,7 +863,7 @@ cgraph_node::create_version_clone (tree new_decl,
new_version->local = local;
new_version->externally_visible = false;
new_version->no_reorder = no_reorder;
- new_version->local.local = new_version->definition;
+ new_version->local = new_version->definition;
new_version->inlined_to = inlined_to;
new_version->rtl = rtl;
new_version->count = count;
@@ -931,7 +934,7 @@ cgraph_node::create_version_clone_with_body
return NULL;
/* TODO: Restore an assert that we do not change signature if
- local.can_change_signature is false. We cannot just check that
+ can_change_signature is false. We cannot just check that
param_adjustments is NULL because unfortunately ipa-split removes return
values from such functions. */
@@ -987,7 +990,7 @@ cgraph_node::create_version_clone_with_body
new_version_node->make_decl_local ();
DECL_VIRTUAL_P (new_version_node->decl) = 0;
new_version_node->externally_visible = 0;
- new_version_node->local.local = 1;
+ new_version_node->local = 1;
new_version_node->lowered = true;
if (!implicit_section)
new_version_node->set_section (get_section ());