vacp2p / zerokit

A set of Zero Knowledge modules, written in Rust and designed to be used in other system programming environments.
Apache License 2.0
130 stars 7 forks source link

chore(rln): add ark-zkey support #242

Closed seemenkina closed 4 months ago

seemenkina commented 4 months ago

For now makefile doesn't work correct because of using whole mopro project as submodule. The problem is that mopro uses a patch for wasmer and zerokit doesn't and as a result there is a conflict in dependencies.

In general benchmark and tests are working if it runs by cargo bench/tests.

So I opened an issue to publish ark-key as a library and will wait for the result. In the meantime, I will try to pull up only part of the sub-module as a kludge solution and do some other tasks

Part of #237

rymnc commented 4 months ago

perhaps we need to shallow clone the repo in the benchmarks github job/?

seemenkina commented 4 months ago

perhaps we need to shallow clone the repo in the benchmarks github job/?

wouldn't that just make a dependency conflict? I mean between their patch wasmer and release wasmer?

rymnc commented 4 months ago

perhaps we need to shallow clone the repo in the benchmarks github job/?

wouldn't that just make a dependency conflict? I mean between their patch wasmer and release wasmer?

yup, but we should try to find a way for the benchmarks to run in CI before we can merge this :)

github-actions[bot] commented 4 months ago

Benchmark for 88670db

Click to view benchmark | Test | Base | PR | % | |------|--------------|------------------|---| | FullMerkleTree::compute_root | 0.0±0.00ns | 0.0±0.00ns | NaN% | | FullMerkleTree::delete | 893.9±11.79ns | 890.3±29.69ns | -0.40% | | FullMerkleTree::get | 3.4±0.14ns | 3.4±0.04ns | 0.00% | | FullMerkleTree::override_range | 2.2±0.03µs | 2.2±0.04µs | 0.00% | | FullMerkleTree::set | 891.4±14.89ns | 883.0±12.37ns | -0.94% | | OptimalMerkleTree::compute_root | 1050.2±13.47ns | **1032.6±13.93ns** | **-1.68%** | | OptimalMerkleTree::delete | 1063.5±7.56ns | **1025.3±13.06ns** | **-3.59%** | | OptimalMerkleTree::get | 23.3±0.20ns | 23.1±0.31ns | -0.86% | | OptimalMerkleTree::override_range | 5.2±0.07µs | 5.2±0.17µs | 0.00% | | OptimalMerkleTree::set | 1049.9±13.72ns | **1025.0±12.12ns** | **-2.37%** |
github-actions[bot] commented 4 months ago

Benchmark for 88670db

Click to view benchmark | Test | Base | PR | % | |------|--------------|------------------|---| | Pmtree::compute_root | 0.0±0.00ns | 0.0±0.00ns | NaN% | | Pmtree::get | 324.0±1.78ns | **319.9±4.14ns** | **-1.27%** | | Pmtree::override_range | **230.0±3.32µs** | 236.7±5.88µs | **+2.91%** | | Pmtree::set | 55.8±0.42µs | **54.3±0.62µs** | **-2.69%** | | Pmtree:delete | 55.7±0.43µs | **54.3±0.56µs** | **-2.51%** | | zkey::upload_from_folder | 3.3±0.01s | N/A | N/A |