Issue13622
Created on 2011-12-17 17:53 by Boris.FELD, last changed 2022-04-11 14:57 by admin. This issue is now closed.
Messages (4) |
|
|
msg149683 - (view) |
Author: Boris FELD (Boris.FELD) * |
Date: 2011-12-17 17:53 |
Hello everyone, I juste tried to launch the stringbench on python3.2 and python3.3 dev versions and some bytes tests run slower in python3.3 than in python3.2. I cc the two raw output of both runs. I also extracted most interesting data (all the tests with more than 20% of performance regression): - (b"A"*1000).find(b"B") (*1000): -30.379747% - b"Hello\t \t".rstrip() (*1000): -33.333333% - b"this\nis\na\ntest\n".rsplit(b"\n") (*1000): -23.437500% - b"\nHello!\n".strip() (*1000): -33.333333% - dna.split(b"ACTAT") (*10): -21.066667% - b"Andrew".endswith(b"w") (*1000): -23.529412% - b"...text.with.2000.lines...replace(b"\n", b" ") (*10): -37.668161% - b"\t \tHello".rstrip() (*1000): -33.333333% - (b"A"*1000).rpartition(b"A") (*1000): -21.212121% - (b"Here are some words. "*2).split() (*1000): -22.105263% - b"this\nis\na\ntest\n".split(b"\n") (*1000): -23.437500% - b"Hello!\n".rstrip() (*1000): -35.714286% - b"B" in b"A"*1000 (*1000): -32.089552% - b"Hello!\n".strip() (*1000): -35.714286% - b"\nHello!".strip() (*1000): -28.571429% - b"Andrew".startswith(b"A") (*1000): -20.588235% - b"\nHello!".rstrip() (*1000): -35.714286% - b"Andrew".endswith(b"Andrew") (*1000): -22.857143% - b"Andrew".endswith(b"Anders") (*1000): -23.529412% - b"Andrew".startswith(b"Anders") (*1000): -23.529412% - b"this--is--a--test--of--the--emergency--broadcast--system".split(b"--") (*1000): -22.429907% - b"Andrew"+b"Dalke" (*1000): -23.076923% Hope it help |
|
|
msg149685 - (view) |
Author: STINNER Victor (vstinner) *  |
Date: 2011-12-17 18:07 |
Sorted and grouped results. "replace", "find" and "concat" should be easy to fix, "strip" and "split" depend on "find" performance. replace: - b"...text.with.2000.lines...replace(b"\n", b" ") (*10): -37.668161% find: - (b"A"*1000).find(b"B") (*1000): -30.379747% - b"Andrew".startswith(b"A") (*1000): -20.588235% - b"Andrew".startswith(b"Anders") (*1000): -23.529412% - b"Andrew".endswith(b"w") (*1000): -23.529412% - b"Andrew".endswith(b"Andrew") (*1000): -22.857143% - b"Andrew".endswith(b"Anders") (*1000): -23.529412% - b"B" in b"A"*1000 (*1000): -32.089552% concat: - b"Andrew"+b"Dalke" (*1000): -23.076923% strip: - b"\nHello!\n".strip() (*1000): -33.333333% - b"Hello!\n".strip() (*1000): -35.714286% - b"\nHello!".strip() (*1000): -28.571429% - b"Hello\t \t".rstrip() (*1000): -33.333333% - b"\t \tHello".rstrip() (*1000): -33.333333% - b"Hello!\n".rstrip() (*1000): -35.714286% - b"\nHello!".rstrip() (*1000): -35.714286% split: - dna.split(b"ACTAT") (*10): -21.066667% - (b"Here are some words. "*2).split() (*1000): -22.105263% - b"this\nis\na\ntest\n".split(b"\n") (*1000): -23.437500% - b"this--is--a--test--of--the--emergency--broadcast--system".split(b"--") (*1000): -22.429907% - b"this\nis\na\ntest\n".rsplit(b"\n") (*1000): -23.437500% - (b"A"*1000).rpartition(b"A") (*1000): -21.212121% |
|
|
msg149687 - (view) |
Author: Boris FELD (Boris.FELD) * |
Date: 2011-12-17 18:08 |
Forgot to describe my environment: Mac OS X 10.6.8 GCC i686-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5666) (dot 3) CPython3.3 revision ea421c534305 CPython3.2 revision 0b86da9d6964 |
|
|
msg149692 - (view) |
Author: STINNER Victor (vstinner) *  |
Date: 2011-12-17 18:42 |
Boris.FELD told me that there was a bug in compare.py: all numbers are related to Unicode (see #13621), not bytes. |
|
|
History |
|
|
|
Date |
User |
Action |
Args |
2022-04-11 14:57:24 |
admin |
set |
github: 57831 |
2011-12-17 18:42:50 |
vstinner |
set |
status: open -> closedresolution: not a bug |
2011-12-17 18:42:41 |
vstinner |
set |
messages: + |
2011-12-17 18:08:09 |
Boris.FELD |
set |
messages: + |
2011-12-17 18:07:10 |
vstinner |
set |
nosy: + vstinnermessages: + |
2011-12-17 17:54:16 |
Boris.FELD |
set |
files: + compare.py |
2011-12-17 17:54:06 |
Boris.FELD |
set |
files: + stringbench_log_cpython3.3 |
2011-12-17 17:53:49 |
Boris.FELD |
create |
|