#serialization #transmute

no-std winter-utils

Utilities for the Winterfell STARK prover/verifier

5 releases (breaking)

Uses new Rust 2021

0.4.0 Apr 29, 2022
0.3.0 Jan 5, 2022
0.2.0 Aug 24, 2021
0.1.0 Aug 4, 2021
0.0.0 Aug 3, 2021

#267 in Cryptography

Download history 394/week @ 2022-06-13 341/week @ 2022-06-20 701/week @ 2022-06-27 597/week @ 2022-07-04 662/week @ 2022-07-11 428/week @ 2022-07-18 439/week @ 2022-07-25 598/week @ 2022-08-01 429/week @ 2022-08-08 350/week @ 2022-08-15 382/week @ 2022-08-22 412/week @ 2022-08-29 665/week @ 2022-09-05 521/week @ 2022-09-12 465/week @ 2022-09-19 427/week @ 2022-09-26

2,091 downloads per month
Used in 19 crates (12 directly)

MIT license

34KB
561 lines

Winter utils

This crate contains utilities used by the Winterfell STARK prover and verifier. These utilities fall into the following broad categories:

  • Traits used for serialization and deserialization.
  • Functions for transmuting vectors and slices.
  • Macros for easily switching between regular and parallel iterators.
  • Feature-based re-exports of collections and strings.

Crate features

This crate can be compiled with the following features:

  • std - enabled by default and relies on the Rust standard library.
  • concurrent - implies std and also re-exports rayon crate and enables multi-threaded execution for some of the crate functions.
  • no_std - does not rely on Rust's standard library and enables compilation to WebAssembly.

To compile with no_std, disable default features via --no-default-features flag.

Concurrent execution

When compiled with concurrent feature enabled, this crate re-exports rayon crate and executes the following functions using multiple threads:

  • transpose_slice()

The number of threads can be configured via RAYON_NUM_THREADS environment variable, and usually defaults to the number of logical cores on the machine.

License

This project is MIT licensed.

Dependencies

~0–270KB