Differences between revisions 1 and 21 (spanning 20 versions)
Revision 1 as of 2006-05-22 16:51:26
Size: 49
Editor: SteveHolden
Comment:
Revision 21 as of 2006-05-24 21:26:52
Size: 1975
Editor: TimPeters
Comment:
Deletions are marked like this. Additions are marked like this.
Line 2: Line 2:

 * Frame optimizations: once a function is called it retains the allocated frame for use in future calls, avoiding allocation and initialization overhead. Frame size has also been slightly reduced.

 PyStone is over 10% higher on RichardJones' test machine, compared to Python 2.4 (from 20242 to 22935). PyBench reports an overall slowdown, attributed to a 150% slowdown in a piece of code that wasn't changed. Sigh.

 * Made Gzip readline 30-40% faster (BobIppolito)

 * Speed up Unicode operations (AndrewDalke, FredrikLundh). Most notable, repeat is much faster, and most search operations (find, index, count, in) are a LOT faster (20x for the related stringbench tests). Also, rsplit is now as fast as split, and splitlines is nearly as fast as a plain split("\n"). Current stringbench results:

{{{
        str(ms) uni(ms) % comment
        -----------------------------------------------------
        2271.31 3608.32 62.9 TOTAL 2.5a2
        2261.85 1187.84 190.4 TOTAL tuesday
        2247.84 875.13 256.9 TOTAL wednesday
}}}

  (yes, the Unicode string type is now more than twice as fast on this set of tests, and over 4 times faster than when we started. ymmv.)

 * Patch 1335972 was a combination bugfix+speedup for string->int conversion. These are the speedups measured on my Windows box for decimal strings of various lengths. Note that the difference between 9 and 10 is the difference between short and long Python ints on a 32-bit box. The patch doesn't actually do anything to speed conversion to long directly; the speedup in those cases is solely due to detecting "unsigned long" overflow more quickly:

{{{
        length speedup
        ------ -------
         1 12.4%
         2 15.7%
         3 20.6%
         4 28.1%
         5 33.2%
         6 37.5%
         7 41.9%
         8 46.3%
        

Things we think the Python community will like.

  • Frame optimizations: once a function is called it retains the allocated frame for use in future calls, avoiding allocation and initialization overhead. Frame size has also been slightly reduced.

    PyStone is over 10% higher on RichardJones' test machine, compared to Python 2.4 (from 20242 to 22935). PyBench reports an overall slowdown, attributed to a 150% slowdown in a piece of code that wasn't changed. Sigh.

  • Made Gzip readline 30-40% faster (BobIppolito)

  • Speed up Unicode operations (AndrewDalke, FredrikLundh). Most notable, repeat is much faster, and most search operations (find, index, count, in) are a LOT faster (20x for the related stringbench tests). Also, rsplit is now as fast as split, and splitlines is nearly as fast as a plain split("\n"). Current stringbench results:

        str(ms) uni(ms) %       comment
        -----------------------------------------------------
        2271.31 3608.32 62.9    TOTAL 2.5a2
        2261.85 1187.84 190.4   TOTAL tuesday
        2247.84  875.13 256.9   TOTAL wednesday
  • (yes, the Unicode string type is now more than twice as fast on this set of tests, and over 4 times faster than when we started. ymmv.)
  • Patch 1335972 was a combination bugfix+speedup for string->int conversion. These are the speedups measured on my Windows box for decimal strings of various lengths. Note that the difference between 9 and 10 is the difference between short and long Python ints on a 32-bit box. The patch doesn't actually do anything to speed conversion to long directly; the speedup in those cases is solely due to detecting "unsigned long" overflow more quickly:

NeedForSpeed/Successes (last edited 2008-11-15 14:00:10 by localhost)

Unable to edit the page? See the FrontPage for instructions.