Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
class_id_derivation_trace.cpp
Go to the documentation of this file.
2
3#include <memory>
4
11
12namespace bb::avm2::tracegen {
13
27 TraceContainer& trace)
28{
29 using C = Column;
30
31 uint32_t row = 0;
32 for (const auto& event : events) {
33 trace.set(row,
34 { {
35 { C::class_id_derivation_sel, 1 },
36 // Class ID.
37 { C::class_id_derivation_class_id, event.class_id },
38 // Class members.
39 { C::class_id_derivation_artifact_hash, event.artifact_hash },
40 { C::class_id_derivation_private_functions_root, event.private_functions_root },
41 { C::class_id_derivation_public_bytecode_commitment, event.public_bytecode_commitment },
42 // Constant columns (this is temp because aliasing is not allowed in lookups).
43 { C::class_id_derivation_gen_index_contract_class_id, DOM_SEP__CONTRACT_CLASS_ID },
44 { C::class_id_derivation_const_four, 4 },
45 } });
46 row++;
47 }
48}
49
53 .add<lookup_class_id_derivation_class_id_poseidon2_1_settings, InteractionType::LookupSequential>();
54
55} // namespace bb::avm2::tracegen
#define DOM_SEP__CONTRACT_CLASS_ID
void process(const simulation::EventEmitterInterface< simulation::ClassIdDerivationEvent >::Container &events, TraceContainer &trace)
Process class id derivation events and populate the relevant columns in the trace....
InteractionDefinition & add(auto &&... args)
TestTraceContainer trace
lookup_settings< lookup_class_id_derivation_class_id_poseidon2_0_settings_ > lookup_class_id_derivation_class_id_poseidon2_0_settings
simulation::PublicDataTreeReadWriteEvent event