++ed by:

167 PAUSE users
144 non-PAUSE users.

William J. Middleton


dprofpp - display perl profile data


dprofpp [-a|-z|-l|-v|-U] [-s|-r|-u] [-q] [-F] [-I|-E] [-O cnt] [profile]

dprofpp -T [-F] [profile]

dprofpp -t [-F] [profile]

dprofpp -p script [-Q] [other opts]

dprofpp -V [profile]


The dprofpp command interprets profile data produced by a profiler, such as the Devel::DProf profiler. Dprofpp will read the file tmon.out and will display the 15 subroutines which are using the most time. By default the times for each subroutine are given exclusive of the times of their child subroutines.

To profile a Perl script run the perl interpreter with the -d switch. So to profile script test.pl with Devel::DProf the following command should be used.

        $ perl5 -d:DProf test.pl

Then run dprofpp to analyze the profile.

        $ dprofpp -u
        Total Elapsed Time =    1.67 Seconds
                 User Time =    0.61 Seconds
        Exclusive Times
        %Time Seconds     #Calls sec/call Name
         52.4   0.320          2   0.1600 main::foo
         45.9   0.280        200   0.0014 main::bar
         0.00   0.000          1   0.0000 DynaLoader::import
         0.00   0.000          1   0.0000 main::baz

The dprofpp tool can also run the profiler before analyzing the profile data. The above two commands can be executed with one dprofpp command.

        $ dprofpp -u -p test.pl

Consult "PROFILE FORMAT" in Devel::DProf for a description of the raw profile.



Sort alphabetically by subroutine names.


(default) Display all subroutine times exclusive of child subroutine times.


Force the generation of fake exit timestamps if dprofpp reports that the profile is garbled. This is only useful if dprofpp determines that the profile is garbled due to missing exit timestamps. You're on your own if you do this. Consult the BUGS section.


Display all subroutine times inclusive of child subroutine times.


Sort by number of calls to the subroutines. This may help identify candidates for inlining.

-O cnt

Show only cnt subroutines. The default is 15.

-p script

Tells dprofpp that it should profile the given script and then interpret its profile data. See -Q.


Used with -p to tell dprofpp to quit after profiling the script, without interpreting the data.


Do not display column headers.


Display elapsed real times rather than user+system times.


Display system times rather than user+system times.


Display subroutine call tree to stdout. Subroutine statistics are not displayed.


Display subroutine call tree to stdout. Subroutine statistics are not displayed. When a function is called multiple consecutive times at the same calling level then it is displayed once with a repeat count.


Do not sort. Display in the order found in the raw profile.


Display user times rather than user+system times.


Print dprofpp's version number and exit. If a raw profile is found then its XS_VERSION variable will be displayed, too.


Sort by average time spent in subroutines during each call. This may help identify candidates for inlining.


(default) Sort by amount of user+system time used. The first few lines should show you which subroutines are using the most time.


The environment variable DPROFPP_OPTS can be set to a string containing options for dprofpp. You might use this if you prefer -I over -E or if you want -F on all the time.

This was added fairly lazily, so there are some undesirable side effects. Options on the commandline should override options in DPROFPP_OPTS--but don't count on that in this version.


Applications which call die from within an eval for exception handling (catch/throw) or for setjmp/longjmp may not generate a readable profile. See the -F option.

Applications which call exit from within a subroutine will leave an incomplete profile. See the -F option.

Any bugs in Devel::DProf, or any profiler generating the profile data, could be visible here. See "BUGS" in Devel::DProf.

Mail bug reports and feature requests to the perl5-porters mailing list at <perl5-porters@africa.nicoh.com>. Bug reports should include the output of the -V option.


        dprofpp         - profile processor
        tmon.out        - raw profile


perl, Devel::DProf, times(2)