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]

get link map during execution


Hi.

I'm writing a profiler for gcc-compiled C and C++ programs
(http://sourceforge.net/projects/fnccheck/)

The profiling part is fine, but I have a problem when trying
to convert symbol addresses into functions names.

I use BFD to open the program and convert addresses into names.
In order to allow profiling of dynamic libraries, I also open used
.so to solve unresolved addresses.

My only problem is about .so opened with 'dlopen' from 'dlfcn.h'.
These symbols are profiled but the references are not present in
the program (of course).

I'm now using 'link.h' to parse the existing libraries, and it appear
that objects opened with 'dlopen' are visible, but only between the
'dlopen' and the corresponding 'dlclose'.
Is there a way to get the complete list of used libraries at the end of
the execution (even those which are closed) ?

Thank you for any help or documentation about 'link.h' features
(I can't find anything in the libc info, neither in the gcc info).

Regards,
--
Yannick



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