← Index
NYTProf Performance Profile   « block view • line view • sub view »
For xt/tapper-mcp-scheduler-with-db-longrun.t
  Run on Tue May 22 17:18:39 2012
Reported on Tue May 22 17:23:42 2012

Filename/2home/ss5/perl5/perlbrew/perls/perl-5.12.3/lib/site_perl/5.12.3/x86_64-linux/YAML/Syck.pm
StatementsExecuted 44 statements in 2.41ms
Subroutines
Calls P F Exclusive
Time
Inclusive
Time
Subroutine
221463µs463µsYAML::Syck::::LoadYAMLYAML::Syck::LoadYAML (xsub)
11151µs594µsYAML::Syck::::LoadFileYAML::Syck::LoadFile
11136µs89µsYAML::Syck::::BEGIN@36YAML::Syck::BEGIN@36
11132µs32µsYAML::Syck::::CORE:openYAML::Syck::CORE:open (opcode)
22224µs486µsYAML::Syck::::LoadYAML::Syck::Load
11122µs259µsYAML::Syck::::BEGIN@15YAML::Syck::BEGIN@15
11114µs14µsYAML::Syck::::BEGIN@12YAML::Syck::BEGIN@12
11114µs14µsYAML::Syck::::CORE:ftisYAML::Syck::CORE:ftis (opcode)
11112µs12µsYAML::Syck::::CORE:readlineYAML::Syck::CORE:readline (opcode)
11111µs13µsYAML::Syck::::BEGIN@4YAML::Syck::BEGIN@4
11110µs12µsYAML::Syck::::_is_globYAML::Syck::_is_glob
1117µs20µsYAML::Syck::::BEGIN@13YAML::Syck::BEGIN@13
1117µs149µsYAML::Syck::::BEGIN@5YAML::Syck::BEGIN@5
1112µs2µsYAML::Syck::::CORE:ftzeroYAML::Syck::CORE:ftzero (opcode)
1111µs1µsYAML::Syck::::CORE:matchYAML::Syck::CORE:match (opcode)
0000s0sYAML::Syck::::DumpYAML::Syck::Dump
0000s0sYAML::Syck::::DumpFileYAML::Syck::DumpFile
0000s0sYAML::Syck::::__ANON__[:37]YAML::Syck::__ANON__[:37]
0000s0sYAML::Syck::::__ANON__[:38]YAML::Syck::__ANON__[:38]
0000s0sYAML::Syck::::__ANON__[:39]YAML::Syck::__ANON__[:39]
0000s0sYAML::Syck::::__ANON__[:40]YAML::Syck::__ANON__[:40]
0000s0sYAML::Syck::::__ANON__[:41]YAML::Syck::__ANON__[:41]
0000s0sYAML::Syck::::__ANON__[:42]YAML::Syck::__ANON__[:42]
0000s0sYAML::Syck::::__ANON__[:43]YAML::Syck::__ANON__[:43]
0000s0sYAML::Syck::::__ANON__[:44]YAML::Syck::__ANON__[:44]
0000s0sYAML::Syck::::__ANON__[:45]YAML::Syck::__ANON__[:45]
0000s0sYAML::Syck::::__ANON__[:46]YAML::Syck::__ANON__[:46]
0000s0sYAML::Syck::::__ANON__[:47]YAML::Syck::__ANON__[:47]
0000s0sYAML::Syck::::__ANON__[:48]YAML::Syck::__ANON__[:48]
0000s0sYAML::Syck::::__ANON__[:49]YAML::Syck::__ANON__[:49]
0000s0sYAML::Syck::::__ANON__[:50]YAML::Syck::__ANON__[:50]
0000s0sYAML::Syck::::__ANON__[:51]YAML::Syck::__ANON__[:51]
0000s0sYAML::Syck::::__ANON__[:52]YAML::Syck::__ANON__[:52]
0000s0sYAML::Syck::::__qr_helperYAML::Syck::__qr_helper
Call graph for these subroutines as a Graphviz dot language file.
Line State
ments
Time
on line
Calls Time
in subs
Code
1package YAML::Syck;
2# See documentation after the __END__ mark.
3
4329µs215µs
# spent 13µs (11+2) within YAML::Syck::BEGIN@4 which was called: # once (11µs+2µs) by Tapper::Config::BEGIN@15 at line 4
use strict;
# spent 13µs making 1 call to YAML::Syck::BEGIN@4 # spent 2µs making 1 call to strict::import
515µs1142µs
# spent 149µs (7+142) within YAML::Syck::BEGIN@5 which was called: # once (7µs+142µs) by Tapper::Config::BEGIN@15 at line 11
use vars qw(
# spent 142µs making 1 call to vars::import
6 @ISA @EXPORT $VERSION
7 $Headless $SortKeys $SingleQuote
8 $ImplicitBinary $ImplicitTyping $ImplicitUnicode
9 $UseCode $LoadCode $DumpCode
10 $DeparseObject $LoadBlessed
11214µs1149µs);
# spent 149µs making 1 call to YAML::Syck::BEGIN@5
12327µs114µs
# spent 14µs within YAML::Syck::BEGIN@12 which was called: # once (14µs+0s) by Tapper::Config::BEGIN@15 at line 12
use 5.006;
# spent 14µs making 1 call to YAML::Syck::BEGIN@12
13381µs233µs
# spent 20µs (7+13) within YAML::Syck::BEGIN@13 which was called: # once (7µs+13µs) by Tapper::Config::BEGIN@15 at line 13
use Exporter;
# spent 20µs making 1 call to YAML::Syck::BEGIN@13 # spent 13µs making 1 call to Exporter::import
14
15
# spent 259µs (22+238) within YAML::Syck::BEGIN@15 which was called: # once (22µs+238µs) by Tapper::Config::BEGIN@15 at line 34
BEGIN {
161400ns $VERSION = '1.20';
1711µs @EXPORT = qw( Dump Load DumpFile LoadFile );
1819µs @ISA = qw( Exporter );
19
201300ns $SortKeys = 1;
211200ns $LoadBlessed = 1;
22
231200ns local $@;
24 eval {
251600ns require XSLoader;
261243µs1238µs XSLoader::load(__PACKAGE__, $VERSION);
# spent 238µs making 1 call to XSLoader::load
271900ns 1;
2813µs } or do {
29 require DynaLoader;
30 push @ISA, 'DynaLoader';
31 __PACKAGE__->bootstrap($VERSION);
32 };
33
341289µs1259µs}
# spent 259µs making 1 call to YAML::Syck::BEGIN@15
35
36
# spent 89µs (36+53) within YAML::Syck::BEGIN@36 which was called: # once (36µs+53µs) by Tapper::Config::BEGIN@15 at line 53
use constant QR_MAP => {
37 '' => sub { qr{$_[0]} },
38 x => sub { qr{$_[0]}x },
39 i => sub { qr{$_[0]}i },
40 s => sub { qr{$_[0]}s },
41 m => sub { qr{$_[0]}m },
42 ix => sub { qr{$_[0]}ix },
43 sx => sub { qr{$_[0]}sx },
44 mx => sub { qr{$_[0]}mx },
45 si => sub { qr{$_[0]}si },
46 mi => sub { qr{$_[0]}mi },
47 ms => sub { qr{$_[0]}sm },
48 six => sub { qr{$_[0]}six },
49 mix => sub { qr{$_[0]}mix },
50 msx => sub { qr{$_[0]}msx },
51 msi => sub { qr{$_[0]}msi },
52 msix => sub { qr{$_[0]}msix },
533436µs2142µs};
# spent 89µs making 1 call to YAML::Syck::BEGIN@36 # spent 53µs making 1 call to constant::import
54
55sub __qr_helper {
56 if ($_[0] =~ /\A \(\? ([ixsm]*) (?:- (?:[ixsm]*))? : (.*) \) \z/x) {
57 my $sub = QR_MAP()->{$1} || QR_MAP()->{''};
58 &$sub($2);
59 }
60 else {
61 qr/$_[0]/;
62 }
63}
64
65sub Dump {
66 $#_ ? join('', map { YAML::Syck::DumpYAML($_) } @_)
67 : YAML::Syck::DumpYAML($_[0]);
68}
69
70
# spent 486µs (24+462) within YAML::Syck::Load which was called 2 times, avg 243µs/call: # once (10µs+462µs) by YAML::Syck::LoadFile at line 123 # once (15µs+0s) by Tapper::Config::_switch_context at line 72 of Tapper/Config.pm
sub Load {
7124µs if (wantarray) {
721468µs1462µs my ($rv) = YAML::Syck::LoadYAML($_[0]);
# spent 462µs making 1 call to YAML::Syck::LoadYAML
731900ns @{$rv};
74 }
75 else {
76110µs @_ = $_[0];
771659µs11µs goto &YAML::Syck::LoadYAML;
# spent 1µs making 1 call to YAML::Syck::LoadYAML
78 }
79}
80
81
# spent 12µs (10+1) within YAML::Syck::_is_glob which was called: # once (10µs+1µs) by YAML::Syck::LoadFile at line 115
sub _is_glob {
821600ns my $h = shift;
83
8411µs return 1 if(ref($h) eq 'GLOB');
8511µs return 1 if(ref(\$h) eq 'GLOB');
8616µs11µs return 1 if(ref($h) =~ m/^IO::/);
# spent 1µs making 1 call to YAML::Syck::CORE:match
87
8814µs return;
89}
90
91sub DumpFile {
92 my $file = shift;
93 if ( _is_glob($file) ) {
94 if ($#_) {
95 print {$file} YAML::Syck::DumpYAML($_) for @_;
96 }
97 else {
98 print {$file} YAML::Syck::DumpYAML($_[0]);
99 }
100 }
101 else {
102 open(my $fh, '>', $file) or die "Cannot write to $file: $!";
103 if ($#_) {
104 print {$fh} YAML::Syck::DumpYAML($_) for @_;
105 }
106 else {
107 print {$fh} YAML::Syck::DumpYAML($_[0]);
108 }
109 close $fh;
110 }
111}
112
113
# spent 594µs (51+543) within YAML::Syck::LoadFile which was called: # once (51µs+543µs) by Test::Fixture::DBIC::Schema::_load_fixture at line 36 of Test/Fixture/DBIC/Schema.pm
sub LoadFile {
1141600ns my $file = shift;
11515µs112µs if ( _is_glob($file) ) {
# spent 12µs making 1 call to YAML::Syck::_is_glob
116 Load(do { local $/; <$file> });
117 }
118 else {
119127µs216µs if(!-e $file || -z $file) {
# spent 14µs making 1 call to YAML::Syck::CORE:ftis # spent 2µs making 1 call to YAML::Syck::CORE:ftzero
120 die("'$file' is empty or non-existant");
121 }
122140µs132µs open(my $fh, '<', $file) or die "Cannot read from $file: $!";
# spent 32µs making 1 call to YAML::Syck::CORE:open
123337µs2483µs Load(do { local $/; <$fh> });
# spent 471µs making 1 call to YAML::Syck::Load # spent 12µs making 1 call to YAML::Syck::CORE:readline
124 }
125}
126
12713µs1;
128
129__END__
 
# spent 14µs within YAML::Syck::CORE:ftis which was called: # once (14µs+0s) by YAML::Syck::LoadFile at line 119
sub YAML::Syck::CORE:ftis; # opcode
# spent 2µs within YAML::Syck::CORE:ftzero which was called: # once (2µs+0s) by YAML::Syck::LoadFile at line 119
sub YAML::Syck::CORE:ftzero; # opcode
# spent 1µs within YAML::Syck::CORE:match which was called: # once (1µs+0s) by YAML::Syck::_is_glob at line 86
sub YAML::Syck::CORE:match; # opcode
# spent 32µs within YAML::Syck::CORE:open which was called: # once (32µs+0s) by YAML::Syck::LoadFile at line 122
sub YAML::Syck::CORE:open; # opcode
# spent 12µs within YAML::Syck::CORE:readline which was called: # once (12µs+0s) by YAML::Syck::LoadFile at line 123
sub YAML::Syck::CORE:readline; # opcode
# spent 463µs within YAML::Syck::LoadYAML which was called 2 times, avg 231µs/call: # once (462µs+0s) by YAML::Syck::Load at line 72 # once (1µs+0s) by Tapper::Config::_switch_context at line 77
sub YAML::Syck::LoadYAML; # xsub