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

--- Comment #60 from Markus Trippelsdorf <trippels at gcc dot gnu.org> ---
(In reply to Jason Merrill from comment #59)
> (In reply to Markus Trippelsdorf from comment #58)
> 
> These are breaking with -flto because make_decl_local clears DECL_COMDAT, so
> the check I added to ipa_devirt doesn't trigger.  Honza, can we just remove
> that from make_decl_local?  It seems harmless to me to leave the flag set.

For 4.9 this may trigger the assert in gcc/ipa.c:

 983       gcc_assert ((!DECL_WEAK (node->decl)
 984                   && !DECL_COMDAT (node->decl))
 985                   || TREE_PUBLIC (node->decl)
 986                   || node->weakref
 987                   || DECL_EXTERNAL (node->decl));

Reply via email to