develooper Front page | perl.vmsperl | Postings from March 2006

Re: Threads and safesysfree?

Thread Previous | Thread Next
From:
Nicholas Clark
Date:
March 9, 2006 02:43
Subject:
Re: Threads and safesysfree?
Message ID:
20060309104324.GA32132@plum.flirble.org
On Thu, Mar 09, 2006 at 10:01:52AM +0000, Dave Mitchell wrote:
> On Tue, Mar 07, 2006 at 10:50:45PM -0500, John E. Malmberg wrote:
> > In util.c the routines Perl_safesysmalloc and friends are updating a 
> > linked list.
> > 
> > There does not seem to be any protection from a different thread also 
> > updating the same linked list at the same time, especially on a 
> > multi-processor system.
> 
> They are updating a per-thread linked list, so I think it's thread-safe.

Which is what I was thinking but I hadn't replied yet. The other bit I
was thinking was "unless things have got very buggy" but I'm not sure how
many defences one puts in against the sky falling.

Nicholas Clark

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