Behaviours: application.
Percept2 - An Enhanced version of the Erlang Concurrency Profiling Tool Percept.
Percept2 extends Percept in two aspects: functionality and scalability. Among the new functionalities added to Percept are:filespec() = file:filename() | {file:filename(), wrap, Suffix::string(), WrapSize::pos_integer(), WrapCnt::pos_integer()}
function_name() = atom()
module_name() = atom()
trace_profile_option() = procs | ports | schedulers | running | message | migration | all | {callgraph, [module_name()]}
analyze/1 | Parallel analysis of trace files. |
analyze/4 | Parallel analysis of trace files. |
profile/2 | Starts the profiling while an application of interest is already running. |
profile/3 | The profiling starts with executing the entry function given, and goes on for the whole duration until the entry function returns and the profiling has concluded. |
start_webserver/0 | Starts webserver. |
start_webserver/1 | Starts webserver with a given port number. |
stop_db/0 | Stops the percept2 database. |
stop_profile/0 | Stops the profiling. |
stop_webserver/0 | Stops webserver. |
stop_webserver/1 | Stops webserver of the given port. |
analyze(FileNames::[file:filename()]) -> ok | {error, any()}
Parallel analysis of trace files. See the Overview page for examples.
analyze(Filename::file:filename(), Suffix::string(), StartIndex::pos_integer(), EndIndex::pos_integer()) -> ok | {error, any()}
Parallel analysis of trace files. See the Overview page for examples.
profile(FileSpec::filespec(), TraceProfileOptions::[trace_profile_option()]) -> {ok, integer()} | {already_started, port()}
Starts the profiling while an application of interest
is already running.
The profiling can be stopped by percept2:stop_profile/0
.
The valid TraceProfileOptions
values are: procs
, ports
,
schedulers
, running
, message
, migration
and all
. See
profile/3 for the
descriptions of the options.
See also: stop_profile/0.
profile(FileSpec::filespec(), Entry::{module_name(), function_name(), [term()]}, TraceProfileOptions::[trace_profile_option()]) -> ok | {already_started, port()}
The profiling starts with executing the entry function given, and goes on for
the whole duration until the entry function returns and the profiling
has concluded. The events to be traced/profiled depends on the options
specified by TraceProfileOptions
. The following options are available:
-- procs
: enables the profiling of process concurrency.
-- ports
: enables the profiling of port concurrecny.
-- schedulers
: enables the profiling of scheduler concurrency.
-- running
: enables the feature to distinguish running from
runnable process states. If the procs
option is
not given, this option enables the process concurrency
automatically.
-- message
: this enables the profiling of message passing between
processes; If the procs
option is not given, this
option enables the process concurrency automatically.
-- migration
: this enables the profiling of process migration between
schedulers; If the procs
option is not given, this
option enables the process concurrency automatically.
-- all
: this enable all the previous options.
-- {callgraph, Mods}
: This enables the profiling of function activities
(call
and return_to
) of functions defined in Mods
.
If the procs
option is not given, this option enables
the process concurrency automatically. Given the huge
amount of data that could possibly be produced when this
feature is on, we do not recommend profiling many modules
in one go at this stage.
start_webserver() -> {started, Hostname, Port} | {error, Reason}
Starts webserver. An available port number will be assigned by inets.
start_webserver(Port::integer()) -> {started, Hostname, AssignedPort} | {error, Reason}
Starts webserver with a given port number. If port number is 0, an available port number will be assigned by inets.
stop_db() -> ok
Stops the percept2 database.
stop_profile() -> ok | {error, not_started}
Stops the profiling.
See also: profile/1, profile/2.
stop_webserver() -> ok | {error, not_started}
Stops webserver.
stop_webserver(Port::integer()) -> ok | {error, not_started}
Stops webserver of the given port.
Generated by EDoc, Mar 28 2013, 21:53:01.