#ifndef SWIFT_DATA_FNV_HASH_H
#define SWIFT_DATA_FNV_HASH_H

#include <swift/stdlib.h>

#include <swift/data/api.h>

#define SWIFT_FNV32_OFFSET UINT32_C(2166136261)
#define SWIFT_FNV64_OFFSET UINT64_C(14695981039346656037)

#define SWIFT_FNV32_PRIME UINT32_C(16777619)
#define SWIFT_FNV64_PRIME UINT64_C(1099511628211)

SWIFT_DATA_API uint32_t swift_fnv1_hash32(const void *data, size_t size);
SWIFT_DATA_API uint32_t swift_fnv1a_hash32(const void *data, size_t size);
SWIFT_DATA_API uint64_t swift_fnv1_hash64(const void *data, size_t size);
SWIFT_DATA_API uint64_t swift_fnv1a_hash64(const void *data, size_t size);

#endif /* SWIFT_DATA_FNV_HASH_H */
