aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Hubicka <hubicka@gcc.gnu.org>2010-05-29 07:32:24 +0000
committerJan Hubicka <hubicka@gcc.gnu.org>2010-05-29 07:32:24 +0000
commit9990e02a91ef87f091d324206074b4a263f1fb31 (patch)
tree3f729b5594d5da5a16c67b490dbcdcd15da77804
parent036546e58ac96338a9167fb1b239670fdca99ab3 (diff)
downloadgcc-9990e02a91ef87f091d324206074b4a263f1fb31.zip
gcc-9990e02a91ef87f091d324206074b4a263f1fb31.tar.gz
gcc-9990e02a91ef87f091d324206074b4a263f1fb31.tar.bz2
Add missing part of previous commit.
From-SVN: r160017
-rw-r--r--gcc/cgraphunit.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/gcc/cgraphunit.c b/gcc/cgraphunit.c
index e7e9e29..ab6bf06 100644
--- a/gcc/cgraphunit.c
+++ b/gcc/cgraphunit.c
@@ -2181,6 +2181,12 @@ cgraph_function_versioning (struct cgraph_node *old_version_node,
else
new_decl = build_function_decl_skip_args (old_decl, args_to_skip);
+ cgraph_make_decl_local (new_decl);
+ /* Generate a new name for the new version. */
+ DECL_NAME (new_decl) = clone_function_name (old_decl, clone_name);
+ SET_DECL_ASSEMBLER_NAME (new_decl, DECL_NAME (new_decl));
+ SET_DECL_RTL (new_decl, NULL);
+
/* Create the new version's call-graph node.
and update the edges of the new node. */
new_version_node =