Message45077
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:
- BEFORE -
% ./python Lib/timeit.py
'"/aaa/bbb/ccc/ddd/eee/fff/ggg/hhh/iii".split("/")'
100000 loops, best of 3: 7.84 usec per loop
- AFTER -
% ./python Lib/timeit.py
'"/aaa/bbb/ccc/ddd/eee/fff/ggg/hhh/iii".split("/")'
100000 loops, best of 3: 5.39 usec per loop
|
|
Date |
User |
Action |
Args |
2007-08-23 15:30:45 | admin | link | issue866875 messages |
2007-08-23 15:30:45 | admin | create | |
|