in reply to Re^13: Parallel::ForkManager is time consuming...takes too long
in thread Parallel::ForkManager is time consuming...takes too long

He added

<#> gv[*b] s # my $b = $b[$i]; <1> rv2av sKR/1 <0> padsv[$i:2,4] s <2> aelem sK/2 <0> padsv[$b:3,4] sRM*/LVINTRO <2> sassign vKS/2

in order to replace a large number of

<#> gv[*b] s # $b[$i] <1> rv2av sKR/1 <0> padsv[$i:2,3] s <2> aelem sK/2

with

<0> padsv[$b:3,4] s # $b

Assuming each of these ops take roughly the same amount of time to execute, this adds up. Basically,

my $b = $b[$i]; ... $b ... $b ... $b # 6 + 1*3 = 9 ops

is faster than

$b[$i] ... $b[$i] ... $b[$i]; # 0 + 4*3 = 12 ops

Since his code looks up $b[i] 4 to 8 times (depending on the value of $b[$i]), this saves 6 to 18 ops. Per loop pass!