Lard Toolkit User Guide

lprof - Lard Profiler

Name

lprof - Decode profiling information from interpretted lard program.

Synopsis

lprof [filename]*

Description

lprof reads and decodes a profiling information file profile.out written by li. To generate the profile.out file you must:

Running lprof with no command line arguments outputs profiling information about all of the program. If any command line arguments are provided they are interpretted as filenames (excluding any extensions) and information is displayed only for functions in those files.

The information is displayed in the following sections:

In each case, the filename, line number and identifier is given. For identifiers declared at the top level in any file it is not possible to report the filename and line number; instead these identifiers are listed as "global". In the functions, expressions, types and val/var functions sections the number of calls to that entity is listed. For function times the total time spent in each function in sections and the percentage of the total execution time is listed. This time excludes time spent in children that have their own function time entries, but includes time spent in children that do not have entries, such as standard library routines.

Enabling optimisation will cause statistics for some library routines to be incaccurate, but does not affect the validity of results for user functions.