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

make Miri's scheduler proper round-robin #2197

Merged
merged 2 commits into from
Jun 5, 2022
Merged

Conversation

RalfJung
Copy link
Member

@RalfJung RalfJung commented Jun 5, 2022

When thread N blocks or yields, we activate thread N+1 next, rather than always activating thread 0. This should guarantee that as long as all threads regularly yield, each thread eventually takes a step again.

Fixes the "multiple loops that yield playing ping-pong" part of #1388.
@cbeuw I hope this doesn't screw up the scheduler-dependent tests you are adding in your PR.

@RalfJung
Copy link
Member Author

RalfJung commented Jun 5, 2022

@bors r+

@bors
Copy link
Collaborator

bors commented Jun 5, 2022

📌 Commit 34b359b has been approved by RalfJung

@bors
Copy link
Collaborator

bors commented Jun 5, 2022

⌛ Testing commit 34b359b with merge 2eae474...

@bors
Copy link
Collaborator

bors commented Jun 5, 2022

☀️ Test successful - checks-actions
Approved by: RalfJung
Pushing 2eae474 to master...

@bors bors merged commit 2eae474 into rust-lang:master Jun 5, 2022
@RalfJung RalfJung deleted the round-robin branch June 6, 2022 15:00
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 this pull request may close these issues.

2 participants