This component transpiles Aztec public contracts code from Noir's Brillig bytecode to AVM (Aztec Virtual Machine) bytecode.
./bootstrap.sh
cargo run <aztec-contract-artifact-json> <transpiled-output-json>
After bootstrap in avm-transpiler
, go to noir-contracts
and only compile avm_test_contract with:
nargo compile --package avm_test_contract --inliner-aggressiveness=0 --silence-warnings
Important: use the right nargo binary located in
aztec-packages/noir/noir-repo/target/release/nargo
If required, build nargo by going in noir/noir-repo
and run
cargo build --release
.
Then, transpile it:
scripts/transpile.sh
Go to yarn-project/simulator and run:
yarn build:fast
This takes in the TS generated by the compilation and transpilation.
Finally, run
yarn test src/avm/avm_simulator.test.ts
To test against some .cpp changes, compile the bb binary and run bb prover test:
yarn test src/avm_proving.test.ts