[Patches] [ python-Patches-923226 ] 'os' patch to speed up import
(and python startup)
SourceForge.net
noreply at sourceforge.net
Thu Mar 25 14:32:29 EST 2004
Patches item #923226, was opened at 2004-03-25 17:18
Message generated for change (Comment added) made by loewis
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=923226&group_id=5470
Category: Library (Lib)
Group: Python 2.4
Status: Open
Resolution: None
Priority: 5
Submitted By: Nick Bastin (mondragon)
Assigned to: Nobody/Anonymous (nobody)
Summary: 'os' patch to speed up import (and python startup)
Initial Comment:
This patch changes the _Environ subclass of UserDict to use dict
instead, which avoids the import of UserDict, save 6-8ms on
python startup with site.py (~4% improvement).
I tested this on my MacOS X box, but since this code is really only
used in Win32, someone should test it there.
----------------------------------------------------------------------
>Comment By: Martin v. Löwis (loewis)
Date: 2004-03-25 20:32
Message:
Logged In: YES
user_id=21627
The patch is incorrect. dict has no attribute data, and subclassing from
dict involves many more changes than just changing __setitem__/
__getitem__.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=923226&group_id=5470
More information about the Patches
mailing list