Skip to content

Commit d466757

Browse files
committed
docs(crc32b): add comprehensive documentation and unit tests
- Add 15 comprehensive unit tests covering: * Known test vectors (ISO 3309 correctness) * Various input sizes (1 byte to 1MB) * Buffer boundary conditions (256 bytes, 4KB) * Incremental updates and reset behavior * Edge cases (empty input, single byte) - Add detailed doc comments to all public methods: * Struct-level documentation with examples * Method-level documentation with performance notes * Buffering strategy explanation * SIMD capability detection documentation - Add feature detection documentation: * Performance tiers (AVX512 > SSE > Software) * Buffer sizing strategy (64KB for AVX512, 8KB for SSE) * Threshold-based flushing (256 bytes for AVX512, 4KB for SSE) * Architecture-specific optimizations - Add error handling and validation: * Input validation (empty input handling) * Output buffer size validation * Invariant documentation * Edge case handling Test Results: 15/15 passed ✅ Build Status: Successful ✅
1 parent 05b8e67 commit d466757

File tree

1 file changed

+512
-18
lines changed
  • src/uucore/src/lib/features

1 file changed

+512
-18
lines changed

0 commit comments

Comments
 (0)