diff options
author | Jan Hubicka <hubicka@ucw.cz> | 2014-11-20 07:15:03 +0100 |
---|---|---|
committer | Jan Hubicka <hubicka@gcc.gnu.org> | 2014-11-20 06:15:03 +0000 |
commit | 1be0e58d3003aa8a780d229bf38b0e4a61928b9e (patch) | |
tree | b027bc052b062a295ed4e82de7214afde37561ce /gcc/ipa-devirt.c | |
parent | 1b5695e6100dec3f7c1e86ba5594471987cda466 (diff) | |
download | gcc-1be0e58d3003aa8a780d229bf38b0e4a61928b9e.zip gcc-1be0e58d3003aa8a780d229bf38b0e4a61928b9e.tar.gz gcc-1be0e58d3003aa8a780d229bf38b0e4a61928b9e.tar.bz2 |
tree.c (free_lang_data_in_type): If BINFO has no important information in it, set it to NULL.
* tree.c (free_lang_data_in_type): If BINFO has no important
information in it, set it to NULL.
(get_binfo_at_offset): Do not walk fields, only bases.
* ipa-utils.h (polymorphic_type_binfo_p): Be ready for BINFO_TYPE
to be NULL.
* ipa-polymorphic-call.c (record_known_type): Likewise.
From-SVN: r217824
Diffstat (limited to 'gcc/ipa-devirt.c')
-rw-r--r-- | gcc/ipa-devirt.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/gcc/ipa-devirt.c b/gcc/ipa-devirt.c index 99475f6..41d4554 100644 --- a/gcc/ipa-devirt.c +++ b/gcc/ipa-devirt.c @@ -1849,7 +1849,7 @@ possible_polymorphic_call_targets_1 (vec <cgraph_node *> &nodes, { tree binfo = TYPE_BINFO (type->type); unsigned int i; - vec <tree> type_binfos = vNULL; + auto_vec <tree, 8> type_binfos; bool possibly_instantiated = type_possibly_instantiated_p (type->type); /* We may need to consider types w/o instances because of possible derived @@ -1868,7 +1868,6 @@ possible_polymorphic_call_targets_1 (vec <cgraph_node *> &nodes, inserted, matched_vtables, type->anonymous_namespace, completep); } - type_binfos.release (); for (i = 0; i < type->derived_types.length (); i++) possible_polymorphic_call_targets_1 (nodes, inserted, matched_vtables, @@ -2226,7 +2225,7 @@ possible_polymorphic_call_targets (tree otr_type, { static struct cgraph_node_hook_list *node_removal_hook_holder; vec <cgraph_node *> nodes = vNULL; - vec <tree> bases_to_consider = vNULL; + auto_vec <tree, 8> bases_to_consider; odr_type type, outer_type; polymorphic_call_target_d key; polymorphic_call_target_d **slot; @@ -2521,7 +2520,6 @@ possible_polymorphic_call_targets (tree otr_type, } } - bases_to_consider.release(); (*slot)->targets = nodes; (*slot)->complete = complete; if (completep) |