[Dwarf-Discuss] How to get union member offset?

Jun Koi junkoi2004@gmail.com
Fri Mar 27 01:37:03 GMT 2009

On Fri, Mar 27, 2009 at 10:33 AM, Jun Koi <junkoi2004 at gmail.com> wrote:
> Hi,
> I am trying to get the offset of a member in an union. However, there
> is no attribute DW_AT_data_member_location attached to it!
> I heard that we can get the offset of the container union instead (the
> union is a member of another struct). But how can we get the
> container?
> I use objdump to see the information, and information attached to my
> union's member is only:
> - DW_AT_name
> - DW_AT_decl_file
> - DW_AT_decl_line
> - DW_AT_type

I use "objdump -W" to retrieve information, and I suppose that already
gave me as much information it can?


More information about the Dwarf-discuss mailing list