[Python-Dev] Silly little benchmark

Skip Montanaro skip@pobox.com (Skip Montanaro)
Tue, 10 Jul 2001 12:23:15 -0500

    >> Python 1.6   Python 2.1   change
    >> pass           0.12         0.20    1.67x
    >> x = 1          0.17         0.30    1.76x
    >> x = ``1`+`2``  1.60         2.13    1.33x

    Tim> Please don't post stuff with hard tab characters (I took them out
    Tim> by hand so this wasn't an unreadable mess).

Damn!  I meant to run untabify before posting (I knew you'd bitch about hard
tabs ;-) but then I went and forgot.  I just added an untab hook to my Emacs
mail-send-hooks, so this shouldn't happen in the future.

    Tim> The loop speedup in 2.2 requires changes in the PVM as well as
    Tim> adopting the iterator protocol.  If you've got some *easy*
    Tim> performance improvements, sure, but then I have to wonder why
    Tim> you've been holding them back <wink>.

I've not been holding anything back.  Like I said, I don't know what made me
take the 10 minutes right then to whip up a couple trivial benchmarks.
(Bored, I guess.)  I'll try playing around to see what I can dig up.