alan little’s weblog

i am impressed

14th December 2005 permanent link

James Robertson is clearly very good indeed at his job. I have posted here twice about perhaps-not-wholly-positive experiences with VisualWorks Smalltalk; both times, without any prompting from me, he has found the postings and responded in an entirely constructive and non-critical manner.

The second one was when I found that VisualWorks parsed my large iTunes library file on my Powerbook at about the same speed as python’s not-very-impressive default XML parser, and significantly more slowly than elementtree, which by general consensus is probably the fastest pure python XML tool.

That gave rise to a still-ongoing comment saga on James’s blog, in which several helpful, polite, apparently well-informed Smalltalk enthusiasts are concerned about my disappointing test result and earnestly trying to find out why it might be, without anybody in any way appearing to flame me personally.

What I have learned so far from this:

  1. My Smalltalk code wasn’t doing anything obviously stupid (I would hope not, since it was based closely on the first example on Cincom’s “How To Do XML With VisualWorks Smalltalk” page). It might be slightly slower than James’s version, but certainly not enough to account for the difference in our test results.
  2. Other people seem to be able to get XML files of a similar size to mine parsed considerably faster on similar hardware. They are reporting parse times well under a minute against my three minutes – comparable with the pure python version of elementtree, although still nowhere near cElementTree’s 3 to 4 seconds. These are of course not my file – which I have now sent to a couple of people to see how they get on with it. UPDATE: apparently on James’s Mac Mini my file loads and parses in 61.7 seconds. Roughly comparable machines – 1.25 Ghz versus my Powerbook’s 1GHz (and a faster frontside bus), but 256 MB versus my 512MB – so clearly something wrong with my test setup.
  3. There are two versions of VisualWorks Smalltalk that run on the Mac, a native OS X one and an X11 one. The current native OS X version, which is what I was using, is known to be slow (fix due soon, apparently). James can load and parse my file in 20.6 seconds on his Wondows box.

So it looks like Chris Petrilli was right about Smalltalk performance after all. Even using a notoriously slow version of the Smalltalk VM that is overdue for replacement, it’s still about on a par with the fastest pure python parser.

Far more important than all that from the point of view of James’s job, though, is this: if this is the level of support somebody gets when they are just dabbling with the non-commercial version, what must the paid support be like? Based on this experience I have to say I would be seriously considering VisualWorks Smalltalk if I had free choice of development tools for a significant commercial development(*). (Sadly there is no immediate prospect of me finding myself in that situation). Commercial development tools can’t be an easy sell in these days of ubiquitous high quality open source languages, and VisualWorks isn’t cheap if you’re not an investment bank, but I certainly begin to see how it could be worth it.

(*) Unless the project crucially depended on being able to crunch large XML files very fast, in which case python with cElementTree would still be clearly the right tool for the job.

related entries: Programming

all text and images © 2003–2008