|
Barretenberg
The ZK-SNARK library at the core of Aztec
|
#include "sumcheck_round.hpp"#include "barretenberg/circuit_checker/circuit_checker.hpp"#include "barretenberg/common/tuple.hpp"#include "barretenberg/flavor/multilinear_batching_flavor.hpp"#include "barretenberg/flavor/sumcheck_test_flavor.hpp"#include "barretenberg/flavor/ultra_recursive_flavor.hpp"#include "barretenberg/relations/utils.hpp"#include <gtest/gtest.h>Go to the source code of this file.
Functions | |
| TEST (SumcheckRound, SumcheckTupleOfTuplesOfUnivariates) | |
| Test SumcheckRound functions for operations on tuples (and tuples of tuples) of Univariates. | |
| TEST (SumcheckRound, TuplesOfEvaluationArrays) | |
| Test utility functions for applying operations to tuple of std::arrays of field elements. | |
| TEST (SumcheckRound, AddTuplesOfTuplesOfUnivariates) | |
| Test utility functions for adding two tuples of tuples of Univariates. | |
| TEST (SumcheckRound, ComputeEffectiveRoundSize) | |
| Test compute_effective_round_size optimization for non-ZK flavors. | |
| TEST (SumcheckRound, ComputeEffectiveRoundSizeZK) | |
| Test that compute_effective_round_size returns full size for ZK flavors. | |
| TEST (SumcheckRound, ExtendEdgesShortMonomial) | |
| Test that extend_edges works correctly in the cases we're using ShortMonomials. | |
| TEST (SumcheckRound, ExtendEdges) | |
| Test extend_edges with full barycentric extension (non-short-monomial flavor) | |
| TEST (SumcheckRound, AccumulateRelationUnivariatesSumcheckTestFlavor) | |
| Test accumulate_relation_univariates for SumcheckTestFlavor. | |
| TEST (SumcheckRound, CheckSumFieldArithmetic) | |
| Test check_sum with field arithmetic edge cases. | |
| TEST (SumcheckRound, CheckSumPaddingIndicator) | |
| Test check_sum with padding indicator. | |
| TEST (SumcheckRound, CheckSumRoundFailurePersistence) | |
| Test round_failed flag persistence in check_sum. | |
| TEST (SumcheckRound, CheckSumRecursiveUnsatisfiableWitness) | |
| Test check_sum in a recursive circuit with unsatisfiable witness. | |
| TEST | ( | SumcheckRound | , |
| AccumulateRelationUnivariatesSumcheckTestFlavor | |||
| ) |
Test accumulate_relation_univariates for SumcheckTestFlavor.
Tests that:
Definition at line 475 of file sumcheck_round.test.cpp.
| TEST | ( | SumcheckRound | , |
| AddTuplesOfTuplesOfUnivariates | |||
| ) |
Test utility functions for adding two tuples of tuples of Univariates.
Definition at line 114 of file sumcheck_round.test.cpp.
| TEST | ( | SumcheckRound | , |
| CheckSumFieldArithmetic | |||
| ) |
Test check_sum with field arithmetic edge cases.
Verifies that check_sum works correctly with large field elements near the modulus
Definition at line 683 of file sumcheck_round.test.cpp.
| TEST | ( | SumcheckRound | , |
| CheckSumPaddingIndicator | |||
| ) |
Test check_sum with padding indicator.
Verifies that padding rounds (indicator=0) bypass the check, while non-padding rounds (indicator=1) perform the check
Definition at line 751 of file sumcheck_round.test.cpp.
| TEST | ( | SumcheckRound | , |
| CheckSumRecursiveUnsatisfiableWitness | |||
| ) |
Test check_sum in a recursive circuit with unsatisfiable witness.
Creates a recursive circuit where check_sum is called with witnesses that don't satisfy the constraint, verifying that the circuit correctly detects the failure.
Definition at line 890 of file sumcheck_round.test.cpp.
| TEST | ( | SumcheckRound | , |
| CheckSumRoundFailurePersistence | |||
| ) |
Test round_failed flag persistence in check_sum.
Verifies that once a check fails, the round_failed flag persists across subsequent checks
Definition at line 825 of file sumcheck_round.test.cpp.
| TEST | ( | SumcheckRound | , |
| ComputeEffectiveRoundSize | |||
| ) |
Test compute_effective_round_size optimization for non-ZK flavors.
This function optimizes sumcheck iteration by only processing up to the active witness region, avoiding iteration over trailing zeros when HasZK is false.
Definition at line 150 of file sumcheck_round.test.cpp.
| TEST | ( | SumcheckRound | , |
| ComputeEffectiveRoundSizeZK | |||
| ) |
Test that compute_effective_round_size returns full size for ZK flavors.
For ZK flavors, we must always iterate over the full round_size including masked rows
Definition at line 314 of file sumcheck_round.test.cpp.
| TEST | ( | SumcheckRound | , |
| ExtendEdges | |||
| ) |
Test extend_edges with full barycentric extension (non-short-monomial flavor)
Uses MultilinearBatchingFlavor which has USE_SHORT_MONOMIALS=false to test that the barycentric extension to MAX_PARTIAL_RELATION_LENGTH works correctly.
Definition at line 405 of file sumcheck_round.test.cpp.
| TEST | ( | SumcheckRound | , |
| ExtendEdgesShortMonomial | |||
| ) |
Test that extend_edges works correctly in the cases we're using ShortMonomials.
Verifies that the barycentric extension preserves the univariate property: the extended univariate should be a degree-1 polynomial that passes through the two given points.
Definition at line 346 of file sumcheck_round.test.cpp.
| TEST | ( | SumcheckRound | , |
| SumcheckTupleOfTuplesOfUnivariates | |||
| ) |
Test SumcheckRound functions for operations on tuples (and tuples of tuples) of Univariates.
Definition at line 17 of file sumcheck_round.test.cpp.
| TEST | ( | SumcheckRound | , |
| TuplesOfEvaluationArrays | |||
| ) |
Test utility functions for applying operations to tuple of std::arrays of field elements.
Definition at line 72 of file sumcheck_round.test.cpp.