This file contains functions for the dummy tables that we use in UltraHonk to make table, sorted and lookup selector polynomials non-zero.
More...
#include "types.hpp"
Go to the source code of this file.
This file contains functions for the dummy tables that we use in UltraHonk to make table, sorted and lookup selector polynomials non-zero.
- Author
- Rumata888
◆ generate_honk_dummy_table()
template<uint64_t table_id>
| BasicTable plookup::dummy_tables::generate_honk_dummy_table |
( |
const BasicTableId |
id, |
|
|
const size_t |
table_index |
|
) |
| |
|
inline |
Generate the whole table.
This function is used to generate the whole table for the table polynomial. It's templated with id, since we generate 2 slightly different fake tables.
- Template Parameters
-
| table_id | The id of the table this function is instantiated for |
- Parameters
-
| id | Table id that is the same for all circuits |
| table_index | The index for this table that is used in this circuit. 0, 1, ... |
- Returns
- A table of values
◆ get_honk_dummy_multitable()
| MultiTable plookup::dummy_tables::get_honk_dummy_multitable |
( |
| ) |
|
|
inline |
Create a multitable for filling UltraHonk polynomials with non-zero values.
Consists of 2 Basic tables that are almost identical. Each of those basic tables should only have 4 entries, so the overall overhead is just 8
◆ get_value_from_key()
template<uint64_t id>
| std::array< barretenberg::fr, 2 > plookup::dummy_tables::get_value_from_key |
( |
const std::array< uint64_t, 2 > |
key | ) |
|
|
inline |
Lookup the value corresponding to a specific key.
We need this function for when we are constructing the circuit and want to query the table. Since we need two basic tables to make the table polynomial have non-zero values, we instantiate two tables with the same function, but change it slightly through templating
- Template Parameters
-
| id | The id of the basic table used to parametrize the values for 2 fake tables |
- Parameters
-
| key | The key that we are looking up |
- Returns
- std::array<barretenberg::fr, 2>