in reply to High Performance Perl

There is an article on perl.com by MJD (locally known as Dominus,) that explains this pretty well. (far better than I could myself.)

What it boils down to is, it isn't that perl is so particularly slow, it just has a lot of overhead from the built in memory managment and flexible data structures. The very things that make perl so powerful and flexible, make it run somewhat slower than C/C++.

Replies are listed 'Best First'.
Re^2: High Performance Perl
by willyyam (Priest) on May 25, 2005 at 12:35 UTC

    Thank you, that was an interesting article, and goes a long way to explaining things for me.

    I was asking because I get this sensation, more like the barest, subtlest hint, that people like writing code in Perl, but there are things that Perl isn't good for. So I thought to my self: 'Self, if all code of any language is just CPU math in the end anyway, why can't you write kernels in Perl - just use the derived math on bare metal, rather than parse-interpret-compile-execute?'

    I'm beginning to see that there is more to it than that - mostly due to memory issues - as I understand it, all memory allocations must be defined in size and type for code to be safe, and Perl does that for us (which is one reason to love it) but that added complexity precludes Perl's use on bare metal. Very cool. These computer thingies are complicated.