biomcmc-lib  0.1
low level library for phylogenetic analysis
Go to the documentation of this file.
1 /*
2  * This file is part of biomcmc-lib, a low-level library for phylogenomic analysis.
3  * Copyright (C) 2019-today Leonardo de Oliveira Martins [ leomrtns at; ]
4  *
5  * biomcmc is free software; you can redistribute it and/or modify it under the terms of the GNU General Public
6  * License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later
7  * version.
8  *
9  * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
10  * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
11  * details (file "COPYING" or
12  */
18 #ifndef _biomcmc_hashfunctions_h_
19 #define _biomcmc_hashfunctions_h_
21 #include "bipartition.h" // includes lowlevel.h
23 uint32_t biomcmc_hashint_salted (uint32_t a, int salt);
24 uint32_t biomcmc_hashbyte_salted (const void *str, size_t size, int salt);
25 uint64_t biomcmc_hashint64_salted (uint64_t k, int salt);
26 uint32_t biomcmc_hashint_mix_salted (uint32_t a, uint32_t b, int salt);
27 uint64_t biomcmc_hashint64_mix_salted (uint64_t a, uint64_t b, int salt);
29 uint32_t biomcmc_hashint_64to32_seed (uint64_t x, int seed);
30 uint32_t biomcmc_hashint_64to32 (uint64_t key);
32 uint32_t bipartition_hash (bipartition bip);
36 uint64_t biomcmc_murmurhash3_128bits ( const void *key, const size_t len, const uint32_t seed, void *out);
38 uint64_t biomcmc_murmurhash3_64bits ( const void *key, const size_t len, const uint32_t seed);
40 uint32_t biomcmc_murmurhash3_32bits (const void *data, size_t nbytes, const uint32_t seed);
42 uint64_t biomcmc_xxh64 (const void *input, const size_t len, const uint32_t seed);
44 #endif
uint64_t biomcmc_murmurhash3_64bits(const void *key, const size_t len, const uint32_t seed)
convenience function for calling mumurhash_128bits without an output vector
Definition: hashfunctions.c:212
uint32_t biomcmc_murmurhash3_32bits(const void *data, size_t nbytes, const uint32_t seed)
murmurhash3 using 32bits to return 32 bits of hash as return value
Definition: hashfunctions.c:274
Unary/binary operators on arbitrarily-sized bitstrings (strings of zeros and ones) like split biparti...
uint64_t biomcmc_murmurhash3_128bits(const void *key, const size_t len, const uint32_t seed, void *out)
murmurhash3 using 64bits to return 128 bits (4 ints) of hash into out[] and also 64 bits as return va...
Definition: hashfunctions.c:218
Bit-string representation of splits.
Definition: bipartition.h:30
uint32_t bipartition_hash(bipartition bip)
32bits hash value for bipartition
Definition: hashfunctions.c:200
uint64_t biomcmc_xxh64(const void *input, const size_t len, const uint32_t seed)
xxhash function for 64 bits
Definition: hashfunctions.c:401