Filename | /home/ss5/perl5/perlbrew/perls/tapper-perl/lib/site_perl/5.16.3/Test/Deep/Blessed.pm |
Statements | Executed 25 statements in 305µs |
Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
---|---|---|---|---|---|
2 | 1 | 1 | 23µs | 119µs | descend | Test::Deep::Blessed::
1 | 1 | 1 | 22µs | 38µs | BEGIN@1.20 | Test::Deep::
1 | 1 | 1 | 11µs | 17µs | BEGIN@2.21 | Test::Deep::
1 | 1 | 1 | 11µs | 45µs | BEGIN@8 | Test::Deep::Blessed::
1 | 1 | 1 | 11µs | 28µs | BEGIN@6 | Test::Deep::Blessed::
2 | 1 | 1 | 6µs | 6µs | init | Test::Deep::Blessed::
0 | 0 | 0 | 0s | 0s | renderGot | Test::Deep::Blessed::
0 | 0 | 0 | 0s | 0s | render_stack | Test::Deep::Blessed::
Line | State ments |
Time on line |
Calls | Time in subs |
Code |
---|---|---|---|---|---|
1 | 2 | 31µs | 2 | 55µs | # spent 38µs (22+17) within Test::Deep::BEGIN@1.20 which was called:
# once (22µs+17µs) by Test::Deep::__ANON__[/home/ss5/perl5/perlbrew/perls/tapper-perl/lib/site_perl/5.16.3/Test/Deep.pm:81] at line 1 # spent 38µs making 1 call to Test::Deep::BEGIN@1.20
# spent 17µs making 1 call to strict::import |
2 | 2 | 35µs | 2 | 23µs | # spent 17µs (11+6) within Test::Deep::BEGIN@2.21 which was called:
# once (11µs+6µs) by Test::Deep::__ANON__[/home/ss5/perl5/perlbrew/perls/tapper-perl/lib/site_perl/5.16.3/Test/Deep.pm:81] at line 2 # spent 17µs making 1 call to Test::Deep::BEGIN@2.21
# spent 6µs making 1 call to warnings::import |
3 | |||||
4 | package Test::Deep::Blessed; | ||||
5 | |||||
6 | 2 | 30µs | 2 | 45µs | # spent 28µs (11+17) within Test::Deep::Blessed::BEGIN@6 which was called:
# once (11µs+17µs) by Test::Deep::__ANON__[/home/ss5/perl5/perlbrew/perls/tapper-perl/lib/site_perl/5.16.3/Test/Deep.pm:81] at line 6 # spent 28µs making 1 call to Test::Deep::Blessed::BEGIN@6
# spent 17µs making 1 call to Test::Deep::Cmp::import |
7 | |||||
8 | 2 | 176µs | 2 | 79µs | # spent 45µs (11+34) within Test::Deep::Blessed::BEGIN@8 which was called:
# once (11µs+34µs) by Test::Deep::__ANON__[/home/ss5/perl5/perlbrew/perls/tapper-perl/lib/site_perl/5.16.3/Test/Deep.pm:81] at line 8 # spent 45µs making 1 call to Test::Deep::Blessed::BEGIN@8
# spent 34µs making 1 call to Exporter::import |
9 | |||||
10 | sub init | ||||
11 | # spent 6µs within Test::Deep::Blessed::init which was called 2 times, avg 3µs/call:
# 2 times (6µs+0s) by Test::Deep::Cmp::new at line 33 of Test/Deep/Cmp.pm, avg 3µs/call | ||||
12 | 2 | 700ns | my $self = shift; | ||
13 | |||||
14 | 2 | 600ns | my $val = shift; | ||
15 | |||||
16 | 2 | 10µs | $self->{val} = $val; | ||
17 | } | ||||
18 | |||||
19 | sub descend | ||||
20 | # spent 119µs (23+96) within Test::Deep::Blessed::descend which was called 2 times, avg 60µs/call:
# 2 times (23µs+96µs) by Test::Deep::descend at line 344 of Test/Deep.pm, avg 60µs/call | ||||
21 | 2 | 900ns | my $self = shift; | ||
22 | 2 | 500ns | my $got = shift; | ||
23 | |||||
24 | 2 | 2µs | my $exp = $self->{val}; | ||
25 | 2 | 7µs | 2 | 1µs | my $blessed = blessed($got); # spent 1µs making 2 calls to Scalar::Util::blessed, avg 550ns/call |
26 | |||||
27 | 2 | 10µs | 4 | 28µs | return Test::Deep::descend($blessed, Test::Deep::shallow($exp)); # spent 28µs making 2 calls to Test::Deep::__ANON__[Test/Deep.pm:81], avg 14µs/call
# spent 67µs making 2 calls to Test::Deep::descend, avg 34µs/call, recursion: max depth 3, sum of overlapping time 67µs |
28 | } | ||||
29 | |||||
30 | sub render_stack | ||||
31 | { | ||||
32 | my $self = shift; | ||||
33 | my $var = shift; | ||||
34 | |||||
35 | return "blessed($var)" | ||||
36 | } | ||||
37 | |||||
38 | sub renderGot | ||||
39 | { | ||||
40 | my $self = shift; | ||||
41 | |||||
42 | my $got = shift; | ||||
43 | |||||
44 | $self->SUPER::renderGot(blessed($got)); | ||||
45 | } | ||||
46 | |||||
47 | 1 | 2µs | 1; |