[Python-bugs-list] [ python-Bugs-780807 ] time.strptime() 1,200 times slower in python2.3
SourceForge.net
noreply@sourceforge.net
Sat, 02 Aug 2003 01:53:42 -0700
Bugs item #780807, was opened at 2003-07-31 07:17
Message generated for change (Comment added) made by rhettinger
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=780807&group_id=5470
Category: Python Library
Group: Python 2.3
Status: Open
Resolution: None
>Priority: 4
Submitted By: Malte John (drmalte)
>Assigned to: Brett Cannon (bcannon)
Summary: time.strptime() 1,200 times slower in python2.3
Initial Comment:
time.strptime() ist about 1,200 (onethousand and
twohundred) times slower in 2.3 than in 2.2! (1m:48.45s
vs. 0.09s) This is caused by the pure python
implementation.
Fix:
I simply repaced the function time_strptime(PyObject
*self, PyObject *args) from
Python-2.3/Modules/timemodule.c with the function from
python 2.2.
Maybe 'configure' should check for existence of the
strptime() function on the target system and use it, if
available?
Regards,
Malte
----------------------------------------------------------------------
>Comment By: Raymond Hettinger (rhettinger)
Date: 2003-08-02 03:53
Message:
Logged In: YES
user_id=80475
It would be interesting for you to pull down the CVS version
from two weeks ago and re-run your timings. The caching
code was removed at the end because it was a temporary
suspect on a bug-hunt just days before the release.
Note, the whole purpose of the pure python version was to
avoid the non-portable differences between strptime()
implementations on various target systems.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=780807&group_id=5470