Classes | Macros | Typedefs | Enumerations | Functions
xxhash.h File Reference
#include <stddef.h>
Include dependency graph for xxhash.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  XXH32_canonical_t
 Canonical (big endian) representation of XXH32_hash_t. More...
 
struct  XXH64_canonical_t
 

Macros

#define XXH_PUBLIC_API   /* do nothing */
 
#define XXH_VERSION_MAJOR   0
 
#define XXH_VERSION_MINOR   6
 
#define XXH_VERSION_NUMBER   (XXH_VERSION_MAJOR *100*100 + XXH_VERSION_MINOR *100 + XXH_VERSION_RELEASE)
 
#define XXH_VERSION_RELEASE   5
 

Typedefs

typedef unsigned int XXH32_hash_t
 
typedef struct XXH32_state_s XXH32_state_t
 
typedef unsigned long long XXH64_hash_t
 
typedef struct XXH64_state_s XXH64_state_t
 

Enumerations

enum  XXH_errorcode { XXH_OK =0, XXH_ERROR }
 

Functions

XXH_PUBLIC_API XXH32_hash_t XXH32 (const void *input, size_t length, unsigned int seed)
 Calculates the 32-bit hash of input using xxHash32. More...
 
XXH_PUBLIC_API void XXH32_canonicalFromHash (XXH32_canonical_t *dst, XXH32_hash_t hash)
 Converts an XXH32_hash_t to a big endian XXH32_canonical_t. More...
 
XXH_PUBLIC_API void XXH32_copyState (XXH32_state_t *dst_state, const XXH32_state_t *src_state)
 Copies one XXH32_state_t to another. More...
 
XXH_PUBLIC_API XXH32_state_tXXH32_createState (void)
 
XXH_PUBLIC_API XXH32_hash_t XXH32_digest (const XXH32_state_t *statePtr)
 Returns the calculated hash value from an XXH32_state_t. More...
 
XXH_PUBLIC_API XXH_errorcode XXH32_freeState (XXH32_state_t *statePtr)
 Frees an XXH32_state_t. More...
 
XXH_PUBLIC_API XXH32_hash_t XXH32_hashFromCanonical (const XXH32_canonical_t *src)
 Converts an XXH32_canonical_t to a native XXH32_hash_t. More...
 
XXH_PUBLIC_API XXH_errorcode XXH32_reset (XXH32_state_t *statePtr, unsigned int seed)
 Resets an XXH32_state_t to begin a new hash. More...
 
XXH_PUBLIC_API XXH_errorcode XXH32_update (XXH32_state_t *statePtr, const void *input, size_t length)
 Consumes a block of input to an XXH32_state_t. More...
 
XXH_PUBLIC_API XXH64_hash_t XXH64 (const void *input, size_t length, unsigned long long seed)
 Calculates the 64-bit hash of input using xxHash64. More...
 
XXH_PUBLIC_API void XXH64_canonicalFromHash (XXH64_canonical_t *dst, XXH64_hash_t hash)
 
XXH_PUBLIC_API void XXH64_copyState (XXH64_state_t *dst_state, const XXH64_state_t *src_state)
 
XXH_PUBLIC_API XXH64_state_tXXH64_createState (void)
 
XXH_PUBLIC_API XXH64_hash_t XXH64_digest (const XXH64_state_t *statePtr)
 
XXH_PUBLIC_API XXH_errorcode XXH64_freeState (XXH64_state_t *statePtr)
 
XXH_PUBLIC_API XXH64_hash_t XXH64_hashFromCanonical (const XXH64_canonical_t *src)
 
XXH_PUBLIC_API XXH_errorcode XXH64_reset (XXH64_state_t *statePtr, unsigned long long seed)
 
XXH_PUBLIC_API XXH_errorcode XXH64_update (XXH64_state_t *statePtr, const void *input, size_t length)
 
XXH_PUBLIC_API unsigned XXH_versionNumber (void)
 

Detailed Description

xxHash prototypes and implementation

Definition in file xxhash.h.

Macro Definition Documentation

◆ XXH_PUBLIC_API

#define XXH_PUBLIC_API   /* do nothing */

XXH_INLINE_ALL (and XXH_PRIVATE_API) This is useful to include xxhash functions in static mode in order to inline them, and remove their symbol from the public list. Inlining can offer dramatic performance improvement on small keys. Methodology : #define XXH_INLINE_ALL #include "xxhash.h" xxhash.c is automatically included. It's not useful to compile and link it as a separate module.

Definition at line 110 of file xxhash.h.

◆ XXH_VERSION_MAJOR

#define XXH_VERSION_MAJOR   0

XXH_NAMESPACE, aka Namespace Emulation :

If you want to include and expose xxHash functions from within your own library, but also want to avoid symbol collisions with other libraries which may also include xxHash,

you can use XXH_NAMESPACE, to automatically prefix any public symbol from xxhash library with the value of XXH_NAMESPACE (therefore, avoid NULL and numeric values).

Note that no change is required within the calling program as long as it includes xxhash.h : regular symbol name will be automatically translated by this header.

Definition at line 152 of file xxhash.h.

◆ XXH_VERSION_MINOR

#define XXH_VERSION_MINOR   6

Definition at line 153 of file xxhash.h.

◆ XXH_VERSION_NUMBER

#define XXH_VERSION_NUMBER   (XXH_VERSION_MAJOR *100*100 + XXH_VERSION_MINOR *100 + XXH_VERSION_RELEASE)

Definition at line 155 of file xxhash.h.

◆ XXH_VERSION_RELEASE

#define XXH_VERSION_RELEASE   5

Definition at line 154 of file xxhash.h.

Typedef Documentation

◆ XXH32_hash_t

typedef unsigned int XXH32_hash_t

Definition at line 162 of file xxhash.h.

◆ XXH32_state_t

typedef struct XXH32_state_s XXH32_state_t

Definition at line 172 of file xxhash.h.

◆ XXH64_hash_t

typedef unsigned long long XXH64_hash_t

Definition at line 219 of file xxhash.h.

◆ XXH64_state_t

typedef struct XXH64_state_s XXH64_state_t

Definition at line 229 of file xxhash.h.

Enumeration Type Documentation

◆ XXH_errorcode

Enumerator
XXH_OK 
XXH_ERROR 

Definition at line 79 of file xxhash.h.

Function Documentation

◆ XXH32_createState()

XXH_PUBLIC_API XXH32_state_t* XXH32_createState ( void  )

Definition at line 422 of file xxhash.c.

◆ XXH64_createState()

XXH_PUBLIC_API XXH64_state_t* XXH64_createState ( void  )

Definition at line 883 of file xxhash.c.

◆ XXH_versionNumber()

XXH_PUBLIC_API unsigned XXH_versionNumber ( void  )

Definition at line 257 of file xxhash.c.



plotjuggler
Author(s): Davide Faconti
autogenerated on Sun Aug 11 2024 02:24:28