| Filename | /usr/lib/perl5/5.14/i686-cygwin-threads-64int/lib.pm |
| Statements | Executed 31 statements in 7.33ms |
| Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
|---|---|---|---|---|---|
| 1 | 1 | 1 | 5.22ms | 15.8ms | lib::BEGIN@6 |
| 4 | 4 | 1 | 463µs | 463µs | lib::CORE:ftdir (opcode) |
| 1 | 1 | 1 | 134µs | 134µs | lib::CORE:ftis (opcode) |
| 1 | 1 | 1 | 114µs | 736µs | lib::import |
| 1 | 1 | 1 | 18µs | 18µs | lib::_get_dirs |
| 1 | 1 | 1 | 17µs | 22µs | lib::BEGIN@8 |
| 1 | 1 | 1 | 7µs | 7µs | lib::CORE:match (opcode) |
| 0 | 0 | 0 | 0s | 0s | lib::unimport |
| Line | State ments |
Time on line |
Calls | Time in subs |
Code |
|---|---|---|---|---|---|
| 1 | package lib; | ||||
| 2 | |||||
| 3 | # THIS FILE IS AUTOMATICALLY GENERATED FROM lib_pm.PL. | ||||
| 4 | # ANY CHANGES TO THIS FILE WILL BE OVERWRITTEN BY THE NEXT PERL BUILD. | ||||
| 5 | |||||
| 6 | 2 | 5.63ms | 2 | 15.9ms | # spent 15.8ms (5.22+10.6) within lib::BEGIN@6 which was called:
# once (5.22ms+10.6ms) by main::BEGIN@31 at line 6 # spent 15.8ms making 1 call to lib::BEGIN@6
# spent 114µs making 1 call to Config::import |
| 7 | |||||
| 8 | 2 | 886µs | 2 | 27µs | # spent 22µs (17+5) within lib::BEGIN@8 which was called:
# once (17µs+5µs) by main::BEGIN@31 at line 8 # spent 22µs making 1 call to lib::BEGIN@8
# spent 5µs making 1 call to strict::import |
| 9 | |||||
| 10 | 1 | 16µs | 1 | 9µs | my $archname = $Config{archname}; # spent 9µs making 1 call to Config::FETCH |
| 11 | 1 | 8µs | 1 | 5µs | my $version = $Config{version}; # spent 5µs making 1 call to Config::FETCH |
| 12 | 1 | 14µs | 1 | 4µs | my @inc_version_list = reverse split / /, $Config{inc_version_list}; # spent 4µs making 1 call to Config::FETCH |
| 13 | |||||
| 14 | |||||
| 15 | 1 | 8µs | our @ORIG_INC = @INC; # take a handy copy of 'original' value | ||
| 16 | 1 | 1µs | our $VERSION = '0.63'; | ||
| 17 | |||||
| 18 | # spent 736µs (114+622) within lib::import which was called:
# once (114µs+622µs) by main::BEGIN@31 at line 31 of /cygdrive/c/lo/libo-master/instsetoo_native/util/C:/lo/libo-master/solenv/bin/make_installer.pl | ||||
| 19 | 14 | 718µs | shift; | ||
| 20 | |||||
| 21 | my %names; | ||||
| 22 | foreach (reverse @_) { | ||||
| 23 | my $path = $_; # we'll be modifying it, so break the alias | ||||
| 24 | if ($path eq '') { | ||||
| 25 | require Carp; | ||||
| 26 | Carp::carp("Empty compile time value given to use lib"); | ||||
| 27 | } | ||||
| 28 | |||||
| 29 | 3 | 144µs | if ($path !~ /\.par$/i && -e $path && ! -d _) { # spent 134µs making 1 call to lib::CORE:ftis
# spent 7µs making 1 call to lib::CORE:match
# spent 2µs making 1 call to lib::CORE:ftdir | ||
| 30 | require Carp; | ||||
| 31 | Carp::carp("Parameter to use lib must be directory, not file"); | ||||
| 32 | } | ||||
| 33 | unshift(@INC, $path); | ||||
| 34 | # Add any previous version directories we found at configure time | ||||
| 35 | foreach my $incver (@inc_version_list) | ||||
| 36 | { | ||||
| 37 | my $dir = "$path/$incver"; | ||||
| 38 | unshift(@INC, $dir) if -d $dir; | ||||
| 39 | } | ||||
| 40 | # Put a corresponding archlib directory in front of $path if it | ||||
| 41 | # looks like $path has an archlib directory below it. | ||||
| 42 | 1 | 18µs | my($arch_auto_dir, $arch_dir, $version_dir, $version_arch_dir) # spent 18µs making 1 call to lib::_get_dirs | ||
| 43 | = _get_dirs($path); | ||||
| 44 | 1 | 169µs | unshift(@INC, $arch_dir) if -d $arch_auto_dir; # spent 169µs making 1 call to lib::CORE:ftdir | ||
| 45 | 1 | 160µs | unshift(@INC, $version_dir) if -d $version_dir; # spent 160µs making 1 call to lib::CORE:ftdir | ||
| 46 | 1 | 131µs | unshift(@INC, $version_arch_dir) if -d $version_arch_dir; # spent 131µs making 1 call to lib::CORE:ftdir | ||
| 47 | } | ||||
| 48 | |||||
| 49 | # remove trailing duplicates | ||||
| 50 | @INC = grep { ++$names{$_} == 1 } @INC; | ||||
| 51 | return; | ||||
| 52 | } | ||||
| 53 | |||||
| 54 | |||||
| 55 | sub unimport { | ||||
| 56 | shift; | ||||
| 57 | |||||
| 58 | my %names; | ||||
| 59 | foreach my $path (@_) { | ||||
| 60 | my($arch_auto_dir, $arch_dir, $version_dir, $version_arch_dir) | ||||
| 61 | = _get_dirs($path); | ||||
| 62 | ++$names{$path}; | ||||
| 63 | ++$names{$arch_dir} if -d $arch_auto_dir; | ||||
| 64 | ++$names{$version_dir} if -d $version_dir; | ||||
| 65 | ++$names{$version_arch_dir} if -d $version_arch_dir; | ||||
| 66 | } | ||||
| 67 | |||||
| 68 | # Remove ALL instances of each named directory. | ||||
| 69 | @INC = grep { !exists $names{$_} } @INC; | ||||
| 70 | return; | ||||
| 71 | } | ||||
| 72 | |||||
| 73 | # spent 18µs within lib::_get_dirs which was called:
# once (18µs+0s) by lib::import at line 42 | ||||
| 74 | 7 | 21µs | my($dir) = @_; | ||
| 75 | my($arch_auto_dir, $arch_dir, $version_dir, $version_arch_dir); | ||||
| 76 | |||||
| 77 | $arch_auto_dir = "$dir/$archname/auto"; | ||||
| 78 | $arch_dir = "$dir/$archname"; | ||||
| 79 | $version_dir = "$dir/$version"; | ||||
| 80 | $version_arch_dir = "$dir/$version/$archname"; | ||||
| 81 | |||||
| 82 | return($arch_auto_dir, $arch_dir, $version_dir, $version_arch_dir); | ||||
| 83 | } | ||||
| 84 | |||||
| 85 | 1 | 27µs | 1; | ||
| 86 | __END__ | ||||
sub lib::CORE:ftdir; # opcode | |||||
# spent 134µs within lib::CORE:ftis which was called:
# once (134µs+0s) by lib::import at line 29 | |||||
# spent 7µs within lib::CORE:match which was called:
# once (7µs+0s) by lib::import at line 29 |