[Python-Dev] C Decimal - is there any interest?

Facundo Batista facundobatista at gmail.com
Tue Oct 16 23:12:49 CEST 2007


2007/10/15, Mateusz Rukowicz <mateusz.rukowicz at vp.pl>:

>     I've been working on C decimal project during gSoC 2006. After year
> of idling (I had extremely busy first year on University, but well, most
> of us are extremely busy) I decided, that I will handle further

Welcome back, :)


> merging C Decimal with main tree are much lower than year ago, so I
> would like to know if there is still interest in C version of Decimal.
> If so - should I write PEP, or just code and 'we'll see later'?

First of all you need to address some issues raised by some people
here after you finished your work last year. I remember of Raymond
Hattinger, but maybe there were others.

After that, you should update the C version to comply the spec in its
last version.

Now that we have more prefixes in Py3k (0b110101, for example), we can
push to have something like 0d1.34. Or even that 1.34 is decimal by
default, and have a 0f1.34 if you want binary floating point. Or that
that behaviour is selectable system wide somehow. What people do you
think is the future here?


> I've made a little benchmark - given loan amount, assets and months that
> it's meant to be payed off, find minimal monthly loan cost (It's just

I will prepare, just for decimal.py, a benchmark that is a mix of all
operations and use (a mix of common operations like add, not so used
ones like log10, context switching, exceptions raised, etc).  You can
use this if you want, to measure also the difference in speed from Py
to C. Note, however, that you need to update it first for the last
spec.

Regards,

-- 
.    Facundo

Blog: http://www.taniquetil.com.ar/plog/
PyAr: http://www.python.org/ar/


More information about the Python-Dev mailing list