← Index
NYTProf Performance Profile   « line view »
For script/ponapi
  Run on Wed Feb 10 15:51:26 2016
Reported on Thu Feb 11 09:43:10 2016

Filename/usr/local/share/perl/5.18.2/Stream/Buffered/File.pm
StatementsExecuted 9 statements in 178µs
Subroutines
Calls P F Exclusive
Time
Inclusive
Time
Subroutine
1118µs17µsStream::Buffered::File::::BEGIN@2Stream::Buffered::File::BEGIN@2
1118µs108µsStream::Buffered::File::::BEGIN@6Stream::Buffered::File::BEGIN@6
1117µs10µsStream::Buffered::File::::BEGIN@3Stream::Buffered::File::BEGIN@3
1115µs52µsStream::Buffered::File::::BEGIN@4Stream::Buffered::File::BEGIN@4
0000s0sStream::Buffered::File::::newStream::Buffered::File::new
0000s0sStream::Buffered::File::::printStream::Buffered::File::print
0000s0sStream::Buffered::File::::rewindStream::Buffered::File::rewind
0000s0sStream::Buffered::File::::sizeStream::Buffered::File::size
Call graph for these subroutines as a Graphviz dot language file.
Line State
ments
Time
on line
Calls Time
in subs
Code
1package Stream::Buffered::File;
2219µs226µs
# spent 17µs (8+9) within Stream::Buffered::File::BEGIN@2 which was called: # once (8µs+9µs) by Stream::Buffered::BEGIN@7 at line 2
use strict;
# spent 17µs making 1 call to Stream::Buffered::File::BEGIN@2 # spent 9µs making 1 call to strict::import
3221µs214µs
# spent 10µs (7+3) within Stream::Buffered::File::BEGIN@3 which was called: # once (7µs+3µs) by Stream::Buffered::BEGIN@7 at line 3
use warnings;
# spent 10µs making 1 call to Stream::Buffered::File::BEGIN@3 # spent 3µs making 1 call to warnings::import
4221µs298µs
# spent 52µs (5+47) within Stream::Buffered::File::BEGIN@4 which was called: # once (5µs+47µs) by Stream::Buffered::BEGIN@7 at line 4
use base 'Stream::Buffered';
# spent 52µs making 1 call to Stream::Buffered::File::BEGIN@4 # spent 47µs making 1 call to base::import
5
62115µs2208µs
# spent 108µs (8+100) within Stream::Buffered::File::BEGIN@6 which was called: # once (8µs+100µs) by Stream::Buffered::BEGIN@7 at line 6
use IO::File;
# spent 108µs making 1 call to Stream::Buffered::File::BEGIN@6 # spent 100µs making 1 call to Exporter::import
7
8sub new {
9 my $class = shift;
10
11 my $fh = IO::File->new_tmpfile;
12 $fh->binmode;
13
14 bless { fh => $fh }, $class;
15}
16
17sub print {
18 my $self = shift;
19 $self->{fh}->print(@_);
20}
21
22sub size {
23 my $self = shift;
24 $self->{fh}->flush;
25 -s $self->{fh};
26}
27
28sub rewind {
29 my $self = shift;
30 $self->{fh}->seek(0, 0);
31 $self->{fh};
32}
33
3412µs1;