develooper Front page | perl.perl5.porters | Postings from July 2001

Re: Asynchronous callbacks from C

Thread Previous | Thread Next
From:
Nick Ing-Simmons
Date:
July 6, 2001 05:58
Subject:
Re: Asynchronous callbacks from C
Message ID:
20010706134546.1279.8@bactrian.ni-s.u-net.com
Benjamin Stuhl <tiriath@yahoo.com> writes:
>--- "David M. Lloyd" <dmlloyd@tds.net> wrote:
>> I have written an XS interface into a library that
>> performs I/O and then
>> can asynchronously call a C function upon completion.  Is
>> there a SAFE way
>> I can reflect an asynchronous callback into Perl?
>
>AFAIK, only if the perl is built to expect such. In
>5.8.0-to-be there is the PERL_ASYNC_CHECK which is used for
>safe signals. You would have to hack around a bit in the
>core to interface that to your XS, and even then it would
>only work with a perl built for it.
>
>Maybe 5.8.0 should make PL_signal_pending or whatever it's
>called public and provide a way for modules to register a
>event-checking callback?

A very good idea. But I don't know when _I_ will have a chance to look 
at it. (Starting a new job, buying house near there, selling old house
3 hours drive away...)

>
>-- BKS
>
>__________________________________________________
>Do You Yahoo!?
>Get personalized email addresses from Yahoo! Mail
>http://personal.mail.yahoo.com/
-- 
Nick Ing-Simmons
http://www.ni-s.u-net.com/


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About