static_maps: consteval std::map and std::unordered_map Implementations in C++23

Read full text
Authors: Isaac Myhal, Oliver Serang
Cited by: 0

Abstract

Using consteval from C++23, we implement efficient, new versions of std::map and std::unordered_map for use when the keys are known at compile time. We demonstrate superior performance of our unordered_map on three demonstration use-cases: Lookup of elemental mass from atomic symbol, lookup of amino acid from codon, and modification of stock prices from S&P 500 ticker symbols all produced runtimes

Fields of Study & Subjects

Algorithms and Data Compression Logic programming and type systems Parallel Computing and Optimization Techniques

Publication details

Journal / source
arXiv (Cornell University)
Publication date
26 February 2026
Language
EN
Document type
Preprint