[svlug] language benchmarks

Rick Kwan kwanrj03 at comcast.net
Mon May 17 23:11:51 PDT 2004


David N. Welton wrote:
> Rick Kwan <kwanrj03 at comcast.net> writes:

>>I've been looking for current Perl and Python benchmarks, showing
>>relative performance merits.  The benchmarks I've seen so far are a
>>couple of years old.

> Check this out:
> 
> http://scutigena.sourceforge.net/

I looked.  This is definitely good stuff.

>>In particular, http://www.flat222.org/mac/bench/
>>compares several languages, including:
>>     perl 5.6.1
>>     python 2.1.3
>>     java 1.4.0_01
>>     C++ (2.95.4?)
>>These were done in 2002 on debian woody.  The results for
>>Python are alarmingly slower than the other three in some
>>areas.

>>Any insights into this?

To answer my own question, in the more recent benchmarks,
the  gap between Perl and Python has narrowed considerably.
I think this means the Python language implementation has
matured.  The earlier disparity was what drove me to ask
the question.

> My favorite way of doing stuff like this is to hack up an app in Tcl
> and then rewrite bits of it in C as needs be.

I remember extending the Tcl interpreter. :-)  The nice
thing about Tcl was that it was that it actually was
designed to be extended.  (Now I admit, I haven't done
this for a few years.)

> If you have a Really Big web site, Java might be worthwhile, but
> otherwise it's a huge, heavy system that is slow to develop for
> compared to something like Tcl or Python.
> 
> It really depends on what you need to do with what resources, I guess.

In the last 18 months or so, my brain has turned into
computing mush.  I've found myself doing sizable projects
in C, C++, Java, Perl, PHP, and Python.  (And just to freak
myself out, I got pulled into discussions of how to interface
C with Fortran.)

In dealing with so many languages and their rapid evolution,
it is impossible to be a language lawyer for each one.
On numerous occasions, I've found myself implementing
in a fashion that was very sub-optimal for the language in
question.  Seeing how different languages attack a similar
problem is therefore quite useful.

--Rick Kwan





More information about the svlug mailing list