You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description
Thanks shiyue.xw for his initial work.
Wisp2 use N:M scheduler to prevent starving and unbalanced task queues, but the underlying VM representation of a coroutine is still bound to a carrier thread, which leads to unnecessary lock contention and heavier coroutine stealing.
So we introduce a global coroutine list like threads_list for all java threads, hereby removed the stealing lock (intended to prevent the coroutine list on carrier thread).
The global list contended when multiple carrier threads are inserting new coroutines the same time, coroutine list cleaning up is done during safepoint time.
The text was updated successfully, but these errors were encountered:
Summary:
Since there is no need to move the coroutine in coroutine list,
the lock is useless. So remove it.
Test Plan: all wisp cases
Reviewed-by: lei.yul, zhengxiaolinX
Issue: dragonwell-project/dragonwell8#227
…h thread
Summary:
Currently, we need to add a lock when we steal a coroutine.
If the lock can't be got, the stealing failed.
Use global coroutine list to avoid the moving in coroutine list.
When we steal the coroutine, we only set the thread in the coroutine.
With the change, the success rate has been greatly increased.
Test Plan: all wisp cases
Reviewed-by: lei.yul, zhengxiaolinX
Issue: dragonwell-project/dragonwell8#227
…h thread
Summary:
Currently, we need to add a lock when we steal a coroutine.
If the lock can't be got, the stealing failed.
Use global coroutine list to avoid the moving in coroutine list.
When we steal the coroutine, we only set the thread in the coroutine.
With the change, the success rate has been greatly increased.
Test Plan: all wisp cases
Reviewed-by: lei.yul, zhengxiaolinX
Issue: dragonwell-project/dragonwell8#227
Description
Thanks shiyue.xw for his initial work.
Wisp2 use N:M scheduler to prevent starving and unbalanced task queues, but the underlying VM representation of a coroutine is still bound to a carrier thread, which leads to unnecessary lock contention and heavier coroutine stealing.
So we introduce a global coroutine list like threads_list for all java threads, hereby removed the stealing lock (intended to prevent the coroutine list on carrier thread).
The global list contended when multiple carrier threads are inserting new coroutines the same time, coroutine list cleaning up is done during safepoint time.
The text was updated successfully, but these errors were encountered: