RE: Creating an XSUB on the fly

[email protected] (David Mertens)
Newsgroups perl.xs
Message-ID <CA+4ieYU5tri1ov+2yaLkrgrHyVWj5_SSzzjkgtvw2dveHgKhSA@mail.gmail.com>
In this case, Perl stack args. The easy solution would be to include
EXTERN.h, perl.h, etc (as with a normal XS file), but that leads to a lot
of work for the preprocessor. This work targets true jit compiling, so the
less work I throw at the preprocessor, the better. My plan here is to comb
over those header files and pull out the most useful bits into fine-grained
pieces so function writers only pull in what they need. One of those pieces
would be Perl stack manipulation.

An alternative would be to simply return a function pointer that function
writers could wrap with a Foreign Function Interface caller. A few months
ago I was pushing Reini and others on their Ctypes work, and Joel Berger on
Alien::Base so I could distribute libffi as a Ctypes dependency. Actually,
I think this would be a simpler solution to the problem rather than digging
around the Perl XS headers. For me, work on both fronts has stopped as my
attention has shifted to other projects.

David
On Jul 21, 2012 2:01 PM, "bulk 88" <[email protected]> wrote:

>
>
> > Date: Sat, 21 Jul 2012 06:28:17 -0500
> > Subject: Re: Creating an XSUB on the fly
> > From: [email protected]
> > To: [email protected]
> > CC: [email protected]
> >
> > bulk88 -
> >
> > That's exactly what I needed! Thank you! Now I have to figure out how
> > to add args processing to this jit-compiled C function, but that's a
> > different problem. :-)
> >
> > David
>
> C stack args or Perl stack args?
>
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.