https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94469
--- Comment #15 from Tom de Vries <vries at gcc dot gnu.org> --- (In reply to Tom de Vries from comment #8) > > So while I intended to have the early CUs behave like fully abstract > > the actual DWARF is different. I understand that if I emit the early CU as > > partial unit it becomes abstract? > > Well, that's my theory. > > I've created a minimal dwarf assembler variant corresponding to the C > test-case (with only var aaa), and I could reproduce the problem, however > after changing the tag to DW_TAG_partial_unit still a symbol table for that > partial unit was created. It seems that the inter-cu ref handling code is > responsible for that. I'll try to fix this. > Filed PR gdb/25798 - "symbol in non-imported PU should not appear in symtabs.