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
Hi, I have used glommio for a while and I tried this api ExecutorProxy::.yield_task_queue_now, but it does not seem to work as expected.
Natually, when I see the name of this function, I think it yields the current TaskQueue and this queue will not be executed anymore in the current iteration of scheduler. (Specifically, an iteration of the loop in LocalExecutor::runhttps://github.com/DataDog/glommio/blob/master/glommio/src/executor/mod.rs#L1494). The scheduler is supposed to run other coroutine and poll IO, etc. However, when I actually used this function, I find my coroutine just keep running and running. Neither other task queues nor IO polling get any chance to run. I think this is a little bit wierd, since the function is called "yield_task_queue".
Hi, I have used glommio for a while and I tried this api
ExecutorProxy::.yield_task_queue_now
, but it does not seem to work as expected.Natually, when I see the name of this function, I think it yields the current TaskQueue and this queue will not be executed anymore in the current iteration of scheduler. (Specifically, an iteration of the loop in
LocalExecutor::run
https://github.com/DataDog/glommio/blob/master/glommio/src/executor/mod.rs#L1494). The scheduler is supposed to run other coroutine and poll IO, etc. However, when I actually used this function, I find my coroutine just keep running and running. Neither other task queues nor IO polling get any chance to run. I think this is a little bit wierd, since the function is called "yield_task_queue".When I dive into the source code of the schedular, I find that in this function (https://github.com/DataDog/glommio/blob/master/glommio/src/executor/mod.rs#L1369), as long as there is runnable task in the current task queue, the queue will be repushed, regard less of whether it is yielded already. So I propose to take the yieldness into the consideration of
need_repush
(https://github.com/DataDog/glommio/blob/master/glommio/src/executor/mod.rs#L1423).The text was updated successfully, but these errors were encountered: