crc_adler/lib.rs
1//! # CRC-Adler: High-Performance Checksum Library
2//!
3//! A high-performance Rust implementation of Adler-32 and CRC-32 checksum algorithms,
4//! optimized for speed and reliability.
5//!
6//! ## Features
7//!
8//! - **Blazing Fast Performance**: Achieves up to **2.86 GiB/s** throughput on modern hardware
9//! - **Zero Dependencies**: No external dependencies for maximum compatibility
10//! - **Memory Safe**: 100% safe Rust code with no `unsafe` blocks
11//! - **`#![no_std]` Compatible**: Works in embedded and constrained environments
12//! - **Comprehensive Testing**: Extensive test suite with known test vectors
13//! - **Optimized Algorithms**: Advanced optimizations including chunk processing and modulo reduction tricks
14//!
15//! ## Quick Start
16//!
17//! ```rust
18//! use crc_adler::{adler32, crc32};
19//!
20//! // Adler-32 checksum
21//! let data = b"Hello, World!";
22//! let checksum = adler32(data);
23//! println!("Adler-32 checksum: 0x{:08x}", checksum);
24//!
25//! // CRC-32 checksum
26//! let data = b"123456789";
27//! let checksum = crc32(data);
28//! println!("CRC-32 checksum: 0x{:08x}", checksum);
29//! ```
30//!
31//! ## Performance
32//!
33//! Our optimized implementations deliver exceptional performance:
34//!
35//! - **Adler-32**: Up to 2.86 GiB/s on 1MB data
36//! - **CRC-32**: Up to 528 MiB/s on 1MB data
37//!
38//! *Benchmarks run on Intel Core i9-9980HK (x86_64) with Rust 1.70+ in release mode*
39
40pub mod crc32;
41pub mod adler32;
42
43pub use crc32::crc32;
44pub use adler32::adler32;
45