From: | Rudi Chiarito |
Date: | 22 Aug 2000 at 14:00:39 |
Subject: | Re: AMIOPEN: Amiga python |
On Sun, Aug 20, 2000 at 03:43:47PM -0500, Marc Culler wrote:
> than Intel machine language. Second is that the VP version is
> somewhat slower. My Amiga SDK benchmarks at 3360.77 pystones/second,
> while the host linux system benchmarks at 5076.14 pystones/second.
While recompiling it, I noticed several warnings like the following:
object.c: In function `make_pair':
object.c:337: warning: cast from pointer to integer of different size
object.c:337: warning: cast from pointer to integer of different size
object.c: In function `PyObject_Hash':
object.c:486: warning: cast from pointer to integer of different size
Taking just a quick look at the sources, it seems like in quite a few
places the Python developers happily cast pointers to longs. Under
Linux/x86, both types are 32bit long. With VP, type long is 64bits.
So there are some places in the code where VP is forced (without a real
need, it seems) to do more work. It doesn't sound that fair to me. ;)
I have no measure of how much performance is hurt this way, but it might
be worth trying to replace longs with ints (I have no better and quicker
workaround). That and telling the Python developers about it. ;)
Ah, the joys of C...