From: Wido D. <wid...@gm...> - 2005-01-12 21:43:27
|
On Wed, 12 Jan 2005 07:51:29 +0100, Michael Str=F6der <mi...@st...> wrote: > > In the current shape, the function is only 3% slower than the old > > code, but works with all LDAP servers, including Oracle now. >=20 > I will test. I'd be happy if you provide a LDIF dump of a sub schema > entry of Oracle's OID. I'll do that tomorrow. >=20 > > But if we > > could use string.split(aList), this algorithm would be 3 times faster > > than the current one. >=20 > I currently do not have the time to analyse this any further. Can you > please explain why string.split(aList) can't be used within your > implementation? Hmm, nothing. I may not have expressed myself clearly enough. I wasn't sure if you were following certain coding conventions, so i tried to do the algortihm as simple as possible and keeping the usage of the string module low. But since we can use this module, the part can be replaced by string.split(). If have a more general question about some things you do in the source code. At some points you assign a function from a module to a variable, like "string_split =3D string.split". I've asked myself, why you do this. Is it to improve speed? Your assignment would spare a lookup of split in the string module and be somehow faster. But some quick testing showed, that this trick only gains 0.3 seconds when splitting a string 1.000.000 times. > > I leave it up to you, to integrate my function, or find your own > > solution. >=20 > I'd add your code to python-ldap provided you give away copyright for it > to the python-ldap project. Please confirm (list Cc:-ed). I hereby grant the python-ldap project (http://python-ldap.sourceforge.net/) my copyright belonging to all parts of code, which is meant to be included into python-ldap. This includes all future commits, unless otherwise stated. =20 mfg. Wido --=20 Wido Depping ICQ: 51303067 AIM: wido3379 Jabber: wi...@ja... Blog: http://widoww.blogspot.com |