Speed of Python 1.5.x vs 2.0

Steve Horne sh at ttsoftware.co.uk
Fri Dec 22 06:21:30 EST 2000


On Fri, 22 Dec 2000 09:59:58 +0100, Andreas Jung
<andreas at andreas-jung.com> wrote:

>On Thu, Dec 21, 2000 at 10:53:32PM -0500, Tyler Eaves wrote:
>> 	I'm soon going to attemp to talk my webhost into upgrading to
>> 2.0, but I figure the only way I'm going to be able to make that
>> happen is if I can show results that show 2.0 being faster / more
>> effcient than 1.5.x. Their servers run on Red Hat 7.
>
>2.0 runs a bit faster than 1.5.X but don't expect a performance
>boost. You should upgrade when you need some of the new features
>of Python 2.0 like unicode support... 
>
>Andreas 

I'd expect list comprehensions to work significantly faster than
equivalent expressions using filter, map and lambdas - the reason
being that the overhead of repeatedly calling the lambda should be
avoided, not to mention avoiding the temp storage between the filter
and map.

I haven't tried this, but it might be worth a go.

-- 
Steve Horne
Home : steve at lurking.demon.co.uk
Work : sh at ttsoftware.co.uk



More information about the Python-list mailing list