Filename | /usr/lib/perl5/site_perl/5.14/Archive/Zip/FileMember.pm |
Statements | Executed 496730 statements in 1.67s |
Calls | P | F | Exclusive Time |
Inclusive Time |
Subroutine |
---|---|---|---|---|---|
101011 | 18 | 1 | 732ms | 4.73s | fh | Archive::Zip::FileMember::
35182 | 4 | 2 | 659ms | 926ms | endRead | Archive::Zip::FileMember::
9982 | 1 | 1 | 171ms | 3.72s | _openFile | Archive::Zip::FileMember::
1381 | 1 | 1 | 57.4ms | 62.4ms | _become | Archive::Zip::FileMember::
19964 | 2 | 2 | 55.5ms | 55.5ms | externalFileName | Archive::Zip::FileMember::
1 | 1 | 1 | 219µs | 225µs | BEGIN@3 | Archive::Zip::FileMember::
1 | 1 | 1 | 21µs | 21µs | BEGIN@6 | Archive::Zip::FileMember::
1 | 1 | 1 | 13µs | 300µs | BEGIN@11 | Archive::Zip::FileMember::
1 | 1 | 1 | 13µs | 86µs | BEGIN@4 | Archive::Zip::FileMember::
0 | 0 | 0 | 0s | 0s | _usesFileNamed | Archive::Zip::FileMember::
Line | State ments |
Time on line |
Calls | Time in subs |
Code |
---|---|---|---|---|---|
1 | package Archive::Zip::FileMember; | ||||
2 | |||||
3 | 2 | 65µs | 2 | 232µs | # spent 225µs (219+7) within Archive::Zip::FileMember::BEGIN@3 which was called:
# once (219µs+7µs) by installer::archivefiles::BEGIN@30 at line 3 # spent 225µs making 1 call to Archive::Zip::FileMember::BEGIN@3
# spent 7µs making 1 call to strict::import |
4 | 2 | 80µs | 2 | 159µs | # spent 86µs (13+73) within Archive::Zip::FileMember::BEGIN@4 which was called:
# once (13µs+73µs) by installer::archivefiles::BEGIN@30 at line 4 # spent 86µs making 1 call to Archive::Zip::FileMember::BEGIN@4
# spent 73µs making 1 call to vars::import |
5 | |||||
6 | # spent 21µs within Archive::Zip::FileMember::BEGIN@6 which was called:
# once (21µs+0s) by installer::archivefiles::BEGIN@30 at line 9 | ||||
7 | 2 | 21µs | $VERSION = '1.30'; | ||
8 | @ISA = qw ( Archive::Zip::Member ); | ||||
9 | 1 | 54µs | 1 | 21µs | } # spent 21µs making 1 call to Archive::Zip::FileMember::BEGIN@6 |
10 | |||||
11 | 1 | 287µs | # spent 300µs (13+287) within Archive::Zip::FileMember::BEGIN@11 which was called:
# once (13µs+287µs) by installer::archivefiles::BEGIN@30 at line 13 # spent 287µs making 1 call to Exporter::import | ||
12 | :UTILITY_METHODS | ||||
13 | 2 | 529µs | 1 | 300µs | ); # spent 300µs making 1 call to Archive::Zip::FileMember::BEGIN@11 |
14 | |||||
15 | # spent 55.5ms within Archive::Zip::FileMember::externalFileName which was called 19964 times, avg 3µs/call:
# 9982 times (27.9ms+0s) by Archive::Zip::FileMember::_openFile at line 38, avg 3µs/call
# 9982 times (27.6ms+0s) by Archive::Zip::ZipFileMember::_seekToLocalHeader at line 71 of Archive/Zip/ZipFileMember.pm, avg 3µs/call | ||||
16 | 19964 | 87.2ms | shift->{'externalFileName'}; | ||
17 | } | ||||
18 | |||||
19 | # Return true if I depend on the named file | ||||
20 | sub _usesFileNamed { | ||||
21 | my $self = shift; | ||||
22 | my $fileName = shift; | ||||
23 | my $xfn = $self->externalFileName(); | ||||
24 | return undef if ref($xfn); | ||||
25 | return $xfn eq $fileName; | ||||
26 | } | ||||
27 | |||||
28 | # spent 4.73s (732ms+3.99) within Archive::Zip::FileMember::fh which was called 101011 times, avg 47µs/call:
# 10349 times (75.5ms+32.4ms) by Archive::Zip::ZipFileMember::_readRawChunk at line 411 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 9982 times (72.8ms+31.8ms) by Archive::Zip::ZipFileMember::_readCentralDirectoryFileHeader at line 319 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 9982 times (72.6ms+28.5ms) by Archive::Zip::ZipFileMember::_seekToLocalHeader at line 71 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 9982 times (69.8ms+29.4ms) by Archive::Zip::ZipFileMember::_seekToLocalHeader at line 68 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 8601 times (62.0ms+3.21s) by Archive::Zip::ZipFileMember::rewindData at line 384 of Archive/Zip/ZipFileMember.pm, avg 381µs/call
# 8601 times (67.3ms+31.1ms) by Archive::Zip::ZipFileMember::rewindData at line 386 of Archive/Zip/ZipFileMember.pm, avg 11µs/call
# 8601 times (62.7ms+25.3ms) by Archive::Zip::ZipFileMember::_skipLocalFileHeader at line 156 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 8601 times (61.2ms+26.5ms) by Archive::Zip::ZipFileMember::_skipLocalFileHeader at line 137 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 8601 times (62.1ms+24.8ms) by Archive::Zip::ZipFileMember::_skipLocalFileHeader at line 169 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 8601 times (60.4ms+24.5ms) by Archive::Zip::ZipFileMember::rewindData at line 399 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 1381 times (9.21ms+505ms) by Archive::Zip::ZipFileMember::_become at line 104 of Archive/Zip/ZipFileMember.pm, avg 373µs/call
# 1381 times (10.6ms+4.59ms) by Archive::Zip::ZipFileMember::_become at line 105 of Archive/Zip/ZipFileMember.pm, avg 11µs/call
# 1381 times (10.1ms+4.29ms) by Archive::Zip::ZipFileMember::_readLocalFileHeader at line 240 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 1381 times (10.2ms+4.16ms) by Archive::Zip::ZipFileMember::_readLocalFileHeader at line 225 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 1381 times (10.0ms+4.25ms) by Archive::Zip::ZipFileMember::_readLocalFileHeader at line 206 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 1381 times (9.74ms+4.13ms) by Archive::Zip::ZipFileMember::_become at line 108 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 822 times (5.87ms+2.38ms) by Archive::Zip::ZipFileMember::_skipLocalFileHeader at line 162 of Archive/Zip/ZipFileMember.pm, avg 10µs/call
# 2 times (14µs+6µs) by Archive::Zip::ZipFileMember::_readLocalFileHeader at line 233 of Archive/Zip/ZipFileMember.pm, avg 10µs/call | ||||
29 | 303033 | 729ms | my $self = shift; | ||
30 | 101011 | 3.99s | $self->_openFile() # spent 3.72s making 9982 calls to Archive::Zip::FileMember::_openFile, avg 372µs/call
# spent 278ms making 91029 calls to IO::Handle::opened, avg 3µs/call | ||
31 | if !defined( $self->{'fh'} ) || !$self->{'fh'}->opened(); | ||||
32 | return $self->{'fh'}; | ||||
33 | } | ||||
34 | |||||
35 | # opens my file handle from my file name | ||||
36 | # spent 3.72s (171ms+3.55) within Archive::Zip::FileMember::_openFile which was called 9982 times, avg 372µs/call:
# 9982 times (171ms+3.55s) by Archive::Zip::FileMember::fh at line 30, avg 372µs/call | ||||
37 | 59892 | 147ms | my $self = shift; | ||
38 | 19964 | 3.24s | my ( $status, $fh ) = _newFileHandle( $self->externalFileName(), 'r' ); # spent 3.21s making 9982 calls to Archive::Zip::_newFileHandle, avg 322µs/call
# spent 27.9ms making 9982 calls to Archive::Zip::FileMember::externalFileName, avg 3µs/call | ||
39 | if ( !$status ) { | ||||
40 | _ioError( "Can't open", $self->externalFileName() ); | ||||
41 | return undef; | ||||
42 | } | ||||
43 | $self->{'fh'} = $fh; | ||||
44 | 9982 | 306ms | _binmode($fh); # spent 306ms making 9982 calls to Archive::Zip::_binmode, avg 31µs/call | ||
45 | return $fh; | ||||
46 | } | ||||
47 | |||||
48 | # Make sure I close my file handle | ||||
49 | # spent 926ms (659+267) within Archive::Zip::FileMember::endRead which was called 35182 times, avg 26µs/call:
# 9982 times (107ms+51.2ms) by Archive::Zip::Archive::readFromFileHandle at line 608 of Archive/Zip/Archive.pm, avg 16µs/call
# 8601 times (104ms+39.5ms) by Archive::Zip::Member::extractToFileHandle at line 993 of Archive/Zip/Member.pm, avg 17µs/call
# 8368 times (91.4ms+38.4ms) by Archive::Zip::Member::readChunk at line 801 of Archive/Zip/Member.pm, avg 16µs/call
# 8231 times (356ms+138ms) by Archive::Zip::Member::_inflateChunk at line 856 of Archive/Zip/Member.pm, avg 60µs/call | ||||
50 | 105546 | 647ms | my $self = shift; | ||
51 | undef $self->{'fh'}; # _closeFile(); | ||||
52 | 35182 | 267ms | return $self->SUPER::endRead(@_); # spent 267ms making 35182 calls to Archive::Zip::Member::endRead, avg 8µs/call | ||
53 | } | ||||
54 | |||||
55 | # spent 62.4ms (57.4+5.06) within Archive::Zip::FileMember::_become which was called 1381 times, avg 45µs/call:
# 1381 times (57.4ms+5.06ms) by Archive::Zip::ZipFileMember::_become at line 117 of Archive/Zip/ZipFileMember.pm, avg 45µs/call | ||||
56 | 8286 | 56.1ms | my $self = shift; | ||
57 | my $newClass = shift; | ||||
58 | return $self if ref($self) eq $newClass; | ||||
59 | delete( $self->{'externalFileName'} ); | ||||
60 | delete( $self->{'fh'} ); | ||||
61 | 1381 | 5.06ms | return $self->SUPER::_become($newClass); # spent 5.06ms making 1381 calls to Archive::Zip::Member::_become, avg 4µs/call | ||
62 | } | ||||
63 | |||||
64 | 1 | 7µs | 1; |