[issue2459] speedup for / while / if with better bytecode
Jeffrey Yasskin
report at bugs.python.org
Mon Mar 2 07:11:52 CET 2009
Jeffrey Yasskin <jyasskin at gmail.com> added the comment:
I've updated for_iter.patch to the latest trunk, merging in issue 4715.
I also changed tracing a bit so that the first line of a loop doesn't
get traced twice in the first iteration, and added to test_dis to check
that decreasing line numbers work there.
Review at http://codereview.appspot.com/20103 if you like.
Performance:
32-bit gcc-4.3 Intel Core2:
2to3:
25.09 -> 24.63: 1.87% faster
Django:
Min: 0.614 -> 0.609: 0.86% faster
Avg: 0.616 -> 0.635: 3.09% slower
Pickle: (cPickle)
Min: 1.647 -> 1.651: 0.21% slower
Avg: 1.650 -> 1.656: 0.39% slower
PyBench:
Min: 5341 -> 5273: 1.29% faster
Avg: 5450 -> 5397: 0.98% faster
SlowPickle: (pickle)
Min: 1.384 -> 1.341: 3.13% faster
Avg: 1.385 -> 1.343: 3.08% faster
Spitfire:
Min: 0.773 -> 0.690: 11.97% faster
Avg: 0.776 -> 0.695: 11.62% faster
Spitfire re-run:
Min: 0.740 -> 0.693: 6.81% faster
Avg: 0.744 -> 0.695: 6.93% faster
SlowUnpickle: (pickle)
Min: 0.645 -> 0.668: 3.37% slower
Avg: 0.646 -> 0.670: 3.59% slower
SlowUnpickle re-run:
Min: 0.645 -> 0.660: 2.31% slower
Avg: 0.645 -> 0.661: 2.32% slower
Unpickle: (cPickle)
Min: 1.015 -> 1.006: 0.89% faster
Avg: 1.021 -> 1.009: 1.16% faster
64-bit gcc-4.3 Intel Core2
2to3:
22.31 -> 21.97: 1.57% faster
Django:
Min: 0.577 -> 0.564: 2.29% faster
Avg: 0.579 -> 0.566: 2.20% faster
Pickle:
Min: 1.162 -> 1.178: 1.35% slower
Avg: 1.166 -> 1.183: 1.37% slower
PyBench:
Min: 4498 -> 4193: 7.27% faster
Avg: 4586 -> 4276: 7.25% faster
SlowPickle:
Min: 1.212 -> 1.133: 6.92% faster
Avg: 1.213 -> 1.135: 6.92% faster
Spitfire:
Min: 0.631 -> 0.617: 2.32% faster
Avg: 0.632 -> 0.621: 1.75% faster
SlowUnpickle:
Min: 0.575 -> 0.551: 4.31% faster
Avg: 0.576 -> 0.553: 4.14% faster
Unpickle:
Min: 0.708 -> 0.722: 1.88% slower
Avg: 0.745 -> 0.736: 1.20% faster
----------
assignee: -> pitrou
Added file: http://bugs.python.org/file13227/trunk-opt-loop.patch
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue2459>
_______________________________________
More information about the Python-bugs-list
mailing list