Skip to content

Commit

Permalink
chore: update internal documentation (#3376)
Browse files Browse the repository at this point in the history
Co-authored-by: Tom French <15848336+TomAFrench@users.noreply.github.com>
  • Loading branch information
kek kek kek and TomAFrench authored Nov 14, 2023
1 parent 2883488 commit fd836cb
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 26 deletions.
27 changes: 1 addition & 26 deletions compiler/readme.md
Original file line number Diff line number Diff line change
@@ -1,32 +1,11 @@
# Structure

Below we briefly describe the purpose of each crate in this repository.

## acir - Abstract Circuit Intermediate Representation

This is the intermediate representation that Noir compiles down to. It is agnostic to any particular NP-Complete language.

## acvm - Abstract Circuit Virtual Machine

This is the virtual machine that runs ACIR. Given a proving system to power it, one can create and verify proofs, create smart contracts that verify proofs.
Below we briefly describe the purpose of each crate related to the compiler in this repository.

## fm - File Manager

This is the abstraction that the compiler uses to manage source files.

## lsp

This is the platform agnostic implementation of Noir's Language Server. It implements the various features supported, but doesn't bind to any particular transport. Binding to a transport must be done when consuming the crate.

## nargo

This is the default package manager used by Noir. One may draw similarities to Rusts' Cargo.

## noir_field

Since the DSL allows a user to create constants which can be as large as the field size, we must have a datatype that is able to store them. This is the purpose of the field crate.
One could alternatively use a BigInt library and store the modulus in a Context struct that gets passed to every compiler pass.

## noirc_abi

When consuming input from the user, a common ABI must be provided such that input provided in JSON/TOML can be converted to noir data types. This crate defines such an ABI.
Expand All @@ -42,7 +21,3 @@ This crate can be seen as the middle end. It is in charge of generating the ACIR
## noirc_frontend

This crate comprises of the first few compiler passes that together we denote as the compiler frontend (in order): lexing, parsing, name resolution, type checking, and monomorphization. If any of these passes error, the resulting monomorphized AST will not be passed to the middle-end (noirc_evaluator)

## wasm

This crate is used to compile the Noir compiler into wasm. This is useful in the context where one wants to compile noir programs in the web browser.
15 changes: 15 additions & 0 deletions tooling/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
# Structure

Below we briefly describe the purpose of each tool-related crate in this repository.

## nargo

This is the default package manager used by Noir. One may draw similarities to Rusts' Cargo.

## nargo_fmt

This is the default formatter used by Noir, analogous to Rust's rustfmt.

## lsp

This is the platform agnostic implementation of Noir's Language Server. It implements the various features supported, but doesn't bind to any particular transport. Binding to a transport must be done when consuming the crate.

0 comments on commit fd836cb

Please sign in to comment.