Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TC_CoroutineScheduler::put 线程安全问题 #287

Open
ztq2009 opened this issue Aug 23, 2023 · 1 comment
Open

TC_CoroutineScheduler::put 线程安全问题 #287

ztq2009 opened this issue Aug 23, 2023 · 1 comment

Comments

@ztq2009
Copy link

ztq2009 commented Aug 23, 2023

image /* * 需要激活的协程队列,其他线程使用,用来激活等待结果的协程 */ deque _activeCoroQueue;

请教下,这里其他线程调用put, 并发场景会否有问题;deque理解并不是线程安全的

@ruanshudong
Copy link
Contributor

框架里面目前是没有跨线程调用的, 如果自己用, 确实可能会有问题, 这个问题我有时间完善一下, 估计还是得加把锁

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants