Skip to content

Commit

Permalink
removed circuit scope synthesize
Browse files Browse the repository at this point in the history
  • Loading branch information
gabriel-barrett committed Jan 12, 2024
1 parent 5835741 commit 7f25be3
Showing 1 changed file with 4 additions and 21 deletions.
25 changes: 4 additions & 21 deletions src/coprocessor/memoset/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ pub struct Scope<F, Q, M> {
internal_insertions: Vec<Ptr>,
/// unique keys
all_insertions: Vec<Ptr>,
_p: PhantomData<(F, Q)>,
_p: PhantomData<F>,
}

impl<F: LurkField, Q> Default for Scope<F, Q, LogMemo<F>> {
Expand Down Expand Up @@ -394,23 +394,6 @@ impl<F: LurkField, CQ: CircuitQuery<F>> CircuitScope<F, CQ, LogMemo<F>> {
self.transcript = CircuitTranscript::new(cs, g, s);
}

pub fn synthesize<CS: ConstraintSystem<F>>(
&mut self,
scope: &mut Scope<F, CQ::Q, LogMemo<F>>,
cs: &mut CS,
g: &mut GlobalAllocator<F>,
s: &Store<F>,
) -> Result<(), SynthesisError> {
scope.ensure_transcript_finalized(s);
self.init(cs, g, s);
{
self.synthesize_insert_toplevel_queries(scope, cs, g, s)?;
self.synthesize_prove_all_queries(scope, cs, g, s)?;
}
self.finalize(cs, g);
Ok(())
}

fn synthesize_insert_query<CS: ConstraintSystem<F>>(
&self,
cs: &mut CS,
Expand Down Expand Up @@ -801,10 +784,10 @@ mod test {

let cs = &mut TestConstraintSystem::new();
let g = &mut GlobalAllocator::default();
let mut circuit_scope: CircuitScope<_, ScopeCircuitQuery<F>, _> =
CircuitScope::from_scope(&mut cs.namespace(|| "transcript"), g, s, &scope);

circuit_scope.synthesize(&mut scope, cs, g, s).unwrap();
scope
.synthesize::<_, ScopeCircuitQuery<F>>(cs, g, s)
.unwrap();

println!(
"transcript: {}",
Expand Down

0 comments on commit 7f25be3

Please sign in to comment.