[Pythonmac-SIG] RE: [wxPython-mac] two-level namespaces enabled?

Kevin Altis altis@semi-retired.com
Thu, 2 Jan 2003 12:21:05 -0800


Sorry I forgot to include this bit when I edited the original message

> From: Bill Bumgarner
>
> If you have OS9 installed, try the same test under MacPython under 
> OS9-- if it is noticeably faster, then the test on OS X is getting 
> nailed by an unfortunate bit o' implementation in the Mach ABI, I 
> believe.

I don't have OS9 installed, so I wasn't able to do the test.

ka

> -----Original Message-----
> From: Kevin Altis [mailto:altis@semi-retired.com]
> Sent: Thursday, January 02, 2003 12:05 PM
> To: pythonmac-sig@python.org
> Cc: Wxpython-Mac
> Subject: [wxPython-mac] two-level namespaces enabled?
> 
> 
> Bill Bumgarner has been porting some of my PythonCard sample code to work
> under PyObjC. Yesterday I sent him the life sample code cut down 
> to just the
> pure Python calculation of each generation. Basically, the "grid" 
> is just a
> dictionary of (x, y) tuples with values of either 0 or 1. No Mac libs,
> floating point, disk i/o, etc. is involved in the loop that I timed.
> 
> Anyway, I ran it with both the Jaguar Python (/usr/bin/python) and the
> MachoPython 2.2.1-4 disk image (/usr/local/bin/python) at:
> 
> http://sourceforge.net/project/showfiles.php?group_id=10718
> 
> and there was a 10% speed difference on the same box. I asked Bill for an
> explanation and he suggested...
> 
> > From: Bill Bumgarner
> >
> > On Thursday, Jan 2, 2003, at 00:10 US/Eastern, Kevin Altis wrote:
> > > I was a bit surprised when I ran the cmdLife.py program on my Mac.
> > > /usr/bin/python (Apple) takes 38.8 seconds pretty consistently and
> > > /usr/local/bin/python (2.2.1 framework build) takes roughly 43.3. Not
> > > sure what that means, but it is a 10% difference.
> >
> > In any case, this is likely because the Framework build is not built
> > w/two level namespaces enabled and, as such, is causing an extra
> > indirection when dispatching calls into other frameworks [or something
> > like that].
> >
> > The Apple build definitely had two-level namespaces enabled and is also
> > a static build, so no indirection is involved.
> 
> I can send the code to anyone that is interested, but I bet it would
> probably be more useful to simply run Python through its test 
> suite and see
> how the numbers compare on both versions in case this would have 
> any impact
> on the 2.2.2 and/or 2.3 builds people are working on.
> 
> ka
> ---
> Kevin Altis
> altis@semi-retired.com
> http://radio.weblogs.com/0102677/
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: wxPython-mac-unsubscribe@lists.wxwindows.org
> For additional commands, e-mail: wxPython-mac-help@lists.wxwindows.org
> 
>