VCP::Debug3pm
Debugging support for vcp
Overview
Debugging support for VCP. Enabled by setting the environment variable VCPDEBUG=1.
- debug
-
debug $foo if debugging $self ;Emits a line of debugging (a "\n" will be appended). Use to avoid the "\n". Any undefined parameters will be displayed as
"<undef>".
- debugging
-
debug "blah" if debugging ;Returns TRUE if the caller's module is being debugged
debug "blah" if debugging $self ;debug "blah" if debugging $other, $self ; ## ORs the arguments togetherReturns TRUE if any of the arguments are being debugged. Plain strings can be passed or blessed references.
- profiling
-
Returns true if VCP is profiling itself compared to shell command performance.
This is different from using perl's profilers (-d:DProf and the like); this profiling tracks the operation of some of VCP's internals and also how long is spent waiting for child processes to complete.
- $VCP::Debug::profile_category
-
Sets the category for the next profile_start and profile_end pair of calls:
local $VCP::Debug::profile_category = "p4 files" if profiling;
- profile_start
-
Notes the current time as the start of a profiling interval.
Defaults to the category
$profile_categoryif none passed.
- profile_end
-
Notes the current time as the end of a profiling interval.
Defaults to the category
$profile_categoryif none passed.
- profile_group
-
Called with the prefix of a set of profile categories to sum up and emit subtotals for.
Releases
2 releases since Debian 3.1 (Sarge); the text changed 1 time.