#include <stdbool.h>
#include <stddef.h>
#include <stdint.h>
#include "blake3_impl.h"
#if defined(IS_X86)
#if defined(_MSC_VER)
#include <intrin.h>
#elif defined(__GNUC__)
#include <immintrin.h>
#else
#error "Unimplemented!"
#endif
#endif
#define MAYBE_UNUSED(x) …
#if defined(IS_X86)
static uint64_t xgetbv(void) { … }
static void cpuid(uint32_t out[4], uint32_t id) { … }
static void cpuidex(uint32_t out[4], uint32_t id, uint32_t sid) { … }
#endif
enum cpu_feature { … };
#if !defined(BLAKE3_TESTING)
static
#endif
enum cpu_feature g_cpu_features = …;
LLVM_ATTRIBUTE_USED
#if !defined(BLAKE3_TESTING)
static
#endif
enum cpu_feature
get_cpu_features(void) { … }
void blake3_compress_in_place(uint32_t cv[8],
const uint8_t block[BLAKE3_BLOCK_LEN],
uint8_t block_len, uint64_t counter,
uint8_t flags) { … }
void blake3_compress_xof(const uint32_t cv[8],
const uint8_t block[BLAKE3_BLOCK_LEN],
uint8_t block_len, uint64_t counter, uint8_t flags,
uint8_t out[64]) { … }
void blake3_hash_many(const uint8_t *const *inputs, size_t num_inputs,
size_t blocks, const uint32_t key[8], uint64_t counter,
bool increment_counter, uint8_t flags,
uint8_t flags_start, uint8_t flags_end, uint8_t *out) { … }
size_t blake3_simd_degree(void) { … }