|
Barretenberg
The ZK-SNARK library at the core of Aztec
|
#include <eccvm_circuit_builder.hpp>
Public Types | |
| using | CycleGroup = bb::g1 |
| using | FF = grumpkin::fr |
| using | Polynomial = bb::Polynomial< FF > |
| using | CycleScalar = typename CycleGroup::Fr |
| using | Element = typename CycleGroup::element |
| using | AffineElement = typename CycleGroup::affine_element |
| using | ScalarMul = bb::eccvm::ScalarMul< CycleGroup > |
| using | MSM = bb::eccvm::MSM< CycleGroup > |
Public Member Functions | |
| ECCVMCircuitBuilder (std::shared_ptr< ECCOpQueue > &op_queue) | |
| uint32_t | get_number_of_muls () const |
| std::vector< MSM > | get_msms () const |
| size_t | get_estimated_num_finalized_gates () const |
| size_t | get_circuit_subgroup_size (const size_t num_rows) const |
Static Public Member Functions | |
| static std::vector< ScalarMul > | get_flattened_scalar_muls (const std::vector< MSM > &msms) |
Public Attributes | |
| std::shared_ptr< ECCOpQueue > | op_queue |
Static Public Attributes | |
| static constexpr size_t | NUM_SCALAR_BITS = bb::eccvm::NUM_SCALAR_BITS |
| static constexpr size_t | NUM_WNAF_DIGIT_BITS = bb::eccvm::NUM_WNAF_DIGIT_BITS |
| static constexpr size_t | NUM_WNAF_DIGITS_PER_SCALAR = bb::eccvm::NUM_WNAF_DIGITS_PER_SCALAR |
| static constexpr uint64_t | WNAF_MASK = bb::eccvm::WNAF_MASK |
| static constexpr size_t | POINT_TABLE_SIZE = bb::eccvm::POINT_TABLE_SIZE |
| static constexpr size_t | WNAF_DIGITS_PER_ROW = bb::eccvm::WNAF_DIGITS_PER_ROW |
| static constexpr size_t | ADDITIONS_PER_ROW = bb::eccvm::ADDITIONS_PER_ROW |
Definition at line 24 of file eccvm_circuit_builder.hpp.
| using bb::ECCVMCircuitBuilder::AffineElement = typename CycleGroup::affine_element |
Definition at line 32 of file eccvm_circuit_builder.hpp.
Definition at line 26 of file eccvm_circuit_builder.hpp.
| using bb::ECCVMCircuitBuilder::CycleScalar = typename CycleGroup::Fr |
Definition at line 30 of file eccvm_circuit_builder.hpp.
| using bb::ECCVMCircuitBuilder::Element = typename CycleGroup::element |
Definition at line 31 of file eccvm_circuit_builder.hpp.
Definition at line 27 of file eccvm_circuit_builder.hpp.
Definition at line 47 of file eccvm_circuit_builder.hpp.
Definition at line 28 of file eccvm_circuit_builder.hpp.
Definition at line 45 of file eccvm_circuit_builder.hpp.
|
inline |
Definition at line 48 of file eccvm_circuit_builder.hpp.
|
inline |
Definition at line 260 of file eccvm_circuit_builder.hpp.
|
inline |
Definition at line 253 of file eccvm_circuit_builder.hpp.
|
inlinestatic |
Definition at line 242 of file eccvm_circuit_builder.hpp.
|
inline |
For input point [P], return { -15[P], -13[P], ..., -[P], [P], ..., 13[P], 15[P] } this "precomputed table" will be an entry in ScalarMuls corresponding to [P]
Computes the WNAF representation of scalar. When scalar is even, we represent this by adding 1 to the least-significant slice. we will also later set the skew boolean to True when we populate ScalarMul. (this is necessary because otherwise we would only be able to represent odd multiples of our point.) Note also that in our applications, NUM_WNAF_DIGITS_PER_SCALAR = 32; this corresponds to the fact that we split up our scalar into two 128 bit numbers, using the endomorphism of the curve (corresponding to a primitive cube root of unity).
Definition at line 53 of file eccvm_circuit_builder.hpp.
|
inline |
Definition at line 51 of file eccvm_circuit_builder.hpp.
|
staticconstexpr |
Definition at line 40 of file eccvm_circuit_builder.hpp.
|
staticconstexpr |
Definition at line 34 of file eccvm_circuit_builder.hpp.
|
staticconstexpr |
Definition at line 35 of file eccvm_circuit_builder.hpp.
|
staticconstexpr |
Definition at line 36 of file eccvm_circuit_builder.hpp.
| std::shared_ptr<ECCOpQueue> bb::ECCVMCircuitBuilder::op_queue |
Definition at line 42 of file eccvm_circuit_builder.hpp.
|
staticconstexpr |
Definition at line 38 of file eccvm_circuit_builder.hpp.
|
staticconstexpr |
Definition at line 39 of file eccvm_circuit_builder.hpp.
|
staticconstexpr |
Definition at line 37 of file eccvm_circuit_builder.hpp.