Skip to content

Commit 8434e8d

Browse files
committed
feat: Expand AVX-512 support
1 parent 60c0716 commit 8434e8d

27 files changed

Lines changed: 771 additions & 471 deletions

.github/workflows/ci.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,3 +31,14 @@ jobs:
3131

3232
- name: Build with LZ4 and FFI features
3333
run: cargo build --features lz4,ffi
34+
35+
build-avx512:
36+
name: Build with AVX-512
37+
runs-on: ubuntu-latest
38+
steps:
39+
- uses: actions/checkout@v6
40+
- uses: dtolnay/rust-toolchain@stable
41+
- name: Build with all features including avx512
42+
run: cargo build --release --all-features
43+
- name: Test (avx512 code compiles, runtime detection skips if HW unavailable)
44+
run: cargo test --release --all-features --lib

Cargo.toml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
[package]
22
name = "zipora"
3-
version = "3.1.6"
3+
version = "3.1.7"
44
edition = "2024"
5-
rust-version = "1.88"
5+
rust-version = "1.95"
66
authors = ["InfiniLabs"]
77
description = "High-performance Rust implementation providing advanced data structures and compression algorithms with memory safety guarantees. Features LRU page cache, sophisticated caching layer, fiber-based concurrency, real-time compression, secure memory pools, SIMD optimizations, and complete C FFI for migration from C++."
88
license-file = "LICENSE"
@@ -15,13 +15,11 @@ name = "zipora"
1515
crate-type = ["rlib"]
1616

1717
[features]
18-
default = ["simd", "mmap", "zstd", "serde", "lz4", "async"]
18+
default = ["simd", "mmap", "zstd", "serde", "lz4", "async", "avx512"]
1919
simd = []
20-
# AVX-512 support requires nightly Rust due to experimental intrinsics
21-
# Currently disabled by default for stable Rust compatibility
20+
# AVX-512 code paths (runtime-detected, safe on all x86_64 CPUs)
21+
# Disable to reduce binary size on platforms without AVX-512 hardware
2222
avx512 = ["simd"]
23-
# Nightly features for performance optimizations
24-
nightly = []
2523
mmap = ["dep:memmap2"]
2624
zstd = ["dep:zstd"]
2725
lz4 = ["dep:lz4_flex"]
@@ -135,3 +133,7 @@ exclude = [
135133
"benchmarks/*",
136134
]
137135

136+
137+
[[bench]]
138+
name = "avx512_bench"
139+
harness = false

0 commit comments

Comments
 (0)