[Dwarf-Discuss] libdwarf - Working with 64 bit images
Fri Jul 8 20:31:08 GMT 2011
On 07/08/2011 11:59 AM, Ron Louzon wrote:
> I have been using libelf/libdwarf to parse 32-bit debug images. I now need to
> accomodate 64-bit image files. I enabled some libelf defines to allow the
> reading of those 64-bit image files. After examining libdwarf, it appears to me
> that the 2 halves of 64-bit address data should be available in the Dwarf_loc
> structures as number1 and number 2. Is there anything else I need to know as I
> attempt to parse these files? Thanks.
Unless you have done something special (why would you?) the types
for all libdwarf fields are such that they all hold 64bit values.
So the address data (regardless if 32 or 64 bits) will be in individual
libdwarf has always done everything in 64bit signed/unsigned at all times
(except the fields like the DWARF version and a few others that are defined
to be smaller than 64 bits).
So reading 64 bits requires no effort on your part other than getting the
libelf that has the 64bit interfaces (and indeed I would expect 64bit
libelf functions to be
on any libelf one would be likely to find!).
The thunder was ominous sounding, much like the sound of a thin sheet of metal being shaken backstage during the storm scene in a play. -- Barbara Fetherolf
More information about the Dwarf-discuss