Skip to content

Special Ordered Dict that automtically swaps from LittleDict to another type when too full #57

Open
@oxinabox

Description

@oxinabox

Originally posted by @PallHaraldsson in #54 (comment)

Since LittleDict is faster, is it a reasonable default?

"It is reasonable to expect it to outperform an OrderedDict,
with up to around 30 elements in general;
or with up to around 50 elements if using a LittleDict backed by Tuples"

[I proposed OrderedDict as replacement for Dict at julialang.] I mean LittleDict is maybe not a good default as you can have more elements (how likely for Julia itself?). For a lot of code you will not have more, while the possibility should give you pause. Does it make sense to build a new Dict on this one for the first 30-50 elements, and have a fallback to another, OrderedDict (or some newer Swiss or OrderedRobinDict?).

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions