mirror of
https://github.com/logos-storage/zk-benchmarks.git
synced 2026-01-07 08:13:07 +00:00
Plonky2 Hash Circuit Benchmarking
- The
plonky2/benchcontains the following hash circuit benchamrking code: sha256, keccak256 and poseidon. - The code for sha256 is taken from plonky2-sha256.
- The keccak hash has two different implementation taken from plonky2-keccak256 and Polygon-zero zk_evm.
- The
build.shscript builds the whole code. You need rust nightly version to build the code. The script overrides the default rust version to nightly. run.shandrun_tree.shruns the benchmark. (run.shfor sha256, keccak, and keccak-polygon andrun_tree.shfor poseidon)- Benchmarks can be parameterized using environment variables. By convention, we start the names of these environment variables with the
ZKBENCH_prefix. - By default the
run.shwill run the sha256 benchmark over 256 Bytes of data. other hashes can be run by settig the environment variables accordingly. - By default the
run_tree.shwill run the poseidon benchmark over tree depth 4. - Additional files
bench.cfgandbench_tree.cfgspecifies the configurations and parameters.