PhantomSubExecutor

Trait PhantomSubExecutor 

Source
pub trait PhantomSubExecutor<F>: Send + Sync {
    // Required method
    fn phantom_execute(
        &self,
        memory: &GuestMemory,
        streams: &mut Streams<F>,
        rng: &mut StdRng,
        discriminant: PhantomDiscriminant,
        a: u32,
        b: u32,
        c_upper: u16,
    ) -> Result<()>;
}
Expand description

Phantom sub-instructions affect the runtime of the VM and the trace matrix values. However they all have no AIR constraints besides advancing the pc by DEFAULT_PC_STEP.

They should not mutate memory, but they can mutate the input & hint streams.

Phantom sub-instructions are only allowed to use operands a,b and c_upper = c.as_canonical_u32() >> 16.

Required Methods§

Source

fn phantom_execute( &self, memory: &GuestMemory, streams: &mut Streams<F>, rng: &mut StdRng, discriminant: PhantomDiscriminant, a: u32, b: u32, c_upper: u16, ) -> Result<()>

Implementors§