[Dwarf-Discuss] DWARF5 line table file numbering inconsistent

Robinson, Paul paul.robinson@sony.com
Thu Oct 15 16:27:16 GMT 2020


> On Thu, Oct 15, 2020 at 11:46:55AM -0400, Eric Christopher via Dwarf-
> Discuss wrote:
> > "This margin is too narrow to contain..." ;)
> >
> > I'd like to see the doc - it's easy to believe we've gotten something
> wrong
> > here.. Might be good to fix this as textual edits rather than waiting on
> a
> > full dwarf standard release because we're going to run into this a lot
> if
> > we can't get it sorted quickly as multiple producers all produce
> something
> > slightly different and incompatible.
> >
> > Thoughts?
> 
> Yes. Please do publish the document somewhere. It would be interesting
> to know exactly what is being said to be inconsistent. As far as I
> know the issue of the file index defaulting to one and not having a
> way to refer to index zero from an DIE attribute is
> inconvenient/inefficient (because you often end up duplicating the
> zero file entry), but not inconsistent. It is consistent with how
> DWARF4 line table file numbers are interpreted and I believe that is
> also how consumers do it.
> 
> Thanks,
> 
> Mark
> 

The best place for a list/document would be on wiki.dwarfstd.org I think?

The line table has allowed file 0 to mean the primary source file starting
in DWARF v4; DWARF v5 just made file 0 be explicit in the file table and
not implicitly a reference to the info in the compile_unit header.  It is
an oversight that we missed the reference regarding DW_AT_decl_file (and
presumably the other _file attributes, I haven't checked).

--paulr





More information about the Dwarf-discuss mailing list