![]() |
|
Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Re^5: Performance penalties of in-Perl docn vs compiled CGIs. (updated x 2)by dave_the_m (Monsignor) |
on Feb 03, 2021 at 18:44 UTC ( #11127867=note: print w/replies, xml ) | Need Help?? |
A difference is that perl doesn't haven anything resembling a virtual machine or bytecode. Bytecode typically maps fairly easily to equivalent machine code instructions; in principle you could envisage building a CPU that directly executes Java bytecode, in exactly the same sense that we currently have CPUs which can directly execute X86_64 machine code. Perl just has heaps of complex data structures - OP trees, SV trees, regexes etc - none of which maps to a linear set of bytes representing an idealised CPU.
At one point there was perl "bytecode" - but all it was was a way of serialising the contents of all those data structures to a file and then reading them back. It was said to be slower than just compiling. But this is all a bit nit-picky and toying with semantics. The main take-home point is that when people look for "a perl compiler", what they will find likely won't match their expectations in terms of what it does and what benefits it provides. Hence why I usually feel the urge to disabuse OPs of the notion in such threads. Dave.
In Section
Seekers of Perl Wisdom
|
|