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

Add benchmarks using triomphe::Arc #85

Closed
wants to merge 2 commits into from

Conversation

michaelsproul
Copy link
Contributor

This is a companion PR to orium/archery#27.

Using triomphe::Arc in rpds seems to result in some substantial speedups, with no slowdowns compared to std::sync::Arc. The data structures that benefit most (~10-40%) seem to be List, Queue, Vector, and RedBlackTreeMap, with less substantial (2-10%) speed-ups for HashTrieMap. The persistent (non-mut) variants of operations also tend to be more greatly affected.

Full data here:

https://gist.github.com/michaelsproul/00a7a41e2f4c1134ae1f95951c86e617

The benchmarking process is:

cargo bench -- sync # establish a baseline
cargo bench --features triomphe-bench -- sync # rerun with triomphe and compare to baseline

Benchmarks were run on an 8-core M1 Pro CPU.

@orium
Copy link
Owner

orium commented Oct 30, 2023

@michaelsproul Sorry, I just renamed the master branch to main. Can you open the PR again after rebasing on main please?

@michaelsproul
Copy link
Contributor Author

I'll leave this closed as the benchmark functionality is also achieved by #88

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