https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69393
--- Comment #10 from rguenther at suse dot de <rguenther at suse dot de> --- On Fri, 22 Jan 2016, jakub at gcc dot gnu.org wrote: > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69393 > > --- Comment #9 from Jakub Jelinek <jakub at gcc dot gnu.org> --- > Yes, the type is meant to go into the debug info. But it is DECL_NAMELESS, so > the debug info should not contain DW_AT_name or linkage name for it. So is_naming_typedef_decl should check DECL_NAMELESS? Like so? Index: gcc/dwarf2out.c =================================================================== --- gcc/dwarf2out.c (revision 232717) +++ gcc/dwarf2out.c (working copy) @@ -22970,6 +22970,7 @@ is_naming_typedef_decl (const_tree decl) { if (decl == NULL_TREE || TREE_CODE (decl) != TYPE_DECL + || DECL_NAMELESS (decl) || !is_tagged_type (TREE_TYPE (decl)) || DECL_IS_BUILTIN (decl) || is_redundant_typedef (decl) this unfortunately doesn't fix the ICE for me because we don't stream DECL_NAMELESS it seems. If I fix that the fix above works. The lack of consistency between where free-lang-data forces a assembler name and the debug expectation is disturbing (I suppose with -fno-lto-odr-type-merging it would ICE all over the place)