Finding a profiler that works, damnit
Posted Mar 24, 2010 8:10 UTC (Wed) by
ringerc (subscriber, #3071)
In reply to:
Finding a profiler that works, damnit by foom
Parent article:
KVM, QEMU, and kernel project management
gprof: Old standby -- I used to use this all the time back in the day... Unfortunately, only works on staticly linked programs.
gprof works fine on dynamically linked programs. In fact, it's awfully rare to find a genuinely statically linked program these days - most "static" programs dynamically link to libc via ld-linux.so and statically link in all the other libraries they use, as ldd will reveal. Not always, but usually.
I suspect what you were going for was "gprof only profiles one particular library or executable at a time, not a whole program including any shared libraries or plugins it uses." (Even that's not strictly true, it's just that you have to rebuild those plugins or shared libraries with gprof instrumentation too).
I'm totally with you on the general "argh" re callgraph profiling across multiple programs or a subset of the system, though.
(
Log in to post comments)