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

Specialize TakeWhileInclusive::fold #851

Merged

Conversation

Philippe-Cholet
Copy link
Member

Related to #755

cargo bench --bench specializations "take_while_inclusive/fold"

take_while_inclusive/fold   [556.44 ns 559.37 ns 562.70 ns]
                            [536.51 ns 538.17 ns 539.76 ns]
                            [-6.2459% -4.9270% -3.8918%]

It's not much of a win but try_fold does not show real performance wins on slices and we benchmark on slices. It would perform better on other kind of iterators.

@Philippe-Cholet Philippe-Cholet added this to the next milestone Jan 14, 2024
@phimuemue phimuemue added this pull request to the merge queue Jan 14, 2024
Merged via the queue into rust-itertools:master with commit f60fe7e Jan 14, 2024
9 checks passed
@Philippe-Cholet Philippe-Cholet deleted the fold-take-while-inclusive branch January 14, 2024 19:42
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.

None yet

2 participants