BitShares-Core  7.0.2
BitShares blockchain node software and command-line wallet software
Namespaces | Macros | Functions
city.cpp File Reference
#include <algorithm>
#include <array>
#include <string.h>
#include <fc/crypto/city.hpp>
#include <boost/endian/buffers.hpp>

Go to the source code of this file.

Namespaces

 fc
 

Macros

#define LIKELY(x)   (x)
 
#define PERMUTE3(a, b, c)   do { std::swap(a, b); std::swap(a, c); } while (0)
 
#define CHUNK(r)
 

Functions

uint64_t _mm_crc32_u64_impl (uint64_t a, uint64_t b)
 
uint64_t fc::Hash128to64 (const uint128_t &x)
 
uint32_t fc::city_hash32 (const char *buf, size_t len)
 
uint64_t fc::city_hash64 (const char *buf, size_t len)
 
uint64_t fc::CityHash64WithSeeds (const char *s, size_t len, uint64_t seed0, uint64_t seed1)
 
uint64_t fc::CityHash64WithSeed (const char *s, size_t len, uint64_t seed)
 
uint128_t fc::CityMurmur (const char *s, size_t len, uint128_t seed)
 
uint128_t fc::CityHash128WithSeed (const char *s, size_t len, uint128_t seed)
 
uint128_t fc::city_hash128 (const char *s, size_t len)
 
void fc::CityHashCrc256 (const char *s, size_t len, uint64_t *result)
 
array< uint64_t, 4 > fc::city_hash_crc_256 (const char *s, size_t len)
 
uint128_t fc::CityHashCrc128WithSeed (const char *s, size_t len, uint128_t seed)
 
uint128_t fc::city_hash_crc_128 (const char *s, size_t len)
 

Macro Definition Documentation

◆ CHUNK

#define CHUNK (   r)
Value:
PERMUTE3(x, z, y); \
b += Fetch64(s); \
c += Fetch64(s + 8); \
d += Fetch64(s + 16); \
e += Fetch64(s + 24); \
f += Fetch64(s + 32); \
a += b; \
h += f; \
b += c; \
f += d; \
g += e; \
e += z; \
g += x; \
z = _mm_crc32_u64_impl(z, b + g); \
y = _mm_crc32_u64_impl(y, e + h); \
x = _mm_crc32_u64_impl(x, f + a); \
e = Rotate(e, r); \
c += e; \
s += 40

◆ LIKELY

#define LIKELY (   x)    (x)

Definition at line 115 of file city.cpp.

◆ PERMUTE3

#define PERMUTE3 (   a,
  b,
 
)    do { std::swap(a, b); std::swap(a, c); } while (0)

Definition at line 157 of file city.cpp.

Function Documentation

◆ _mm_crc32_u64_impl()

uint64_t _mm_crc32_u64_impl ( uint64_t  a,
uint64_t  b 
)

Definition at line 607 of file crc.cpp.

PERMUTE3
#define PERMUTE3(a, b, c)
Definition: city.cpp:157
_mm_crc32_u64_impl
uint64_t _mm_crc32_u64_impl(uint64_t a, uint64_t b)
Definition: crc.cpp:607