| Filename | /usr/share/perl/5.28/warnings/register.pm |
| Statements | Executed 23 statements in 43µs |
| Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
|---|---|---|---|---|---|
| 4 | 4 | 4 | 30µs | 133µs | warnings::register::import |
| 0 | 0 | 0 | 0s | 0s | warnings::register::mkMask |
| Line | State ments |
Time on line |
Calls | Time in subs |
Code |
|---|---|---|---|---|---|
| 1 | package warnings::register; | ||||
| 2 | |||||
| 3 | 1 | 400ns | our $VERSION = '1.04'; | ||
| 4 | 1 | 500ns | require warnings; | ||
| 5 | |||||
| 6 | # left here as cruft in case other users were using this undocumented routine | ||||
| 7 | # -- rjbs, 2010-09-08 | ||||
| 8 | sub mkMask | ||||
| 9 | { | ||||
| 10 | my ($bit) = @_; | ||||
| 11 | my $mask = ""; | ||||
| 12 | |||||
| 13 | vec($mask, $bit, 1) = 1; | ||||
| 14 | return $mask; | ||||
| 15 | } | ||||
| 16 | |||||
| 17 | sub import | ||||
| 18 | # spent 133µs (30+103) within warnings::register::import which was called 4 times, avg 33µs/call:
# once (10µs+29µs) by vars::BEGIN@7 at line 7 of vars.pm
# once (6µs+28µs) by constant::BEGIN@4 at line 4 of constant.pm
# once (8µs+26µs) by overload::BEGIN@142 at line 142 of overload.pm
# once (5µs+21µs) by flock::BEGIN@132 at line 132 of Path/Tiny.pm | ||||
| 19 | 4 | 1µs | shift; | ||
| 20 | 4 | 2µs | my @categories = @_; | ||
| 21 | |||||
| 22 | 4 | 12µs | my $package = (caller(0))[0]; | ||
| 23 | 4 | 9µs | 4 | 103µs | warnings::register_categories($package); # spent 103µs making 4 calls to warnings::register_categories, avg 26µs/call |
| 24 | |||||
| 25 | 4 | 15µs | warnings::register_categories($package . "::$_") for @categories; | ||
| 26 | } | ||||
| 27 | 1 | 3µs | 1; | ||
| 28 | __END__ |