Skip to content

Commit

Permalink
fix serialization
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasxia01 committed Nov 14, 2024
1 parent f1a429d commit c86252b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,12 @@ TYPED_TEST(FlavorSerializationTests, VerificationKeySerialization)
// Set the pcs ptr to null since this will not be reconstructed correctly from buffer
original_vkey.pcs_verification_key = nullptr;

// probably not needed
if constexpr (DoesRecursiveIPA<TypeParam>) {
original_vkey.contains_ipa_claim = 0;
original_vkey.ipa_claim_public_input_indices =
std::array<uint32_t, IPA_CLAIM_SIZE>{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
}
// Populate some non-zero values in the databus_propagation_data to ensure its being handled
if constexpr (IsMegaBuilder<Builder>) {
original_vkey.databus_propagation_data.app_return_data_public_input_idx = 2;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -476,6 +476,8 @@ class UltraFlavor {
const uint64_t pub_inputs_offset,
const bool contains_pairing_point_accumulator,
const PairingPointAccumulatorPubInputIndices& pairing_point_accumulator_public_input_indices,
const bool contains_ipa_claim,
const IPAClaimPubInputIndices& ipa_claim_public_input_indices,
const Commitment& q_m,
const Commitment& q_c,
const Commitment& q_l,
Expand Down Expand Up @@ -503,6 +505,8 @@ class UltraFlavor {
const Commitment& table_4,
const Commitment& lagrange_first,
const Commitment& lagrange_last)
: contains_ipa_claim(contains_ipa_claim)
, ipa_claim_public_input_indices(ipa_claim_public_input_indices)
{
this->circuit_size = circuit_size;
this->log_circuit_size = numeric::get_msb(this->circuit_size);
Expand Down Expand Up @@ -546,6 +550,8 @@ class UltraFlavor {
pub_inputs_offset,
contains_pairing_point_accumulator,
pairing_point_accumulator_public_input_indices,
contains_ipa_claim,
ipa_claim_public_input_indices,
q_m,
q_c,
q_l,
Expand Down

0 comments on commit c86252b

Please sign in to comment.