This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils 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: STABS API..


--- Ian Lance Taylor <ian@airs.com> wrote:
>... 
> I don't think you need to call write_debug for the
> specific case of handling fields offsets in structs.

> Once you have the parsed debug information, I think 
> you can call debug_find_tagged_type to find the
> struct, debug_get_fields to get the fields of the
> struct, debug_get_field_name to get the field name, 
> and debug_get_field_bitpos to get the bit offset.
>...

Ian, 

Thanks for the pointers; they've helped me a lot. 

I just saw your original reply on May 2 about five
minutes ago. It must have been tagged as spam in my
Inbox, and hidden among the other emails in my
gdb/binutils mailing list box. Thanks for the re-post.


I created a 'debug_find_named_variable()' function,
then made some of the debug_type functions visible
outside of debug.c. I think I've got most of the
functionality I need now, at least in terms of getting
the field name(s) once I have the debug_type handle.
I'm sure I've misinterpreted some of the
DEBUG_KIND_... values, but it hasn't bitten me yet.

Since those debug_variable functions didn't already
exist in the debug.[ch] interface, that makes me think
that I'm looking in the wrong place for the variable
info. I looked at using the asymbol struct directly,
but it wasn't clear how to map the asymbol->value to
what I need. Do you think adding the debug_variable
functions to debug.h makes sense?

It seems like for several of the debug_XXX types in
debug.c, either the types aren't exported (i.e. aren't
in debug.h), and/or they only have 'make' and 'write'
functions available externally, if at all. Is there a
design reason for that, or is adding in the accessor
functions to the debug.h interface Just Fine(tm)?

BTW, I checked out your website, and saw the pictures
of your daughter. My daughter Svea is two months older
(August 11), and from the looks of it they'd enjoy
getting into things together.

Thanks again,
    Justin




		
__________________________________ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/ 


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