Skip to content

TFHE-rs v1.0.0

Latest
Compare
Choose a tag to compare
@IceTDrinker IceTDrinker released this 26 Feb 15:12
· 41 commits to main since this release
tfhe-rs-1.0.0

Summary

TFHE-rs v1.0.0 marks the first official stable release of the TFHE-rs library.

TFHE-rs v1.0.0 stabilizes the high-level API for the x86 CPU backend and introduces new parameters for the classic PBS with an error probability lower than $2^{-128}$.

This milestone release empowers developers with robust, performant, and user-friendly cryptographic primitives—ensuring greater reliability and efficiency for secure computations.

What's Changed

Breaking Changes

Warning

  • The trait HlCompactable is now required for types used in a CompactCiphertextList
  • GpuIndex has been refactored and its internal field is no longer public. Use new and try_new to create a GpuIndex
  • Conformance parameters names have been updated and now follow the "StructConformanceParam" naming schemer for a given Struct

New features

CPU

  • Add a modulus switch noise reduction technique, greatly improving performance for low error probabilities.
  • Add Abs to the high-level C API binding
  • Add a named implementation for integer compression/decompression, allowing safe serialization
  • Make strings compatible with the compact and compressed lists
  • Add parameters for the classic PBS in shortint with a probability of failure less than 2^-128

GPU

  • Add encrypted Pseudo Random Generation
  • Add GPU selection in high-level API

Improvements

CPU

  • Use destructuring in more places to ensure exhaustive field checks in some parts of the API

GPU

  • Optimized packing keyswitch
  • GpuIndex now enforces a validity invariant at creation time
  • Enable more samples in the keyswitch
  • Enable more samples in PBS (TBC variant)

Fixes

CPU

  • Fix deserialization of old structures, which were renamed but still supported
  • Fix compression, which was crashing if output compute parameters were Multi Bit
  • Fix decompression of ciphertext lists after a safe deserialization for various device selections
  • Fix that trivial ciphertexts were crashing compression due to an invalid noise check
  • Fix rotations/shifts on less than 2 blocks

GPU

  • Fix corner cases in match value function
  • Fix scalar mul with 1 block
  • Fix internal indices for multi-GPU contexts
  • Fix some noise/degree bugs
  • Fix degree after shift/rotate
  • Fix wrong degree in ciphertexts after decompression, which led to degraded performance
  • Fix compressed ciphertext lists conversions between CPU and GPU

Resources

Documentation: