diff --git a/Cargo.toml b/Cargo.toml index bbf0cb2f..99d48457 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -9,7 +9,7 @@ repository = "https://github.com/lurk-lab/neptune" rust-version = "1.64.0" [dependencies] -bellperson = { workspace = true } +bellpepper = { workspace = true } blake2s_simd = { workspace = true } blstrs = { workspace = true, optional = true } byteorder = { workspace = true } @@ -51,7 +51,7 @@ incremental = false codegen-units = 1 [features] -default = ["bellperson/default"] +default = ["bellpepper/default"] cuda = ["ec-gpu-gen/cuda", "ec-gpu", "pasta_curves/gpu"] opencl = ["ec-gpu-gen/opencl", "ec-gpu", "pasta_curves/gpu"] # The supported arities for Poseidon running on the GPU are specified at compile-time. @@ -76,7 +76,7 @@ members = [ # Dependencies that should be kept in sync through the whole workspace [workspace.dependencies] -bellperson = { git = "https://github.com/filecoin-project/bellperson", branch = "master" } +bellpepper = { path = "../bellpepper" } blake2s_simd = "0.5" blstrs = { version = "0.7.0" } ff = "0.13.0" diff --git a/benches/synthesis.rs b/benches/synthesis.rs index 537ef54d..6cf4aa79 100644 --- a/benches/synthesis.rs +++ b/benches/synthesis.rs @@ -1,8 +1,8 @@ use crate::poseidon::{Arity, PoseidonConstants}; -use bellperson::gadgets::num::AllocatedNum; -use bellperson::util_cs::bench_cs::BenchCS; -use bellperson::util_cs::witness_cs::WitnessCS; -use bellperson::{ConstraintSystem, SynthesisError}; +use bellpepper::gadgets::num::AllocatedNum; +use bellpepper::util_cs::bench_cs::BenchCS; +use bellpepper::util_cs::witness_cs::WitnessCS; +use bellpepper::{ConstraintSystem, SynthesisError}; use blstrs::Scalar as Fr; use criterion::{criterion_group, criterion_main, BenchmarkId, Criterion}; use ff::Field; diff --git a/gbench/Cargo.toml b/gbench/Cargo.toml index 6fb2241d..5d78e51a 100644 --- a/gbench/Cargo.toml +++ b/gbench/Cargo.toml @@ -7,7 +7,7 @@ edition = "2018" license = "MIT OR Apache-2.0" [dependencies] -bellperson = { workspace = true, default-features = false } +bellpepper = { workspace = true, default-features = false } blake2s_simd = { workspace = true } blstrs = { workspace = true, features = ["gpu"] } byteorder = { workspace = true } @@ -23,5 +23,5 @@ structopt = { version = "0.3", default-features = false } [features] default = ["opencl"] -cuda = ["neptune/cuda", "bellperson/cuda", "ec-gpu-gen/cuda"] -opencl = ["neptune/opencl", "bellperson/opencl", "ec-gpu-gen/opencl"] +cuda = ["neptune/cuda", "ec-gpu-gen/cuda"] +opencl = ["neptune/opencl", "ec-gpu-gen/opencl"] diff --git a/src/circuit.rs b/src/circuit.rs index 6b659b20..17a9d3c3 100644 --- a/src/circuit.rs +++ b/src/circuit.rs @@ -6,10 +6,10 @@ use crate::hash_type::HashType; use crate::matrix::Matrix; use crate::mds::SparseMatrix; use crate::poseidon::{Arity, PoseidonConstants}; -use bellperson::gadgets::boolean::Boolean; -use bellperson::gadgets::num; -use bellperson::gadgets::num::AllocatedNum; -use bellperson::{ConstraintSystem, LinearCombination, SynthesisError}; +use bellpepper::gadgets::boolean::Boolean; +use bellpepper::gadgets::num; +use bellpepper::gadgets::num::AllocatedNum; +use bellpepper::{ConstraintSystem, LinearCombination, SynthesisError}; use ff::{Field, PrimeField}; use std::marker::PhantomData; @@ -613,8 +613,8 @@ mod tests { use super::*; use crate::poseidon::HashMode; use crate::{Poseidon, Strength}; - use bellperson::util_cs::test_cs::TestConstraintSystem; - use bellperson::ConstraintSystem; + use bellpepper::util_cs::test_cs::TestConstraintSystem; + use bellpepper::ConstraintSystem; use blstrs::Scalar as Fr; use generic_array::typenum; use rand::SeedableRng; diff --git a/src/circuit2.rs b/src/circuit2.rs index dab7757e..1235efff 100644 --- a/src/circuit2.rs +++ b/src/circuit2.rs @@ -6,10 +6,10 @@ use crate::hash_type::HashType; use crate::matrix::Matrix; use crate::mds::SparseMatrix; use crate::poseidon::{Arity, PoseidonConstants}; -use bellperson::gadgets::boolean::Boolean; -use bellperson::gadgets::num::{self, AllocatedNum}; -use bellperson::gadgets::test::TestConstraintSystem; -use bellperson::{ConstraintSystem, LinearCombination, SynthesisError}; +use bellpepper::gadgets::boolean::Boolean; +use bellpepper::gadgets::num::{self, AllocatedNum}; +use bellpepper::gadgets::test::TestConstraintSystem; +use bellpepper::{ConstraintSystem, LinearCombination, SynthesisError}; use ff::{Field, PrimeField}; use std::marker::PhantomData; @@ -699,8 +699,8 @@ mod tests { use super::*; use crate::poseidon::HashMode; use crate::{Poseidon, Strength}; - use bellperson::util_cs::test_cs::TestConstraintSystem; - use bellperson::ConstraintSystem; + use bellpepper::util_cs::test_cs::TestConstraintSystem; + use bellpepper::ConstraintSystem; use blstrs::Scalar as Fr; use generic_array::typenum; use rand::SeedableRng; diff --git a/src/circuit2_witness.rs b/src/circuit2_witness.rs index d9ddc34a..39056c1b 100644 --- a/src/circuit2_witness.rs +++ b/src/circuit2_witness.rs @@ -6,12 +6,12 @@ use crate::hash_type::HashType; use crate::matrix::Matrix; use crate::mds::SparseMatrix; use crate::poseidon::{Arity, Poseidon, PoseidonConstants}; -use bellperson::util_cs::witness_cs::SizedWitness; +use bellpepper::util_cs::witness_cs::SizedWitness; -use bellperson::gadgets::boolean::Boolean; -use bellperson::gadgets::num::{self, AllocatedNum}; -use bellperson::gadgets::test::TestConstraintSystem; -use bellperson::{ConstraintSystem, LinearCombination, SynthesisError}; +use bellpepper::gadgets::boolean::Boolean; +use bellpepper::gadgets::num::{self, AllocatedNum}; +use bellpepper::gadgets::test::TestConstraintSystem; +use bellpepper::{ConstraintSystem, LinearCombination, SynthesisError}; use ff::{Field, PrimeField}; use generic_array::sequence::GenericSequence; use generic_array::typenum::Unsigned; @@ -324,8 +324,8 @@ mod test { use crate::circuit2; use crate::poseidon::HashMode; use crate::{Poseidon, Strength}; - use bellperson::util_cs::{test_cs::TestConstraintSystem, witness_cs::WitnessCS, Comparable}; - use bellperson::ConstraintSystem; + use bellpepper::util_cs::{test_cs::TestConstraintSystem, witness_cs::WitnessCS, Comparable}; + use bellpepper::ConstraintSystem; use blstrs::Scalar as Fr; use generic_array::typenum; use rand::SeedableRng; diff --git a/src/sponge/circuit.rs b/src/sponge/circuit.rs index e35be4bb..3f00ce7b 100644 --- a/src/sponge/circuit.rs +++ b/src/sponge/circuit.rs @@ -8,10 +8,10 @@ use crate::sponge::{ vanilla::{Direction, Mode, SpongeTrait}, }; use crate::Strength; -use bellperson::gadgets::boolean::Boolean; -use bellperson::gadgets::num::{self, AllocatedNum}; -use bellperson::util_cs::witness_cs::{SizedWitness, WitnessCS}; -use bellperson::{ConstraintSystem, LinearCombination, Namespace, SynthesisError}; +use bellpepper::gadgets::boolean::Boolean; +use bellpepper::gadgets::num::{self, AllocatedNum}; +use bellpepper::util_cs::witness_cs::{SizedWitness, WitnessCS}; +use bellpepper::{ConstraintSystem, LinearCombination, Namespace, SynthesisError}; use ff::{Field, PrimeField}; use std::collections::VecDeque; use std::marker::PhantomData; @@ -254,7 +254,7 @@ mod tests { use super::*; use crate::sponge::vanilla::Sponge; - use bellperson::{ + use bellpepper::{ util_cs::{test_cs::TestConstraintSystem, witness_cs::WitnessCS}, Circuit, };