This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
call graphs in sprof
- From: "Arvind Ayyangar" <arvind dot ayyangar at gmail dot com>
- To: libc-alpha at sourceware dot org
- Date: Mon, 2 Jul 2007 12:53:57 +0530
- Subject: call graphs in sprof
Hi,
I have a little library (libfun.so) which calls routines in two
other libraries (libfoo.c and libc.so.6). I have a program which
links to this little library. I tried to profile the library and using
sprof.
The output of sprof is as below:
Flat profile:
Each sample counts as 0.01 seconds.
% cumulative self self total
time seconds seconds calls us/call us/call name
0.00 0.00 0.00 1 0.00 fun
index % time self children called name
[0] 0.0 0.00 0.00 0 printf@@GLIBC_2.0 [0]
0.00 0.00 1/1 fun [2]
-----------------------------------------------
0.00 0.00 1/1 <UNKNOWN>
[2] 0.0 0.00 0.00 1 fun [2]
-----------------------------------------------
The call graph gives me information about calls to glibc
{printf@@GLIBC_2.0 [0]} but provides no information about calls to
library libfoo.so.
Also, what does the <UNKNOWN> in the output above mean? Does it refer
to the function calling it (viz main) or the function foo that it
called..
Thanks in advance
-Arvind