Performance of int/long in Python 3

Roy Smith roy at panix.com
Wed Apr 3 00:10:36 EDT 2013


In article 
<5f8ed721-7c89-4ffd-8f2b-21979cc3386a at kk11g2000pbb.googlegroups.com>,
 rusi <rustompmody at gmail.com> wrote:

> On Apr 3, 8:31 am, Neil Hodgson <nhodg... at iinet.net.au> wrote:
> 
> >     Sorting a million string list (all the file paths on a particular
> > computer) went from 0.4 seconds with Python 3.2 to 0.78 with 3.3 so
> > we're out of the 'not noticeable by humans' range.

On the other hand, how long did it take you to do the directory tree 
walk required to find those million paths?  I'll bet a long longer than 
0.78 seconds, so this gets lost in the noise.

Still, it is unfortunate if sort performance got hurt significantly.  My 
mind was blown a while ago when I discovered that python could sort a 
file of strings faster than the unix command-line sort utility.  That's 
pretty impressive.



More information about the Python-list mailing list