Filename | /usr/share/perl/5.20/warnings/register.pm |
Statements | Executed 38 statements in 76µs |
Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
---|---|---|---|---|---|
7 | 7 | 7 | 65µs | 603µs | import | warnings::register::
0 | 0 | 0 | 0s | 0s | mkMask | warnings::register::
Line | State ments |
Time on line |
Calls | Time in subs |
Code |
---|---|---|---|---|---|
1 | package warnings::register; | ||||
2 | |||||
3 | 1 | 700ns | our $VERSION = '1.03'; | ||
4 | |||||
5 | 1 | 500ns | require warnings; | ||
6 | |||||
7 | # left here as cruft in case other users were using this undocumented routine | ||||
8 | # -- rjbs, 2010-09-08 | ||||
9 | sub mkMask | ||||
10 | { | ||||
11 | my ($bit) = @_; | ||||
12 | my $mask = ""; | ||||
13 | |||||
14 | vec($mask, $bit, 1) = 1; | ||||
15 | return $mask; | ||||
16 | } | ||||
17 | |||||
18 | sub import | ||||
19 | # spent 603µs (65+538) within warnings::register::import which was called 7 times, avg 86µs/call:
# once (11µs+94µs) by vars::BEGIN@7 at line 7 of vars.pm
# once (10µs+86µs) by overload::BEGIN@144 at line 144 of overload.pm
# once (9µs+79µs) by File::Find::BEGIN@5 at line 5 of File/Find.pm
# once (10µs+73µs) by constant::BEGIN@4 at line 4 of constant.pm
# once (9µs+73µs) by Tie::Hash::BEGIN@6 at line 6 of Tie/Hash.pm
# once (8µs+69µs) by Socket::BEGIN@11 at line 11 of Socket.pm
# once (10µs+64µs) by DateTime::BEGIN@9 at line 9 of DateTime.pm | ||||
20 | 7 | 2µs | shift; | ||
21 | 7 | 5µs | my @categories = @_; | ||
22 | |||||
23 | 7 | 22µs | my $package = (caller(0))[0]; | ||
24 | 7 | 15µs | 7 | 538µs | warnings::register_categories($package); # spent 538µs making 7 calls to warnings::register_categories, avg 77µs/call |
25 | |||||
26 | 7 | 27µs | warnings::register_categories($package . "::$_") for @categories; | ||
27 | } | ||||
28 | |||||
29 | 1 | 4µs | 1; |