zlib-rs 比 C 更快

  • Released Version: 0.4.2 of zlib-rs with substantial performance improvements.

    • Decompression: Now the fastest api-compatible implementation, beating zlib-ng and zlib-chromium in most relevant cases.

      • Multiversioning: Manually implemented due to lack of native support in Rust, involves unsafe code.
      • DFA optimizations: Use -Cllvm-args=-enable-dfa-jump-thread option to recover performance, looking to support in rustc.
    • Compression: Chipping away at it too, faster for some compression levels on x86_64 linux but still slower for others.
  • Dashboard: https://trifectatechfoundation.github.io/zlib-rs-bench/ shows performance compared to other implementations and tracks progress.
  • Usage: Can be used in C projects and as a Rust crate. For Rust projects, use 1.1.0 release of flate2 with zlib-rs feature flag. For C projects, build as a C dynamic library.
  • Missing Functionality: Missing some less commonly used API functions related to gzip files.
  • Funding: Seeking €95,000 for completing work and improving performance and packaging. Contact https://trifectatech.org/support if interested.
阅读 6
0 条评论