The Joys of “perl -d:DProf”
I am working on my thesis for an MS in computer science, and my topic is finite automata. It is being done in Perl, and once I finish what I am doing I will be sure to release the details. I promise it is not Earth shattering. It seems like the more low level I get into CS the more I like it....anyway, on to the subject.
I discovered the joys of perl -d:DProf, and was able to drastically improve performance for RE->to_nfa by only changing state names if there was a clash and only sync’ing the epsilon symbol if they were different. This netted a 300% peformance gain when converting fifty 32-character regexes. Granted they were randomly generated and contained varying degrees of nested expressions, but it is still a great result! Check out the profiles below showing the improvement: BEFORE: Total Elapsed Time = 14.75619 Seconds #—-!! User+System Time = 14.82619 Seconds Exclusive Times %Time ExclSec CumulS #Calls sec/call Csec/c Name 59.0 8.753 13.007 30974 0.0003 0.0004 NFA::rename_state #—-!! 14.9 2.213 2.213 186601 0.0000 0.0000 FA::is_member 11.6 1.721 1.721 123476 0.0000 0.0000 FA::get_states 5.73 0.849 1.706 41571 0.0000 0.0000 NFA::add_transition 3.53 0.524 11.198 1406 0.0004 0.0080 NFA::append_nfa 1.65 0.245 0.245 41914 0.0000 0.0000 FA::get_final 1.57 0.233 3.099 84890 0.0000 0.0000 FA::is_state 1.47 0.218 0.547 48447 0.0000 0.0000 FA::is_symbol 1.21 0.180 0.180 3937 0.0000 0.0000 RE::get_terminals 1.15 0.171 0.171 3648 0.0000 0.0000 RE::is_member 1.14 0.169 0.882 17619 0.0000 0.0001 FA::add_state 1.05 0.156 0.704 46634 0.0000 0.0000 FA::add_symbol 0.93 0.138 0.381 1975 0.0001 0.0002 RE::L 0.92 0.136 13.205 3241 0.0000 0.0041 FA::append_state_names 0.82 0.121 15.850 3391 0.0000 0.0047 RE::thompsonAFTER: Total Elapsed Time = 4.336713 Seconds #—-!! User+System Time = 4.276713 Seconds Exclusive Times %Time ExclSec CumulS #Calls sec/call Csec/c Name 24.7 1.060 1.060 100111 0.0000 0.0000 FA::is_member 12.8 0.550 0.550 65038 0.0000 0.0000 FA::get_states 12.5 0.535 0.832 3116 0.0002 0.0003 NFA::rename_state #—-!! 8.63 0.369 1.927 1558 0.0002 0.0012 FA::ensure_unique_states #—-!! 6.76 0.289 0.651 14560 0.0000 0.0000 NFA::add_transition 6.64 0.284 1.540 56014 0.0000 0.0000 FA::is_state 6.10 0.261 3.173 1396 0.0002 0.0023 NFA::append_nfa 5.05 0.216 0.869 16413 0.0000 0.0001 FA::add_state 3.79 0.162 0.162 3895 0.0000 0.0000 RE::get_terminals 3.58 0.153 0.153 3626 0.0000 0.0000 RE::is_member 2.92 0.125 0.334 1926 0.0001 0.0002 RE::L 2.76 0.118 0.552 1396 0.0001 0.0004 NFA::clone 2.50 0.107 4.524 3416 0.0000 0.0013 RE::thompson 2.36 0.101 0.322 19589 0.0000 0.0000 FA::add_symbol 2.15 0.092 0.092 14069 0.0000 0.0000 FA::get_final
wuynkgim by Anonymous (not verified)
furosemide by Anonymous (not verified)
paxil by Anonymous (not verified)
buy ambien online by Anonymous (not verified)
furosemide by Anonymous (not verified)
generic prevacid by Anonymous (not verified)
buy phentermine online by Anonymous (not verified)
furosemide by Anonymous (not verified)
amoxil by Anonymous (not verified)
buy hydrocodone online by Anonymous (not verified)
zanaflex by Anonymous (not verified)
orlistat by Anonymous (not verified)
vicodin online by Anonymous (not verified)
sumatriptan by Anonymous (not verified)
testosterone by Anonymous (not verified)
zoloft online by Anonymous (not verified)
buy adipex online by Anonymous (not verified)
tenormin by Anonymous (not verified)
generic prozac denticulated prig by Anonymous (not verified)
lipitor by Anonymous (not verified)
finasteride by Anonymous (not verified)
adipex by Anonymous (not verified)
testosterone by Anonymous (not verified)
valium online by Anonymous (not verified)
lipitor by Anonymous (not verified)
x72d239 by x72d239 (not verified)
x065cac by x065cac (not verified)
x47353c by x47353c (not verified)
generic zoloft rerubber twerp by Anonymous (not verified)
generic lexapro by Anonymous (not verified)
buspirone by Anonymous (not verified)
fexofenadine by Anonymous (not verified)
cozaar idolization lardaceous by Anonymous (not verified)
omeprazole by Anonymous (not verified)
lipitor by Anonymous (not verified)
alprazolam by Anonymous (not verified)
buy xanax online by Anonymous (not verified)
zyrtec by Anonymous (not verified)
omeprazole by Anonymous (not verified)
amoxil by Anonymous (not verified)
trazodone by Anonymous (not verified)
atorvastatin by Anonymous (not verified)
celexa by Anonymous (not verified)
order fioricet by Anonymous (not verified)
tretinoin by Anonymous (not verified)
buy tramadol by Anonymous (not verified)
zyban by Anonymous (not verified)
buy propecia by Anonymous (not verified)
generic soma by Anonymous (not verified)
prozac online by Anonymous (not verified)
generic celexa by Anonymous (not verified)
zyrtec humanitites actuality by Anonymous (not verified)
carisoprodol online perilabyrinthitis unsay by Anonymous (not verified)
hydrocodone by Anonymous (not verified)
furosemide by Anonymous (not verified)
cozaar by Anonymous (not verified)
buy soma by Anonymous (not verified)
generic plavix radiochemistry bant by Anonymous (not verified)
generic ultram by Anonymous (not verified)
lexapro by Anonymous (not verified)
fluconazole by Anonymous (not verified)
glucophage by Anonymous (not verified)
ambien by Anonymous (not verified)
triamcinolone by Anonymous (not verified)
allegra by Anonymous (not verified)
generic effexor by Anonymous (not verified)
aleve by Anonymous (not verified)
buy tramadol drawrope gimp by Anonymous (not verified)
buy fioricet by Anonymous (not verified)
tramadol online by Anonymous (not verified)
generic tadalafil by Anonymous (not verified)
alprazolam by Anonymous (not verified)
cheap alprazolam by Anonymous (not verified)
generic ambien by Anonymous (not verified)
retin-a by Anonymous (not verified)
cipralex by Anonymous (not verified)
cialis by Anonymous (not verified)
generic cialis online by Anonymous (not verified)
proscar by Anonymous (not verified)
singulair by Anonymous (not verified)
viagra online by Anonymous (not verified)
carisoprodol online by Anonymous (not verified)
online soma income buy by name (not verified)
generic prevacid by Anonymous (not verified)
order vicodin by Anonymous (not verified)
celebrex by Anonymous (not verified)
lortab by Anonymous (not verified)
fioricet by Anonymous (not verified)
ibuprofen by Anonymous (not verified)
paxil by Anonymous (not verified)
cheap levitra by Anonymous (not verified)
lunesta by Anonymous (not verified)
buy phentermine online by Anonymous (not verified)
order viagra by Anonymous (not verified)
xda6a90 by xda6a90 (not verified)
Light by Sem (not verified)
xanax without prescription by Caleb (not verified)
buy phentermine by Daan (not verified)
herbal phentermine by Yu (not verified)
Cheap Phentermine by Arturo (not verified)
xanax for sale by Stephen (not verified)
cheap phentermine online by Miguel (not verified)
adipex online by Lewis (not verified)
|
TopicsRecent blog posts
|