pub struct LookupConstraintSystem<F: FftField> {
pub lookup_table: Vec<DensePolynomial<F>>,
pub lookup_table8: Vec<Evaluations<F, Radix2EvaluationDomain<F>>>,
pub table_ids: Option<DensePolynomial<F>>,
pub table_ids8: Option<Evaluations<F, Radix2EvaluationDomain<F>>>,
pub lookup_selectors: LookupSelectors<Evaluations<F, Radix2EvaluationDomain<F>>>,
pub runtime_selector: Option<Evaluations<F, Radix2EvaluationDomain<F>>>,
pub runtime_tables: Option<Vec<RuntimeTableSpec>>,
pub runtime_table_offset: Option<usize>,
pub configuration: LookupConfiguration<F>,
}
Fields§
§lookup_table: Vec<DensePolynomial<F>>
Lookup tables
lookup_table8: Vec<Evaluations<F, Radix2EvaluationDomain<F>>>
§table_ids: Option<DensePolynomial<F>>
Table IDs for the lookup values.
This may be None
if all lookups originate from table 0.
table_ids8: Option<Evaluations<F, Radix2EvaluationDomain<F>>>
§lookup_selectors: LookupSelectors<Evaluations<F, Radix2EvaluationDomain<F>>>
Lookup selectors: For each kind of lookup-pattern, we have a selector that’s 1 at the rows where that pattern should be enforced, and 0 at all other rows.
runtime_selector: Option<Evaluations<F, Radix2EvaluationDomain<F>>>
An optional runtime table selector. It is 0 everywhere, except at the rows where the runtime tables apply.
runtime_tables: Option<Vec<RuntimeTableSpec>>
Optional runtime tables, listed as tuples (length, id)
.
runtime_table_offset: Option<usize>
The offset of the runtime table within the concatenated table
configuration: LookupConfiguration<F>
Configuration for the lookup constraint.
Implementations§
Source§impl<F: PrimeField> LookupConstraintSystem<F>
impl<F: PrimeField> LookupConstraintSystem<F>
Sourcepub fn create(
gates: &[CircuitGate<F>],
fixed_lookup_tables: Vec<LookupTable<F>>,
runtime_tables: Option<Vec<RuntimeTableCfg<F>>>,
domain: &EvaluationDomains<F>,
zk_rows: usize,
) -> Result<Option<Self>, LookupError>
pub fn create( gates: &[CircuitGate<F>], fixed_lookup_tables: Vec<LookupTable<F>>, runtime_tables: Option<Vec<RuntimeTableCfg<F>>>, domain: &EvaluationDomains<F>, zk_rows: usize, ) -> Result<Option<Self>, LookupError>
Trait Implementations§
Source§impl<F: Clone + FftField> Clone for LookupConstraintSystem<F>
impl<F: Clone + FftField> Clone for LookupConstraintSystem<F>
Source§fn clone(&self) -> LookupConstraintSystem<F>
fn clone(&self) -> LookupConstraintSystem<F>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl<F: Debug + FftField> Debug for LookupConstraintSystem<F>
impl<F: Debug + FftField> Debug for LookupConstraintSystem<F>
Source§impl<'de, F> Deserialize<'de> for LookupConstraintSystem<F>
impl<'de, F> Deserialize<'de> for LookupConstraintSystem<F>
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl<F: FftField> Serialize for LookupConstraintSystem<F>
impl<F: FftField> Serialize for LookupConstraintSystem<F>
Auto Trait Implementations§
impl<F> Freeze for LookupConstraintSystem<F>where
F: Freeze,
impl<F> RefUnwindSafe for LookupConstraintSystem<F>where
F: RefUnwindSafe,
impl<F> Send for LookupConstraintSystem<F>
impl<F> Sync for LookupConstraintSystem<F>
impl<F> Unpin for LookupConstraintSystem<F>where
F: Unpin,
impl<F> UnwindSafe for LookupConstraintSystem<F>where
F: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more