This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: str.split optimization for one character separaters
Type: Stage:
Components: Interpreter Core Versions: Python 2.4
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: hyeshik.chang Nosy List: hyeshik.chang
Priority: normal Keywords: patch

Created on 2003-12-29 03:21 by hyeshik.chang, last changed 2022-04-11 14:56 by admin. This issue is now closed.

File name Uploaded Description Edit
patch-strsplit.diff hyeshik.chang, 2003-12-29 03:21 a patch
Messages (2)
msg45077 - (view) Author: Hyeshik Chang (hyeshik.chang) * (Python committer) Date: 2003-12-29 03:21
Attached patch tries to optimize str.split by a
speciaiized splitter for one character separacters.
This trick is used for unicode.split too. I just
applied it to str.split. :)

quick perf. test:

% ./python Lib/
100000 loops, best of 3: 7.84 usec per loop

% ./python Lib/
100000 loops, best of 3: 5.39 usec per loop
msg45078 - (view) Author: Hyeshik Chang (hyeshik.chang) * (Python committer) Date: 2004-01-05 00:30
Logged In: YES 

Committed as 1.37 and stringobject.c 2.217
Date User Action Args
2022-04-11 14:56:01adminsetgithub: 39736
2003-12-29 03:21:45hyeshik.changcreate