{"id":17965164,"url":"https://github.com/tokenrove/fixie-trie","last_synced_at":"2025-10-19T23:54:40.685Z","repository":{"id":147613118,"uuid":"92168035","full_name":"tokenrove/fixie-trie","owner":"tokenrove","description":"Compact tries for fixed-width keys","archived":false,"fork":false,"pushed_at":"2018-06-04T12:22:35.000Z","size":59,"stargazers_count":25,"open_issues_count":2,"forks_count":3,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-03-19T09:40:49.035Z","etag":null,"topics":["data-structure","rust","rust-library","trie"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tokenrove.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-05-23T12:02:53.000Z","updated_at":"2024-11-28T16:33:21.000Z","dependencies_parsed_at":"2023-08-16T09:03:04.124Z","dependency_job_id":null,"html_url":"https://github.com/tokenrove/fixie-trie","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tokenrove%2Ffixie-trie","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tokenrove%2Ffixie-trie/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tokenrove%2Ffixie-trie/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tokenrove%2Ffixie-trie/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tokenrove","download_url":"https://codeload.github.com/tokenrove/fixie-trie/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245413704,"owners_count":20611353,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["data-structure","rust","rust-library","trie"],"created_at":"2024-10-29T12:10:21.626Z","updated_at":"2025-10-19T23:54:35.649Z","avatar_url":"https://github.com/tokenrove.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n\u003e By their very nature, maps were always works in progress, and Gentle\n\u003e – his resolve strengthened by thinking of them that way – decided\n\u003e after many months of delay to turn his hand to making one.\n\n  — Imajica\n\nAn implementation of \"fixie tries\", inspired by Tony Finch's\n[qp-tries] but for fixed-length keys, storing the key implicitly in\nthe trie where possible.  Even though qp-tries were the inspiration,\nthe approach is actually closer to [array mapped tries] (AMT/HAMT).\n\nYou can (and should) run the benchmarks with `benchmark.sh`.  This\nshould tell you at least a little about how fixie tries fare, both in\nspeed and memory consumption, on your system, at least for the cases\nof random insertions of certain sizes.\n\nThere are countless trie variants, so although I'm giving this one a\nnew name, it probably already exists in some form.\n\nThis is x86_64-specific, because we stuff the branch bitmap in the\nupper 16 bits of a pointer; pointers on this platform are actually\n48-bit, so no harm done, but this doesn't necessarily hold on other\nplatforms.  And there wouldn't be enough room for the bitmap if\npointers were 32-bit.\n\n(The mask for pointers is `0x0000_ffff_ffff_fffe`.)\n\nPart of my interest in doing this was to see if it was possible to\nwrite this kind of stuff in Rust, and it seems to be possible and\nmostly pleasant.\n\nThis implementation is mostly an experiment; in particular, the\ncurrent approach is unfriendly to the allocator, making a lot of tiny\nallocations.  Slab allocation or similar would probably make sense.\n\nIt might be nice to do something like direct pointing from [poptries]\non top, where the first _n_ bits are covered by a 2ⁿ array of tries.\n\nI discuss this structure in more detail in [an article on my blog].\n\n[qp-tries]: http://dotat.at/prog/qp/\n[poptries]: http://conferences.sigcomm.org/sigcomm/2015/pdf/papers/p57.pdf\n[array mapped tries]: https://idea.popcount.org/2012-07-25-introduction-to-hamt/\n[an article on my blog]: https://www.cipht.net/2017/10/29/fixie-tries.html\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftokenrove%2Ffixie-trie","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftokenrove%2Ffixie-trie","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftokenrove%2Ffixie-trie/lists"}