openvm_stark_backend

Trait Chip

Source
pub trait Chip<SC: StarkGenericConfig>: ChipUsageGetter + Sized {
    // Required methods
    fn air(&self) -> Arc<dyn AnyRap<SC>>;
    fn generate_air_proof_input(self) -> AirProofInput<SC>;

    // Provided method
    fn generate_air_proof_input_with_id(
        self,
        air_id: usize,
    ) -> (usize, AirProofInput<SC>) { ... }
}
Expand description

A chip is a stateful struct that stores the state necessary to generate the trace of an AIR. This trait is for proving purposes and has a generic StarkGenericConfig since it needs to know the STARK config.

Required Methods§

Source

fn air(&self) -> Arc<dyn AnyRap<SC>>

Source

fn generate_air_proof_input(self) -> AirProofInput<SC>

Generate all necessary input for proving a single AIR.

Provided Methods§

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementations on Foreign Types§

Source§

impl<SC: StarkGenericConfig, C: Chip<SC>> Chip<SC> for Rc<C>

Source§

impl<SC: StarkGenericConfig, C: Chip<SC>> Chip<SC> for Arc<C>

Source§

impl<SC: StarkGenericConfig, C: Chip<SC>> Chip<SC> for RefCell<C>

Source§

impl<SC: StarkGenericConfig, C: Chip<SC>> Chip<SC> for Mutex<C>

Implementors§