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 {array,vec}::race fair #71

Merged
merged 2 commits into from
Nov 16, 2022
Merged

make {array,vec}::race fair #71

merged 2 commits into from
Nov 16, 2022

Conversation

yoshuawuyts
Copy link
Owner

Ref #22

Makes {array,vec}::race fair. Apparently we did not yet implement fair scheduling for the race combinators; this fixes it.

Additionally it seems we don't have a need for PollState in these structs because on the first "success" poll we immediately terminate. So we don't need to track state over time.

There is some perf regression, but that's expected because we do more work. But also: I'm not sure how good our race benches actually are since they don't actually measure repeated polling - they will always return on the first call to poll. For it to really show we'd have to author benches which return on the nth poll - but that's significantly harder and probably not worth it.

@yoshuawuyts yoshuawuyts changed the title make {array,vec}::race fair make {array,vec}::race fair Nov 14, 2022
@yoshuawuyts
Copy link
Owner Author

This should be pretty straightforward; going to be merging a few of these.

@yoshuawuyts yoshuawuyts merged commit c13f81e into main Nov 16, 2022
@delete-merged-branch delete-merged-branch bot deleted the race-use-pollstate branch November 16, 2022 12:48
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.

1 participant