Profile of App/Cmd/Command/version.pm

← Index
NYTProf Performance Profile «line view»
For script/ponapi
Run on Wed Feb 10 15:51:26 2016
Reported on Thu Feb 11 09:43:09 2016

Filename | /usr/local/share/perl/5.18.2/App/Cmd/Command/version.pm
Statements | Executed 10 statements in 196µs

Subroutines
Calls | P | F | Exclusive Time | Inclusive Time | Subroutine
--- | --- | --- | --- | --- | ---
1 | 1 | 1 | 10µs | 22µs | Module::Runtime::::BEGIN@1.14 Module::Runtime::BEGIN@1.14
1 | 1 | 1 | 7µs | 7µs | App::Cmd::Command::version::::BEGIN@7App::Cmd::Command::version::BEGIN@7
1 | 1 | 1 | 6µs | 10µs | Module::Runtime::::BEGIN@2.15 Module::Runtime::BEGIN@2.15
1 | 1 | 1 | 4µs | 4µs | App::Cmd::Command::version::::BEGIN@6App::Cmd::Command::version::BEGIN@6
1 | 1 | 1 | 2µs | 2µs | App::Cmd::Command::version::::command_namesApp::Cmd::Command::version::command_names
0 | 0 | 0 | 0s | 0s | App::Cmd::Command::version::::executeApp::Cmd::Command::version::execute
0 | 0 | 0 | 0s | 0s | App::Cmd::Command::version::::version_for_displayApp::Cmd::Command::version::version_for_display
0 | 0 | 0 | 0s | 0s | App::Cmd::Command::version::::version_packageApp::Cmd::Command::version::version_package

Call graph for these subroutines as a Graphviz dot language file.

Line | State ments | Time on line | Calls | Time in subs | Code
--- | --- | --- | --- | --- | ---
1 | 2 | 20µs | 2 | 33µs | # spent 22µs (10+11) within Module::Runtime::BEGIN@1.14 which was called: # once (10µs+11µs) by Module::Runtime::require_module at line 1 use strict; # spent 22µs making 1 call to Module::Runtime::BEGIN@1.14 # spent 11µs making 1 call to strict::import
2 | 2 | 34µs | 2 | 14µs | # spent 10µs (6+4) within Module::Runtime::BEGIN@2.15 which was called: # once (6µs+4µs) by Module::Runtime::require_module at line 2 use warnings; # spent 10µs making 1 call to Module::Runtime::BEGIN@2.15 # spent 4µs making 1 call to warnings::import
3 |  |  |  |  |
4 |  |  |  |  | package App::Cmd::Command::version;
5 | 1 | 600ns |  |  | $App::Cmd::Command::version::VERSION = '0.330';
6 | 2 | 25µs | 1 | 4µs | # spent 4µs within App::Cmd::Command::version::BEGIN@6 which was called: # once (4µs+0s) by Module::Runtime::require_module at line 6 use App::Cmd::Command; # spent 4µs making 1 call to App::Cmd::Command::version::BEGIN@6
7 | 1 | 110µs | 1 | 7µs | # spent 7µs within App::Cmd::Command::version::BEGIN@7 which was called: # once (7µs+0s) by Module::Runtime::require_module at line 7 BEGIN { our @ISA = 'App::Cmd::Command'; } # spent 7µs making 1 call to App::Cmd::Command::version::BEGIN@7
8 |  |  |  |  |
9 |  |  |  |  | # ABSTRACT: display an app's version
10 |  |  |  |  |
11 |  |  |  |  | #pod =head1 DESCRIPTION
12 |  |  |  |  | #pod
13 |  |  |  |  | #pod This command will display the program name, its base class
14 |  |  |  |  | #pod with version number, and the full program name.
15 |  |  |  |  | #pod
16 |  |  |  |  | #pod =cut
17 |  |  |  |  |
18 | 1 | 4µs |  |  | # spent 2µs within App::Cmd::Command::version::command_names which was called: # once (2µs+0s) by App::Cmd::_load_default_plugin at line 288 of App/Cmd.pm sub command_names { qw/version --version/ }
19 |  |  |  |  |
20 |  |  |  |  | sub version_for_display {
21 |  |  |  |  | $_[0]->version_package->VERSION
22 |  |  |  |  | }
23 |  |  |  |  |
24 |  |  |  |  | sub version_package {
25 |  |  |  |  | ref($_[0]->app)
26 |  |  |  |  | }
27 |  |  |  |  |
28 |  |  |  |  | sub execute {
29 |  |  |  |  | my ($self, $opts, $args) = @_;
30 |  |  |  |  |
31 |  |  |  |  | printf "%s (%s) version %s (%s)\n",
32 |  |  |  |  | $self->app->arg0, $self->version_package,
33 |  |  |  |  | $self->version_for_display, $self->app->full_arg0;
34 |  |  |  |  | }
35 |  |  |  |  |
36 | 1 | 2µs |  |  | 1;
37 |  |  |  |  |
38 |  |  |  |  | __END__