← Index
NYTProf Performance Profile   « block view • line view • sub view »
For -e
  Run on Wed Nov 17 21:39:01 2010
Reported on Wed Nov 17 22:04:56 2010

Filename/home/doy/perl5/perlbrew/perls/perl-5.10.1/lib/5.10.1/x86_64-linux/Hash/Util/FieldHash.pm
StatementsExecuted 23 statements in 2.35ms
Subroutines
Calls P F Exclusive
Time
Inclusive
Time
Subroutine
111114µs114µsHash::Util::FieldHash::::BEGIN@3Hash::Util::FieldHash::BEGIN@3
11140µs199µsHash::Util::FieldHash::::BEGIN@6Hash::Util::FieldHash::BEGIN@6
11139µs117µsHash::Util::FieldHash::::BEGIN@5Hash::Util::FieldHash::BEGIN@5
11138µs55µsHash::Util::FieldHash::::BEGIN@4Hash::Util::FieldHash::BEGIN@4
11138µs38µsHash::Util::FieldHash::::_ob_regHash::Util::FieldHash::_ob_reg
0000s0sHash::Util::FieldHash::::fieldhashHash::Util::FieldHash::fieldhash
0000s0sHash::Util::FieldHash::::fieldhashesHash::Util::FieldHash::fieldhashes
0000s0sHash::Util::FieldHash::::idhashHash::Util::FieldHash::idhash
0000s0sHash::Util::FieldHash::::idhashesHash::Util::FieldHash::idhashes
Call graph for these subroutines as a Graphviz dot language file.
Line State
ments
Time
on line
Calls Time
in subs
Code
1package Hash::Util::FieldHash;
2
33165µs1114µs
# spent 114µs within Hash::Util::FieldHash::BEGIN@3 which was called: # once (114µs+0s) by Hash::Util::FieldHash::Compat::BEGIN@8 at line 3
use 5.009004;
# spent 114µs making 1 call to Hash::Util::FieldHash::BEGIN@3
4391µs271µs
# spent 55µs (38+17) within Hash::Util::FieldHash::BEGIN@4 which was called: # once (38µs+17µs) by Hash::Util::FieldHash::Compat::BEGIN@8 at line 4
use strict;
# spent 55µs making 1 call to Hash::Util::FieldHash::BEGIN@4 # spent 17µs making 1 call to strict::import
53128µs2194µs
# spent 117µs (39+78) within Hash::Util::FieldHash::BEGIN@5 which was called: # once (39µs+78µs) by Hash::Util::FieldHash::Compat::BEGIN@8 at line 5
use warnings;
# spent 117µs making 1 call to Hash::Util::FieldHash::BEGIN@5 # spent 78µs making 1 call to warnings::import
631.10ms2358µs
# spent 199µs (40+159) within Hash::Util::FieldHash::BEGIN@6 which was called: # once (40µs+159µs) by Hash::Util::FieldHash::Compat::BEGIN@8 at line 6
use Scalar::Util qw( reftype);
# spent 199µs making 1 call to Hash::Util::FieldHash::BEGIN@6 # spent 159µs making 1 call to Exporter::import
7
814µsour $VERSION = '1.04';
9
1014µsrequire Exporter;
11129µsour @ISA = qw(Exporter);
12110µsour %EXPORT_TAGS = (
13 'all' => [ qw(
14 fieldhash
15 fieldhashes
16 idhash
17 idhashes
18 id
19 id_2obj
20 register
21 )],
22);
23113µsour @EXPORT_OK = ( @{ $EXPORT_TAGS{'all'} } );
24
25{
2627µs require XSLoader;
2712µs my %ob_reg; # private object registry
28139µs
# spent 38µs within Hash::Util::FieldHash::_ob_reg which was called: # once (38µs+0s) by XSLoader::load at line 94 of XSLoader.pm
sub _ob_reg { \ %ob_reg }
291728µs1777µs XSLoader::load('Hash::Util::FieldHash', $VERSION);
# spent 777µs making 1 call to XSLoader::load
30}
31
32sub fieldhash (\%) {
33 for ( shift ) {
34 return unless ref() && reftype( $_) eq 'HASH';
35 return $_ if Hash::Util::FieldHash::_fieldhash( $_, 0);
36 return $_ if Hash::Util::FieldHash::_fieldhash( $_, 2) == 2;
37 return;
38 }
39}
40
41sub idhash (\%) {
42 for ( shift ) {
43 return unless ref() && reftype( $_) eq 'HASH';
44 return $_ if Hash::Util::FieldHash::_fieldhash( $_, 0);
45 return $_ if Hash::Util::FieldHash::_fieldhash( $_, 1) == 1;
46 return;
47 }
48}
49
50sub fieldhashes { map &fieldhash( $_), @_ }
51sub idhashes { map &idhash( $_), @_ }
52
53130µs1;
54__END__