Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. C/C++
  3. KOMIHASH

KOMIHASH

MITC++

A very fast, high-quality 64-bit non-cryptographic hash function for hash tables, maps, and checksums, with discrete-incremental and streamed hashing capabilities.

GitHubGitHub
283 stars16 forks0 contributors

What is KOMIHASH?

KOMIHASH is a very fast, high-quality 64-bit non-cryptographic hash function designed for hash tables, hash maps, bloom filters, and data checksums. It solves the need for a reliable, portable hash function with excellent performance on both small strings and large data blocks, offering discrete-incremental and streamed hashing capabilities.

Target Audience

Developers and engineers building high-performance data structures like hash tables and bloom filters, or those needing fast checksums for files and large datasets in C/C++ environments.

Value Proposition

Developers choose KOMIHASH for its exceptional speed (up to 27 GB/s), header-only portability, and robust quality—passing all SMHasher tests—while providing flexible hashing modes like discrete-incremental and streamed hashing that many alternatives lack.

Overview

Very fast, high-quality hash function, discrete-incremental and streamed hashing-capable (non-cryptographic, header-only C/C++) 27GB/s + PRNG

Use Cases

Best For

  • Implementing high-performance hash tables or hash maps in C/C++
  • Building bloom filters with fast hashing needs
  • Generating checksums for large files or data streams
  • Hashing small strings with minimal overhead in latency-sensitive applications
  • Creating custom data structures requiring incremental hashing of structured records
  • Needing a portable, non-cryptographic hash function for cross-platform projects

Not Ideal For

  • Cryptographic applications requiring security against collision attacks
  • Projects deployed on 32-bit architectures where hash performance is critical
  • Systems using big-endian byte order that cannot tolerate a 20% performance drop in bulk hashing

Pros & Cons

Pros

Exceptional Performance

Achieves up to 27 GB/s bulk hashing and ~8 cycles/hash for small strings, often outperforming competitors like wyhash and XXH3 in benchmarks, as detailed in the extensive comparison tables.

Portable and Header-Only

Written in ISO C99 with zero allocations, it's compatible across C/C++ compilers and platforms including x86, ARM, Windows, Linux, and macOS, making integration straightforward.

Flexible Hashing Modes

Supports discrete-incremental hashing for sequential data like database records and streamed hashing for continuous data streams, enabling intermediate hash retrieval without buffering.

Proven Quality

Passes all SMHasher and SMHasher3 tests with collision statistics meeting expectations, ensuring reliability for hash tables, maps, and bloom filters.

Cons

Non-Cryptographic Security

Admits it's not cryptographically secure; requires a secret seed in open systems to prevent hash flooding attacks, adding complexity for secure use cases.

Poor 32-bit Performance

Explicitly states performance on 32-bit systems is 'quite low,' making it suboptimal for embedded or legacy environments where speed matters.

Big-Endian Overhead

Bulk hashing on big-endian systems may be 20% slower due to byte-swapping, unless disabled with a compile-time define, which can impact cross-platform performance consistency.

Frequently Asked Questions

Quick Stats

Stars283
Forks16
Contributors0
Open Issues0
Last commit7 days ago
CreatedSince 2021

Tags

#c-library#c-plus-plus-library#hash-tables#hash#hash-table#hashing#non-cryptographic-hash#prng#bloom-filter#checksum#hashing-algorithm#header-only#hash-function#performance

Built With

C
C++

Included in

C/C++70.6k
Auto-fetched 17 hours ago

Related Projects

stbstb

stb single-file public domain libraries for C/C++

Stars34,264
Forks8,066
Last commit3 months ago
{fmt}{fmt}

A modern formatting library

Stars23,683
Forks2,926
Last commit1 day ago
xxHashxxHash

Extremely fast non-cryptographic hash algorithm

Stars11,161
Forks907
Last commit4 days ago
single_file_libssingle_file_libs

List of single-file C/C++ libraries, with emphasis on clause-less licenses.

Stars9,962
Forks650
Last commit1 month ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub