The answer is yes, and I have done that sometime ago with perl 5.6.1.  Take a look of 
http://www.perldoc.com/perl5.8.0/pod/perlembed.html#Maintaining-multiple-interpreter-instances.

The key is to invoke the PERL_SET_CONTEXT macro in front of any perl API.

Good luck.

Kong

> Hi,
> 
> I am writing an application that uses perl embedded in a C++ program.
> The perl man pages/faq makes it very clear on how to create and maintain
> multiple perl interpreter instances.  It does not mention whether these
> instances can be used in different threads.
> 
> The latest version of the application I am writing uses a thread 
> pool for its processing, and it would be nice to be able to a separate
> perl interpreter in each of these threads.
> 
> So my question is, does the ithread implementation allow multiple
> instances
> of the perl interpreter to be run in separate application threads?  Does
> anyone know of any examples that do this, or perhaps a better way of 
> doing achieving the same goal.

-- 
_______________________________________________
Sign-up for your own FREE Personalized E-mail at Mail.com
http://www.mail.com/?sr=signup

One click access to the Top Search Engines
http://www.exactsearchbar.com/mailcom

Reply via email to