This repository contains SNARK circuits of a cryptographic hash function SHA-256 implemented with Plonky2.
Run benchmarks
RUSTFLAGS=-Ctarget-cpu=native cargo run --release --package plonky2_sha256 --bin plonky2_sha256
Benchmark on a Macbook Pro (M1), preimage message size = 2828 (block count = 45)
block count: 45
Constructing inner proof with 261980 gates
[INFO plonky2::plonk::circuit_builder] Degree before blinding & padding: 262019
[INFO plonky2::plonk::circuit_builder] Degree after blinding & padding: 262144
[DEBUG plonky2::plonk::circuit_builder] Building circuit took 14.396462s
[DEBUG plonky2::util::timing] 16.7942s to prove
[DEBUG plonky2::util::timing] 0.0064s to verify