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

Should we use std::hint::spin_loop in cas loop #330

Closed
driftluo opened this issue Aug 18, 2021 · 1 comment · Fixed by #331
Closed

Should we use std::hint::spin_loop in cas loop #330

driftluo opened this issue Aug 18, 2021 · 1 comment · Fixed by #331

Comments

@driftluo
Copy link
Collaborator

driftluo commented Aug 18, 2021

base:tokio-rs/tokio#4037 which resolves tokio-rs/tokio#4034

code:

PopResult::Inconsistent => {
if inconsistent_spin_number == 0 {
thread::yield_now();

@doitian
Copy link
Member

doitian commented Aug 18, 2021

Do some benchmarks?

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

Successfully merging a pull request may close this issue.

2 participants