Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: update crs to ark-srs #1215

Merged
merged 1 commit into from
Mar 8, 2024
Merged
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
36 changes: 18 additions & 18 deletions Cargo.lock

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

2 changes: 1 addition & 1 deletion contracts/rust/adapter/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ ark-ed-on-bn254 = { workspace = true }
ark-ff = { workspace = true }
ark-poly = { workspace = true }
ark-serialize = { workspace = true }
ark-srs = { git = "https://github.com/alxiong/ark-srs", tag = "v0.1.0" }
ark-std = { workspace = true }
contract-bindings = { path = "../../../contract-bindings" }
crs = { git = "https://github.com/alxiong/crs" }
diff-test-bn254 = { git = "https://github.com/EspressoSystems/solidity-bn254.git" }
ethers = { version = "2.0.4" }
hotshot-types = { workspace = true }
Expand Down
2 changes: 1 addition & 1 deletion contracts/rust/diff-test/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ ark-ec = { workspace = true }
ark-ed-on-bn254 = { workspace = true }
ark-ff = { workspace = true }
ark-poly = { workspace = true }
ark-srs = { git = "https://github.com/alxiong/ark-srs", tag = "v0.1.0" }
ark-std = { workspace = true }
clap = { version = "^4.4", features = ["derive"] }
crs = { git = "https://github.com/alxiong/crs" }
diff-test-bn254 = { git = "https://github.com/EspressoSystems/solidity-bn254.git" }
digest = { version = "0.10", default-features = false, features = ["alloc"] }
ethers = { version = "2.0.4" }
Expand Down
2 changes: 1 addition & 1 deletion contracts/rust/gen-vk-contract/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ authors = { workspace = true }
edition = { workspace = true }

[dependencies]
crs = { git = "https://github.com/alxiong/crs" }
ark-srs = { git = "https://github.com/alxiong/ark-srs", tag = "v0.1.0" }
hotshot-contract-adapter = { path = "../adapter" }
hotshot-stake-table = { workspace = true }
hotshot-state-prover = { path = "../../../hotshot-state-prover" }
Expand Down
4 changes: 2 additions & 2 deletions contracts/rust/gen-vk-contract/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ use jf_primitives::pcs::prelude::UnivariateUniversalParams;
fn main() {
let srs = {
// load SRS from Aztec's ceremony
let srs =
crs::aztec20::kzg10_setup(2u64.pow(20) as usize + 2).expect("Aztec SRS fail to load");
let srs = ark_srs::aztec20::kzg10_setup(2u64.pow(20) as usize + 2)
.expect("Aztec SRS fail to load");
// convert to Jellyfish type
// TODO: (alex) use constructor instead https://github.com/EspressoSystems/jellyfish/issues/440
UnivariateUniversalParams {
Expand Down
2 changes: 1 addition & 1 deletion hotshot-state-prover/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ ark-ec = { workspace = true }
ark-ed-on-bn254 = { workspace = true }
ark-ff = { workspace = true }
ark-serialize = { workspace = true }
ark-srs = { git = "https://github.com/alxiong/ark-srs", tag = "v0.1.0" }
ark-std = { workspace = true }
async-compatibility-layer = { workspace = true }
async-std = { workspace = true }
Expand All @@ -20,7 +21,6 @@ blake3 = "1.5"
clap = { workspace = true }
cld = { workspace = true }
contract-bindings = { path = "../contract-bindings" }
crs = { git = "https://github.com/alxiong/crs" }
derive_more = { workspace = true }
displaydoc = { version = "0.2.3", default-features = false }
ethers = { workspace = true }
Expand Down
6 changes: 3 additions & 3 deletions hotshot-state-prover/src/mock_ledger.rs
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@ impl MockLedger {

let srs = {
// load SRS from Aztec's ceremony
let srs = crs::aztec20::kzg10_setup(2u64.pow(16) as usize + 2)
let srs = ark_srs::aztec20::kzg10_setup(2u64.pow(16) as usize + 2)
.expect("Aztec SRS fail to load");
// convert to Jellyfish type
// TODO: (alex) use constructor instead https://github.com/EspressoSystems/jellyfish/issues/440
Expand Down Expand Up @@ -301,7 +301,7 @@ impl MockLedger {

let srs = {
// load SRS from Aztec's ceremony
let srs = crs::aztec20::kzg10_setup(2u64.pow(16) as usize + 2)
let srs = ark_srs::aztec20::kzg10_setup(2u64.pow(16) as usize + 2)
.expect("Aztec SRS fail to load");
// convert to Jellyfish type
// TODO: (alex) use constructor instead https://github.com/EspressoSystems/jellyfish/issues/440
Expand Down Expand Up @@ -430,7 +430,7 @@ pub fn gen_plonk_proof_for_test(
// 1. Simulate universal setup
let rng = &mut jf_utils::test_rng();
let srs = {
let aztec_srs = crs::aztec20::kzg10_setup(1024).expect("Aztec SRS fail to load");
let aztec_srs = ark_srs::aztec20::kzg10_setup(1024).expect("Aztec SRS fail to load");

UnivariateUniversalParams {
powers_of_g: aztec_srs.powers_of_g,
Expand Down
4 changes: 2 additions & 2 deletions hotshot-state-prover/src/service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ pub fn load_proving_key() -> ProvingKey {

std::println!("Loading SRS from Aztec's ceremony...");
let srs_timer = Instant::now();
let srs = crs::aztec20::kzg10_setup(num_gates + 2).expect("Aztec SRS fail to load");
let srs = ark_srs::aztec20::kzg10_setup(num_gates + 2).expect("Aztec SRS fail to load");
let srs_elapsed = srs_timer.elapsed();
std::println!("Done in {srs_elapsed:.3}");

Expand Down Expand Up @@ -456,7 +456,7 @@ mod test {

let srs = {
// load SRS from Aztec's ceremony
let srs = crs::aztec20::kzg10_setup(2u64.pow(16) as usize + 2)
let srs = ark_srs::aztec20::kzg10_setup(2u64.pow(16) as usize + 2)
.expect("Aztec SRS fail to load");
// convert to Jellyfish type
// TODO: (alex) use constructor instead https://github.com/EspressoSystems/jellyfish/issues/440
Expand Down
Loading