From 479f99c9679096f14f8d9d8bbb0ada049dbdead1 Mon Sep 17 00:00:00 2001 From: Jan Hubicka Date: Mon, 16 May 2016 11:55:14 +0200 Subject: [PATCH] lto-cgraph.c (compute_ltrans_boundary, [...]): Fix handling of inline thunks * lto-cgraph.c (compute_ltrans_boundary, output_symtab): Fix handling of inline thunks * lto-partition.c (add_symbol_to_partition_1): Likewise. From-SVN: r236270 --- gcc/ChangeLog | 5 +++++ gcc/lto-cgraph.c | 4 ++-- gcc/lto/ChangeLog | 4 ++++ gcc/lto/lto-partition.c | 2 +- 4 files changed, 12 insertions(+), 3 deletions(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 4b7aeb535c8..2bbd60e12c8 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2016-05-16 Jan Hubicka + + * lto-cgraph.c (compute_ltrans_boundary, output_symtab): Fix handling + of inline thunks + 2016-05-16 Matthew Wahab Ramana Radhakrishnan Jiong Wang diff --git a/gcc/lto-cgraph.c b/gcc/lto-cgraph.c index 14302138efa..11d440b7b74 100644 --- a/gcc/lto-cgraph.c +++ b/gcc/lto-cgraph.c @@ -972,7 +972,7 @@ compute_ltrans_boundary (lto_symtab_encoder_t in_encoder) if (node->alias && node->analyzed) create_references (encoder, node); if (cnode - && cnode->thunk.thunk_p) + && cnode->thunk.thunk_p && !cnode->global.inlined_to) add_node_to (encoder, cnode->callees->callee, false); while (node->transparent_alias && node->analyzed) { @@ -1028,7 +1028,7 @@ output_symtab (void) { node = dyn_cast (lto_symtab_encoder_deref (encoder, i)); if (node - && (node->thunk.thunk_p + && ((node->thunk.thunk_p && !node->global.inlined_to) || lto_symtab_encoder_in_partition_p (encoder, node))) { output_outgoing_cgraph_edges (node->callees, ob, encoder); diff --git a/gcc/lto/ChangeLog b/gcc/lto/ChangeLog index 80ffba329ad..06458d46033 100644 --- a/gcc/lto/ChangeLog +++ b/gcc/lto/ChangeLog @@ -1,3 +1,7 @@ +2016-05-16 Jan Hubicka + + * lto-partition.c (add_symbol_to_partition_1): Likewise. + 2016-05-03 Jan Hubicka * lto-symtab.c (lto_cgraph_replace_node): Initialize inline_failed. diff --git a/gcc/lto/lto-partition.c b/gcc/lto/lto-partition.c index c191d24b497..453343a8471 100644 --- a/gcc/lto/lto-partition.c +++ b/gcc/lto/lto-partition.c @@ -163,7 +163,7 @@ add_symbol_to_partition_1 (ltrans_partition part, symtab_node *node) /* Add all thunks associated with the function. */ for (e = cnode->callers; e; e = e->next_caller) - if (e->caller->thunk.thunk_p) + if (e->caller->thunk.thunk_p && !e->caller->global.inlined_to) add_symbol_to_partition_1 (part, e->caller); /* Instrumented version is actually the same function. -- 2.30.2