EnergySystemsModellingLab / EnergySystemsModellingLab/MUSE2

Use different hasher for collections

Open
#1,288 0 comments 0 reactions 0 assignees View on GitHub
enhancement performance
Dominant language
Rust
Stars
8
Forks
5
Avg merge
1d 2m
Merged PRs (30d)
37

Description

There are a few collection types that we use heavily which involve hashing: `HashMap`, `HashSet`, `IndexMap` and `IndexSet`. By default, they use a strong hashing algorithm which is slow but provides stronger security guarantees. You can, however, use different hashing algorithms if you want, so we could use a faster one. We don't need to worry about security in this context, so we also don't need to pay the performance penalty of a slower hasher.

More information here: https://nnethercote.github.io/perf-book/hashing.html#alternative-hashers

As always, we should benchmark carefully on a realistic workload.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.