|
|
|
|
|
by 23409125
3235 days ago
|
|
Subpar performance is a huge drawback of Perl 6. I usually don't program in Perl, but occasionally use it instead of sed. Compare, Perl 5 vs. Perl 6: $ time yes | head -n1000000 | perl -pe 's/y/n/' >/dev/null
real 0m0.945s
user 0m0.944s
sys 0m0.016s
$ time yes | head -n1000000 | perl6 -pe 's/y/n/' >/dev/null
real 2m49.881s
user 2m44.892s
sys 0m2.184s
Spending several minutes to do what can be done in under 1 second is just unacceptable. |
|
Go is on the other end of the spectrum; they have tuned their syntax to be fast to parse, and have stuck to implementing existing compiler technology. If your semantics are very far removed from how computers work, you need a very advanced compiler like GHC.
It sounds like Perl6 is somewhat centrist in its approach, and has innovated quite a bit; I think it will be possible to almost match Perl5's speed with reasonable effort. The interpreter might do well on small examples, but the VM will dominate in very large ones. Many compilers are tiered in that they use an interpreter for cold code, and spend the effort to generate code and JIT hot code.