You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by JD Brennan <Br...@opsware.com> on 2005/11/19 02:12:10 UTC

perl_alloc or perl_clone in multi-threaded app?

If this is too far off topic, can you suggest
where the experts on perl_alloc() and threads
hang out?

I'm trying to use Perl 5.8.7 (ActiveState) in
a multi-threaded Java app on Solaris 5.9 (dual-proc).

I have a test cases that crashes about 1% of the time:

Unexpected Signal : 11 occurred at PC=3D0xE6BBDF60
Function=3D[Unknown. Nearest: Perl_savesvpv+0x70]
Library=3D/home/brennan/dev/mainline/lib/JPerl/solaris/libjperl.so

I'm wondering if switching to perl_clone() instead
of perl_alloc() would help.  I haven't totally narrowed
it down yet, but it's crashing in one of these 3 routines:

perl_alloc()
perl_construct()
perl_parse()

mod_perl2 uses perlembed in a multi-threaded
environment.  And from looking at the code it uses
perl_clone().  Seems like perl_clone() would be 
useful if I had a large parse tree to share between 
threads (but I don't).  But maybe perl_clone() would 
work better in a multi-threaded app.

Thanks for any suggestions or pointers!

JD

Re: perl_alloc or perl_clone in multi-threaded app?

Posted by Tom Schindl <to...@gmx.at>.
JD Brennan wrote:
> If this is too far off topic, can you suggest
> where the experts on perl_alloc() and threads
> hang out?
> 
p5p = perl5porters Maillinglist is much more appropriate for such perl
internals perl5-porters@perl.org.

tom