Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
99 changes: 42 additions & 57 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ futures = "0.3.31"
hex = "0.4.3"
rayon = "1.10.0"
reqwest = "0.12.15"
risc0-zkp = "3.0.2"
risc0-zkvm-platform = "2.2.1"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
sha2 = "0.10.8"
Expand Down
2 changes: 1 addition & 1 deletion app-swap/core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ license = "Apache-2.0"
repository = "https://github.com/essential-contributions/void-reference-impl"

[dependencies]
void-core = { path = "../../void/void-core", version = "0.1.0" }
void-core = { path = "../../void/void-core", version = "0.1.0", features = ["poseidon2-r0"] }

#Testing only dependencies
tracing = { version = "0.1", features = ["max_level_debug", "release_max_level_info"], optional = true }
Expand Down
4 changes: 2 additions & 2 deletions app-swap/core/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
use void_core::{
hash::Sha256,
hash::{Poseidon2, Sha256},
state::kv_store::{
binary_trie_store::BinaryTrieStore,
zk_binary_trie_store::{BinaryTrieWitness, ZkBinaryTrieStore},
Expand All @@ -13,7 +13,7 @@ pub mod testing;
pub mod queries;

pub type EventsHash = Sha256;
pub type StorageHash = Sha256;
pub type StorageHash = Poseidon2;

pub type AppState = BinaryTrieStore<StorageHash>;
pub type ZkAppState = ZkBinaryTrieStore<StorageHash>;
Expand Down
79 changes: 19 additions & 60 deletions benchmarks/zk-proving/risczero/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,82 +62,41 @@ The following results were obtained on the various reference machines.
### AMD Ryzen 9 9950X + RTX 5090
GPU proving
```
Proof generation benchmark results:
Events Time (s) TPS
1 3.84 0.26
2 3.92 0.51
5 4.47 1.12
10 4.23 2.36
20 5.66 3.53
50 7.96 6.28
100 11.43 8.75
200 19.53 10.24
500 39.54 12.65
1000 74.62 13.40
2000 135.90 14.72
5000 309.93 16.13
10000 566.03 17.67
20000 1021.02 19.59

Estimated TPS at various latencies:
Latency (s) TPS
5 3.07
10 7.94
30 11.90
60 13.19
120 14.50
300 16.10
```

### AWS g6.xlarge
GPU proving
```
Proof generation benchmark results:
Events Time (s) TPS
1 6.23 0.16
2 6.26 0.32
5 6.79 0.74
10 7.78 1.29
20 9.23 2.17
50 13.66 3.66
100 19.64 5.09
200 32.81 6.10
500 69.10 7.24
1000 126.09 7.93
2000 234.46 8.53
5000 520.38 9.61
10000 942.56 10.61
1 6.10 0.16
2 6.11 0.33
5 6.40 0.78
10 6.86 1.46
20 6.98 2.86
50 9.12 5.48
100 12.08 8.28
200 18.05 11.08
500 35.28 14.17
1000 61.64 16.22
2000 112.62 17.76
5000 256.39 19.50
10000 473.71 21.11

Estimated TPS at various latencies:
Latency (s) TPS
5 --
10 2.52
30 5.96
60 7.08
120 7.89
300 8.96
10 6.48
30 13.60
60 16.15
120 17.95
300 20.01
600 --
```

### AWS c6i.8xlarge
CPU proving
```
Proof generation benchmark results:
Events Time (s) TPS
1 66.61 0.02
2 66.52 0.03
5 84.84 0.06
10 125.10 0.08
20 152.68 0.13
50 297.24 0.17
100 472.23 0.21
200 848.63 0.24

Estimated TPS at various latencies:
Latency (s) TPS
5 --
10 --
30 --
60 --
120 0.08
300 0.17
```
2 changes: 1 addition & 1 deletion benchmarks/zk-proving/risczero/methods/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ version = "0.1.0"
edition = "2021"

[build-dependencies]
risc0-build = { version = "^3.0.3" }
risc0-build = { git = "https://github.com/risc0/risc0.git", rev = "e03b8f0" }

[package.metadata.risc0]
methods = ["guest"]
Loading