1
0
Fork 0
mirror of https://github.com/BLAKE3-team/BLAKE3 synced 2024-05-18 03:56:08 +02:00
BLAKE3/Cargo.toml
Cesar Eduardo Barros 4690c5f14e Use fixed-size constant_time_eq
The generic constant_time_eq has several branches on the slice length,
which are not necessary when the slice length is known. However, the
optimizer is not allowed to look into the core of constant_time_eq, so
these branches cannot be elided.

Use instead a fixed-size variant of constant_time_eq, which has no
branches since the length is known.
2020-01-12 17:40:57 -05:00

46 lines
1.6 KiB
INI

[package]
name = "blake3"
version = "0.1.0"
authors = ["Jack O'Connor <oconnor663@gmail.com>"]
description = "the BLAKE3 hash function"
repository = "https://github.com/BLAKE3-team/BLAKE3"
license = "CC0-1.0 OR Apache-2.0"
documentation = "https://docs.rs/blake3"
readme = "README.md"
edition = "2018"
[features]
default = ["std"]
# Like SSE4.1 and AVX2, the AVX-512 implementation participates in dynamic CPU
# feature detection. A binary with "c_avx512" on is still cross-platform. This
# feature has no effect on non-x86.
c_avx512 = []
# The NEON implementation does not participate in dynamic feature detection,
# which is currently x86-only. If "c_neon" is on, NEON support is assumed. Note
# that AArch64 always supports NEON, but support on ARMv7 varies.
c_neon = []
std = []
[dependencies]
arrayref = "0.3.5"
arrayvec = { version = "0.5.1", default-features = false, features = ["array-sizes-33-128"] }
constant_time_eq = "0.1.5"
# A performance note for the "rayon" feature: Multi-threading can have
# significant overhead for small inputs, particularly on x86 where individual
# cores are very fast. On the other hand, on slower platforms like ARM,
# multi-threading can be beneficial for all inputs. There's no one input size
# threshold that would work well everywhere, and this crate doesn't try to be
# clever. If you're going to enable the "rayon" feature, you should benchmark
# it for your specific use case.
rayon = { version = "1.2.1", optional = true }
cfg-if = "0.1.10"
[dev-dependencies]
page_size = "0.4.1"
rand = "0.7.2"
rand_chacha = "0.2.1"
reference_impl = { path = "./reference_impl" }
[build-dependencies]
cc = "1.0.48"