FARGOS/VISTA Object Management Environment Core  ..
FARGOS/VISTA Object Management Environment Core Table of Contents
Concatenable Hash Functions

Hash functions that support concatenation; logically: hash(A + B) = hash(a) + hash(b);. More...

Functions

uint32_t hash_string32 (const char *str)
 Generate a concatenateable 32-bit hash of a null-terminated string. More...
 
uint32_t hash_block32 (const void *block, size_t blockLen)
 Generate a concatenateable 32-bit hash of a block of memory. More...
 
uint32_t hash_concat32 (uint32_t left, uint32_t right) OME_CONST_FUNCTION
 Compose a new hash of a logically concatenated string from previous hashes of the two elements. More...
 

Detailed Description

Hash functions that support concatenation; logically: hash(A + B) = hash(a) + hash(b);.

Function Documentation

◆ hash_block32()

uint32_t hash_block32 ( const void *  block,
size_t  blockLen 
)

Generate a concatenateable 32-bit hash of a block of memory.

Parameters
blockpoints at the start of the block to be hashed
blockLenspecifies the length of the block

References OME_PREFETCH.

◆ hash_concat32()

uint32_t hash_concat32 ( uint32_t  left,
uint32_t  right 
)

Compose a new hash of a logically concatenated string from previous hashes of the two elements.

Parameters
leftis the hash of the left-hand component
rightis the hash of the right-hand component

◆ hash_string32()

uint32_t hash_string32 ( const char *  str)

Generate a concatenateable 32-bit hash of a null-terminated string.

Parameters
strpoints at the string to be hashed

References OME_PREFETCH.

Generated: Fri Jul 31 2020 18:19:16
Support Information