aboutsummaryrefslogtreecommitdiff
path: root/gcc/ipa.c
diff options
context:
space:
mode:
authorDavid Malcolm <dmalcolm@redhat.com>2013-10-31 21:26:14 +0000
committerDavid Malcolm <dmalcolm@gcc.gnu.org>2013-10-31 21:26:14 +0000
commit5e20cdc96e65d712b5149af59e4580873d7928b7 (patch)
treef027b7dfe45942a8ae7ec9d539dbfe1b2330a706 /gcc/ipa.c
parent64f37e9d425fc58e75724f4461431a30b5836403 (diff)
downloadgcc-5e20cdc96e65d712b5149af59e4580873d7928b7.zip
gcc-5e20cdc96e65d712b5149af59e4580873d7928b7.tar.gz
gcc-5e20cdc96e65d712b5149af59e4580873d7928b7.tar.bz2
Automated part of renaming of symtab_node_base to symtab_node.
gcc/ Patch autogenerated by rename_symtab.py from https://github.com/davidmalcolm/gcc-refactoring-scripts revision 58bb219cc090b2f4516a9297d868c245495ee622 with ChangeLog entry fixed up by hand. * cgraph.c (x_cgraph_nodes_queue): Rename symtab_node_base to symtab_node. (cgraph_node_for_asm): Likewise. * cgraph.h (symtab_node_base): Likewise. (cgraph_node): Likewise. (varpool_node): Likewise. (is_a_helper <cgraph_node>::test): Likewise. (is_a_helper <varpool_node>::test): Likewise. (symtab_nodes): Likewise. (symtab_register_node): Likewise. (symtab_unregister_node): Likewise. (symtab_remove_node): Likewise. (symtab_get_node): Likewise. (symtab_node_for_asm): Likewise. (symtab_node_asm_name): Likewise. (symtab_node_name): Likewise. (symtab_insert_node_to_hashtable): Likewise. (symtab_add_to_same_comdat_group): Likewise. (symtab_dissolve_same_comdat_group_list): Likewise. (dump_symtab_node): Likewise. (debug_symtab_node): Likewise. (dump_symtab_base): Likewise. (verify_symtab_node): Likewise. (verify_symtab_base): Likewise. (symtab_used_from_object_file_p): Likewise. (symtab_alias_ultimate_target): Likewise. (symtab_resolve_alias): Likewise. (fixup_same_cpp_alias_visibility): Likewise. (symtab_for_node_and_aliases): Likewise. (symtab_nonoverwritable_alias): Likewise. (availability symtab_node_availability): Likewise. (symtab_semantically_equivalent_p): Likewise. (fixup_same_cpp_alias_visibility): Likewise. (symtab_prevail_in_asm_name_hash): Likewise. (cgraph): Likewise. (varpool): Likewise. (varpool_first_variable): Likewise. (varpool_next_variable): Likewise. (varpool_first_static_initializer): Likewise. (varpool_next_static_initializer): Likewise. (varpool_first_defined_variable): Likewise. (varpool_next_defined_variable): Likewise. (cgraph_first_defined_function): Likewise. (cgraph_next_defined_function): Likewise. (cgraph_first_function): Likewise. (cgraph_next_function): Likewise. (cgraph_first_function_with_gimple_body): Likewise. (cgraph_next_function_with_gimple_body): Likewise. (symtab_alias_target): Likewise. (symtab_real_symbol_p): Likewise. (symtab_can_be_discarded): Likewise. * cgraphbuild.c (mark_address): Likewise. (mark_load): Likewise. (mark_store): Likewise. * cgraphunit.c (decide_is_symbol_needed): Likewise. (first): Likewise. (enqueue_node): Likewise. (referred_to_p): Likewise. (cgraph_process_same_body_aliases): Likewise. (analyze_functions): Likewise. (handle_alias_pairs): Likewise. (output_weakrefs): Likewise. (compile): Likewise. * gimple-fold.c (can_refer_decl_in_current_unit_p): Likewise. * ipa-inline-analysis.c (inline_write_summary): Likewise. * ipa-prop.c (remove_described_reference): Likewise. (try_decrement_rdesc_refcount): Likewise. (ipa_edge_duplication_hook): Likewise. * ipa-ref.c (ipa_record_reference): Likewise. (ipa_maybe_record_reference): Likewise. (ipa_clone_ref): Likewise. (ipa_clone_references): Likewise. (ipa_clone_referring): Likewise. (ipa_find_reference): Likewise. (ipa_remove_stmt_references): Likewise. (ipa_clear_stmts_in_references): Likewise. * ipa-ref.h (symtab_node_base): Likewise. (ipa_ref): Likewise. (ipa_record_reference): Likewise. (ipa_maybe_record_reference): Likewise. (ipa_clone_references): Likewise. (ipa_clone_referring): Likewise. (ipa_clone_ref): Likewise. (ipa_find_reference): Likewise. (ipa_remove_stmt_references): Likewise. (ipa_clear_stmts_in_references): Likewise. * ipa-reference.c (ipa_reference_write_optimization_summary): Likewise. * ipa.c (enqueue_node): Likewise. (process_references): Likewise. (walk_polymorphic_call_targets): Likewise. (symtab_remove_unreachable_nodes): Likewise. (address_taken_from_non_vtable_p): Likewise. (comdat_can_be_unshared_p_1): Likewise. (comdat_can_be_unshared_p): Likewise. (can_replace_by_local_alias): Likewise. (function_and_variable_visibility): Likewise. * is-a.h: Likewise (within example in comment). * lto-cgraph.c (input_cgraph_opt_summary): Likewise. (lto_symtab_encoder_encode): Likewise. (lto_symtab_encoder_delete_node): Likewise. (lto_symtab_encoder_in_partition_p): Likewise. (lto_set_symtab_encoder_in_partition): Likewise. (output_refs): Likewise. (compute_ltrans_boundary): Likewise. (output_symtab): Likewise. (input_node): Likewise. (input_ref): Likewise. (input_edge): Likewise. (input_cgraph_1): Likewise. (input_refs): Likewise. (output_cgraph_opt_summary): Likewise. (input_node_opt_summary): Likewise. (input_cgraph_opt_section): Likewise. * lto-section-in.c (lto_free_function_in_decl_state_for_node): Likewise. * lto-streamer-out.c (lto_output): Likewise. (output_symbol_p): Likewise. (produce_symtab): Likewise. * lto-streamer.h (lto_encoder_entry): Likewise. (lto_free_function_in_decl_state_for_node): Likewise. (lto_symtab_encoder_encode): Likewise. (lto_symtab_encoder_delete_node): Likewise. (lto_symtab_encoder_in_partition_p): Likewise. (lto_set_symtab_encoder_in_partition): Likewise. (lto_symtab_encoder_lookup): Likewise. (lsei_node): Likewise. (lto_symtab_encoder_deref): Likewise. * symtab.c (symtab_hash): Likewise. (assembler_name_hash): Likewise. (symtab_nodes): Likewise. (hash_node): Likewise. (eq_node): Likewise. (hash_node_by_assembler_name): Likewise. (eq_assembler_name): Likewise. (insert_to_assembler_name_hash): Likewise. (unlink_from_assembler_name_hash): Likewise. (symtab_prevail_in_asm_name_hash): Likewise. (symtab_register_node): Likewise. (symtab_insert_node_to_hashtable): Likewise. (symtab_unregister_node): Likewise. (symtab_get_node): Likewise. (symtab_remove_node): Likewise. (symtab_initialize_asm_name_hash): Likewise. (symtab_node_for_asm): Likewise. (symtab_add_to_same_comdat_group): Likewise. (symtab_dissolve_same_comdat_group_list): Likewise. (symtab_node_asm_name): Likewise. (symtab_node_name): Likewise. (dump_symtab_base): Likewise. (dump_symtab_node): Likewise. (dump_symtab): Likewise. (debug_symtab_node): Likewise. (verify_symtab_base): Likewise. (verify_symtab_node): Likewise. (verify_symtab): Likewise. (symtab_used_from_object_file_p): Likewise. (symtab_node_availability): Likewise. (symtab_alias_ultimate_target): Likewise. (fixup_same_cpp_alias_visibility): Likewise. (symtab_resolve_alias): Likewise. (symtab_for_node_and_aliases): Likewise. (symtab_for_node_and_aliases): Likewise. (symtab_nonoverwritable_alias_1): Likewise. (symtab_nonoverwritable_alias): Likewise. (symtab_semantically_equivalent_p): Likewise. * value-prof.c (init_node_map): Likewise. * varasm.c (find_decl): Likewise. * varpool.c (varpool_node_for_asm): Likewise. (varpool_remove_unreferenced_decls): Likewise. gcc/c-family/ Patch autogenerated by rename_symtab.py from https://github.com/davidmalcolm/gcc-refactoring-scripts revision 58bb219cc090b2f4516a9297d868c245495ee622 * c-pragma.c (maybe_apply_pending_pragma_weaks): Rename symtab_node_base to symtab_node. gcc/lto/ Patch autogenerated by rename_symtab.py from https://github.com/davidmalcolm/gcc-refactoring-scripts revision 58bb219cc090b2f4516a9297d868c245495ee622 * lto-partition.c (add_symbol_to_partition): Rename symtab_node_base to symtab_node. (get_symbol_class): Likewise. (symbol_partitioned_p): Likewise. (add_references_to_partition): Likewise. (add_symbol_to_partition_1): Likewise. (contained_in_symbol): Likewise. (add_symbol_to_partition): Likewise. (lto_1_to_1_map): Likewise. (lto_max_map): Likewise. (lto_balanced_map): Likewise. (privatize_symbol_name): Likewise. (promote_symbol): Likewise. (may_need_named_section_p): Likewise. (rename_statics): Likewise. (lto_promote_statics_nonwpa): Likewise. * lto-symtab.c (lto_symtab_merge): Likewise. (lto_symtab_resolve_replaceable_p): Likewise. (lto_symtab_symbol_p): Likewise. (lto_symtab_resolve_can_prevail_p): Likewise. (lto_symtab_resolve_symbols): Likewise. (lto_symtab_merge_decls_2): Likewise. (lto_symtab_merge_decls_1): Likewise. (lto_symtab_merge_decls): Likewise. (lto_symtab_merge_symbols_1): Likewise. (lto_symtab_merge_symbols): Likewise. (lto_symtab_prevailing_decl): Likewise. * lto.c (lto_wpa_write_files): Likewise. (read_cgraph_and_symbols): Likewise. (do_whole_program_analysis): Likewise. From-SVN: r204279
Diffstat (limited to 'gcc/ipa.c')
-rw-r--r--gcc/ipa.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/gcc/ipa.c b/gcc/ipa.c
index 9600b48c..aef437a 100644
--- a/gcc/ipa.c
+++ b/gcc/ipa.c
@@ -107,7 +107,7 @@ update_inlined_to_pointer (struct cgraph_node *node, struct cgraph_node *inlined
reachable. */
static void
-enqueue_node (symtab_node node, symtab_node *first,
+enqueue_node (symtab_node *node, symtab_node **first,
struct pointer_set_t *reachable)
{
/* Node is still in queue; do nothing. */
@@ -125,7 +125,7 @@ enqueue_node (symtab_node node, symtab_node *first,
static void
process_references (struct ipa_ref_list *list,
- symtab_node *first,
+ symtab_node **first,
bool before_inlining_p,
struct pointer_set_t *reachable)
{
@@ -133,7 +133,7 @@ process_references (struct ipa_ref_list *list,
struct ipa_ref *ref;
for (i = 0; ipa_ref_list_reference_iterate (list, i, ref); i++)
{
- symtab_node node = ref->referred;
+ symtab_node *node = ref->referred;
if (node->definition && !node->in_other_partition
&& ((!DECL_EXTERNAL (node->decl) || node->alias)
@@ -161,7 +161,7 @@ process_references (struct ipa_ref_list *list,
static void
walk_polymorphic_call_targets (pointer_set_t *reachable_call_targets,
struct cgraph_edge *edge,
- symtab_node *first,
+ symtab_node **first,
pointer_set_t *reachable, bool before_inlining_p)
{
unsigned int i;
@@ -287,7 +287,7 @@ walk_polymorphic_call_targets (pointer_set_t *reachable_call_targets,
bool
symtab_remove_unreachable_nodes (bool before_inlining_p, FILE *file)
{
- symtab_node first = (symtab_node) (void *) 1;
+ symtab_node *first = (symtab_node *) (void *) 1;
struct cgraph_node *node, *next;
struct varpool_node *vnode, *vnext;
bool changed = false;
@@ -339,12 +339,12 @@ symtab_remove_unreachable_nodes (bool before_inlining_p, FILE *file)
}
/* Perform reachability analysis. */
- while (first != (symtab_node) (void *) 1)
+ while (first != (symtab_node *) (void *) 1)
{
bool in_boundary_p = !pointer_set_contains (reachable, first);
- symtab_node node = first;
+ symtab_node *node = first;
- first = (symtab_node)first->aux;
+ first = (symtab_node *)first->aux;
/* If we are processing symbol in boundary, mark its AUX pointer for
possible later re-processing in enqueue_node. */
@@ -363,7 +363,7 @@ symtab_remove_unreachable_nodes (bool before_inlining_p, FILE *file)
all other in the same comdat group to be also reachable. */
if (node->same_comdat_group)
{
- symtab_node next;
+ symtab_node *next;
for (next = node->same_comdat_group;
next != node;
next = next->same_comdat_group)
@@ -640,7 +640,7 @@ ipa_discover_readonly_nonaddressable_vars (void)
/* Return true when there is a reference to node and it is not vtable. */
static bool
-address_taken_from_non_vtable_p (symtab_node node)
+address_taken_from_non_vtable_p (symtab_node *node)
{
int i;
struct ipa_ref *ref;
@@ -661,7 +661,7 @@ address_taken_from_non_vtable_p (symtab_node node)
/* A helper for comdat_can_be_unshared_p. */
static bool
-comdat_can_be_unshared_p_1 (symtab_node node)
+comdat_can_be_unshared_p_1 (symtab_node *node)
{
/* When address is taken, we don't know if equality comparison won't
break eventually. Exception are virutal functions, C++
@@ -704,13 +704,13 @@ comdat_can_be_unshared_p_1 (symtab_node node)
but in C++ there is no way to compare their addresses for equality. */
static bool
-comdat_can_be_unshared_p (symtab_node node)
+comdat_can_be_unshared_p (symtab_node *node)
{
if (!comdat_can_be_unshared_p_1 (node))
return false;
if (node->same_comdat_group)
{
- symtab_node next;
+ symtab_node *next;
/* If more than one function is in the same COMDAT group, it must
be shared even if just one function in the comdat group has
@@ -859,7 +859,7 @@ varpool_externally_visible_p (struct varpool_node *vnode)
*/
bool
-can_replace_by_local_alias (symtab_node node)
+can_replace_by_local_alias (symtab_node *node)
{
return (symtab_node_availability (node) > AVAIL_OVERWRITABLE
&& !symtab_can_be_discarded (node));
@@ -919,7 +919,7 @@ function_and_variable_visibility (bool whole_program)
if (node->same_comdat_group && DECL_EXTERNAL (node->decl))
{
#ifdef ENABLE_CHECKING
- symtab_node n;
+ symtab_node *n;
for (n = node->same_comdat_group;
n != node;