FunctionPackage: profToCDocOverviewCGDocRelNotesFAQIndexPermutedIndex
Allegro CL version 10.1
Significant update since the initial 10.1 release.
10.0 version


Arguments: name &key profile verbose start end current-profile

Use of this function is deprecated. While it still works as described, users should istead use cl:disassemble which has been enhanced with a :profile argument. The Allegro CL implementation of cl:disassemble is described in the section Extensions to cl:disassemble in implementation.htm.

There is an example using cl:disassemble to see profile data in the section A disassembly with profiling example in runtime-analyzer.htm.

This function prints to *standard-output* a disassembly of the function denoted by name. In the disassembly, each instruction is annotated with actual hits on that instruction, plus a percentage of the total hits in the function. Since the hits are from a statistical sampling, an estimate can be made as to where in the function time is being spent (the more hits, the better the estimate).

A hit that occurs just after (we define just after for various platforms below) an instruction that does a call probably means that the function was not itself executing but had called another function at the time of the hit. A hit that occurs any other place means the function was actually executing at the time.

By just after above, we mean different things for different architectures:

On Windows, the hit is on the instruction after the jsr, call, or bctrl instruction, respectively.

On Sparcs, the hit occurs exactly at the jmpl instruction.

name must evaluate to a symbol or a compiled function object or a string. A symbol or compiled function object identifies a Lisp function. A string identifies a C function. The disassembler will disassemble C functions on most platforms. Note that you must use the string that appears in a runtime analyzer output (such as a call graph or a flat profile).

The profile keyword argument specifies the profile to examine. Its value must be a name of a profile (see save-named-profile) or a profile object (see find-named-profile). The value :current is also accepted and is the default. It indicates the current profile (the most recent run and stopped but not saved and named profile).

The verbose keyword argument controls whether or not messages about the progress of the analysis are printed to *standard-output*. The messages will be printed if the value is true and they will not be printed if the value is nil. The value defaults to nil. (Note that in the default, both the messages and the result are printed to *standard-output* so if you rebind *standard-output* to be a stream open to a file, the messages will be printed to the file as well.)

The start and end keyword arguments are passed to cl:disassemble. Allegro CL enhances cl:disassemble by adding these arguments, which resemble the start and end arguments to sequence functions. Both values, if specified, should be non-negative integers indicating the pc-offset where printing of disassembled code should start and stop, but there are many details. See the description of the Allegro CL implementation of cl:disassemble in Extensions to cl:make-package, cl:disassemble, cl:open, cl:apropos in implementation.htm.

Use of the current-profile keyword argument is deprecated and will cause a warning to be signaled. User profile instead. If supplied, its value must be a profile saved by save-named-profile (profiles saved by the deprecated function save-current-profile will also work).

This function returns nil.

See runtime-analyzer.htm for general information on the runtime analyzer.

Copyright (c) 1998-2019, Franz Inc. Oakland, CA., USA. All rights reserved.
This page was not revised from the 10.0 page.
Created 2019.8.20.

Allegro CL version 10.1
Significant update since the initial 10.1 release.
10.0 version