[PATCH] D39854: [DWARFv5] Support FORM_strp in .debug_line.dwo

Jonas Devlieghere via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 13 03:41:04 PST 2017


JDevlieghere added a comment.

In https://reviews.llvm.org/D39854#922574, @probinson wrote:

> Oh, head-smack!  You don't need a unit to know the address size; the line table has always had that info, although indirectly.
>  DW_LNE_set_address (the only opcode that specifies an actual address) is an extended opcode, which has a ULEB telling you how long the operands are.  Which is, one byte for the opcode, and.... the size of the address.  Doh!
>
> That means, DWARF v5 is the first time we actually *do* (sometimes) need a unit to parse the .debug_line section, instead of the first time we *don't* need it.
>
> This patch is about one of the cases where we do need a DWARFUnit, so I think it's not particularly affected by this revelation, but there is likely to be some simplification that can be done as a follow-up.


I missed the call to `setAddressSize` below, but I'm glad that I did. Thanks for explaining Paul!


https://reviews.llvm.org/D39854





More information about the llvm-commits mailing list