Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Remove unused methods and small state cleanup #8968

Merged
merged 3 commits into from
Oct 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ namespace bb {
template <typename Flavor> void compute_concatenated_polynomials(typename Flavor::ProverPolynomials& polynomials)
{
// Concatenation groups are vectors of polynomials that are concatenated together
auto concatenation_groups = polynomials.get_concatenation_groups();
auto concatenation_groups = polynomials.get_groups_to_be_concatenated();

// Resulting concatenated polynomials
auto targets = polynomials.get_concatenated_constraints();
auto targets = polynomials.get_concatenated();

// Targets have to be full-sized polynomials. We can compute the mini circuit size from them by dividing by
// concatenation index
Expand Down Expand Up @@ -116,7 +116,7 @@ void compute_translator_range_constraint_ordered_polynomials(typename Flavor::Pr
std::vector<size_t> extra_denominator_uint(full_circuit_size);

// Get information which polynomials need to be concatenated
auto concatenation_groups = polynomials.get_concatenation_groups();
auto concatenation_groups = polynomials.get_groups_to_be_concatenated();

// A function that transfers elements from each of the polynomials in the chosen concatenation group in the uint
// ordered polynomials
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -125,8 +125,8 @@ std::array<typename Flavor::GroupElement, 2> TranslatorRecursiveVerifier_<Flavor
multivariate_challenge,
Commitment::one(builder),
transcript,
commitments.get_concatenation_groups(),
claimed_evaluations.get_concatenated_constraints());
commitments.get_groups_to_be_concatenated(),
claimed_evaluations.get_concatenated());
auto pairing_points = PCS::reduce_verify(opening_claim, transcript);

return pairing_points;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ TEST_F(TranslatorRelationCorrectnessTests, Permutation)
using Flavor = TranslatorFlavor;
using FF = typename Flavor::FF;
using ProverPolynomials = typename Flavor::ProverPolynomials;
using ProvingKey = typename Flavor::ProvingKey;
using Polynomial = bb::Polynomial<FF>;
auto& engine = numeric::get_debug_randomness();
const size_t mini_circuit_size = 2048;
Expand All @@ -56,7 +57,9 @@ TEST_F(TranslatorRelationCorrectnessTests, Permutation)
params.gamma = gamma;

// Create storage for polynomials
ProverPolynomials prover_polynomials;
auto proving_key = std::make_shared<ProvingKey>();

ProverPolynomials& prover_polynomials = proving_key->polynomials;
// ensure we can shift these
for (Polynomial& prover_poly : prover_polynomials.get_to_be_shifted()) {
prover_poly = Polynomial::shiftable(full_circuit_size);
Expand Down Expand Up @@ -147,7 +150,7 @@ TEST_F(TranslatorRelationCorrectnessTests, Permutation)
compute_translator_range_constraint_ordered_polynomials<Flavor>(prover_polynomials, mini_circuit_size);

// Compute the fixed numerator (part of verification key)
prover_polynomials.compute_extra_range_constraint_numerator();
proving_key->compute_extra_range_constraint_numerator();

// Compute concatenated polynomials (4 polynomials produced from other constraint polynomials by concatenation)
compute_concatenated_polynomials<Flavor>(prover_polynomials);
Expand Down Expand Up @@ -221,8 +224,8 @@ TEST_F(TranslatorRelationCorrectnessTests, DeltaRangeConstraint)
prover_polynomials.ordered_range_constraints_0.coeffs().begin(),
[](uint64_t in) { return FF(in); });

// Copy the same polynomial into the 4 other ordered polynomials (they are not the same in an actual proof, but we
// only need to check the correctness of the relation and it acts independently on each polynomial)
// Copy the same polynomial into the 4 other ordered polynomials (they are not the same in an actual proof, but
// we only need to check the correctness of the relation and it acts independently on each polynomial)
parallel_for(4, [&](size_t i) {
std::copy(prover_polynomials.ordered_range_constraints_0.coeffs().begin(),
prover_polynomials.ordered_range_constraints_0.coeffs().end(),
Expand Down
Loading
Loading