Skip to content
This repository was archived by the owner on Aug 2, 2023. It is now read-only.
This repository was archived by the owner on Aug 2, 2023. It is now read-only.

Faster dictionary for k-Nucleotide #2428

@danmoseley

Description

@danmoseley

Goal is to include in the proposed corefxlab collection package a dictionary that

  1. Outperforms the regular Dictionary<K,V> in k-Nucleotide and the existing top C# submission (that uses reflection tricks)
  2. Is sufficiently general purpose that it fits the letter and spirit of the CLBG rules, and is useful beyond the benchmark. For example, it's a dictionary better than Dictionary<K,V> if your keys are ulong. It would be nice if it was not quite that specific (for example, possibly it is better if your keys' hashcode is cheap to calculate, so it need not be stored). Java's submission uses a dictionary that is specialized specifically <long, int> but it is part of a package that also has dictionaries specialized for every other kind of combination also.

@mikedn has a version that he found to be 40% faster than the current submission, we may want to explore taking that and making this slightly less specialized.

@Zhentar noted in another issue that K-Nuc benefits tremendously from coalesced chaining preserving insertion order locality ie., it's probably best to stick with chaining rather than open addressing.

@safern @AnthonyLloyd

Metadata

Metadata

Assignees

Labels

OpenBeforeArchivingThese issues were open before the repo was archived. For re-open them, file them in the new repoarea-System.Collections

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions