1
0
Fork 0
mirror of https://github.com/BLAKE3-team/BLAKE3 synced 2024-06-07 07:06:05 +02:00

Misc textual improvements

This commit is contained in:
Ivan Boldyrev 2023-09-10 18:57:24 +04:00
parent 909c6fc608
commit cdeb9f7fdb
4 changed files with 11 additions and 11 deletions

View File

@ -18,9 +18,9 @@ default = ["std"]
# implementation uses C intrinsics and requires a C compiler. # implementation uses C intrinsics and requires a C compiler.
neon = [] neon = []
# The WASM-SIMD implementation does not participate in dynamic feature detection, # The Wasm SIMD implementation does not participate in dynamic feature detection,
# which is currently x86-only. If "wasm_simd" is on, WASM SIMD support is assumed. # which is currently x86-only. If "wasm_simd" is on, Wasm SIMD support is assumed.
# Note that not all WASM implementation may support WASM-SIMD specification. # Note that not all Wasm implementation may support Wasm SIMD specification.
wasm32_simd = [] wasm32_simd = []
# This crate uses libstd for std::io trait implementations, and also for # This crate uses libstd for std::io trait implementations, and also for

View File

@ -35,8 +35,8 @@ This repository is the official implementation of BLAKE3. It includes:
* The [`blake3`](https://crates.io/crates/blake3) Rust crate, which * The [`blake3`](https://crates.io/crates/blake3) Rust crate, which
includes optimized implementations for SSE2, SSE4.1, AVX2, AVX-512, includes optimized implementations for SSE2, SSE4.1, AVX2, AVX-512,
and NEON, with automatic runtime CPU feature detection on x86. The NEON and Wasm SIMD, with automatic runtime CPU feature detection on x86.
`rayon` feature provides multithreading. The `rayon` feature provides multithreading.
* The [`b3sum`](https://crates.io/crates/b3sum) Rust crate, which * The [`b3sum`](https://crates.io/crates/b3sum) Rust crate, which
provides a command line interface. It uses multithreading by default, provides a command line interface. It uses multithreading by default,

View File

@ -235,7 +235,7 @@ fn build_neon_c_intrinsics() {
fn build_wasm32_simd() { fn build_wasm32_simd() {
assert!(is_wasm32()); assert!(is_wasm32());
// No C code to compile here. Set the cfg flags that enable the WASM SIMD. // No C code to compile here. Set the cfg flags that enable the Wasm SIMD.
// The regular Cargo build will compile it. // The regular Cargo build will compile it.
println!("cargo:rustc-cfg=blake3_wasm32_simd"); println!("cargo:rustc-cfg=blake3_wasm32_simd");
} }

View File

@ -5,11 +5,11 @@
* Performance measurements with a primitive benchmark with ~16Kb of data: * Performance measurements with a primitive benchmark with ~16Kb of data:
* *
* | M1 native | 11,610 ns | * | M1 native | 11,610 ns |
* | M1 WASM SIMD | 13,355 ns | * | M1 Wasm SIMD | 13,355 ns |
* | M1 WASM | 22,037 ns | * | M1 Wasm | 22,037 ns |
* | x64 native | 6,713 ns | * | x64 native | 6,713 ns |
* | x64 WASM SIMD | 11,985 ns | * | x64 Wasm SIMD | 11,985 ns |
* | x64 WASM | 25,978 ns | * | x64 Wasm | 25,978 ns |
* *
* wasmtime v12.0.1 was used on both platforms. * wasmtime v12.0.1 was used on both platforms.
*/ */
@ -690,7 +690,7 @@ unsafe fn hash1<const N: usize>(
block_flags = flags; block_flags = flags;
slice = &slice[BLOCK_LEN..]; slice = &slice[BLOCK_LEN..];
} }
*out = core::mem::transmute(cv); // x86 is little-endian *out = core::mem::transmute(cv);
} }
#[target_feature(enable = "simd128")] #[target_feature(enable = "simd128")]