991108.4 | B | A | D. Anderson | Editorial | DW_form_ref ambiguous |
The problem is that the description of
DW_FORM_ref_addr and 'references'
needs clarification. Or so I believe.
Section 7.5.4, Attribute Encodings, describes
DW_FORM_ref_addr.
The description says the reference is the size of an address
on the target architecture.
This is surely a mistake, because on a 16bit-pointer-architecture
it would mean that the reference could not exceed
16 bits, which makes only
a limited amount of sense as the reference is from one
part of the dwarf to another, and could (in theory)
be *on the disk* and not limited to what fits in memory.
Since MIPS is 32 bit pointers (at the smallest)
the restriction is not a problem for MIPS/SGI.
The 32bit pointer ABIs are limited to 32 bit section sizes
anyway (as a result of Elf32).
I cannot really call this a proposal as I am not proposing
new wording. I am saying I think new wording is needed.
Maybe I am just misunderstanding the intent of this FORM. ?
Editorial change: The wording should be clarified. In the description for DW_FORM_ref_addr "address" should be replaced with "offset from the beginning of the .debug_info section". The size of a DW_FORM_ref_addr should be 32 or 64 bits. See Issue 991102.1.