-
Notifications
You must be signed in to change notification settings - Fork 398
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
Question about io_uring_for_each_cqe #867
Comments
Reloading it should not be necessary. |
But behavior with single load and load on every iteration could be different? Because kernel can produce new cqe while it is iterating. |
That is obviously true, but I would suspect most loops to process CQEs are pretty light (and hence fast) and therefore the likelihood of getting a new entry while looping is pretty small. So while it doesn't hurt to reload the cq tail on every loop, it'd probably be better to avoid it. |
Thanks. |
Could you explain why do you do load on every iteration?
https://github.com/axboe/liburing/blob/master/src/include/liburing.h#L295
The text was updated successfully, but these errors were encountered: