Crate halo2_base

Source
Expand description

Base library to build Halo2 circuits.

Re-exports§

pub use halo2_proofs_axiom as halo2_proofs;

Modules§

gates
Module that contains the main API for creating and working with circuits. gates is misleading because we currently only use one custom gate throughout.
poseidon
Module for the Poseidon hash function.
safe_types
Module for SafeType which enforce value range and realted functions.
utils
Utility functions for converting between different types of field elements.
virtual_region
Trait describing the shared properties for a struct that is in charge of managing a virtual region of a circuit and assigning that virtual region to a “raw” Halo2 region in the “physical” circuit.

Macros§

impl_scalar_field
To ensure ScalarField is only implemented for ff:Field where Repr is little endian, we use the following macro to implement the trait for each field.

Structs§

AssignedValue
Pointer containing cell value and location within Context.
Context
Represents a single thread of an execution trace.
ContextCell
Pointer to the position of a cell at offset in an advice column within a Context of context_id.

Enums§

QuantumCell
Convenience Enum which abstracts the scenarios under a value is added to an advice column.

Constants§

SKIP_FIRST_PASS
Constant representing whether the Layouter calls synthesize once just to get region shape.

Type Aliases§

ContextTag
Unique tag for a context across all virtual regions. In the form (type_id, context_id) where type_id should be a unique identifier for the virtual region this context belongs to, and context_id is a counter local to that virtual region.