[issue17897] Optimize unpickle prefetching

Serhiy Storchaka report at bugs.python.org
Sat Nov 30 19:32:18 CET 2013


Serhiy Storchaka added the comment:

Microbenchmark:

$ ./python -c "import pickle; d = b'x' * 10**6; f = open('test.pickle3', 'wb'); pickle.dump(d, f, 3); f.close()"
$ ./python -m timeit -s "from pickle import load"  "with open('test.pickle3', 'rb') as f: load(f)"

Unpatched:  100 loops, best of 3: 7.27 msec per loop
Patched:    100 loops, best of 3: 4.87 msec per loop

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue17897>
_______________________________________


More information about the Python-bugs-list mailing list