{"id":17702642,"url":"https://github.com/friendlymatthew/eytzinger","last_synced_at":"2025-03-31T03:24:17.381Z","repository":{"id":248168678,"uuid":"827936299","full_name":"friendlymatthew/eytzinger","owner":"friendlymatthew","description":null,"archived":false,"fork":false,"pushed_at":"2024-07-12T18:54:32.000Z","size":3,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-06T08:12:31.915Z","etag":null,"topics":["cache-locality","eytzinger-binary-search"],"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/friendlymatthew.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":"2024-07-12T17:50:32.000Z","updated_at":"2024-07-12T20:36:26.000Z","dependencies_parsed_at":"2024-07-12T21:10:57.027Z","dependency_job_id":null,"html_url":"https://github.com/friendlymatthew/eytzinger","commit_stats":null,"previous_names":["friendlymatthew/eytzinger"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/friendlymatthew%2Feytzinger","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/friendlymatthew%2Feytzinger/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/friendlymatthew%2Feytzinger/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/friendlymatthew%2Feytzinger/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/friendlymatthew","download_url":"https://codeload.github.com/friendlymatthew/eytzinger/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246409361,"owners_count":20772485,"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":["cache-locality","eytzinger-binary-search"],"created_at":"2024-10-24T19:08:34.211Z","updated_at":"2025-03-31T03:24:17.363Z","avatar_url":"https://github.com/friendlymatthew.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# eytzinger search\n\nA cache-friendly binary search implementation using the Eytzinger layout.\n\n```rust\nfn main() {\n    let data = vec![1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15];\n    let eyt = EytzingerVec::from_slice(\u0026data);\n\n    let res = eyt.search(8);\n    assert_eq!(res, 1); // returns the index of element\n\n    let res = eyt.search(69);\n    assert_eq!(res, 0); // returns 0 if not found\n}\n```\n\n## Prefetching\n\nThis implementation makes use of `core_intrinsics::prefetch_read_data` to work across different targets. Temporal\nlocality is set to `3`, indicating maximum temporal locality.\n\n## Memory Alignment\n\n`AlignedVec` holds the `#[repr(align(64))]` attribute. This ensures the vector is aligned to 64-byte cache lines,\noptimizing memory access patterns.\n\n## Literature\n\n* **https://algorithmica.org/en/eytzinger**\n* https://arxiv.org/pdf/1509.05053\n\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffriendlymatthew%2Feytzinger","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffriendlymatthew%2Feytzinger","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffriendlymatthew%2Feytzinger/lists"}