[Cython] better handling of numeric types
Robert Bradshaw
robertwb at math.washington.edu
Fri Feb 27 20:42:19 CET 2009
On Feb 27, 2009, at 5:13 AM, Lisandro Dalcin wrote:
> On Fri, Feb 27, 2009 at 10:15 AM, Robert Bradshaw
> <robertwb at math.washington.edu> wrote:
>>
>> On Feb 27, 2009, at 3:59 AM, Lisandro Dalcin wrote:
>>
>>> Next we can discuss how to optimize this....
>>
>> As long as we don't slow down the (very common) Python int -> int/
>> long code, I'm OK with deferring optimization.
>>
>
> However, do you realize that for Py3 these optimizations are a bit
> pointless?
I'm still not sure where I stand on the union of the long and int
types--certainly it makes some things easier, but it also seems to
slow other things down. In any case, I foresee Cython being used with
Python 2.x for quite some time into the future.
> Moreover, if you look at core CPython 2.X sources, you will
> find many places were were optimizations could be made, but they are
> not there...
True, but who says we can't do better :).
> Anyway, I'll try to do my best...
Don't worry, I have high confidence in you.
- Robert
More information about the Cython-dev
mailing list