Files
ternfs-XTXMarkets/cpp/crc32c/crc32c_pclmul.c
Francesco Mazzoli 136d55bff0 Cleanup CRC32C code
Specifically:

* Extend tables so that they won't wrap around wrongly for big sizes
    (we would never hit this since our blocks are at most a few MBs
    big).
* Use CRC instructions to compute remainders.
2025-09-21 22:22:22 +01:00

16 lines
352 B
C

// Copyright 2025 XTX Markets Technologies Limited
//
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
#include <immintrin.h>
#include <stdint.h>
#include <string.h>
#include <sys/types.h>
typedef uint8_t u8;
typedef uint32_t u32;
typedef uint64_t u64;
#define CRC32C_USE_PCLMUL 1
#define CRC32C_NAME(a) a##_pclmul
#include "crc32c_body.c"