← Index
NYTProf Performance Profile   « line view »
For /usr/local/bin/sa-learn
  Run on Sun Nov 5 02:36:06 2017
Reported on Sun Nov 5 02:56:18 2017

Filename/usr/local/lib/perl5/5.24/mach/MIME/Base64.pm
StatementsExecuted 14 statements in 972µs
Subroutines
Calls P F Exclusive
Time
Inclusive
Time
Subroutine
701112.2ms12.2msMIME::Base64::::decode_base64MIME::Base64::decode_base64 (xsub)
11140µs57µsMIME::Base64::::BEGIN@3MIME::Base64::BEGIN@3
11134µs275µsMIME::Base64::::BEGIN@4MIME::Base64::BEGIN@4
0000s0sMIME::Base64::::decode_base64urlMIME::Base64::decode_base64url
0000s0sMIME::Base64::::encode_base64urlMIME::Base64::encode_base64url
Call graph for these subroutines as a Graphviz dot language file.
Line State
ments
Time
on line
Calls Time
in subs
Code
1package MIME::Base64;
2
3273µs274µs
# spent 57µs (40+17) within MIME::Base64::BEGIN@3 which was called: # once (40µs+17µs) by Mail::SpamAssassin::Util::BEGIN@84 at line 3
use strict;
# spent 57µs making 1 call to MIME::Base64::BEGIN@3 # spent 17µs making 1 call to strict::import
42437µs2516µs
# spent 275µs (34+241) within MIME::Base64::BEGIN@4 which was called: # once (34µs+241µs) by Mail::SpamAssassin::Util::BEGIN@84 at line 4
use vars qw(@ISA @EXPORT @EXPORT_OK $VERSION);
# spent 275µs making 1 call to MIME::Base64::BEGIN@4 # spent 241µs making 1 call to vars::import
5
612µsrequire Exporter;
7119µs@ISA = qw(Exporter);
813µs@EXPORT = qw(encode_base64 decode_base64);
913µs@EXPORT_OK = qw(encode_base64url decode_base64url encoded_base64_length decoded_base64_length);
10
1112µs$VERSION = '3.15';
12
1312µsrequire XSLoader;
141400µs1384µsXSLoader::load('MIME::Base64', $VERSION);
# spent 384µs making 1 call to XSLoader::load
15
1616µs*encode = \&encode_base64;
1712µs*decode = \&decode_base64;
18
19sub encode_base64url {
20 my $e = encode_base64(shift, "");
21 $e =~ s/=+\z//;
22 $e =~ tr[+/][-_];
23 return $e;
24}
25
26sub decode_base64url {
27 my $s = shift;
28 $s =~ tr[-_][+/];
29 $s .= '=' while length($s) % 4;
30 return decode_base64($s);
31}
32
33123µs1;
34
35__END__
 
# spent 12.2ms within MIME::Base64::decode_base64 which was called 70 times, avg 174µs/call: # 70 times (12.2ms+0s) by Mail::SpamAssassin::Util::base64_decode at line 705 of Mail/SpamAssassin/Util.pm, avg 174µs/call
sub MIME::Base64::decode_base64; # xsub