https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80763

Jan Hubicka <hubicka at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED

--- Comment #11 from Jan Hubicka <hubicka at gcc dot gnu.org> ---
The reduced testcase does not reproduce anymore so I assumed this to be fixed,
sorry for that.  The problem is that comdats pass privatizes inlined thunk.
This is bid odd side case of for_symbol_thunk_and_aliases - honestly i am not
sure if it should consider inlined thunk to be thunk anymore, but given the
name it probably should.

Honza

Index: ipa-comdats.c
===================================================================
--- ipa-comdats.c       (revision 256232)
+++ ipa-comdats.c       (working copy)
@@ -341,7 +341,7 @@ ipa_comdats (void)
       if (!symbol->get_comdat_group ()
          && !symbol->alias
          && (!(fun = dyn_cast <cgraph_node *> (symbol))
-             || !fun->thunk.thunk_p)
+             || (!fun->thunk.thunk_p && !fun->global.inlined_to))
          && symbol->real_symbol_p ())
        {
          tree *val = map.get (symbol);

Reply via email to