Skip to content

#️⃣ A collection of hash functions

License

Notifications You must be signed in to change notification settings

mulle-c/mulle-data

Repository files navigation

mulle-data

#️⃣ A collection of hash functions

  • bit avalance for integers and pointers
  • FNV1A for hashing strings for hashtables
  • farmhash for (large) data

It contains the convenient struct mulle_data to keep bytes and length together and to pass it around.

And it contains struct mulle_range, which represents ranges of data with a location (offset) and a length.

Release Version Release Notes
Mulle kybernetiK tag Build Status Coverage RELEASENOTES

API

Documentation Description
mulle-data struct mulle_data holds a pointer to a block of memory (void *bytes) and its length in bytes (size_t length).
mulle-fnv1a FNV-1a is a fast, non-cryptographic hash that provides good distribution and low collisions for strings
mulle-hash MurmurHash3 and FarmHash for fast, efficient, and high-quality hashes of arbitraty data
mulle-prime Prime number support for hashtables
mulle-range struct mulle_range defines a range with a location and length

You are here

Overview

Add

This project is a component of the mulle-core library. As such you usually will not add or install it individually, unless you specifically do not want to link against mulle-core.

Add as an individual component

Use mulle-sde to add mulle-data to your project:

mulle-sde add github:mulle-c/mulle-data

To only add the sources of mulle-data with dependency sources use clib:

clib install --out src/mulle-c mulle-c/mulle-data

Add -isystem src/mulle-c to your CFLAGS and compile all the sources that were downloaded with your project.

Install

Install with mulle-sde

Use mulle-sde to build and install mulle-data and all dependencies:

mulle-sde install --prefix /usr/local \
   https://github.com/mulle-c/mulle-data/archive/latest.tar.gz

Manual Installation

Install the requirements:

Requirements Description
mulle-c11 🔀 Cross-platform C compiler glue (and some cpp conveniences)

Download the latest tar or zip archive and unpack it.

Install mulle-data into /usr/local with cmake:

cmake -B build \
      -DCMAKE_INSTALL_PREFIX=/usr/local \
      -DCMAKE_PREFIX_PATH=/usr/local \
      -DCMAKE_BUILD_TYPE=Release &&
cmake --build build --config Release &&
cmake --install build --config Release

Author

Nat! for Mulle kybernetiK