gprof and Berkeley Unix
gprof use the same data
file gmon.out, and provide essentially the same information. But
there are a few differences.
gprofuses a new, generalized file format with support for basic-block execution counts and non-realtime histograms. A magic cookie and version number allows
gprofto easily identify new style files. Old BSD-style files can still be read. See Profiling Data File Format.
gproflists the function as a parent and as a child, with a
callsfield that lists the number of recursive calls. GNU
gprofomits these lines and puts the number of recursive calls in the primary line.
gprofstill lists it as a subroutine of functions that call it.
gprofaccepts the ‘-k’ with its argument in the form ‘from/to’, instead of ‘from to’.
gprofprints all of their counts, separated by commas.
gprofprints blurbs after the tables, so that you can see the tables without skipping the blurbs.