Barretenberg
The ZK-SNARK library at the core of Aztec
Loading...
Searching...
No Matches
lookups_written_public_data_slots_tree_check.hpp
Go to the documentation of this file.
1// AUTOGENERATED FILE
2#pragma once
3
4#include <cstddef>
5#include <string_view>
6#include <tuple>
7
8#include "../columns.hpp"
11
12namespace bb::avm2 {
13
15
17 static constexpr std::string_view NAME = "LOOKUP_WRITTEN_PUBLIC_DATA_SLOTS_TREE_CHECK_SILO_POSEIDON2";
18 static constexpr std::string_view RELATION_NAME = "written_public_data_slots_tree_check";
19 static constexpr size_t LOOKUP_TUPLE_SIZE = 5;
20 static constexpr Column SRC_SELECTOR = Column::written_public_data_slots_tree_check_sel;
21 static constexpr Column DST_SELECTOR = Column::poseidon2_hash_end;
22 static constexpr Column COUNTS = Column::lookup_written_public_data_slots_tree_check_silo_poseidon2_counts;
23 static constexpr Column INVERSES = Column::lookup_written_public_data_slots_tree_check_silo_poseidon2_inv;
24 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> SRC_COLUMNS = {
25 ColumnAndShifts::written_public_data_slots_tree_check_sel,
26 ColumnAndShifts::written_public_data_slots_tree_check_siloing_separator,
27 ColumnAndShifts::written_public_data_slots_tree_check_address,
28 ColumnAndShifts::written_public_data_slots_tree_check_slot,
29 ColumnAndShifts::written_public_data_slots_tree_check_leaf_slot
30 };
31 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> DST_COLUMNS = {
32 ColumnAndShifts::poseidon2_hash_start,
33 ColumnAndShifts::poseidon2_hash_input_0,
34 ColumnAndShifts::poseidon2_hash_input_1,
35 ColumnAndShifts::poseidon2_hash_input_2,
36 ColumnAndShifts::poseidon2_hash_output
37 };
38};
39
42template <typename FF_>
45
47
49 static constexpr std::string_view NAME = "LOOKUP_WRITTEN_PUBLIC_DATA_SLOTS_TREE_CHECK_LOW_LEAF_POSEIDON2";
50 static constexpr std::string_view RELATION_NAME = "written_public_data_slots_tree_check";
51 static constexpr size_t LOOKUP_TUPLE_SIZE = 5;
52 static constexpr Column SRC_SELECTOR = Column::written_public_data_slots_tree_check_sel;
53 static constexpr Column DST_SELECTOR = Column::poseidon2_hash_end;
54 static constexpr Column COUNTS = Column::lookup_written_public_data_slots_tree_check_low_leaf_poseidon2_counts;
55 static constexpr Column INVERSES = Column::lookup_written_public_data_slots_tree_check_low_leaf_poseidon2_inv;
56 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> SRC_COLUMNS = {
57 ColumnAndShifts::written_public_data_slots_tree_check_sel,
58 ColumnAndShifts::written_public_data_slots_tree_check_low_leaf_slot,
59 ColumnAndShifts::written_public_data_slots_tree_check_low_leaf_next_slot,
60 ColumnAndShifts::written_public_data_slots_tree_check_low_leaf_next_index,
61 ColumnAndShifts::written_public_data_slots_tree_check_low_leaf_hash
62 };
63 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> DST_COLUMNS = {
64 ColumnAndShifts::poseidon2_hash_start,
65 ColumnAndShifts::poseidon2_hash_input_0,
66 ColumnAndShifts::poseidon2_hash_input_1,
67 ColumnAndShifts::poseidon2_hash_input_2,
68 ColumnAndShifts::poseidon2_hash_output
69 };
70};
71
74template <typename FF_>
77
79
81 static constexpr std::string_view NAME = "LOOKUP_WRITTEN_PUBLIC_DATA_SLOTS_TREE_CHECK_UPDATED_LOW_LEAF_POSEIDON2";
82 static constexpr std::string_view RELATION_NAME = "written_public_data_slots_tree_check";
83 static constexpr size_t LOOKUP_TUPLE_SIZE = 5;
84 static constexpr Column SRC_SELECTOR = Column::written_public_data_slots_tree_check_should_insert;
85 static constexpr Column DST_SELECTOR = Column::poseidon2_hash_end;
86 static constexpr Column COUNTS =
87 Column::lookup_written_public_data_slots_tree_check_updated_low_leaf_poseidon2_counts;
88 static constexpr Column INVERSES =
89 Column::lookup_written_public_data_slots_tree_check_updated_low_leaf_poseidon2_inv;
90 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> SRC_COLUMNS = {
91 ColumnAndShifts::written_public_data_slots_tree_check_sel,
92 ColumnAndShifts::written_public_data_slots_tree_check_low_leaf_slot,
93 ColumnAndShifts::written_public_data_slots_tree_check_updated_low_leaf_next_slot,
94 ColumnAndShifts::written_public_data_slots_tree_check_updated_low_leaf_next_index,
95 ColumnAndShifts::written_public_data_slots_tree_check_updated_low_leaf_hash
96 };
97 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> DST_COLUMNS = {
98 ColumnAndShifts::poseidon2_hash_start,
99 ColumnAndShifts::poseidon2_hash_input_0,
100 ColumnAndShifts::poseidon2_hash_input_1,
101 ColumnAndShifts::poseidon2_hash_input_2,
102 ColumnAndShifts::poseidon2_hash_output
103 };
104};
105
108template <typename FF_>
111
113
115 static constexpr std::string_view NAME = "LOOKUP_WRITTEN_PUBLIC_DATA_SLOTS_TREE_CHECK_LOW_LEAF_MERKLE_CHECK";
116 static constexpr std::string_view RELATION_NAME = "written_public_data_slots_tree_check";
117 static constexpr size_t LOOKUP_TUPLE_SIZE = 7;
118 static constexpr Column SRC_SELECTOR = Column::written_public_data_slots_tree_check_sel;
119 static constexpr Column DST_SELECTOR = Column::merkle_check_start;
120 static constexpr Column COUNTS = Column::lookup_written_public_data_slots_tree_check_low_leaf_merkle_check_counts;
121 static constexpr Column INVERSES = Column::lookup_written_public_data_slots_tree_check_low_leaf_merkle_check_inv;
122 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> SRC_COLUMNS = {
123 ColumnAndShifts::written_public_data_slots_tree_check_should_insert,
124 ColumnAndShifts::written_public_data_slots_tree_check_low_leaf_hash,
125 ColumnAndShifts::written_public_data_slots_tree_check_updated_low_leaf_hash,
126 ColumnAndShifts::written_public_data_slots_tree_check_low_leaf_index,
127 ColumnAndShifts::written_public_data_slots_tree_check_tree_height,
128 ColumnAndShifts::written_public_data_slots_tree_check_root,
129 ColumnAndShifts::written_public_data_slots_tree_check_intermediate_root
130 };
131 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> DST_COLUMNS = {
132 ColumnAndShifts::merkle_check_write, ColumnAndShifts::merkle_check_read_node,
133 ColumnAndShifts::merkle_check_write_node, ColumnAndShifts::merkle_check_index,
134 ColumnAndShifts::merkle_check_path_len, ColumnAndShifts::merkle_check_read_root,
135 ColumnAndShifts::merkle_check_write_root
136 };
137};
138
141template <typename FF_>
144
146
148 static constexpr std::string_view NAME = "LOOKUP_WRITTEN_PUBLIC_DATA_SLOTS_TREE_CHECK_LOW_LEAF_SLOT_VALIDATION";
149 static constexpr std::string_view RELATION_NAME = "written_public_data_slots_tree_check";
150 static constexpr size_t LOOKUP_TUPLE_SIZE = 3;
151 static constexpr Column SRC_SELECTOR = Column::written_public_data_slots_tree_check_leaf_not_exists;
152 static constexpr Column DST_SELECTOR = Column::ff_gt_sel_gt;
153 static constexpr Column COUNTS =
154 Column::lookup_written_public_data_slots_tree_check_low_leaf_slot_validation_counts;
155 static constexpr Column INVERSES = Column::lookup_written_public_data_slots_tree_check_low_leaf_slot_validation_inv;
156 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> SRC_COLUMNS = {
157 ColumnAndShifts::written_public_data_slots_tree_check_leaf_slot,
158 ColumnAndShifts::written_public_data_slots_tree_check_low_leaf_slot,
159 ColumnAndShifts::written_public_data_slots_tree_check_sel
160 };
161 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> DST_COLUMNS = { ColumnAndShifts::ff_gt_a,
162 ColumnAndShifts::ff_gt_b,
163 ColumnAndShifts::ff_gt_result };
164};
165
168template <typename FF_>
171
173
175 static constexpr std::string_view NAME =
176 "LOOKUP_WRITTEN_PUBLIC_DATA_SLOTS_TREE_CHECK_LOW_LEAF_NEXT_SLOT_VALIDATION";
177 static constexpr std::string_view RELATION_NAME = "written_public_data_slots_tree_check";
178 static constexpr size_t LOOKUP_TUPLE_SIZE = 3;
179 static constexpr Column SRC_SELECTOR = Column::written_public_data_slots_tree_check_next_slot_is_nonzero;
180 static constexpr Column DST_SELECTOR = Column::ff_gt_sel_gt;
181 static constexpr Column COUNTS =
182 Column::lookup_written_public_data_slots_tree_check_low_leaf_next_slot_validation_counts;
183 static constexpr Column INVERSES =
184 Column::lookup_written_public_data_slots_tree_check_low_leaf_next_slot_validation_inv;
185 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> SRC_COLUMNS = {
186 ColumnAndShifts::written_public_data_slots_tree_check_low_leaf_next_slot,
187 ColumnAndShifts::written_public_data_slots_tree_check_leaf_slot,
188 ColumnAndShifts::written_public_data_slots_tree_check_sel
189 };
190 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> DST_COLUMNS = { ColumnAndShifts::ff_gt_a,
191 ColumnAndShifts::ff_gt_b,
192 ColumnAndShifts::ff_gt_result };
193};
194
197template <typename FF_>
200
202
204 static constexpr std::string_view NAME = "LOOKUP_WRITTEN_PUBLIC_DATA_SLOTS_TREE_CHECK_NEW_LEAF_POSEIDON2";
205 static constexpr std::string_view RELATION_NAME = "written_public_data_slots_tree_check";
206 static constexpr size_t LOOKUP_TUPLE_SIZE = 5;
207 static constexpr Column SRC_SELECTOR = Column::written_public_data_slots_tree_check_should_insert;
208 static constexpr Column DST_SELECTOR = Column::poseidon2_hash_end;
209 static constexpr Column COUNTS = Column::lookup_written_public_data_slots_tree_check_new_leaf_poseidon2_counts;
210 static constexpr Column INVERSES = Column::lookup_written_public_data_slots_tree_check_new_leaf_poseidon2_inv;
211 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> SRC_COLUMNS = {
212 ColumnAndShifts::written_public_data_slots_tree_check_sel,
213 ColumnAndShifts::written_public_data_slots_tree_check_leaf_slot,
214 ColumnAndShifts::written_public_data_slots_tree_check_low_leaf_next_slot,
215 ColumnAndShifts::written_public_data_slots_tree_check_low_leaf_next_index,
216 ColumnAndShifts::written_public_data_slots_tree_check_new_leaf_hash
217 };
218 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> DST_COLUMNS = {
219 ColumnAndShifts::poseidon2_hash_start,
220 ColumnAndShifts::poseidon2_hash_input_0,
221 ColumnAndShifts::poseidon2_hash_input_1,
222 ColumnAndShifts::poseidon2_hash_input_2,
223 ColumnAndShifts::poseidon2_hash_output
224 };
225};
226
229template <typename FF_>
232
234
236 static constexpr std::string_view NAME = "LOOKUP_WRITTEN_PUBLIC_DATA_SLOTS_TREE_CHECK_NEW_LEAF_MERKLE_CHECK";
237 static constexpr std::string_view RELATION_NAME = "written_public_data_slots_tree_check";
238 static constexpr size_t LOOKUP_TUPLE_SIZE = 7;
239 static constexpr Column SRC_SELECTOR = Column::written_public_data_slots_tree_check_should_insert;
240 static constexpr Column DST_SELECTOR = Column::merkle_check_start;
241 static constexpr Column COUNTS = Column::lookup_written_public_data_slots_tree_check_new_leaf_merkle_check_counts;
242 static constexpr Column INVERSES = Column::lookup_written_public_data_slots_tree_check_new_leaf_merkle_check_inv;
243 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> SRC_COLUMNS = {
244 ColumnAndShifts::written_public_data_slots_tree_check_sel,
245 ColumnAndShifts::precomputed_zero,
246 ColumnAndShifts::written_public_data_slots_tree_check_new_leaf_hash,
247 ColumnAndShifts::written_public_data_slots_tree_check_tree_size_before_write,
248 ColumnAndShifts::written_public_data_slots_tree_check_tree_height,
249 ColumnAndShifts::written_public_data_slots_tree_check_intermediate_root,
250 ColumnAndShifts::written_public_data_slots_tree_check_write_root
251 };
252 static constexpr std::array<ColumnAndShifts, LOOKUP_TUPLE_SIZE> DST_COLUMNS = {
253 ColumnAndShifts::merkle_check_write, ColumnAndShifts::merkle_check_read_node,
254 ColumnAndShifts::merkle_check_write_node, ColumnAndShifts::merkle_check_index,
255 ColumnAndShifts::merkle_check_path_len, ColumnAndShifts::merkle_check_read_root,
256 ColumnAndShifts::merkle_check_write_root
257 };
258};
259
262template <typename FF_>
265
266} // namespace bb::avm2
This file contains the template for the generic lookup that can be specialized to enforce various loo...