finding fuction names

Tom.Bucken at sybase.com Tom.Bucken at sybase.com
Sat Oct 18 02:07:11 EST 2008


/*

Hi,

   We have code in our product that produces stacktraces.  Part of the
implementation of this code runs nm to find all of the entry points in 
our libraries.

   Using the 7.0 version of this compiler to compile the simple code below

xlC_r -c -q64 tt.cxx 
 nm -C tt.o
                 U __IBMCPlusPlusExceptionV1
0000000000000000 D test()
0000000000000000 T .test()

   Using the 8.0 version of this compiler to compile the simple code below

xlC_r -c -q64 tt.cxx 
nm -C tt.o
                 U __IBMCPlusPlusExceptionV2
0000000000000000 D test()


    We grep the nm output for text symbols which are labeled with 'T'.
Not all function names are not labeled as text in objects compiled with 
8.0.
Is there another way to find all of the fuction names in a library or
a compiler switch that will put all fuctions into the text segment ?

thanks,

Tom

*/
 
int test()
{
  return 1;
}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ozlabs.org/pipermail/linuxppc-dev/attachments/20081017/4a90ac8e/attachment.htm>


More information about the Linuxppc-dev mailing list