Skip to content

Commit

Permalink
Benchmarking tool using cost estimator (#235)
Browse files Browse the repository at this point in the history
* Benchmarking tool using cost estimator

Co-Authored-By: Iñigo Querejeta Azurmendi <[email protected]>

* Address review comments

* Add example of cost-estimator usage

* Cost model example behind feature

* Make report generic over field size and commitment scheme

* Nits

* Use serde for printing the report

* Calculate max expression degree

Use built-in function to compute cs max_degree

* Add cost computation for KZG GWC

* Add shuffle argument

* Nits

* Remove CLI

* Remove FromStr impl - not needed without CLI

* Fix queries of Lookup

* There is only one permutation argument

* Remove dependency of halo2_gadgets for cost-estimator example

---------

Co-authored-by: Henry Blanchette <[email protected]>
  • Loading branch information
iquerejeta and rybla authored Dec 30, 2023
1 parent 20c1290 commit 3550ab0
Show file tree
Hide file tree
Showing 5 changed files with 435 additions and 304 deletions.
8 changes: 8 additions & 0 deletions halo2_proofs/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ blake2b_simd = "1" # MSRV 1.66.0
sha3 = "0.9.1"
rand_chacha = "0.3"
maybe-rayon = { version = "0.1.0", default-features = false }
serde = { version = "1", optional = true, features = ["derive"] }
serde_derive = { version = "1", optional = true}

# Developer tooling dependencies
plotters = { version = "0.3.0", default-features = false, optional = true }
Expand All @@ -72,6 +74,7 @@ criterion = "0.3"
gumdrop = "0.8"
proptest = "1"
rand_core = { version = "0.6", default-features = false, features = ["getrandom"] }
serde_json = "1"

[target.'cfg(all(target_arch = "wasm32", target_os = "unknown"))'.dev-dependencies]
getrandom = { version = "0.2", features = ["js"] }
Expand All @@ -91,10 +94,15 @@ thread-safe-region = []
sanity-checks = []
batch = ["rand_core/getrandom"]
circuit-params = []
cost-estimator = ["serde", "serde_derive"]

[lib]
bench = false

[[example]]
name = "circuit-layout"
required-features = ["test-dev-graph"]

[[example]]
name = "proof-size"
required-features = ["cost-estimator"]
304 changes: 0 additions & 304 deletions halo2_proofs/examples/cost-model.rs

This file was deleted.

Loading

0 comments on commit 3550ab0

Please sign in to comment.