Skip to content

Commit

Permalink
Fix prover segfault
Browse files Browse the repository at this point in the history
  • Loading branch information
x-mass committed Jul 17, 2024
1 parent 4e7dc62 commit eebc17d
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,6 @@ namespace nil {
, _is_lookup_enabled(constraint_system.lookup_gates().size() > 0)
, _commitment_scheme(commitment_scheme)
{
std::cout << "Table has " << table_description.rows_amount << " rows." << std::endl;

// Initialize transcript.
transcript(preprocessed_public_data.common_data.vk.constraint_system_with_params_hash);
Expand Down Expand Up @@ -197,7 +196,6 @@ namespace nil {
{
std::vector<polynomial_dfs_type> T_splitted_dfs =
quotient_polynomial_split_dfs();

_proof.commitments[QUOTIENT_BATCH] = T_commit(T_splitted_dfs);
}
transcript(_proof.commitments[QUOTIENT_BATCH]);
Expand All @@ -206,7 +204,6 @@ namespace nil {
_proof.eval_proof.challenge = transcript.template challenge<FieldType>();

generate_evaluation_points();

{
PROFILE_PLACEHOLDER_SCOPE("commitment scheme proof eval time");
_proof.eval_proof.eval_proof = _commitment_scheme.proof_eval(transcript);
Expand Down Expand Up @@ -236,7 +233,7 @@ namespace nil {
(split_polynomial_size / preprocessed_public_data.common_data.desc.rows_amount + 1):
(split_polynomial_size / preprocessed_public_data.common_data.desc.rows_amount);

if (preprocessed_public_data.common_data.max_quotient_chunks != 0 &&
if (preprocessed_public_data.common_data.max_quotient_chunks != 0 &&
split_polynomial_size > preprocessed_public_data.common_data.max_quotient_chunks) {
split_polynomial_size = preprocessed_public_data.common_data.max_quotient_chunks;
}
Expand All @@ -254,6 +251,9 @@ namespace nil {
T_splitted_dfs[k].from_coefficients(T_splitted[k]);
}, ThreadPool::PoolLevel::HIGH);

// DO NOT CHANGE, sizes are different by design
T_splitted_dfs.resize(split_polynomial_size);

return T_splitted_dfs;
}

Expand Down

0 comments on commit eebc17d

Please sign in to comment.