Filename | /usr/lib/perl5/site_perl/List/Util.pm |
Statements | Executed 25 statements in 1.26ms |
Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
---|---|---|---|---|---|
7323 | 18 | 2 | 57.4ms | 57.4ms | sum (xsub) | List::Util::
3370 | 4 | 1 | 18.6ms | 18.6ms | max (xsub) | List::Util::
1181 | 1 | 1 | 7.00ms | 7.00ms | any (xsub) | List::Util::
1181 | 1 | 1 | 2.15ms | 2.15ms | min (xsub) | List::Util::
3 | 3 | 3 | 56µs | 56µs | import | List::Util::
1 | 1 | 1 | 26µs | 62µs | BEGIN@9 | List::Util::
1 | 1 | 1 | 18µs | 46µs | BEGIN@30 | List::Util::
0 | 0 | 0 | 0s | 0s | key | List::Util::_Pair::
0 | 0 | 0 | 0s | 0s | value | List::Util::_Pair::
Line | State ments |
Time on line |
Calls | Time in subs |
Code |
---|---|---|---|---|---|
1 | # Copyright (c) 1997-2009 Graham Barr <gbarr@pobox.com>. All rights reserved. | ||||
2 | # This program is free software; you can redistribute it and/or | ||||
3 | # modify it under the same terms as Perl itself. | ||||
4 | # | ||||
5 | # Maintained since 2013 by Paul Evans <leonerd@leonerd.org.uk> | ||||
6 | |||||
7 | package List::Util; | ||||
8 | |||||
9 | 2 | 316µs | 2 | 98µs | # spent 62µs (26+36) within List::Util::BEGIN@9 which was called:
# once (26µs+36µs) by Runner::BEGIN@14 at line 9 # spent 62µs making 1 call to List::Util::BEGIN@9
# spent 36µs making 1 call to strict::import |
10 | 1 | 1µs | require Exporter; | ||
11 | |||||
12 | 1 | 16µs | our @ISA = qw(Exporter); | ||
13 | 1 | 9µs | our @EXPORT_OK = qw( | ||
14 | all any first min max minstr maxstr none notall product reduce sum sum0 shuffle | ||||
15 | pairmap pairgrep pairfirst pairs pairkeys pairvalues | ||||
16 | ); | ||||
17 | 1 | 800ns | our $VERSION = "1.39"; | ||
18 | 1 | 500ns | our $XS_VERSION = $VERSION; | ||
19 | 1 | 35µs | $VERSION = eval $VERSION; # spent 6µs executing statements in string eval | ||
20 | |||||
21 | 1 | 900ns | require XSLoader; | ||
22 | 1 | 473µs | 1 | 456µs | XSLoader::load('List::Util', $XS_VERSION); # spent 456µs making 1 call to XSLoader::load |
23 | |||||
24 | sub import | ||||
25 | # spent 56µs within List::Util::import which was called 3 times, avg 19µs/call:
# once (21µs+0s) by Runner::BEGIN@14 at line 14 of runner.pl
# once (18µs+0s) by Runner::Stats::BEGIN@7 at line 7 of Runner/Stats.pm
# once (18µs+0s) by Runner::IO::BEGIN@6 at line 6 of Runner/IO.pm | ||||
26 | 3 | 6µs | my $pkg = caller; | ||
27 | |||||
28 | # (RT88848) Touch the caller's $a and $b, to avoid the warning of | ||||
29 | # Name "main::a" used only once: possible typo" warning | ||||
30 | 2 | 297µs | 2 | 73µs | # spent 46µs (18+28) within List::Util::BEGIN@30 which was called:
# once (18µs+28µs) by Runner::BEGIN@14 at line 30 # spent 46µs making 1 call to List::Util::BEGIN@30
# spent 28µs making 1 call to strict::unimport |
31 | 3 | 22µs | ${"${pkg}::a"} = ${"${pkg}::a"}; | ||
32 | 3 | 11µs | ${"${pkg}::b"} = ${"${pkg}::b"}; | ||
33 | |||||
34 | 3 | 51µs | 3 | 288µs | goto &Exporter::import; # spent 288µs making 3 calls to Exporter::import, avg 96µs/call |
35 | } | ||||
36 | |||||
37 | # For objects returned by pairs() | ||||
38 | sub List::Util::_Pair::key { shift->[0] } | ||||
39 | sub List::Util::_Pair::value { shift->[1] } | ||||
40 | |||||
41 | 1 | 18µs | 1; | ||
42 | |||||
43 | __END__ | ||||
# spent 7.00ms within List::Util::any which was called 1181 times, avg 6µs/call:
# 1181 times (7.00ms+0s) by Runner::Stats::computeOnMessages at line 107 of Runner/Stats.pm, avg 6µs/call | |||||
# spent 18.6ms within List::Util::max which was called 3370 times, avg 6µs/call:
# 1000 times (5.47ms+0s) by Runner::Stats::computeOnMessages at line 98 of Runner/Stats.pm, avg 5µs/call
# 800 times (4.56ms+0s) by Runner::Stats::computeOnMessages at line 74 of Runner/Stats.pm, avg 6µs/call
# 800 times (4.32ms+0s) by Runner::Stats::computeOnMessages at line 149 of Runner/Stats.pm, avg 5µs/call
# 770 times (4.30ms+0s) by Runner::Stats::computeOnMessages at line 122 of Runner/Stats.pm, avg 6µs/call | |||||
# spent 2.15ms within List::Util::min which was called 1181 times, avg 2µs/call:
# 1181 times (2.15ms+0s) by Runner::Stats::computeOnMessages at line 159 of Runner/Stats.pm, avg 2µs/call | |||||
# spent 57.4ms within List::Util::sum which was called 7323 times, avg 8µs/call:
# 1000 times (9.70ms+0s) by Runner::Stats::computeOnMessages at line 94 of Runner/Stats.pm, avg 10µs/call
# 800 times (7.45ms+0s) by Runner::Stats::computeOnMessages at line 139 of Runner/Stats.pm, avg 9µs/call
# 800 times (7.16ms+0s) by Runner::Stats::computeOnMessages at line 68 of Runner/Stats.pm, avg 9µs/call
# 800 times (5.78ms+0s) by Runner::Stats::computeOnMessages at line 71 of Runner/Stats.pm, avg 7µs/call
# 800 times (5.40ms+0s) by Runner::Stats::computeOnMessages at line 69 of Runner/Stats.pm, avg 7µs/call
# 800 times (4.84ms+0s) by Runner::Stats::computeOnMessages at line 70 of Runner/Stats.pm, avg 6µs/call
# 770 times (6.04ms+0s) by Runner::Stats::computeOnMessages at line 117 of Runner/Stats.pm, avg 8µs/call
# 770 times (5.68ms+0s) by Runner::Stats::computeOnMessages at line 119 of Runner/Stats.pm, avg 7µs/call
# 770 times (5.27ms+0s) by Runner::Stats::computeOnMessages at line 118 of Runner/Stats.pm, avg 7µs/call
# 5 times (4µs+0s) by Runner::IO::dump_node_data at line 159 of Runner/IO.pm, avg 900ns/call
# once (20µs+0s) by Runner::Stats::computeAtTheEnd at line 242 of Runner/Stats.pm
# once (18µs+0s) by Runner::Stats::computeAtTheEnd at line 244 of Runner/Stats.pm
# once (17µs+0s) by Runner::Stats::computeAtTheEnd at line 199 of Runner/Stats.pm
# once (17µs+0s) by Runner::Stats::computeAtTheEnd at line 189 of Runner/Stats.pm
# once (15µs+0s) by Runner::Stats::computeAtTheEnd at line 201 of Runner/Stats.pm
# once (14µs+0s) by Runner::Stats::computeAtTheEnd at line 191 of Runner/Stats.pm
# once (7µs+0s) by Runner::Stats::computeAtTheEnd at line 216 of Runner/Stats.pm
# once (4µs+0s) by Runner::Stats::computeAtTheEnd at line 217 of Runner/Stats.pm |