Filename | /usr/lib/perl/5.18/Config.pm |
Statements | Executed 102 statements in 746µs |
Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
---|---|---|---|---|---|
1 | 1 | 1 | 1.68ms | 1.81ms | AUTOLOAD | Config::
22 | 12 | 6 | 72µs | 2.03ms | FETCH | Config::
5 | 5 | 5 | 56µs | 56µs | import | Config::
1 | 1 | 1 | 8µs | 18µs | BEGIN@9 | Config::
1 | 1 | 1 | 7µs | 13µs | BEGIN@10 | Config::
1 | 1 | 1 | 5µs | 13µs | BEGIN@47 | Config::
1 | 1 | 1 | 5µs | 27µs | BEGIN@11 | Config::
1 | 1 | 1 | 2µs | 2µs | TIEHASH | Config::
0 | 0 | 0 | 0s | 0s | DESTROY | Config::
Line | State ments |
Time on line |
Calls | Time in subs |
Code |
---|---|---|---|---|---|
1 | # This file was created by configpm when Perl was built. Any changes | ||||
2 | # made to this file will be lost the next time perl is built. | ||||
3 | |||||
4 | # for a description of the variables, please have a look at the | ||||
5 | # Glossary file, as written in the Porting folder, or use the url: | ||||
6 | # http://perl5.git.perl.org/perl.git/blob/HEAD:/Porting/Glossary | ||||
7 | |||||
8 | package Config; | ||||
9 | 2 | 20µs | 2 | 27µs | # spent 18µs (8+9) within Config::BEGIN@9 which was called:
# once (8µs+9µs) by Module::Pluggable::Object::BEGIN@4 at line 9 # spent 18µs making 1 call to Config::BEGIN@9
# spent 9µs making 1 call to strict::import |
10 | 2 | 21µs | 2 | 18µs | # spent 13µs (7+6) within Config::BEGIN@10 which was called:
# once (7µs+6µs) by Module::Pluggable::Object::BEGIN@4 at line 10 # spent 13µs making 1 call to Config::BEGIN@10
# spent 6µs making 1 call to warnings::import |
11 | 2 | 108µs | 2 | 48µs | # spent 27µs (5+22) within Config::BEGIN@11 which was called:
# once (5µs+22µs) by Module::Pluggable::Object::BEGIN@4 at line 11 # spent 27µs making 1 call to Config::BEGIN@11
# spent 22µs making 1 call to vars::import |
12 | |||||
13 | 1 | 400ns | $VERSION = "5.018002"; | ||
14 | |||||
15 | # Skip @Config::EXPORT because it only contains %Config, which we special | ||||
16 | # case below as it's not a function. @Config::EXPORT won't change in the | ||||
17 | # lifetime of Perl 5. | ||||
18 | 1 | 3µs | my %Export_Cache = (myconfig => 1, config_sh => 1, config_vars => 1, | ||
19 | config_re => 1, compile_date => 1, local_patches => 1, | ||||
20 | bincompat_options => 1, non_bincompat_options => 1, | ||||
21 | header_files => 1); | ||||
22 | |||||
23 | 1 | 500ns | @Config::EXPORT = qw(%Config); | ||
24 | 1 | 2µs | @Config::EXPORT_OK = keys %Export_Cache; | ||
25 | |||||
26 | # Need to stub all the functions to make code such as print Config::config_sh | ||||
27 | # keep working | ||||
28 | |||||
29 | sub bincompat_options; | ||||
30 | sub compile_date; | ||||
31 | sub config_re; | ||||
32 | sub config_sh; | ||||
33 | sub config_vars; | ||||
34 | sub header_files; | ||||
35 | sub local_patches; | ||||
36 | sub myconfig; | ||||
37 | sub non_bincompat_options; | ||||
38 | |||||
39 | # Define our own import method to avoid pulling in the full Exporter: | ||||
40 | # spent 56µs within Config::import which was called 5 times, avg 11µs/call:
# once (12µs+0s) by DynaLoader::BEGIN@21 at line 21 of DynaLoader.pm
# once (12µs+0s) by Time::Local::BEGIN@5 at line 5 of Time/Local.pm
# once (11µs+0s) by Pod::Perldoc::BEGIN@6 at line 6 of Pod/Perldoc.pm
# once (11µs+0s) by locale::BEGIN@4 at line 4 of locale.pm
# once (10µs+0s) by File::Copy::BEGIN@14 at line 14 of File/Copy.pm | ||||
41 | 5 | 1µs | shift; | ||
42 | 5 | 8µs | @_ = @Config::EXPORT unless @_; | ||
43 | |||||
44 | 5 | 10µs | my @funcs = grep $_ ne '%Config', @_; | ||
45 | 5 | 4µs | my $export_Config = @funcs < @_ ? 1 : 0; | ||
46 | |||||
47 | 2 | 254µs | 2 | 20µs | # spent 13µs (5+8) within Config::BEGIN@47 which was called:
# once (5µs+8µs) by Module::Pluggable::Object::BEGIN@4 at line 47 # spent 13µs making 1 call to Config::BEGIN@47
# spent 8µs making 1 call to strict::unimport |
48 | 5 | 4µs | my $callpkg = caller(0); | ||
49 | 5 | 4µs | foreach my $func (@funcs) { | ||
50 | die qq{"$func" is not exported by the Config module\n} | ||||
51 | unless $Export_Cache{$func}; | ||||
52 | *{$callpkg.'::'.$func} = \&{$func}; | ||||
53 | } | ||||
54 | |||||
55 | 5 | 16µs | *{"$callpkg\::Config"} = \%Config if $export_Config; | ||
56 | 5 | 20µs | return; | ||
57 | } | ||||
58 | |||||
59 | 1 | 42µs | 1 | 14µs | die "Perl lib version (5.18.2) doesn't match executable '$0' version ($])" # spent 14µs making 1 call to version::(bool |
60 | unless $^V; | ||||
61 | |||||
62 | 1 | 22µs | 1 | 5µs | $^V eq 5.18.2 # spent 5µs making 1 call to version::(cmp |
63 | or die "Perl lib version (5.18.2) doesn't match executable '$0' version (" . | ||||
64 | sprintf("v%vd",$^V) . ")"; | ||||
65 | |||||
66 | # spent 2.03ms (72µs+1.96) within Config::FETCH which was called 22 times, avg 92µs/call:
# 8 times (12µs+0s) by deprecate::__loaded_from_core at line 82 of deprecate.pm, avg 1µs/call
# 3 times (6µs+0s) by Data::OptList::BEGIN@10 at line 39 of DynaLoader.pm, avg 2µs/call
# 2 times (8µs+38µs) by locale::import at line 21 of locale.pm, avg 23µs/call
# once (26µs+1.86ms) by PONAPI::CLI::Command::manual::BEGIN@9 at line 81 of Pod/Perldoc.pm
# once (5µs+28µs) by PONAPI::CLI::Command::manual::BEGIN@9 at line 84 of Pod/Perldoc.pm
# once (3µs+28µs) by PONAPI::CLI::Command::manual::BEGIN@9 at line 85 of Pod/Perldoc.pm
# once (6µs+0s) by Hash::MultiValue::BEGIN@18 at line 20 of Hash/MultiValue.pm
# once (2µs+0s) by Module::Pluggable::Object::BEGIN@4 at line 1115 of File/Find.pm
# once (1µs+0s) by Data::OptList::BEGIN@10 at line 58 of DynaLoader.pm
# once (1µs+0s) by Data::OptList::BEGIN@10 at line 62 of DynaLoader.pm
# once (1µs+0s) by Data::OptList::BEGIN@10 at line 60 of DynaLoader.pm
# once (1µs+0s) by Data::OptList::BEGIN@10 at line 61 of DynaLoader.pm | ||||
67 | 22 | 8µs | my($self, $key) = @_; | ||
68 | |||||
69 | # check for cached value (which may be undef so we use exists not defined) | ||||
70 | 22 | 90µs | 4 | 1.91ms | return exists $self->{$key} ? $self->{$key} : $self->fetch_string($key); # spent 1.81ms making 1 call to Config::AUTOLOAD
# spent 95µs making 3 calls to Config::fetch_string, avg 32µs/call |
71 | } | ||||
72 | |||||
73 | # spent 2µs within Config::TIEHASH which was called:
# once (2µs+0s) by Module::Pluggable::Object::BEGIN@4 at line 86 | ||||
74 | 1 | 3µs | bless $_[1], $_[0]; | ||
75 | } | ||||
76 | |||||
77 | sub DESTROY { } | ||||
78 | |||||
79 | # spent 1.81ms (1.68+135µs) within Config::AUTOLOAD which was called:
# once (1.68ms+135µs) by Config::FETCH at line 70 | ||||
80 | 1 | 69µs | require 'Config_heavy.pl'; | ||
81 | 1 | 12µs | 2 | 6µs | goto \&launcher unless $Config::AUTOLOAD =~ /launcher$/; # spent 6µs making 1 call to Config::launcher
# spent 1µs making 1 call to Config::CORE:match |
82 | die "&Config::AUTOLOAD failed on $Config::AUTOLOAD"; | ||||
83 | } | ||||
84 | |||||
85 | # tie returns the object, so the value returned to require will be true. | ||||
86 | 1 | 23µs | 1 | 2µs | tie %Config, 'Config', { # spent 2µs making 1 call to Config::TIEHASH |
87 | archlibexp => '/usr/lib/perl/5.18', | ||||
88 | archname => 'x86_64-linux-gnu-thread-multi', | ||||
89 | cc => 'cc', | ||||
90 | d_readlink => 'define', | ||||
91 | d_symlink => 'define', | ||||
92 | dlext => 'so', | ||||
93 | dlsrc => 'dl_dlopen.xs', | ||||
94 | dont_use_nlink => undef, | ||||
95 | exe_ext => '', | ||||
96 | inc_version_list => '5.18.1', | ||||
97 | intsize => '4', | ||||
98 | ldlibpthname => 'LD_LIBRARY_PATH', | ||||
99 | libpth => '/usr/local/lib /lib/x86_64-linux-gnu /lib/../lib /usr/lib/x86_64-linux-gnu /usr/lib/../lib /lib /usr/lib', | ||||
100 | osname => 'linux', | ||||
101 | osvers => '3.2.0-58-generic', | ||||
102 | path_sep => ':', | ||||
103 | privlibexp => '/usr/share/perl/5.18', | ||||
104 | scriptdir => '/usr/bin', | ||||
105 | sitearchexp => '/usr/local/lib/perl/5.18.2', | ||||
106 | sitelibexp => '/usr/local/share/perl/5.18.2', | ||||
107 | so => 'so', | ||||
108 | useithreads => 'define', | ||||
109 | usevendorprefix => 'define', | ||||
110 | version => '5.18.2', | ||||
111 | }; |