perlquestion
bbs2web
<p>I was under the impression (probably miss guided) that Perl compiled scripts and stored the compiled code somewhere/somehow. If the modification time of the script hadn't changed it would subsequently not need to recompile every time the script was run.</p>
<p>I see some references to compiled Perl scripts but this primarily appears to be around avoiding having to rely on Perl on destination systems.</p>
<p>Are there ways of getting my code to execute faster?</p>
<code>
perl -d:DProf ./test.pl 198.19.28.102 user password -d; dprofpp;
{
"data": [
{ "{#BGPPEER}": "African Bank - HO - Neotel" },
{ "{#BGPPEER}": "African Bank - HO - Teraco" },
{ "{#BGPPEER}": "African Bank - Neotel - Midrand" },
{ "{#BGPPEER}": "Liquid Telecoms - A" },
{ "{#BGPPEER}": "Liquid Telecoms - B" }
]
}
Total Elapsed Time = 0.354916 Seconds
User+System Time = 0.304916 Seconds
Exclusive Times
%Time ExclSec CumulS #Calls sec/call Csec/c Name
13.1 0.040 0.040 138 0.0003 0.0003 Class::MOP::Method::Generated::_eval_closure
9.84 0.030 0.026 23 0.0013 0.0011 Moose::Util::TypeConstraints::BEGIN
6.56 0.020 0.020 4 0.0050 0.0050 B::Hooks::EndOfScope::BEGIN
6.56 0.020 0.038 15 0.0013 0.0026 Class::MOP::BEGIN
6.56 0.020 0.213 24 0.0008 0.0089 Moose::BEGIN
6.56 0.020 0.019 176 0.0001 0.0001 Class::MOP::Mixin::HasAttributes::has_attribute
6.23 0.019 0.018 258 0.0001 0.0001 Class::MOP::Class::Immutable::Class::MOP::Class::get_meta_instance
6.23 0.019 0.019 1106 0.0000 0.0000 Class::MOP::get_metaclass_by_name
6.23 0.019 0.019 1062 0.0000 0.0000 Class::MOP::Package::_package_stash
5.90 0.018 0.018 1712 0.0000 0.0000 Package::Stash::PP::_deconstruct_variable_name
5.25 0.016 0.031 1168 0.0000 0.0000 Package::Stash::PP::get_symbol
3.28 0.010 0.010 1 0.0100 0.0100 Net::SSLeay::load_error_strings
3.28 0.010 0.010 1 0.0100 0.0100 Params::Util::bootstrap
3.28 0.010 0.010 6 0.0017 0.0016 IO::Socket::BEGIN
3.28 0.010 0.010 14 0.0007 0.0007 Package::Stash::PP::BEGIN
</code>