[prev in list] [next in list] [prev in thread] [next in thread] 

List:       lua-l
Subject:    Re: Re: Re: Problem with concurrency, threads, Lua states and maybe
From:       "Matt 'Matic' Page (Lua)" <lua () photon ! me ! uk>
Date:       2010-06-23 14:15:49
Message-ID: 4C221715.3010607 () photon ! me ! uk
[Download RAW message or body]


>>> (This makes tight loops that do not create
>>> objects "atomic", however.)
>>>        
>> Can you elaborate? Could these changes affect the way my Lua&  OS
>> threads work together? (i.e. is there anything I need to be aware
>> of, or change, when migrating up to 5.2)
>>      
> The implementation now only may switch threads when creating objects
> (or calling functions). So, in a loop like
>
>    for i=1,1000000000 do
>      <some-complex-numerical-computation-without-calling-functions>
>    end
>
> the running thread will block access to this Lua state until the loop ends.
>
> -- Roberto
>
>    
Ouch!! I'm pretty sure this will affect our implementation... thanks for 
the info Roberto! I'll certainly have to weigh this issue before 
considering updating to 5.2 ;-)
Matt
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic