Add NIFSGadgetTrait, implement Mova's NIFSGadget, adapt Nova NIFSGadget into NIFSGadgetTrait (#173)

* add new NIFSGadgetTrait

* implement Mova's NIFSGadget

* refactor Nova NIFSGadget to fit into the new NIFSGadgetTrait

* abstract NIFSGadget related tests for all implementors of
  NIFSGadgetTrait to avoid duplicated code in the tests between the
  different Nova variants gadget tests

* frontends/noir update mimc usage since it has been migrated from
  noir's std into it's own repo
This commit is contained in:
2024-11-12 16:34:02 +01:00
committed by GitHub
parent b812dd66df
commit e1183877e7
20 changed files with 782 additions and 405 deletions

View File

@@ -78,7 +78,7 @@ impl<F: PrimeField> FCircuit<F> for CubicFCircuit<F> {
}
fn main() {
let n_steps = 10;
let n_steps = 5;
// set the initial state
let z_0 = vec![Fr::from(3_u32)];

View File

@@ -28,7 +28,7 @@ use folding_schemes::{
Decider, FoldingScheme,
};
use frontends::noir::{load_noir_circuit, NoirFCircuit};
use std::{env, time::Instant};
use std::time::Instant;
use solidity_verifiers::{
evm::{compile_solidity, Evm},
@@ -42,12 +42,7 @@ fn main() {
let z_0 = vec![Fr::from(1)];
// initialize the noir fcircuit
let cur_path = env::current_dir().unwrap();
let circuit_path = format!(
"{}/frontends/src/noir/test_folder/test_mimc/target/test_mimc.json",
cur_path.to_str().unwrap()
);
let circuit_path = format!("./frontends/src/noir/test_folder/test_mimc/target/test_mimc.json",);
let circuit = load_noir_circuit(circuit_path).unwrap();
let f_circuit = NoirFCircuit {