This is the mail archive of the mailing list for the elfutils project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] readelf: DW_CFA_set_loc operand is an address

Mark Wielaard <> writes:

> On Wed, 2015-11-25 at 17:00 +0100, Ben Gamari wrote:
>> Previously this was incorrectly assumed to be an ULEB128. Hilarity
>> ensued.
>> This appears to be the case in both DWARF 3, DWARF 4, and LSB 5.
> Nice catch. Interestingly we seem to handle this correctly in cfi.c, but
> not eu-readelf. But note that DWARF and the LSB eh_frame extension are
> slightly different. For DWARF .debug_frame this is indeed a "plain"
> address and your read_addr_unaligned_inc call is correct. But for
> LSB .eh_frame addresses are "encoded" and you should call read_encoded
> using the fde_encoding. It looks like fde_encoding isn't passed to
> print_cfa_program, so we should probably pass it from
> print_debug_frame_section.
> It appears that there is no testfile which uses DW_CFA_set_loc. If you
> happen to have one that would be nice to add.
> Do you want to combine this with the other patch for printing set_loc?
> Could you add a ChangeLog entry and Signed-off-by line for your patch as
> described in the CONTRIBUTING document:
Oops, sorry about that. I can combine all three of these patches.

Also, I haven't forgotten about the local backtrace support. Your patch
nearly works but I've been under a bit of deadline pressure so I've not
had much time to commit to the elfutils side of things.


- Ben

Attachment: signature.asc
Description: PGP signature

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]