develooper Front page | perl.perl5.porters | Postings from February 2003

Re: New SV Flag

Thread Previous | Thread Next
From:
Arthur Bergman
Date:
February 11, 2003 11:07
Subject:
Re: New SV Flag
Message ID:
D283758A-3DF3-11D7-A2D3-003065D64CBE@contiller.se

On tisdag, feb 11, 2003, at 20:00 Europe/Stockholm, Dave Mitchell wrote:

>
> On Tue, Feb 11, 2003 at 09:07:42AM +0100, Arthur Bergman wrote:
>> On måndag, feb 10, 2003, at 21:38 Europe/Stockholm, Nicholas Clark
>> wrote:
>>> Why do you want to do this? I presume it relates to ithreads. Is the
>>> idea to
>>> make scalars used in the optree common to all threads, so that they
>>> don't
>>> need copying on ithread creation?
>>>
>>
>> Yes, they only get created and destroyed when opcodes get created and
>> destroyed, and that is protected by a mutex.
>
> Surely, if the scalars which are attached to ops are shared across
> ithreads, then all sorts of nasty things can go wrong, eg two threads
> trying to increment the refcnt or modify a flag at the same time ????
>
> Dave.
>
>

Depends on what, but for example the SVIV stored in method_named is not 
at risk for that.

Arthur


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