aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJan Hubicka <hubicka@ucw.cz>2014-10-02 09:07:04 +0200
committerJan Hubicka <hubicka@gcc.gnu.org>2014-10-02 07:07:04 +0000
commit5ae5a2386e7ddfeb79bb703c7d81282bd0a0d885 (patch)
tree29245837e96d630a369b99a5dc1ca12ac87d4c65
parent5ce97055e0f4077280146d62394370882f1b13e0 (diff)
downloadgcc-5ae5a2386e7ddfeb79bb703c7d81282bd0a0d885.zip
gcc-5ae5a2386e7ddfeb79bb703c7d81282bd0a0d885.tar.gz
gcc-5ae5a2386e7ddfeb79bb703c7d81282bd0a0d885.tar.bz2
cgraphclones.c (build_function_type_skip_args): Do not make new type variant of old.
* cgraphclones.c (build_function_type_skip_args): Do not make new type variant of old. From-SVN: r215795
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/cgraphclones.c18
2 files changed, 6 insertions, 17 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index e07c960..8600040 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,10 @@
2014-10-01 Jan Hubicka <hubicka@ucw.cz>
+ * cgraphclones.c (build_function_type_skip_args): Do not make new
+ type variant of old.
+
+2014-10-01 Jan Hubicka <hubicka@ucw.cz>
+
* ipa-prop.h (ipa_get_controlled_uses): Add hack to avoid ICE
when speculation is added.
(ipa_edge_args): Add polymorphic_call_contexts.
diff --git a/gcc/cgraphclones.c b/gcc/cgraphclones.c
index 38d92f5..37b234f 100644
--- a/gcc/cgraphclones.c
+++ b/gcc/cgraphclones.c
@@ -177,7 +177,7 @@ build_function_type_skip_args (tree orig_type, bitmap args_to_skip,
bool skip_return)
{
tree new_type = NULL;
- tree args, new_args = NULL, t;
+ tree args, new_args = NULL;
tree new_reversed;
int i = 0;
@@ -218,22 +218,6 @@ build_function_type_skip_args (tree orig_type, bitmap args_to_skip,
if (skip_return)
TREE_TYPE (new_type) = void_type_node;
- /* This is a new type, not a copy of an old type. Need to reassociate
- variants. We can handle everything except the main variant lazily. */
- t = TYPE_MAIN_VARIANT (orig_type);
- if (t != orig_type)
- {
- t = build_function_type_skip_args (t, args_to_skip, skip_return);
- TYPE_MAIN_VARIANT (new_type) = t;
- TYPE_NEXT_VARIANT (new_type) = TYPE_NEXT_VARIANT (t);
- TYPE_NEXT_VARIANT (t) = new_type;
- }
- else
- {
- TYPE_MAIN_VARIANT (new_type) = new_type;
- TYPE_NEXT_VARIANT (new_type) = NULL;
- }
-
return new_type;
}