possible problems with gprof clocktick resolution when analyzing the program/library time ratio using gprof

Daniel Jacobowitz drow@false.org
Mon Jun 11 01:28:00 GMT 2007


On Sat, Jun 09, 2007 at 12:23:19AM +1200, Mark Farnell wrote:
> Then when I look at the output of gmon flat profile, I saw some
> function being called in the order of 100k times within 8s, that each
> call only take very very little time.

If that's the case, gprof is almost certainly the wrong tool for your
job.  You may want to investigate oprofile or other
non-instrumentation profiling tools.  Gprof tends to skew results for
frequently-called short-lived functions.

-- 
Daniel Jacobowitz
CodeSourcery



More information about the Binutils mailing list