Profile of (eval 593)[Apache/LogFormat/Compiler.pm:151]

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

Filename | (eval 593)[/usr/local/share/perl/5.18.2/Apache/LogFormat/Compiler.pm:151]
Statements | Executed 500008 statements in 5.14s
Eval Invoked At | /usr/local/share/perl/5.18.2/Apache/LogFormat/Compiler.pm line 151

Subroutines
Calls | P | F | Exclusive Time | Inclusive Time | Subroutine
--- | --- | --- | --- | --- | ---
100001 | 1 | 1 | 5.62s | 8.33s | Apache::LogFormat::Compiler::::__ANON__[:21]Apache::LogFormat::Compiler::__ANON__[:21]

Call graph for these subroutines as a Graphviz dot language file.

Line | State ments | Time on line | Calls | Time in subs | Code
--- | --- | --- | --- | --- | ---
1 |  |  |  |  | # spent 8.33s (5.62+2.71) within Apache::LogFormat::Compiler::__ANON__[(eval 593)[/usr/local/share/perl/5.18.2/Apache/LogFormat/Compiler.pm:151]:21] which was called 100001 times, avg 83µs/call: # 100001 times (5.62s+2.71s) by Apache::LogFormat::Compiler::log_line at line 158 of Apache/LogFormat/Compiler.pm, avg 83µs/call sub {
2 | 100001 | 158ms |  |  | $_[TIME] = time() if ! defined $_[TIME];
3 | 100001 | 1.74s |  |  | my @lt = localtime($_[TIME]);
4 | 100001 | 209ms |  |  | if ( ! exists $c->{tz_cache} || ! exists $c->{isdst_cache} || $lt[8] != $c->{isdst_cache} ) {
5 | 1 | 12µs | 1 | 700µs | $c->{tz_cache} = POSIX::strftime::Compiler::strftime('%z',@lt); # spent 700µs making 1 call to POSIX::strftime::Compiler::strftime
6 | 1 | 2µs |  |  | $c->{isdst_cache} = $lt[8];
7 |  |  |  |  | }
8 | 100001 | 789ms |  |  | my $t = sprintf '%02d/%s/%04d:%02d:%02d:%02d %s', $lt[3], $abbr[$lt[4]], $lt[5]+1900,
9 |  |  |  |  | $lt[2], $lt[1], $lt[0], $c->{tz_cache};
10 | 100001 | 2.25s | 400004 | 2.71s | q!! . ($_[ENVS]->{REMOTE_ADDR} || '-') # spent 1.45s making 200002 calls to Apache::LogFormat::Compiler::_safe, avg 7µs/call # spent 1.26s making 200002 calls to Apache::LogFormat::Compiler::_string, avg 6µs/call
11 |  |  |  |  | . q! ! . '-'
12 |  |  |  |  | . q! ! . ($_[ENVS]->{REMOTE_USER} || '-')
13 |  |  |  |  | . q! ! . '[' . $t . ']'
14 |  |  |  |  | . q! "! . _safe($_[ENVS]->{REQUEST_METHOD}) . " " . _safe($_[ENVS]->{REQUEST_URI}) .
15 |  |  |  |  | " " . $_[ENVS]->{SERVER_PROTOCOL}
16 |  |  |  |  | . q!" ! . $_[RES]->[0]
17 |  |  |  |  | . q! ! . (defined $_[LENGTH] ? $_[LENGTH] : '-')
18 |  |  |  |  | . q! "! . _string($_[ENVS]->{'HTTP_REFERER'})
19 |  |  |  |  | . q!" "! . _string($_[ENVS]->{'HTTP_USER_AGENT'})
20 |  |  |  |  | . q!"!
21 | 1 | 5µs |  |  | }
22 |  |  |  |  | ;