Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
bb::avm2::tracegen::GreaterThanTraceBuilder Class Referencefinal

#include <gt_trace.hpp>

Public Member Functions

void process (const simulation::EventEmitterInterface< simulation::GreaterThanEvent >::Container &events, TraceContainer &trace)
 Process the greater-than events and populate the relevant columns in the trace.
 

Static Public Attributes

static const InteractionDefinition interactions
 

Detailed Description

Definition at line 10 of file gt_trace.hpp.

Member Function Documentation

◆ process()

void bb::avm2::tracegen::GreaterThanTraceBuilder::process ( const simulation::EventEmitterInterface< simulation::GreaterThanEvent >::Container &  events,
TraceContainer trace 
)

Process the greater-than events and populate the relevant columns in the trace.

For each event, computes the absolute difference (a - b - 1 if a > b, or b - a otherwise) and the smallest multiple-of-16 bit width that bounds it. Each event produces one trace row with columns: gt_sel, gt_input_a, gt_input_b, gt_res, gt_abs_diff, gt_num_bits.

Parameters
eventsContainer of GreaterThanEvent to process.
traceThe trace container to populate with generated rows.

Definition at line 20 of file gt_trace.cpp.

Member Data Documentation

◆ interactions

const InteractionDefinition bb::avm2::tracegen::GreaterThanTraceBuilder::interactions
static
Initial value:
=
InteractionDefinition().add<lookup_gt_gt_range_settings, InteractionType::LookupGeneric>(Column::range_check_sel)
lookup_settings< lookup_gt_gt_range_settings_ > lookup_gt_gt_range_settings

Definition at line 15 of file gt_trace.hpp.


The documentation for this class was generated from the following files: