This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author collinwinter
Recipients collinwinter
Date 2009-04-02.19:28:14
SpamBayes Score 5.0269467e-08
Marked as misclassified No
Message-id <1238700497.01.0.638889592432.issue5671@psf.upfronthosting.co.za>
In-reply-to
Content
The attached patch adds another version of cPickle.c's batch_list(),
batch_list_exact(), which is specialized for "type(x) is list". This
provides a nice performance boost when pickling objects that use
lists. This is similar to the approach taken in issue 5670, though the
performance boost on our benchmark is smaller:

Pickle:
Min: 2.231 -> 2.200: 1.39% faster
Avg: 2.266 -> 2.227: 1.72% faster
Significant (t=10.994064, a=0.95)


Benchmark is at
http://code.google.com/p/unladen-swallow/source/browse/tests/performance/macro_pickle.py
(driver is  ../perf.py; perf.py was run with "--rigorous -b pickle").
Workloads involving more lists will benefit more.

This patch passes all the tests added in issue 5665. I would recommend
reviewing that patch first. I'll port to py3k once this is reviewed for
trunk.
History
Date User Action Args
2009-04-02 19:28:17collinwintersetrecipients: + collinwinter
2009-04-02 19:28:17collinwintersetmessageid: <1238700497.01.0.638889592432.issue5671@psf.upfronthosting.co.za>
2009-04-02 19:28:15collinwinterlinkissue5671 messages
2009-04-02 19:28:15collinwintercreate