RFR 8232733: Remove need to grab Threads_lock while processing handshakes

Patricio Chilano patricio.chilano.mateo at oracle.com
Tue Dec 10 14:02:00 UTC 2019


Hi Robbin,

On 12/10/19 2:40 AM, Robbin Ehn wrote:
> Hi Patricio,
>
>> One reason was so that the JavaThread would not be freed while 
>> reading it (although looking at that first commit it seems that 
>> between releasing the Threads_lock after setting the handshake and 
>> acquiring it again before processing it, the JavaThread could have 
>> already processed the handshake and exited). 
>
> My memory say this would have been okay, that thread would not been 
> seen any more on threads-linked-list.
> Thus next iteration VM thread wouldn't see it, but still wait for done 
> semaphore.
>
> Anyhow, I think this is great removing Threads_locks.
>
> Looks good, thanks, Robbin.
Thanks for reviewing this!

Patricio
>>
>> Thanks,
>>
>> Patricio
>>> Thanks,
>>> David
>>>
>>>
>>>> Thanks,
>>>>
>>>> Patricio
>>



More information about the hotspot-runtime-dev mailing list