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

Benchmarks don't seem to exercise collision handling #439

Open
sjakobi opened this issue Apr 25, 2022 · 2 comments
Open

Benchmarks don't seem to exercise collision handling #439

sjakobi opened this issue Apr 25, 2022 · 2 comments

Comments

@sjakobi
Copy link
Member

sjakobi commented Apr 25, 2022

We currently have benchmarks with keys of type Int, ByteString and String. All of these use the instances provided in Hashable which I'd expect not to produce a lot of hash collisions.

For tuning the code that handles collisions, e.g. #435, it would be useful to have a key type that is more collision-prone.

@treeowl
Copy link
Collaborator

treeowl commented Apr 25, 2022

Historically, the view has been that collisions had better be rare enough not to matter much. There's plenty of O(n^2) gunk in collision buckets.

@sjakobi
Copy link
Member Author

sjakobi commented Apr 25, 2022

Yeah, this isn't a high priority task. It's mostly the result of me wanting to try the searchSwap trick in #435. Now I simply don't have any benchmarks to tell whether the new code is actually better or not. ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants