gmpy 1.01 rc near... anybody wanna test>

Alex Martelli aleax at mail.comcast.net
Wed Nov 9 22:25:27 EST 2005


<casevh at comcast.net> wrote:
   ...
> I made a successful installer for Windows using Mingw32 and Python 2.4.

Great, thanks.

> I needed to edit setup.py to list gmp as a required library.
> 
> if sys.version.find('MSC')==-1:
>     gmpy_ext = Extension('gmpy', sources=['src/gmpy.c'],
>         # library_dirs=['/usr/local/lib'],
>         libraries=['gmp'])
> else:
>     gmpy_ext = Extension('gmpy', sources=['src/gmpy.c'],
>         include_dirs=['./src'],
>         libraries=['gmp'])    # I added libraries!
> 
> Will you be updating the information in setup.py file?

Done, in the current CVS version.

> Tomorrow, I'll recreate my build process on another computer. I am
> willing to create Windows installers.

Wonderful!

> Which versions of Python do you want to support?

I have tested gmpy with 2.3 and 2.4 on Mac, and those two and also 2.2
on Linux.  I think supporting 2.2 with a Windows download is probably
unneeded, but 2.4 is a must and I suspect 2.3 would be nice...

> Do you want versions that include GMP tailored for specific processors?

My gut reaction here is that people with special processors, Windows,
and demanding performance needs should probably get their own
development environments and build GMP and gmpy accordingly.

Any opinions from the public on this one...?

> With GMP 4.1.4 compiled for pentium3, and running on a 1.8Ghz Pentium
> M, I'm able to calculate the decimal form of 2^25964951 (the 43rd
> Mersenne prime) in 10 seconds. The prior gmpy release takes just over
> 14 seconds. Without gmpy, Python takes 25.4 seconds. On an Athlon
> MP2800+ (2.133Ghz) with GMP compiled for that processor, I can do it in
> 6.6 seconds using gmpy and 22.4 seconds without gmpy. I'm working with
> blocks of 1000 digits and using a combination of Toom-Cook and
> Nussbaumer convolution to perform the multiplies and squares.

Sounds quite decent -- about a 2.5 to 3+ times speedup wrt Python, and
some speedup wrt gmpy 1.0 (all GMP's merit -- I didn't address
performance aspects at all in this delta).  Just out of curiosity: what
performance do you get on the Athlon with a pentium3-compiled GMP?

 
> I did very that the tp_compare errors are fixed. I removed the warnings
> filter in my code and the warning did occur with the old gmpy but did
> not occur with my version.

Excellent.  Sounds like an "all systems go"...!-)


Thanks,

Alex



More information about the Python-list mailing list