Re: [Cython] [Python-Dev] C-level duck typing

2012-05-17 Thread Dag Sverre Seljebotn
I don't know where to put this so I put it up top: I think this talk about implementing caching went a bit overboard myself. Here's a performance ladder for you: Alternative A) Focus on fast lookup; go from 100 ns function call to 5 ns function call Alternative B) Focus on caching a 20 ns l

Re: [Cython] [Python-Dev] C-level duck typing

2012-05-17 Thread Stefan Behnel
mark florisson, 17.05.2012 13:34: > On 17 May 2012 11:14, Stefan Behnel wrote: >> mark florisson, 17.05.2012 11:26: >>> On 17 May 2012 08:36, Stefan Behnel wrote: Dag Sverre Seljebotn, 17.05.2012 09:12: > Stefan Behnel wrote: >> mark florisson, 16.05.2012 21:49: >>> On 16 May 201

Re: [Cython] [Python-Dev] C-level duck typing

2012-05-17 Thread mark florisson
On 17 May 2012 11:14, Stefan Behnel wrote: > mark florisson, 17.05.2012 11:26: >> On 17 May 2012 08:36, Stefan Behnel wrote: >>> Dag Sverre Seljebotn, 17.05.2012 09:12: Stefan Behnel wrote: > mark florisson, 16.05.2012 21:49: >> On 16 May 2012 20:15, Stefan Behnel wrote: >>> Why

Re: [Cython] [Python-Dev] C-level duck typing

2012-05-17 Thread mark florisson
On 17 May 2012 11:03, Stefan Behnel wrote: > mark florisson, 17.05.2012 11:15: >> On 17 May 2012 07:09, Stefan Behnel wrote: >>> mark florisson, 16.05.2012 21:49: On 16 May 2012 20:15, Stefan Behnel wrote: > "Martin v. Löwis", 16.05.2012 20:33: >>> Does this use case make sense to e

Re: [Cython] [Python-Dev] C-level duck typing

2012-05-17 Thread Stefan Behnel
mark florisson, 17.05.2012 11:26: > On 17 May 2012 08:36, Stefan Behnel wrote: >> Dag Sverre Seljebotn, 17.05.2012 09:12: >>> Stefan Behnel wrote: mark florisson, 16.05.2012 21:49: > On 16 May 2012 20:15, Stefan Behnel wrote: >> Why not just use a custom attribute on callables that ho

Re: [Cython] [Python-Dev] C-level duck typing

2012-05-17 Thread Stefan Behnel
mark florisson, 17.05.2012 11:15: > On 17 May 2012 07:09, Stefan Behnel wrote: >> mark florisson, 16.05.2012 21:49: >>> On 16 May 2012 20:15, Stefan Behnel wrote: "Martin v. Löwis", 16.05.2012 20:33: >> Does this use case make sense to everyone? >> >> The reason why we are discus

Re: [Cython] [Python-Dev] C-level duck typing

2012-05-17 Thread mark florisson
On 17 May 2012 08:36, Stefan Behnel wrote: > Dag Sverre Seljebotn, 17.05.2012 09:12: >> Stefan Behnel wrote: >>> mark florisson, 16.05.2012 21:49: On 16 May 2012 20:15, Stefan Behnel wrote: > Why not just use a custom attribute on callables that hold a > PyCapsule? Whenever we see ins

Re: [Cython] [Python-Dev] C-level duck typing

2012-05-17 Thread mark florisson
On 17 May 2012 07:09, Stefan Behnel wrote: > mark florisson, 16.05.2012 21:49: >> On 16 May 2012 20:15, Stefan Behnel wrote: >>> "Martin v. Löwis", 16.05.2012 20:33: > Does this use case make sense to everyone? > > The reason why we are discussing this on python-dev is that we are loo

Re: [Cython] [Python-Dev] C-level duck typing

2012-05-17 Thread Stefan Behnel
Dag Sverre Seljebotn, 17.05.2012 09:12: > Stefan Behnel wrote: >> mark florisson, 16.05.2012 21:49: >>> On 16 May 2012 20:15, Stefan Behnel wrote: Why not just use a custom attribute on callables that hold a PyCapsule? Whenever we see inside of a Cython implemented function that an o

Re: [Cython] [Python-Dev] C-level duck typing

2012-05-17 Thread Dag Sverre Seljebotn
Stefan Behnel wrote: >mark florisson, 16.05.2012 21:49: >> On 16 May 2012 20:15, Stefan Behnel wrote: >>> "Martin v. Löwis", 16.05.2012 20:33: > Does this use case make sense to everyone? > > The reason why we are discussing this on python-dev is that we are >looking > for a ge