Re: [pypy-dev] [pypy-svn] r77083 - pypy/branch/jitffi

2010-09-15 Thread Antonio Cuni
Hi,

On 15/09/10 18:18, Maciej Fijalkowski wrote:
> Hey anto.
>
> There was a SoC about that, I guess it would be good to chat about it
> at least (personally I think jitting rlib/libffi is exactly bad layer
> to be jitted and some experiments were done).

yes, I read the code in the fast-ctypes branch but I wanted to take another 
(simpler) approach.  Note that my goal is not only to speed up ctypes, but 
also to provide a useful building block for cppyy (the module to call c++ 
functions that we started at the cern sprint).

My basic idea was to mark libffi.FuncPtr.{push_arg,call} in a special way, so 
that the backend can recognize the pattern (i.e. push* + call) and emit a 
single assembler call.

I even started to write a bit of code, but then I realized that libffi.FuncPtr 
is not used at all, as _rawffi uses RawFuncPtr: the bad news is that 
RawFuncPtr uses a different interface, as it does not have push_arg but passes 
the arguments already packed in a list, so my easy solution above cannot work. 
  Note however that doing it at the level of FuncPtr might still be useful for 
cppyy.

Question: why does _rawffi use RawFuncPtr instead of FuncPtr? Would it be 
possible/easy/hard/whatever to switch to FuncPtr?

ciao,
Anto
___
pypy-dev@codespeak.net
http://codespeak.net/mailman/listinfo/pypy-dev


Re: [pypy-dev] [pypy-svn] r77083 - pypy/branch/jitffi

2010-09-15 Thread Maciej Fijalkowski
Hey anto.

There was a SoC about that, I guess it would be good to chat about it
at least (personally I think jitting rlib/libffi is exactly bad layer
to be jitted and some experiments were done).

Cheers,
fijal

On Wed, Sep 15, 2010 at 1:07 PM,   wrote:
> Author: antocuni
> Date: Wed Sep 15 13:07:20 2010
> New Revision: 77083
>
> Added:
>   pypy/branch/jitffi/   (props changed)
>      - copied from r77082, pypy/trunk/
> Log:
> a branch in which to try to jit rlib/libffi.py
>
>
> ___
> pypy-svn mailing list
> pypy-...@codespeak.net
> http://codespeak.net/mailman/listinfo/pypy-svn
>
___
pypy-dev@codespeak.net
http://codespeak.net/mailman/listinfo/pypy-dev