STINNER Victor <[email protected]> added the comment:
> I also noticed a difference between Python 3.2 and 3.3,
> but Python 3.3 is 13% *faster* (and not slower).
Oops, I misused the timeit module, there is a regression.
> New changeset c802bfc8acfc by Victor Stinner in branch 'default':
> Issue #13621: Optimize str.replace(char1, char2)
./python -m timeit -s 'f=open("/tmp/README"); t=f.read(); f.close();
t.encode("ascii")' 't.replace("\n", " ")'
Python 3.2: 6.44 usec
Python 3.3 before: 11.6 usec
Python 3.3 after: 2.77 usec
----------
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue13621>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com