Message223656
Here is alternative patch. I believe it makes a code simpler.
Microbenchmarks:
$ ./python -m timeit -n 100000 -s "from ntpath import splitdrive" "splitdrive('c:foo')"
Before: 100000 loops, best of 3: 20 usec per loop
After: 100000 loops, best of 3: 11.5 usec per loop
$ ./python -m timeit -n 100000 -s "from ntpath import splitext" "splitext('python.exe')"
Before: 100000 loops, best of 3: 23.6 usec per loop
After: 100000 loops, best of 3: 18 usec per loop
$ ./python -m timeit -s "from ntpath import join" "join('foo', 'bar')"
Before: 10000 loops, best of 3: 50.9 usec per loop
After: 10000 loops, best of 3: 32.3 usec per loop
$ ./python -m timeit -s "from ntpath import normpath" "normpath('/foo/bar/baz')"
Before: 10000 loops, best of 3: 67.5 usec per loop
After: 10000 loops, best of 3: 40.3 usec per loop
$ ./python -m timeit -s "from ntpath import relpath" "relpath('foo', 'bar')"
Before: 1000 loops, best of 3: 695 usec per loop
After: 1000 loops, best of 3: 456 usec per loop |
|
Date |
User |
Action |
Args |
2014-07-22 10:09:20 | serhiy.storchaka | set | recipients:
+ serhiy.storchaka, terry.reedy, jcea, ezio.melotti, brian.curtin, BreamoreBoy, mandel |
2014-07-22 10:09:20 | serhiy.storchaka | set | messageid: <1406023760.18.0.260279544533.issue15275@psf.upfronthosting.co.za> |
2014-07-22 10:09:20 | serhiy.storchaka | link | issue15275 messages |
2014-07-22 10:09:20 | serhiy.storchaka | create | |
|