From: hubicka Date: Mon, 17 May 2010 23:12:14 +0000 (+0000) Subject: * cgraph.c (cgraph_create_virtual_clone): Only check X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a510bd8da6561c4ae3cc12a7bd3a9ba0ccf185b5;p=thirdparty%2Fgcc.git * cgraph.c (cgraph_create_virtual_clone): Only check versionable_function_p when not in wpa and checking is enabled. * cgrpahunit.c (cgraph_materialize_all_clones): Stabilize after there are no more functions to materialize. * lto/lto.c (lto_1_to_1_map): Partition non-inline clones. (lto_promote_cross_file_statics): Deal with non-inline clones. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@159518 138bc75d-0d04-0410-961f-82ee72b054a4 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 9a7b3c6c52d9..e677aeb94f57 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2010-05-17 Jan Hubicka + + * cgraph.c (cgraph_create_virtual_clone): Only check + versionable_function_p when not in wpa and checking is enabled. + * cgraphunit.c (cgraph_materialize_all_clones): Stabilize after + there are no more functions to materialize. + 2010-05-17 Jan Hubicka * cgraph.h (struct ipa_replace_map): Add parm_num parameter. diff --git a/gcc/cgraph.c b/gcc/cgraph.c index 89e431a7a537..9433301cf776 100644 --- a/gcc/cgraph.c +++ b/gcc/cgraph.c @@ -2184,7 +2184,10 @@ cgraph_create_virtual_clone (struct cgraph_node *old_node, size_t i; struct ipa_replace_map *map; - gcc_assert (tree_versionable_function_p (old_decl)); +#ifdef ENABLE_CHECKING + if (!flag_wpa) + gcc_assert (tree_versionable_function_p (old_decl)); +#endif /* Make a new FUNCTION_DECL tree node */ if (!args_to_skip) diff --git a/gcc/cgraphunit.c b/gcc/cgraphunit.c index 7618dd007434..c811d497afd8 100644 --- a/gcc/cgraphunit.c +++ b/gcc/cgraphunit.c @@ -2425,9 +2425,8 @@ cgraph_materialize_all_clones (void) } } cgraph_materialize_clone (node); + stabilized = false; } - else - stabilized = false; } } } diff --git a/gcc/lto/ChangeLog b/gcc/lto/ChangeLog index e5abeb1f11ae..b26268a3a96f 100644 --- a/gcc/lto/ChangeLog +++ b/gcc/lto/ChangeLog @@ -1,3 +1,8 @@ +2010-05-18 Jan Hubicka + + * lto/lto.c (lto_1_to_1_map): Partition non-inline clones. + (lto_promote_cross_file_statics): Deal with non-inline clones. + 2010-05-18 Jan Hubicka * lto.c (lto_materialize_function): Announce function when diff --git a/gcc/lto/lto.c b/gcc/lto/lto.c index ab55c126e9c2..adfeae95ce88 100644 --- a/gcc/lto/lto.c +++ b/gcc/lto/lto.c @@ -537,9 +537,8 @@ lto_1_to_1_map (void) for (node = cgraph_nodes; node; node = node->next) { - /* We will get proper partition based on function they are inlined to or - cloned from. */ - if (node->global.inlined_to || node->clone_of) + /* We will get proper partition based on function they are inlined to. */ + if (node->global.inlined_to) continue; /* Nodes without a body do not need partitioning. */ if (!node->analyzed) @@ -721,7 +720,7 @@ lto_promote_cross_file_statics (void) struct cgraph_node *node = csi_node (csi); if (node->local.externally_visible) continue; - if (node->clone_of || node->global.inlined_to) + if (node->global.inlined_to) continue; if (!DECL_EXTERNAL (node->decl) && (referenced_from_other_partition_p (&node->ref_list, set, vset)