Poseidon2Inst

Trait Poseidon2Inst 

Source
pub trait Poseidon2Inst: ChipBase {
    // Required methods
    fn hash_babybear_slice_to_digest(
        &mut self,
        values: &[ReducedBabyBearWire<Self::F>],
    ) -> Self::F;
    fn compress_digests(&mut self, left: Self::F, right: Self::F) -> Self::F;
}
Expand description

Poseidon2 digest hashing/compression mirroring the helpers in hash::poseidon2.

Required Methods§

Source

fn hash_babybear_slice_to_digest( &mut self, values: &[ReducedBabyBearWire<Self::F>], ) -> Self::F

Hash a slice of reduced BabyBear wires into a single Bn254 digest cell.

Source

fn compress_digests(&mut self, left: Self::F, right: Self::F) -> Self::F

Two-to-one Poseidon2 digest compression (Merkle node).

Implementors§