<div dir="ltr"><a class="GWVZpf gW" id="IloFPc-0" href="mailto:echristo@gmail.com" tabindex="-1">+Eric Christopher</a>  <a class="GWVZpf gW" id="IloFPc-1" href="mailto:aprantl@apple.com" tabindex="-1">+Adrian Prantl</a> <a class="GWVZpf gW" id="IloFPc-2" href="mailto:jdevlieghere@apple.com" tabindex="-1">+Jonas Devlieghere</a> (seems Jonas is doing a bunch of debug info work - guessing he's working with you, Adrian?)<br><br>I'm guessing Eric's the most likely to have contacts over in GCC land to maybe bridge the gap when talking about assembly syntax across the two. Eric - any ideas how best to negotiate this pseudo-standard? (there's another feature or two I'd like to propose too - at least to standardize what the syntax /should/ be, even if gas doesn't support it immediately)<br><br>Paul - perhaps a brief description of the proposed syntax would be helpful to get the ball rolling (even if it's just discussing it amongst ourselves before it ends up in a cross-project discussion).<br><br>- Dave<br><br><div class="gmail_quote"><div dir="ltr">On Wed, Mar 28, 2018 at 11:16 AM via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">TL;DR: If I'm trying to define new assembler directive syntax to<br>
support DWARF v5, it seems like a good idea for all the various<br>
assemblers out there in the world to support the same syntax.<br>
How would I go about negotiating that syntax with other assembler<br>
providers?  Is GNU as the only really relevant one?<br>
<br>
Long version:<br>
<br>
DWARF v5 introduces a couple of new features in the .debug_line section<br>
that require assembler syntax, because the information relates to the<br>
files read by the compiler and there's no other way to inform the<br>
assembler.<br>
<br>
The two bits of information are:<br>
(1) the MD5 checksum of each source file; and<br>
(2) the primary source filename.<br>
<br>
The primary source filename is given in the .debug_info section. In<br>
DWARF v5 this is repeated in the .debug_line section; prior to DWARF v5<br>
it is not.  In both cases, file number 0 refers to this file.  Because<br>
the compiler emits the .debug_info section directly, the assembler is<br>
not aware of the name of the primary source file without some new syntax<br>
to provide that information.  And, it needs the MD5 checksum as well, so<br>
relying on the old-format '.file' directive is insufficient.<br>
<br>
I've added support in LLVM for both of these features, but somewhat<br>
arbitrarily defined assembler syntax to support them.  Obviously if<br>
implementers of other assemblers also want to support DWARF v5, the same<br>
information will have to be represented with assembler syntax somehow,<br>
and of course it would be best if all assemblers supporting DWARF v5<br>
used the same syntax.  But I don't know how to go about doing that.<br>
<br>
Any advice would be welcome.<br>
Thanks,<br>
--paulr<br>
<br>
_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
</blockquote></div></div>