Message188363
Here are some numbers: # Without the patch $ ./python -m timeit -s "import pickle, io; d=pickle.dumps(list(range(1000)), 4); b=io.BytesIO(d)" "b.seek(0); pickle.load(b)" 10000 loops, best of 3: 180 usec per loop $ ./python -m timeit -s "import pickle, _pyio as io; d=pickle.dumps(list(range(1000)), 4); b=io.BytesIO(d)" "b.seek(0); pickle.load(b)" 100 loops, best of 3: 4.52 msec per loop # With the patch $ ./python -m timeit -s "import pickle, io; d=pickle.dumps(list(range(1000)), 4); b=io.BytesIO(d)" "b.seek(0); pickle.load(b)" 10000 loops, best of 3: 42.8 usec per loop $ ./python -m timeit -s "import pickle, _pyio as io; d=pickle.dumps(list(range(1000)), 4); b=io.BytesIO(d)" "b.seek(0); pickle.load(b)" 10000 loops, best of 3: 47.3 usec per loop | |
| Date | User | Action | Args | | 2013-05-04 14:34:14 | pitrou | set | recipients: + pitrou, rhettinger, alexandre.vassalotti, Arfrever, asvetlov, neologix, serhiy.storchaka | | 2013-05-04 14:34:14 | pitrou | set | messageid: <1367678054.64.0.669085985384.issue17810@psf.upfronthosting.co.za> | | 2013-05-04 14:34:14 | pitrou | link | issue17810 messages | | 2013-05-04 14:34:14 | pitrou | create | | |