-
Notifications
You must be signed in to change notification settings - Fork 191
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
feat: eccvm translator zk sumcheck #9199
base: master
Are you sure you want to change the base?
Conversation
@@ -65,8 +65,8 @@ void eccvm_prove(State& state) noexcept | |||
}; | |||
} | |||
|
|||
BENCHMARK(eccvm_generate_prover)->Unit(kMillisecond)->DenseRange(10, 20); | |||
BENCHMARK(eccvm_prove)->Unit(kMillisecond)->DenseRange(10, 20); | |||
BENCHMARK(eccvm_generate_prover)->Unit(kMillisecond)->DenseRange(12, 18); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The proving is quite slow and the time grows somewhat predictably.
std::get<0>(accumulator) += | ||
((z_perm + lagrange_first) * numerator_evaluation - (z_perm_shift + lagrange_last) * denominator_evaluation) * | ||
scaling_factor; | ||
|
||
// Contribution (2) | ||
std::get<1>(accumulator) += (lagrange_last * z_perm_shift) * scaling_factor; | ||
std::get<1>(accumulator) += lagrange_last_short * z_perm_shift_short * scaling_factor; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Small optimization: taken into account the fact that the second component of the accumulator is actually of a much smaller degree ( 2 )
@@ -70,7 +70,7 @@ template <typename Flavor> void ECCVMRecursiveVerifier_<Flavor>::verify_proof(co | |||
gate_challenges[idx] = transcript->template get_challenge<FF>("Sumcheck:gate_challenge_" + std::to_string(idx)); | |||
} | |||
|
|||
auto [multivariate_challenge, claimed_evaluations, sumcheck_verified] = | |||
auto [multivariate_challenge, claimed_evaluations, libra_evaluations, sumcheck_verified] = |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
here, the sumcheck verifier is getting evaluations of univariates that are used to mask sumcheck round univariates
transcript->send_to_verifier("Libra:evaluations", zk_sumcheck_data.libra_evaluations); | ||
for (size_t idx = 0; idx < multivariate_d; idx++) { | ||
const FF& libra_evaluation = zk_sumcheck_data.libra_evaluations[idx]; | ||
std::string libra_evaluation_label = "Libra:evaluation_" + std::to_string(idx); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed a discrepancy in the way the prover and the verifer send/receive these evals
…tocol/aztec-packages into si/eccvm-translator-zk-sumcheck
Turned on ZK Sumcheck in ECCVM and Translator Flavors.
Benching
ClientIvc
with ZK sumcheck turned on in ECCVM and Translator:*Using non-optimized ZK Sumcheck