This is the mail archive of the binutils@sourceware.org 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]

working with debug symbols


Hi everyone,

I am working on a project where, ideally, we would like to be able to
say for every byte in the .text section of an (ELF or PE) executable,
whether or not it is part of an instruction or not (i.e. whether it's
code or data). The executables will be compiled with gcc and debugging
information. At which granularity can we extract this information from
the debug symbols? I know it's possible to get back the addresses of
the function entry points. I assume we can also get the address of the
first instruction of most lines in a source file. I would appreciate
some pointers on how to do that. However, a way to tag each address as
code or data would be even better. Finally, will any of these break if
the debug symbols are stored outside the executable?

Thank you,
Nikos


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