From b747bfcc7d34769d146ac70743e7332c4887bbb6 Mon Sep 17 00:00:00 2001 From: IlyasRidhuan Date: Mon, 24 Jun 2024 15:09:29 +0000 Subject: [PATCH 1/4] feat(avm): poseidon2 constraints --- .../cpp/pil/avm/gadgets/poseidon2.pil | 1298 ++++- .../cpp/pil/avm/gadgets/poseidon2_params.pil | 336 ++ .../relations/generated/avm/declare_views.hpp | 512 ++ .../vm/avm/generated/full_row.cpp | 642 ++ .../barretenberg/vm/avm/generated/prover.cpp | 775 +++ .../vm/generated/avm_circuit_builder.hpp | 941 +++ .../barretenberg/vm/generated/avm_flavor.hpp | 5191 +++++++++++++++++ .../vm/generated/avm_verifier.cpp | 786 +++ .../srs_db/grumpkin/monomial/transcript00.dat | Bin 0 -> 92 bytes 9 files changed, 10479 insertions(+), 2 deletions(-) create mode 100644 barretenberg/cpp/pil/avm/gadgets/poseidon2_params.pil create mode 100644 barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp create mode 100644 barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp create mode 100644 barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp create mode 100644 barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp create mode 100644 barretenberg/srs_db/grumpkin/monomial/transcript00.dat diff --git a/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil b/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil index b89685bc018f..3f8283674fa8 100644 --- a/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil +++ b/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil @@ -1,11 +1,1305 @@ +include "poseidon2_params.pil"; + namespace poseidon2(256); pol commit clk; - // Selector for Radix Operation + // Selector for poseidon2 operation pol commit sel_poseidon_perm; + // Selector is boolean sel_poseidon_perm * (1 - sel_poseidon_perm) = 0; - // These will all be arrays, but we just store the first element for permutation to the main trace for now pol commit input; pol commit output; + // These will all be arrays, but we just store the first element for permutation to the main trace for now + // The input values are represented by a_0, a_1, a_2, a_3 + pol commit a_0; + pol commit a_1; + pol commit a_2; + pol commit a_3; + + // Output values represented by b_0, b_1, b_2, b_3 + pol commit b_0; + pol commit b_1; + pol commit b_2; + pol commit b_3; + + // Intermediate helper values denoted by T_{id}; + // T_0 = a_0 + a_1; + // T_1 = a_2 + a_3; + // T_2 = 2 * a_1 + T_0; + // T_3 = 2 * a_3 + T_0; + // T_4 = 4 * T_1 + T_3; + // T_5 = 4 * T_0 + T_2; + // T_6 = T_3 + T_5; + // T_7 = T_2 + T_4; + + + // We additionally include the round identifier + + ///////////////////////////////////////////////////// + // START FULL ROUND (4 ROUNDS) + ///////////////////////////////////////////////////// + // Round 1 (Full Round) + // ARK (Add Round Constant) + pol ARK_0_0 = a_0 + poseidon2_params.C_0_0; + pol ARK_0_1 = a_1 + poseidon2_params.C_0_1; + pol ARK_0_2 = a_2 + poseidon2_params.C_0_2; + pol ARK_0_3 = a_3 + poseidon2_params.C_0_3; + + // S-BOX (In full round all inputs are exponentiated) + pol A_0_0 = ARK_0_0 * ARK_0_0 * ARK_0_0 * ARK_0_0 * ARK_0_0; + pol A_0_1 = ARK_0_1 * ARK_0_1 * ARK_0_1 * ARK_0_1 * ARK_0_1; + pol A_0_2 = ARK_0_2 * ARK_0_2 * ARK_0_2 * ARK_0_2 * ARK_0_2; + pol A_0_3 = ARK_0_3 * ARK_0_3 * ARK_0_3 * ARK_0_3 * ARK_0_3; + + // MATRIX (Full round uses the external matrix) + pol T_0_0 = A_0_0 + A_0_1; + pol T_0_1 = A_0_2 + A_0_3; + pol T_0_2 = 2 * A_0_1 + T_0_0; + pol T_0_3 = 2 * A_0_3 + T_0_0; + pol T_0_4 = 4 * T_0_1 + T_0_3; + pol T_0_5 = 4 * T_0_0 + T_0_2; + pol T_0_6 = T_0_3 + T_0_5; + pol T_0_7 = T_0_2 + T_0_4; + + // Round 2 (Full Round) + // ARK (Add Round Constant) + pol ARK_1_0 = T_0_6 + poseidon2_params.C_1_0; + pol ARK_1_1 = T_0_5 + poseidon2_params.C_1_1; + pol ARK_1_2 = T_0_7 + poseidon2_params.C_1_2; + pol ARK_1_3 = T_0_4 + poseidon2_params.C_1_3; + + // S-BOX (In full round all inputs are exponentiated) + pol A_1_0 = ARK_1_0 * ARK_1_0 * ARK_1_0 * ARK_1_0 * ARK_1_0; + pol A_1_1 = ARK_1_1 * ARK_1_1 * ARK_1_1 * ARK_1_1 * ARK_1_1; + pol A_1_2 = ARK_1_2 * ARK_1_2 * ARK_1_2 * ARK_1_2 * ARK_1_2; + pol A_1_3 = ARK_1_3 * ARK_1_3 * ARK_1_3 * ARK_1_3 * ARK_1_3; + + // MATRIX (Full round uses the external matrix) + pol T_1_0 = A_1_0 + A_1_1; + pol T_1_1 = A_1_2 + A_1_3; + pol T_1_2 = 2 * A_1_1 + T_1_0; + pol T_1_3 = 2 * A_1_3 + T_1_0; + pol T_1_4 = 4 * T_1_1 + T_1_3; + pol T_1_5 = 4 * T_1_0 + T_1_2; + pol T_1_6 = T_1_3 + T_1_5; + pol T_1_7 = T_1_2 + T_1_4; + + // Round 3 (Full Round) + // ARK (Add Round Constant) + pol ARK_2_0 = T_1_6 + poseidon2_params.C_2_0; + pol ARK_2_1 = T_1_5 + poseidon2_params.C_2_1; + pol ARK_2_2 = T_1_7 + poseidon2_params.C_2_2; + pol ARK_2_3 = T_1_4 + poseidon2_params.C_2_3; + + // S-BOX (In full round all inputs are exponentiated) + pol A_2_0 = ARK_2_0 * ARK_2_0 * ARK_2_0 * ARK_2_0 * ARK_2_0; + pol A_2_1 = ARK_2_1 * ARK_2_1 * ARK_2_1 * ARK_2_1 * ARK_2_1; + pol A_2_2 = ARK_2_2 * ARK_2_2 * ARK_2_2 * ARK_2_2 * ARK_2_2; + pol A_2_3 = ARK_2_3 * ARK_2_3 * ARK_2_3 * ARK_2_3 * ARK_2_3; + + // MATRIX (Full round uses the external matrix) + pol T_2_0 = A_2_0 + A_2_1; + pol T_2_1 = A_2_2 + A_2_3; + pol T_2_2 = 2 * A_2_1 + T_2_0; + pol T_2_3 = 2 * A_2_3 + T_2_0; + pol T_2_4 = 4 * T_2_1 + T_2_3; + pol T_2_5 = 4 * T_2_0 + T_2_2; + pol T_2_6 = T_2_3 + T_2_5; + pol T_2_7 = T_2_2 + T_2_4; + + // Round 4 (Full Round) + // ARK (Add Round Constant) + pol ARK_3_0 = T_2_6 + poseidon2_params.C_3_0; + pol ARK_3_1 = T_2_5 + poseidon2_params.C_3_1; + pol ARK_3_2 = T_2_7 + poseidon2_params.C_3_2; + pol ARK_3_3 = T_2_4 + poseidon2_params.C_3_3; + + // S-BOX (In full round all inputs are exponentiated) + pol A_3_0 = ARK_3_0 * ARK_3_0 * ARK_3_0 * ARK_3_0 * ARK_3_0; + pol A_3_1 = ARK_3_1 * ARK_3_1 * ARK_3_1 * ARK_3_1 * ARK_3_1; + pol A_3_2 = ARK_3_2 * ARK_3_2 * ARK_3_2 * ARK_3_2 * ARK_3_2; + pol A_3_3 = ARK_3_3 * ARK_3_3 * ARK_3_3 * ARK_3_3 * ARK_3_3; + + // MATRIX (Full round uses the external matrix) + pol T_3_0 = A_3_0 + A_3_1; + pol T_3_1 = A_3_2 + A_3_3; + pol T_3_2 = 2 * A_3_1 + T_3_0; + pol T_3_3 = 2 * A_3_3 + T_3_0; + pol T_3_4 = 4 * T_3_1 + T_3_3; + pol T_3_5 = 4 * T_3_0 + T_3_2; + pol T_3_6 = T_3_3 + T_3_5; + pol T_3_7 = T_3_2 + T_3_4; + + ///////////////////////////////////////////////////// + // PARTIAL ROUNDS (56 ROUNDS) + ///////////////////////////////////////////////////// + + // Round 5 (Partial Round) + // ARK (Add Round Constant) + pol ARK_4_0 = T_3_6 + poseidon2_params.C_4_0; + pol ARK_4_1 = T_3_5 + poseidon2_params.C_4_1; + pol ARK_4_2 = T_3_7 + poseidon2_params.C_4_2; + pol ARK_4_3 = T_3_4 + poseidon2_params.C_4_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_4_0 = ARK_4_0 * ARK_4_0 * ARK_4_0 * ARK_4_0 * ARK_4_0; + pol A_4_1 = ARK_4_1; + pol A_4_2 = ARK_4_2; + pol A_4_3 = ARK_4_3; + + // MATRIX (Partial round uses the external matrix) + pol B_4_0 = poseidon2_params.MU_0 * A_4_0 + A_4_1 + A_4_2 + A_4_3; + pol B_4_1 = poseidon2_params.MU_1 * A_4_1 + A_4_0 + A_4_2 + A_4_3; + pol B_4_2 = poseidon2_params.MU_2 * A_4_2 + A_4_0 + A_4_1 + A_4_3; + pol B_4_3 = poseidon2_params.MU_3 * A_4_3 + A_4_0 + A_4_1 + A_4_2; + + // Round 6 (Partial Round) + // ARK (Add Round Constant) + pol ARK_5_0 = B_5_0 + poseidon2_params.C_5_0; + pol ARK_5_1 = B_5_0 + poseidon2_params.C_5_1; + pol ARK_5_2 = B_5_0 + poseidon2_params.C_5_2; + pol ARK_5_3 = B_5_0 + poseidon2_params.C_5_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_5_0 = ARK_5_0 * ARK_5_0 * ARK_5_0 * ARK_5_0 * ARK_5_0; + pol A_5_1 = ARK_5_1; + pol A_5_2 = ARK_5_2; + pol A_5_3 = ARK_5_3; + + // MATRIX (Partial round uses the external matrix) + pol B_5_0 = poseidon2_params.MU_0 * A_5_0 + A_5_1 + A_5_2 + A_5_3; + pol B_5_1 = poseidon2_params.MU_1 * A_5_1 + A_5_0 + A_5_2 + A_5_3; + pol B_5_2 = poseidon2_params.MU_2 * A_5_2 + A_5_0 + A_5_1 + A_5_3; + pol B_5_3 = poseidon2_params.MU_3 * A_5_3 + A_5_0 + A_5_1 + A_5_2; + + // Round 7 (Partial Round) + // ARK (Add Round Constant) + pol ARK_6_0 = B_6_0 + poseidon2_params.C_6_0; + pol ARK_6_1 = B_6_0 + poseidon2_params.C_6_1; + pol ARK_6_2 = B_6_0 + poseidon2_params.C_6_2; + pol ARK_6_3 = B_6_0 + poseidon2_params.C_6_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_6_0 = ARK_6_0 * ARK_6_0 * ARK_6_0 * ARK_6_0 * ARK_6_0; + pol A_6_1 = ARK_6_1; + pol A_6_2 = ARK_6_2; + pol A_6_3 = ARK_6_3; + + // MATRIX (Partial round uses the external matrix) + pol B_6_0 = poseidon2_params.MU_0 * A_6_0 + A_6_1 + A_6_2 + A_6_3; + pol B_6_1 = poseidon2_params.MU_1 * A_6_1 + A_6_0 + A_6_2 + A_6_3; + pol B_6_2 = poseidon2_params.MU_2 * A_6_2 + A_6_0 + A_6_1 + A_6_3; + pol B_6_3 = poseidon2_params.MU_3 * A_6_3 + A_6_0 + A_6_1 + A_6_2; + + // Round 8 (Partial Round) + // ARK (Add Round Constant) + pol ARK_7_0 = B_7_0 + poseidon2_params.C_7_0; + pol ARK_7_1 = B_7_0 + poseidon2_params.C_7_1; + pol ARK_7_2 = B_7_0 + poseidon2_params.C_7_2; + pol ARK_7_3 = B_7_0 + poseidon2_params.C_7_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_7_0 = ARK_7_0 * ARK_7_0 * ARK_7_0 * ARK_7_0 * ARK_7_0; + pol A_7_1 = ARK_7_1; + pol A_7_2 = ARK_7_2; + pol A_7_3 = ARK_7_3; + + // MATRIX (Partial round uses the external matrix) + pol B_7_0 = poseidon2_params.MU_0 * A_7_0 + A_7_1 + A_7_2 + A_7_3; + pol B_7_1 = poseidon2_params.MU_1 * A_7_1 + A_7_0 + A_7_2 + A_7_3; + pol B_7_2 = poseidon2_params.MU_2 * A_7_2 + A_7_0 + A_7_1 + A_7_3; + pol B_7_3 = poseidon2_params.MU_3 * A_7_3 + A_7_0 + A_7_1 + A_7_2; + + // Round 9 (Partial Round) + // ARK (Add Round Constant) + pol ARK_8_0 = B_8_0 + poseidon2_params.C_8_0; + pol ARK_8_1 = B_8_0 + poseidon2_params.C_8_1; + pol ARK_8_2 = B_8_0 + poseidon2_params.C_8_2; + pol ARK_8_3 = B_8_0 + poseidon2_params.C_8_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_8_0 = ARK_8_0 * ARK_8_0 * ARK_8_0 * ARK_8_0 * ARK_8_0; + pol A_8_1 = ARK_8_1; + pol A_8_2 = ARK_8_2; + pol A_8_3 = ARK_8_3; + + // MATRIX (Partial round uses the external matrix) + pol B_8_0 = poseidon2_params.MU_0 * A_8_0 + A_8_1 + A_8_2 + A_8_3; + pol B_8_1 = poseidon2_params.MU_1 * A_8_1 + A_8_0 + A_8_2 + A_8_3; + pol B_8_2 = poseidon2_params.MU_2 * A_8_2 + A_8_0 + A_8_1 + A_8_3; + pol B_8_3 = poseidon2_params.MU_3 * A_8_3 + A_8_0 + A_8_1 + A_8_2; + + // Round 10 (Partial Round) + // ARK (Add Round Constant) + pol ARK_9_0 = B_9_0 + poseidon2_params.C_9_0; + pol ARK_9_1 = B_9_0 + poseidon2_params.C_9_1; + pol ARK_9_2 = B_9_0 + poseidon2_params.C_9_2; + pol ARK_9_3 = B_9_0 + poseidon2_params.C_9_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_9_0 = ARK_9_0 * ARK_9_0 * ARK_9_0 * ARK_9_0 * ARK_9_0; + pol A_9_1 = ARK_9_1; + pol A_9_2 = ARK_9_2; + pol A_9_3 = ARK_9_3; + + // MATRIX (Partial round uses the external matrix) + pol B_9_0 = poseidon2_params.MU_0 * A_9_0 + A_9_1 + A_9_2 + A_9_3; + pol B_9_1 = poseidon2_params.MU_1 * A_9_1 + A_9_0 + A_9_2 + A_9_3; + pol B_9_2 = poseidon2_params.MU_2 * A_9_2 + A_9_0 + A_9_1 + A_9_3; + pol B_9_3 = poseidon2_params.MU_3 * A_9_3 + A_9_0 + A_9_1 + A_9_2; + + // Round 11 (Partial Round) + // ARK (Add Round Constant) + pol ARK_10_0 = B_10_0 + poseidon2_params.C_10_0; + pol ARK_10_1 = B_10_0 + poseidon2_params.C_10_1; + pol ARK_10_2 = B_10_0 + poseidon2_params.C_10_2; + pol ARK_10_3 = B_10_0 + poseidon2_params.C_10_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_10_0 = ARK_10_0 * ARK_10_0 * ARK_10_0 * ARK_10_0 * ARK_10_0; + pol A_10_1 = ARK_10_1; + pol A_10_2 = ARK_10_2; + pol A_10_3 = ARK_10_3; + + // MATRIX (Partial round uses the external matrix) + pol B_10_0 = poseidon2_params.MU_0 * A_10_0 + A_10_1 + A_10_2 + A_10_3; + pol B_10_1 = poseidon2_params.MU_1 * A_10_1 + A_10_0 + A_10_2 + A_10_3; + pol B_10_2 = poseidon2_params.MU_2 * A_10_2 + A_10_0 + A_10_1 + A_10_3; + pol B_10_3 = poseidon2_params.MU_3 * A_10_3 + A_10_0 + A_10_1 + A_10_2; + + // Round 12 (Partial Round) + // ARK (Add Round Constant) + pol ARK_11_0 = B_11_0 + poseidon2_params.C_11_0; + pol ARK_11_1 = B_11_0 + poseidon2_params.C_11_1; + pol ARK_11_2 = B_11_0 + poseidon2_params.C_11_2; + pol ARK_11_3 = B_11_0 + poseidon2_params.C_11_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_11_0 = ARK_11_0 * ARK_11_0 * ARK_11_0 * ARK_11_0 * ARK_11_0; + pol A_11_1 = ARK_11_1; + pol A_11_2 = ARK_11_2; + pol A_11_3 = ARK_11_3; + + // MATRIX (Partial round uses the external matrix) + pol B_11_0 = poseidon2_params.MU_0 * A_11_0 + A_11_1 + A_11_2 + A_11_3; + pol B_11_1 = poseidon2_params.MU_1 * A_11_1 + A_11_0 + A_11_2 + A_11_3; + pol B_11_2 = poseidon2_params.MU_2 * A_11_2 + A_11_0 + A_11_1 + A_11_3; + pol B_11_3 = poseidon2_params.MU_3 * A_11_3 + A_11_0 + A_11_1 + A_11_2; + + // Round 13 (Partial Round) + // ARK (Add Round Constant) + pol ARK_12_0 = B_12_0 + poseidon2_params.C_12_0; + pol ARK_12_1 = B_12_0 + poseidon2_params.C_12_1; + pol ARK_12_2 = B_12_0 + poseidon2_params.C_12_2; + pol ARK_12_3 = B_12_0 + poseidon2_params.C_12_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_12_0 = ARK_12_0 * ARK_12_0 * ARK_12_0 * ARK_12_0 * ARK_12_0; + pol A_12_1 = ARK_12_1; + pol A_12_2 = ARK_12_2; + pol A_12_3 = ARK_12_3; + + // MATRIX (Partial round uses the external matrix) + pol B_12_0 = poseidon2_params.MU_0 * A_12_0 + A_12_1 + A_12_2 + A_12_3; + pol B_12_1 = poseidon2_params.MU_1 * A_12_1 + A_12_0 + A_12_2 + A_12_3; + pol B_12_2 = poseidon2_params.MU_2 * A_12_2 + A_12_0 + A_12_1 + A_12_3; + pol B_12_3 = poseidon2_params.MU_3 * A_12_3 + A_12_0 + A_12_1 + A_12_2; + + // Round 14 (Partial Round) + // ARK (Add Round Constant) + pol ARK_13_0 = B_13_0 + poseidon2_params.C_13_0; + pol ARK_13_1 = B_13_0 + poseidon2_params.C_13_1; + pol ARK_13_2 = B_13_0 + poseidon2_params.C_13_2; + pol ARK_13_3 = B_13_0 + poseidon2_params.C_13_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_13_0 = ARK_13_0 * ARK_13_0 * ARK_13_0 * ARK_13_0 * ARK_13_0; + pol A_13_1 = ARK_13_1; + pol A_13_2 = ARK_13_2; + pol A_13_3 = ARK_13_3; + + // MATRIX (Partial round uses the external matrix) + pol B_13_0 = poseidon2_params.MU_0 * A_13_0 + A_13_1 + A_13_2 + A_13_3; + pol B_13_1 = poseidon2_params.MU_1 * A_13_1 + A_13_0 + A_13_2 + A_13_3; + pol B_13_2 = poseidon2_params.MU_2 * A_13_2 + A_13_0 + A_13_1 + A_13_3; + pol B_13_3 = poseidon2_params.MU_3 * A_13_3 + A_13_0 + A_13_1 + A_13_2; + + // Round 15 (Partial Round) + // ARK (Add Round Constant) + pol ARK_14_0 = B_14_0 + poseidon2_params.C_14_0; + pol ARK_14_1 = B_14_0 + poseidon2_params.C_14_1; + pol ARK_14_2 = B_14_0 + poseidon2_params.C_14_2; + pol ARK_14_3 = B_14_0 + poseidon2_params.C_14_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_14_0 = ARK_14_0 * ARK_14_0 * ARK_14_0 * ARK_14_0 * ARK_14_0; + pol A_14_1 = ARK_14_1; + pol A_14_2 = ARK_14_2; + pol A_14_3 = ARK_14_3; + + // MATRIX (Partial round uses the external matrix) + pol B_14_0 = poseidon2_params.MU_0 * A_14_0 + A_14_1 + A_14_2 + A_14_3; + pol B_14_1 = poseidon2_params.MU_1 * A_14_1 + A_14_0 + A_14_2 + A_14_3; + pol B_14_2 = poseidon2_params.MU_2 * A_14_2 + A_14_0 + A_14_1 + A_14_3; + pol B_14_3 = poseidon2_params.MU_3 * A_14_3 + A_14_0 + A_14_1 + A_14_2; + + // Round 16 (Partial Round) + // ARK (Add Round Constant) + pol ARK_15_0 = B_15_0 + poseidon2_params.C_15_0; + pol ARK_15_1 = B_15_0 + poseidon2_params.C_15_1; + pol ARK_15_2 = B_15_0 + poseidon2_params.C_15_2; + pol ARK_15_3 = B_15_0 + poseidon2_params.C_15_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_15_0 = ARK_15_0 * ARK_15_0 * ARK_15_0 * ARK_15_0 * ARK_15_0; + pol A_15_1 = ARK_15_1; + pol A_15_2 = ARK_15_2; + pol A_15_3 = ARK_15_3; + + // MATRIX (Partial round uses the external matrix) + pol B_15_0 = poseidon2_params.MU_0 * A_15_0 + A_15_1 + A_15_2 + A_15_3; + pol B_15_1 = poseidon2_params.MU_1 * A_15_1 + A_15_0 + A_15_2 + A_15_3; + pol B_15_2 = poseidon2_params.MU_2 * A_15_2 + A_15_0 + A_15_1 + A_15_3; + pol B_15_3 = poseidon2_params.MU_3 * A_15_3 + A_15_0 + A_15_1 + A_15_2; + + // Round 17 (Partial Round) + // ARK (Add Round Constant) + pol ARK_16_0 = B_16_0 + poseidon2_params.C_16_0; + pol ARK_16_1 = B_16_0 + poseidon2_params.C_16_1; + pol ARK_16_2 = B_16_0 + poseidon2_params.C_16_2; + pol ARK_16_3 = B_16_0 + poseidon2_params.C_16_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_16_0 = ARK_16_0 * ARK_16_0 * ARK_16_0 * ARK_16_0 * ARK_16_0; + pol A_16_1 = ARK_16_1; + pol A_16_2 = ARK_16_2; + pol A_16_3 = ARK_16_3; + + // MATRIX (Partial round uses the external matrix) + pol B_16_0 = poseidon2_params.MU_0 * A_16_0 + A_16_1 + A_16_2 + A_16_3; + pol B_16_1 = poseidon2_params.MU_1 * A_16_1 + A_16_0 + A_16_2 + A_16_3; + pol B_16_2 = poseidon2_params.MU_2 * A_16_2 + A_16_0 + A_16_1 + A_16_3; + pol B_16_3 = poseidon2_params.MU_3 * A_16_3 + A_16_0 + A_16_1 + A_16_2; + + // Round 18 (Partial Round) + // ARK (Add Round Constant) + pol ARK_17_0 = B_17_0 + poseidon2_params.C_17_0; + pol ARK_17_1 = B_17_0 + poseidon2_params.C_17_1; + pol ARK_17_2 = B_17_0 + poseidon2_params.C_17_2; + pol ARK_17_3 = B_17_0 + poseidon2_params.C_17_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_17_0 = ARK_17_0 * ARK_17_0 * ARK_17_0 * ARK_17_0 * ARK_17_0; + pol A_17_1 = ARK_17_1; + pol A_17_2 = ARK_17_2; + pol A_17_3 = ARK_17_3; + + // MATRIX (Partial round uses the external matrix) + pol B_17_0 = poseidon2_params.MU_0 * A_17_0 + A_17_1 + A_17_2 + A_17_3; + pol B_17_1 = poseidon2_params.MU_1 * A_17_1 + A_17_0 + A_17_2 + A_17_3; + pol B_17_2 = poseidon2_params.MU_2 * A_17_2 + A_17_0 + A_17_1 + A_17_3; + pol B_17_3 = poseidon2_params.MU_3 * A_17_3 + A_17_0 + A_17_1 + A_17_2; + + // Round 19 (Partial Round) + // ARK (Add Round Constant) + pol ARK_18_0 = B_18_0 + poseidon2_params.C_18_0; + pol ARK_18_1 = B_18_0 + poseidon2_params.C_18_1; + pol ARK_18_2 = B_18_0 + poseidon2_params.C_18_2; + pol ARK_18_3 = B_18_0 + poseidon2_params.C_18_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_18_0 = ARK_18_0 * ARK_18_0 * ARK_18_0 * ARK_18_0 * ARK_18_0; + pol A_18_1 = ARK_18_1; + pol A_18_2 = ARK_18_2; + pol A_18_3 = ARK_18_3; + + // MATRIX (Partial round uses the external matrix) + pol B_18_0 = poseidon2_params.MU_0 * A_18_0 + A_18_1 + A_18_2 + A_18_3; + pol B_18_1 = poseidon2_params.MU_1 * A_18_1 + A_18_0 + A_18_2 + A_18_3; + pol B_18_2 = poseidon2_params.MU_2 * A_18_2 + A_18_0 + A_18_1 + A_18_3; + pol B_18_3 = poseidon2_params.MU_3 * A_18_3 + A_18_0 + A_18_1 + A_18_2; + + // Round 20 (Partial Round) + // ARK (Add Round Constant) + pol ARK_19_0 = B_19_0 + poseidon2_params.C_19_0; + pol ARK_19_1 = B_19_0 + poseidon2_params.C_19_1; + pol ARK_19_2 = B_19_0 + poseidon2_params.C_19_2; + pol ARK_19_3 = B_19_0 + poseidon2_params.C_19_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_19_0 = ARK_19_0 * ARK_19_0 * ARK_19_0 * ARK_19_0 * ARK_19_0; + pol A_19_1 = ARK_19_1; + pol A_19_2 = ARK_19_2; + pol A_19_3 = ARK_19_3; + + // MATRIX (Partial round uses the external matrix) + pol B_19_0 = poseidon2_params.MU_0 * A_19_0 + A_19_1 + A_19_2 + A_19_3; + pol B_19_1 = poseidon2_params.MU_1 * A_19_1 + A_19_0 + A_19_2 + A_19_3; + pol B_19_2 = poseidon2_params.MU_2 * A_19_2 + A_19_0 + A_19_1 + A_19_3; + pol B_19_3 = poseidon2_params.MU_3 * A_19_3 + A_19_0 + A_19_1 + A_19_2; + + // Round 21 (Partial Round) + // ARK (Add Round Constant) + pol ARK_20_0 = B_20_0 + poseidon2_params.C_20_0; + pol ARK_20_1 = B_20_0 + poseidon2_params.C_20_1; + pol ARK_20_2 = B_20_0 + poseidon2_params.C_20_2; + pol ARK_20_3 = B_20_0 + poseidon2_params.C_20_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_20_0 = ARK_20_0 * ARK_20_0 * ARK_20_0 * ARK_20_0 * ARK_20_0; + pol A_20_1 = ARK_20_1; + pol A_20_2 = ARK_20_2; + pol A_20_3 = ARK_20_3; + + // MATRIX (Partial round uses the external matrix) + pol B_20_0 = poseidon2_params.MU_0 * A_20_0 + A_20_1 + A_20_2 + A_20_3; + pol B_20_1 = poseidon2_params.MU_1 * A_20_1 + A_20_0 + A_20_2 + A_20_3; + pol B_20_2 = poseidon2_params.MU_2 * A_20_2 + A_20_0 + A_20_1 + A_20_3; + pol B_20_3 = poseidon2_params.MU_3 * A_20_3 + A_20_0 + A_20_1 + A_20_2; + + // Round 22 (Partial Round) + // ARK (Add Round Constant) + pol ARK_21_0 = B_21_0 + poseidon2_params.C_21_0; + pol ARK_21_1 = B_21_0 + poseidon2_params.C_21_1; + pol ARK_21_2 = B_21_0 + poseidon2_params.C_21_2; + pol ARK_21_3 = B_21_0 + poseidon2_params.C_21_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_21_0 = ARK_21_0 * ARK_21_0 * ARK_21_0 * ARK_21_0 * ARK_21_0; + pol A_21_1 = ARK_21_1; + pol A_21_2 = ARK_21_2; + pol A_21_3 = ARK_21_3; + + // MATRIX (Partial round uses the external matrix) + pol B_21_0 = poseidon2_params.MU_0 * A_21_0 + A_21_1 + A_21_2 + A_21_3; + pol B_21_1 = poseidon2_params.MU_1 * A_21_1 + A_21_0 + A_21_2 + A_21_3; + pol B_21_2 = poseidon2_params.MU_2 * A_21_2 + A_21_0 + A_21_1 + A_21_3; + pol B_21_3 = poseidon2_params.MU_3 * A_21_3 + A_21_0 + A_21_1 + A_21_2; + + // Round 23 (Partial Round) + // ARK (Add Round Constant) + pol ARK_22_0 = B_22_0 + poseidon2_params.C_22_0; + pol ARK_22_1 = B_22_0 + poseidon2_params.C_22_1; + pol ARK_22_2 = B_22_0 + poseidon2_params.C_22_2; + pol ARK_22_3 = B_22_0 + poseidon2_params.C_22_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_22_0 = ARK_22_0 * ARK_22_0 * ARK_22_0 * ARK_22_0 * ARK_22_0; + pol A_22_1 = ARK_22_1; + pol A_22_2 = ARK_22_2; + pol A_22_3 = ARK_22_3; + + // MATRIX (Partial round uses the external matrix) + pol B_22_0 = poseidon2_params.MU_0 * A_22_0 + A_22_1 + A_22_2 + A_22_3; + pol B_22_1 = poseidon2_params.MU_1 * A_22_1 + A_22_0 + A_22_2 + A_22_3; + pol B_22_2 = poseidon2_params.MU_2 * A_22_2 + A_22_0 + A_22_1 + A_22_3; + pol B_22_3 = poseidon2_params.MU_3 * A_22_3 + A_22_0 + A_22_1 + A_22_2; + + // Round 24 (Partial Round) + // ARK (Add Round Constant) + pol ARK_23_0 = B_23_0 + poseidon2_params.C_23_0; + pol ARK_23_1 = B_23_0 + poseidon2_params.C_23_1; + pol ARK_23_2 = B_23_0 + poseidon2_params.C_23_2; + pol ARK_23_3 = B_23_0 + poseidon2_params.C_23_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_23_0 = ARK_23_0 * ARK_23_0 * ARK_23_0 * ARK_23_0 * ARK_23_0; + pol A_23_1 = ARK_23_1; + pol A_23_2 = ARK_23_2; + pol A_23_3 = ARK_23_3; + + // MATRIX (Partial round uses the external matrix) + pol B_23_0 = poseidon2_params.MU_0 * A_23_0 + A_23_1 + A_23_2 + A_23_3; + pol B_23_1 = poseidon2_params.MU_1 * A_23_1 + A_23_0 + A_23_2 + A_23_3; + pol B_23_2 = poseidon2_params.MU_2 * A_23_2 + A_23_0 + A_23_1 + A_23_3; + pol B_23_3 = poseidon2_params.MU_3 * A_23_3 + A_23_0 + A_23_1 + A_23_2; + + // Round 25 (Partial Round) + // ARK (Add Round Constant) + pol ARK_24_0 = B_24_0 + poseidon2_params.C_24_0; + pol ARK_24_1 = B_24_0 + poseidon2_params.C_24_1; + pol ARK_24_2 = B_24_0 + poseidon2_params.C_24_2; + pol ARK_24_3 = B_24_0 + poseidon2_params.C_24_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_24_0 = ARK_24_0 * ARK_24_0 * ARK_24_0 * ARK_24_0 * ARK_24_0; + pol A_24_1 = ARK_24_1; + pol A_24_2 = ARK_24_2; + pol A_24_3 = ARK_24_3; + + // MATRIX (Partial round uses the external matrix) + pol B_24_0 = poseidon2_params.MU_0 * A_24_0 + A_24_1 + A_24_2 + A_24_3; + pol B_24_1 = poseidon2_params.MU_1 * A_24_1 + A_24_0 + A_24_2 + A_24_3; + pol B_24_2 = poseidon2_params.MU_2 * A_24_2 + A_24_0 + A_24_1 + A_24_3; + pol B_24_3 = poseidon2_params.MU_3 * A_24_3 + A_24_0 + A_24_1 + A_24_2; + + // Round 26 (Partial Round) + // ARK (Add Round Constant) + pol ARK_25_0 = B_25_0 + poseidon2_params.C_25_0; + pol ARK_25_1 = B_25_0 + poseidon2_params.C_25_1; + pol ARK_25_2 = B_25_0 + poseidon2_params.C_25_2; + pol ARK_25_3 = B_25_0 + poseidon2_params.C_25_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_25_0 = ARK_25_0 * ARK_25_0 * ARK_25_0 * ARK_25_0 * ARK_25_0; + pol A_25_1 = ARK_25_1; + pol A_25_2 = ARK_25_2; + pol A_25_3 = ARK_25_3; + + // MATRIX (Partial round uses the external matrix) + pol B_25_0 = poseidon2_params.MU_0 * A_25_0 + A_25_1 + A_25_2 + A_25_3; + pol B_25_1 = poseidon2_params.MU_1 * A_25_1 + A_25_0 + A_25_2 + A_25_3; + pol B_25_2 = poseidon2_params.MU_2 * A_25_2 + A_25_0 + A_25_1 + A_25_3; + pol B_25_3 = poseidon2_params.MU_3 * A_25_3 + A_25_0 + A_25_1 + A_25_2; + + // Round 27 (Partial Round) + // ARK (Add Round Constant) + pol ARK_26_0 = B_26_0 + poseidon2_params.C_26_0; + pol ARK_26_1 = B_26_0 + poseidon2_params.C_26_1; + pol ARK_26_2 = B_26_0 + poseidon2_params.C_26_2; + pol ARK_26_3 = B_26_0 + poseidon2_params.C_26_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_26_0 = ARK_26_0 * ARK_26_0 * ARK_26_0 * ARK_26_0 * ARK_26_0; + pol A_26_1 = ARK_26_1; + pol A_26_2 = ARK_26_2; + pol A_26_3 = ARK_26_3; + + // MATRIX (Partial round uses the external matrix) + pol B_26_0 = poseidon2_params.MU_0 * A_26_0 + A_26_1 + A_26_2 + A_26_3; + pol B_26_1 = poseidon2_params.MU_1 * A_26_1 + A_26_0 + A_26_2 + A_26_3; + pol B_26_2 = poseidon2_params.MU_2 * A_26_2 + A_26_0 + A_26_1 + A_26_3; + pol B_26_3 = poseidon2_params.MU_3 * A_26_3 + A_26_0 + A_26_1 + A_26_2; + + // Round 28 (Partial Round) + // ARK (Add Round Constant) + pol ARK_27_0 = B_27_0 + poseidon2_params.C_27_0; + pol ARK_27_1 = B_27_0 + poseidon2_params.C_27_1; + pol ARK_27_2 = B_27_0 + poseidon2_params.C_27_2; + pol ARK_27_3 = B_27_0 + poseidon2_params.C_27_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_27_0 = ARK_27_0 * ARK_27_0 * ARK_27_0 * ARK_27_0 * ARK_27_0; + pol A_27_1 = ARK_27_1; + pol A_27_2 = ARK_27_2; + pol A_27_3 = ARK_27_3; + + // MATRIX (Partial round uses the external matrix) + pol B_27_0 = poseidon2_params.MU_0 * A_27_0 + A_27_1 + A_27_2 + A_27_3; + pol B_27_1 = poseidon2_params.MU_1 * A_27_1 + A_27_0 + A_27_2 + A_27_3; + pol B_27_2 = poseidon2_params.MU_2 * A_27_2 + A_27_0 + A_27_1 + A_27_3; + pol B_27_3 = poseidon2_params.MU_3 * A_27_3 + A_27_0 + A_27_1 + A_27_2; + + // Round 29 (Partial Round) + // ARK (Add Round Constant) + pol ARK_28_0 = B_28_0 + poseidon2_params.C_28_0; + pol ARK_28_1 = B_28_0 + poseidon2_params.C_28_1; + pol ARK_28_2 = B_28_0 + poseidon2_params.C_28_2; + pol ARK_28_3 = B_28_0 + poseidon2_params.C_28_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_28_0 = ARK_28_0 * ARK_28_0 * ARK_28_0 * ARK_28_0 * ARK_28_0; + pol A_28_1 = ARK_28_1; + pol A_28_2 = ARK_28_2; + pol A_28_3 = ARK_28_3; + + // MATRIX (Partial round uses the external matrix) + pol B_28_0 = poseidon2_params.MU_0 * A_28_0 + A_28_1 + A_28_2 + A_28_3; + pol B_28_1 = poseidon2_params.MU_1 * A_28_1 + A_28_0 + A_28_2 + A_28_3; + pol B_28_2 = poseidon2_params.MU_2 * A_28_2 + A_28_0 + A_28_1 + A_28_3; + pol B_28_3 = poseidon2_params.MU_3 * A_28_3 + A_28_0 + A_28_1 + A_28_2; + + // Round 30 (Partial Round) + // ARK (Add Round Constant) + pol ARK_29_0 = B_29_0 + poseidon2_params.C_29_0; + pol ARK_29_1 = B_29_0 + poseidon2_params.C_29_1; + pol ARK_29_2 = B_29_0 + poseidon2_params.C_29_2; + pol ARK_29_3 = B_29_0 + poseidon2_params.C_29_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_29_0 = ARK_29_0 * ARK_29_0 * ARK_29_0 * ARK_29_0 * ARK_29_0; + pol A_29_1 = ARK_29_1; + pol A_29_2 = ARK_29_2; + pol A_29_3 = ARK_29_3; + + // MATRIX (Partial round uses the external matrix) + pol B_29_0 = poseidon2_params.MU_0 * A_29_0 + A_29_1 + A_29_2 + A_29_3; + pol B_29_1 = poseidon2_params.MU_1 * A_29_1 + A_29_0 + A_29_2 + A_29_3; + pol B_29_2 = poseidon2_params.MU_2 * A_29_2 + A_29_0 + A_29_1 + A_29_3; + pol B_29_3 = poseidon2_params.MU_3 * A_29_3 + A_29_0 + A_29_1 + A_29_2; + + // Round 31 (Partial Round) + // ARK (Add Round Constant) + pol ARK_30_0 = B_30_0 + poseidon2_params.C_30_0; + pol ARK_30_1 = B_30_0 + poseidon2_params.C_30_1; + pol ARK_30_2 = B_30_0 + poseidon2_params.C_30_2; + pol ARK_30_3 = B_30_0 + poseidon2_params.C_30_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_30_0 = ARK_30_0 * ARK_30_0 * ARK_30_0 * ARK_30_0 * ARK_30_0; + pol A_30_1 = ARK_30_1; + pol A_30_2 = ARK_30_2; + pol A_30_3 = ARK_30_3; + + // MATRIX (Partial round uses the external matrix) + pol B_30_0 = poseidon2_params.MU_0 * A_30_0 + A_30_1 + A_30_2 + A_30_3; + pol B_30_1 = poseidon2_params.MU_1 * A_30_1 + A_30_0 + A_30_2 + A_30_3; + pol B_30_2 = poseidon2_params.MU_2 * A_30_2 + A_30_0 + A_30_1 + A_30_3; + pol B_30_3 = poseidon2_params.MU_3 * A_30_3 + A_30_0 + A_30_1 + A_30_2; + + // Round 32 (Partial Round) + // ARK (Add Round Constant) + pol ARK_31_0 = B_31_0 + poseidon2_params.C_31_0; + pol ARK_31_1 = B_31_0 + poseidon2_params.C_31_1; + pol ARK_31_2 = B_31_0 + poseidon2_params.C_31_2; + pol ARK_31_3 = B_31_0 + poseidon2_params.C_31_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_31_0 = ARK_31_0 * ARK_31_0 * ARK_31_0 * ARK_31_0 * ARK_31_0; + pol A_31_1 = ARK_31_1; + pol A_31_2 = ARK_31_2; + pol A_31_3 = ARK_31_3; + + // MATRIX (Partial round uses the external matrix) + pol B_31_0 = poseidon2_params.MU_0 * A_31_0 + A_31_1 + A_31_2 + A_31_3; + pol B_31_1 = poseidon2_params.MU_1 * A_31_1 + A_31_0 + A_31_2 + A_31_3; + pol B_31_2 = poseidon2_params.MU_2 * A_31_2 + A_31_0 + A_31_1 + A_31_3; + pol B_31_3 = poseidon2_params.MU_3 * A_31_3 + A_31_0 + A_31_1 + A_31_2; + + // Round 33 (Partial Round) + // ARK (Add Round Constant) + pol ARK_32_0 = B_32_0 + poseidon2_params.C_32_0; + pol ARK_32_1 = B_32_0 + poseidon2_params.C_32_1; + pol ARK_32_2 = B_32_0 + poseidon2_params.C_32_2; + pol ARK_32_3 = B_32_0 + poseidon2_params.C_32_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_32_0 = ARK_32_0 * ARK_32_0 * ARK_32_0 * ARK_32_0 * ARK_32_0; + pol A_32_1 = ARK_32_1; + pol A_32_2 = ARK_32_2; + pol A_32_3 = ARK_32_3; + + // MATRIX (Partial round uses the external matrix) + pol B_32_0 = poseidon2_params.MU_0 * A_32_0 + A_32_1 + A_32_2 + A_32_3; + pol B_32_1 = poseidon2_params.MU_1 * A_32_1 + A_32_0 + A_32_2 + A_32_3; + pol B_32_2 = poseidon2_params.MU_2 * A_32_2 + A_32_0 + A_32_1 + A_32_3; + pol B_32_3 = poseidon2_params.MU_3 * A_32_3 + A_32_0 + A_32_1 + A_32_2; + + // Round 34 (Partial Round) + // ARK (Add Round Constant) + pol ARK_33_0 = B_33_0 + poseidon2_params.C_33_0; + pol ARK_33_1 = B_33_0 + poseidon2_params.C_33_1; + pol ARK_33_2 = B_33_0 + poseidon2_params.C_33_2; + pol ARK_33_3 = B_33_0 + poseidon2_params.C_33_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_33_0 = ARK_33_0 * ARK_33_0 * ARK_33_0 * ARK_33_0 * ARK_33_0; + pol A_33_1 = ARK_33_1; + pol A_33_2 = ARK_33_2; + pol A_33_3 = ARK_33_3; + + // MATRIX (Partial round uses the external matrix) + pol B_33_0 = poseidon2_params.MU_0 * A_33_0 + A_33_1 + A_33_2 + A_33_3; + pol B_33_1 = poseidon2_params.MU_1 * A_33_1 + A_33_0 + A_33_2 + A_33_3; + pol B_33_2 = poseidon2_params.MU_2 * A_33_2 + A_33_0 + A_33_1 + A_33_3; + pol B_33_3 = poseidon2_params.MU_3 * A_33_3 + A_33_0 + A_33_1 + A_33_2; + + // Round 35 (Partial Round) + // ARK (Add Round Constant) + pol ARK_34_0 = B_34_0 + poseidon2_params.C_34_0; + pol ARK_34_1 = B_34_0 + poseidon2_params.C_34_1; + pol ARK_34_2 = B_34_0 + poseidon2_params.C_34_2; + pol ARK_34_3 = B_34_0 + poseidon2_params.C_34_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_34_0 = ARK_34_0 * ARK_34_0 * ARK_34_0 * ARK_34_0 * ARK_34_0; + pol A_34_1 = ARK_34_1; + pol A_34_2 = ARK_34_2; + pol A_34_3 = ARK_34_3; + + // MATRIX (Partial round uses the external matrix) + pol B_34_0 = poseidon2_params.MU_0 * A_34_0 + A_34_1 + A_34_2 + A_34_3; + pol B_34_1 = poseidon2_params.MU_1 * A_34_1 + A_34_0 + A_34_2 + A_34_3; + pol B_34_2 = poseidon2_params.MU_2 * A_34_2 + A_34_0 + A_34_1 + A_34_3; + pol B_34_3 = poseidon2_params.MU_3 * A_34_3 + A_34_0 + A_34_1 + A_34_2; + + // Round 36 (Partial Round) + // ARK (Add Round Constant) + pol ARK_35_0 = B_35_0 + poseidon2_params.C_35_0; + pol ARK_35_1 = B_35_0 + poseidon2_params.C_35_1; + pol ARK_35_2 = B_35_0 + poseidon2_params.C_35_2; + pol ARK_35_3 = B_35_0 + poseidon2_params.C_35_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_35_0 = ARK_35_0 * ARK_35_0 * ARK_35_0 * ARK_35_0 * ARK_35_0; + pol A_35_1 = ARK_35_1; + pol A_35_2 = ARK_35_2; + pol A_35_3 = ARK_35_3; + + // MATRIX (Partial round uses the external matrix) + pol B_35_0 = poseidon2_params.MU_0 * A_35_0 + A_35_1 + A_35_2 + A_35_3; + pol B_35_1 = poseidon2_params.MU_1 * A_35_1 + A_35_0 + A_35_2 + A_35_3; + pol B_35_2 = poseidon2_params.MU_2 * A_35_2 + A_35_0 + A_35_1 + A_35_3; + pol B_35_3 = poseidon2_params.MU_3 * A_35_3 + A_35_0 + A_35_1 + A_35_2; + + // Round 37 (Partial Round) + // ARK (Add Round Constant) + pol ARK_36_0 = B_36_0 + poseidon2_params.C_36_0; + pol ARK_36_1 = B_36_0 + poseidon2_params.C_36_1; + pol ARK_36_2 = B_36_0 + poseidon2_params.C_36_2; + pol ARK_36_3 = B_36_0 + poseidon2_params.C_36_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_36_0 = ARK_36_0 * ARK_36_0 * ARK_36_0 * ARK_36_0 * ARK_36_0; + pol A_36_1 = ARK_36_1; + pol A_36_2 = ARK_36_2; + pol A_36_3 = ARK_36_3; + + // MATRIX (Partial round uses the external matrix) + pol B_36_0 = poseidon2_params.MU_0 * A_36_0 + A_36_1 + A_36_2 + A_36_3; + pol B_36_1 = poseidon2_params.MU_1 * A_36_1 + A_36_0 + A_36_2 + A_36_3; + pol B_36_2 = poseidon2_params.MU_2 * A_36_2 + A_36_0 + A_36_1 + A_36_3; + pol B_36_3 = poseidon2_params.MU_3 * A_36_3 + A_36_0 + A_36_1 + A_36_2; + + // Round 38 (Partial Round) + // ARK (Add Round Constant) + pol ARK_37_0 = B_37_0 + poseidon2_params.C_37_0; + pol ARK_37_1 = B_37_0 + poseidon2_params.C_37_1; + pol ARK_37_2 = B_37_0 + poseidon2_params.C_37_2; + pol ARK_37_3 = B_37_0 + poseidon2_params.C_37_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_37_0 = ARK_37_0 * ARK_37_0 * ARK_37_0 * ARK_37_0 * ARK_37_0; + pol A_37_1 = ARK_37_1; + pol A_37_2 = ARK_37_2; + pol A_37_3 = ARK_37_3; + + // MATRIX (Partial round uses the external matrix) + pol B_37_0 = poseidon2_params.MU_0 * A_37_0 + A_37_1 + A_37_2 + A_37_3; + pol B_37_1 = poseidon2_params.MU_1 * A_37_1 + A_37_0 + A_37_2 + A_37_3; + pol B_37_2 = poseidon2_params.MU_2 * A_37_2 + A_37_0 + A_37_1 + A_37_3; + pol B_37_3 = poseidon2_params.MU_3 * A_37_3 + A_37_0 + A_37_1 + A_37_2; + + // Round 39 (Partial Round) + // ARK (Add Round Constant) + pol ARK_38_0 = B_38_0 + poseidon2_params.C_38_0; + pol ARK_38_1 = B_38_0 + poseidon2_params.C_38_1; + pol ARK_38_2 = B_38_0 + poseidon2_params.C_38_2; + pol ARK_38_3 = B_38_0 + poseidon2_params.C_38_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_38_0 = ARK_38_0 * ARK_38_0 * ARK_38_0 * ARK_38_0 * ARK_38_0; + pol A_38_1 = ARK_38_1; + pol A_38_2 = ARK_38_2; + pol A_38_3 = ARK_38_3; + + // MATRIX (Partial round uses the external matrix) + pol B_38_0 = poseidon2_params.MU_0 * A_38_0 + A_38_1 + A_38_2 + A_38_3; + pol B_38_1 = poseidon2_params.MU_1 * A_38_1 + A_38_0 + A_38_2 + A_38_3; + pol B_38_2 = poseidon2_params.MU_2 * A_38_2 + A_38_0 + A_38_1 + A_38_3; + pol B_38_3 = poseidon2_params.MU_3 * A_38_3 + A_38_0 + A_38_1 + A_38_2; + + // Round 40 (Partial Round) + // ARK (Add Round Constant) + pol ARK_39_0 = B_39_0 + poseidon2_params.C_39_0; + pol ARK_39_1 = B_39_0 + poseidon2_params.C_39_1; + pol ARK_39_2 = B_39_0 + poseidon2_params.C_39_2; + pol ARK_39_3 = B_39_0 + poseidon2_params.C_39_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_39_0 = ARK_39_0 * ARK_39_0 * ARK_39_0 * ARK_39_0 * ARK_39_0; + pol A_39_1 = ARK_39_1; + pol A_39_2 = ARK_39_2; + pol A_39_3 = ARK_39_3; + + // MATRIX (Partial round uses the external matrix) + pol B_39_0 = poseidon2_params.MU_0 * A_39_0 + A_39_1 + A_39_2 + A_39_3; + pol B_39_1 = poseidon2_params.MU_1 * A_39_1 + A_39_0 + A_39_2 + A_39_3; + pol B_39_2 = poseidon2_params.MU_2 * A_39_2 + A_39_0 + A_39_1 + A_39_3; + pol B_39_3 = poseidon2_params.MU_3 * A_39_3 + A_39_0 + A_39_1 + A_39_2; + + // Round 41 (Partial Round) + // ARK (Add Round Constant) + pol ARK_40_0 = B_40_0 + poseidon2_params.C_40_0; + pol ARK_40_1 = B_40_0 + poseidon2_params.C_40_1; + pol ARK_40_2 = B_40_0 + poseidon2_params.C_40_2; + pol ARK_40_3 = B_40_0 + poseidon2_params.C_40_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_40_0 = ARK_40_0 * ARK_40_0 * ARK_40_0 * ARK_40_0 * ARK_40_0; + pol A_40_1 = ARK_40_1; + pol A_40_2 = ARK_40_2; + pol A_40_3 = ARK_40_3; + + // MATRIX (Partial round uses the external matrix) + pol B_40_0 = poseidon2_params.MU_0 * A_40_0 + A_40_1 + A_40_2 + A_40_3; + pol B_40_1 = poseidon2_params.MU_1 * A_40_1 + A_40_0 + A_40_2 + A_40_3; + pol B_40_2 = poseidon2_params.MU_2 * A_40_2 + A_40_0 + A_40_1 + A_40_3; + pol B_40_3 = poseidon2_params.MU_3 * A_40_3 + A_40_0 + A_40_1 + A_40_2; + + // Round 42 (Partial Round) + // ARK (Add Round Constant) + pol ARK_41_0 = B_41_0 + poseidon2_params.C_41_0; + pol ARK_41_1 = B_41_0 + poseidon2_params.C_41_1; + pol ARK_41_2 = B_41_0 + poseidon2_params.C_41_2; + pol ARK_41_3 = B_41_0 + poseidon2_params.C_41_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_41_0 = ARK_41_0 * ARK_41_0 * ARK_41_0 * ARK_41_0 * ARK_41_0; + pol A_41_1 = ARK_41_1; + pol A_41_2 = ARK_41_2; + pol A_41_3 = ARK_41_3; + + // MATRIX (Partial round uses the external matrix) + pol B_41_0 = poseidon2_params.MU_0 * A_41_0 + A_41_1 + A_41_2 + A_41_3; + pol B_41_1 = poseidon2_params.MU_1 * A_41_1 + A_41_0 + A_41_2 + A_41_3; + pol B_41_2 = poseidon2_params.MU_2 * A_41_2 + A_41_0 + A_41_1 + A_41_3; + pol B_41_3 = poseidon2_params.MU_3 * A_41_3 + A_41_0 + A_41_1 + A_41_2; + + // Round 43 (Partial Round) + // ARK (Add Round Constant) + pol ARK_42_0 = B_42_0 + poseidon2_params.C_42_0; + pol ARK_42_1 = B_42_0 + poseidon2_params.C_42_1; + pol ARK_42_2 = B_42_0 + poseidon2_params.C_42_2; + pol ARK_42_3 = B_42_0 + poseidon2_params.C_42_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_42_0 = ARK_42_0 * ARK_42_0 * ARK_42_0 * ARK_42_0 * ARK_42_0; + pol A_42_1 = ARK_42_1; + pol A_42_2 = ARK_42_2; + pol A_42_3 = ARK_42_3; + + // MATRIX (Partial round uses the external matrix) + pol B_42_0 = poseidon2_params.MU_0 * A_42_0 + A_42_1 + A_42_2 + A_42_3; + pol B_42_1 = poseidon2_params.MU_1 * A_42_1 + A_42_0 + A_42_2 + A_42_3; + pol B_42_2 = poseidon2_params.MU_2 * A_42_2 + A_42_0 + A_42_1 + A_42_3; + pol B_42_3 = poseidon2_params.MU_3 * A_42_3 + A_42_0 + A_42_1 + A_42_2; + + // Round 44 (Partial Round) + // ARK (Add Round Constant) + pol ARK_43_0 = B_43_0 + poseidon2_params.C_43_0; + pol ARK_43_1 = B_43_0 + poseidon2_params.C_43_1; + pol ARK_43_2 = B_43_0 + poseidon2_params.C_43_2; + pol ARK_43_3 = B_43_0 + poseidon2_params.C_43_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_43_0 = ARK_43_0 * ARK_43_0 * ARK_43_0 * ARK_43_0 * ARK_43_0; + pol A_43_1 = ARK_43_1; + pol A_43_2 = ARK_43_2; + pol A_43_3 = ARK_43_3; + + // MATRIX (Partial round uses the external matrix) + pol B_43_0 = poseidon2_params.MU_0 * A_43_0 + A_43_1 + A_43_2 + A_43_3; + pol B_43_1 = poseidon2_params.MU_1 * A_43_1 + A_43_0 + A_43_2 + A_43_3; + pol B_43_2 = poseidon2_params.MU_2 * A_43_2 + A_43_0 + A_43_1 + A_43_3; + pol B_43_3 = poseidon2_params.MU_3 * A_43_3 + A_43_0 + A_43_1 + A_43_2; + + // Round 45 (Partial Round) + // ARK (Add Round Constant) + pol ARK_44_0 = B_44_0 + poseidon2_params.C_44_0; + pol ARK_44_1 = B_44_0 + poseidon2_params.C_44_1; + pol ARK_44_2 = B_44_0 + poseidon2_params.C_44_2; + pol ARK_44_3 = B_44_0 + poseidon2_params.C_44_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_44_0 = ARK_44_0 * ARK_44_0 * ARK_44_0 * ARK_44_0 * ARK_44_0; + pol A_44_1 = ARK_44_1; + pol A_44_2 = ARK_44_2; + pol A_44_3 = ARK_44_3; + + // MATRIX (Partial round uses the external matrix) + pol B_44_0 = poseidon2_params.MU_0 * A_44_0 + A_44_1 + A_44_2 + A_44_3; + pol B_44_1 = poseidon2_params.MU_1 * A_44_1 + A_44_0 + A_44_2 + A_44_3; + pol B_44_2 = poseidon2_params.MU_2 * A_44_2 + A_44_0 + A_44_1 + A_44_3; + pol B_44_3 = poseidon2_params.MU_3 * A_44_3 + A_44_0 + A_44_1 + A_44_2; + + // Round 46 (Partial Round) + // ARK (Add Round Constant) + pol ARK_45_0 = B_45_0 + poseidon2_params.C_45_0; + pol ARK_45_1 = B_45_0 + poseidon2_params.C_45_1; + pol ARK_45_2 = B_45_0 + poseidon2_params.C_45_2; + pol ARK_45_3 = B_45_0 + poseidon2_params.C_45_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_45_0 = ARK_45_0 * ARK_45_0 * ARK_45_0 * ARK_45_0 * ARK_45_0; + pol A_45_1 = ARK_45_1; + pol A_45_2 = ARK_45_2; + pol A_45_3 = ARK_45_3; + + // MATRIX (Partial round uses the external matrix) + pol B_45_0 = poseidon2_params.MU_0 * A_45_0 + A_45_1 + A_45_2 + A_45_3; + pol B_45_1 = poseidon2_params.MU_1 * A_45_1 + A_45_0 + A_45_2 + A_45_3; + pol B_45_2 = poseidon2_params.MU_2 * A_45_2 + A_45_0 + A_45_1 + A_45_3; + pol B_45_3 = poseidon2_params.MU_3 * A_45_3 + A_45_0 + A_45_1 + A_45_2; + + // Round 47 (Partial Round) + // ARK (Add Round Constant) + pol ARK_46_0 = B_46_0 + poseidon2_params.C_46_0; + pol ARK_46_1 = B_46_0 + poseidon2_params.C_46_1; + pol ARK_46_2 = B_46_0 + poseidon2_params.C_46_2; + pol ARK_46_3 = B_46_0 + poseidon2_params.C_46_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_46_0 = ARK_46_0 * ARK_46_0 * ARK_46_0 * ARK_46_0 * ARK_46_0; + pol A_46_1 = ARK_46_1; + pol A_46_2 = ARK_46_2; + pol A_46_3 = ARK_46_3; + + // MATRIX (Partial round uses the external matrix) + pol B_46_0 = poseidon2_params.MU_0 * A_46_0 + A_46_1 + A_46_2 + A_46_3; + pol B_46_1 = poseidon2_params.MU_1 * A_46_1 + A_46_0 + A_46_2 + A_46_3; + pol B_46_2 = poseidon2_params.MU_2 * A_46_2 + A_46_0 + A_46_1 + A_46_3; + pol B_46_3 = poseidon2_params.MU_3 * A_46_3 + A_46_0 + A_46_1 + A_46_2; + + // Round 48 (Partial Round) + // ARK (Add Round Constant) + pol ARK_47_0 = B_47_0 + poseidon2_params.C_47_0; + pol ARK_47_1 = B_47_0 + poseidon2_params.C_47_1; + pol ARK_47_2 = B_47_0 + poseidon2_params.C_47_2; + pol ARK_47_3 = B_47_0 + poseidon2_params.C_47_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_47_0 = ARK_47_0 * ARK_47_0 * ARK_47_0 * ARK_47_0 * ARK_47_0; + pol A_47_1 = ARK_47_1; + pol A_47_2 = ARK_47_2; + pol A_47_3 = ARK_47_3; + + // MATRIX (Partial round uses the external matrix) + pol B_47_0 = poseidon2_params.MU_0 * A_47_0 + A_47_1 + A_47_2 + A_47_3; + pol B_47_1 = poseidon2_params.MU_1 * A_47_1 + A_47_0 + A_47_2 + A_47_3; + pol B_47_2 = poseidon2_params.MU_2 * A_47_2 + A_47_0 + A_47_1 + A_47_3; + pol B_47_3 = poseidon2_params.MU_3 * A_47_3 + A_47_0 + A_47_1 + A_47_2; + + // Round 49 (Partial Round) + // ARK (Add Round Constant) + pol ARK_48_0 = B_48_0 + poseidon2_params.C_48_0; + pol ARK_48_1 = B_48_0 + poseidon2_params.C_48_1; + pol ARK_48_2 = B_48_0 + poseidon2_params.C_48_2; + pol ARK_48_3 = B_48_0 + poseidon2_params.C_48_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_48_0 = ARK_48_0 * ARK_48_0 * ARK_48_0 * ARK_48_0 * ARK_48_0; + pol A_48_1 = ARK_48_1; + pol A_48_2 = ARK_48_2; + pol A_48_3 = ARK_48_3; + + // MATRIX (Partial round uses the external matrix) + pol B_48_0 = poseidon2_params.MU_0 * A_48_0 + A_48_1 + A_48_2 + A_48_3; + pol B_48_1 = poseidon2_params.MU_1 * A_48_1 + A_48_0 + A_48_2 + A_48_3; + pol B_48_2 = poseidon2_params.MU_2 * A_48_2 + A_48_0 + A_48_1 + A_48_3; + pol B_48_3 = poseidon2_params.MU_3 * A_48_3 + A_48_0 + A_48_1 + A_48_2; + + // Round 50 (Partial Round) + // ARK (Add Round Constant) + pol ARK_49_0 = B_49_0 + poseidon2_params.C_49_0; + pol ARK_49_1 = B_49_0 + poseidon2_params.C_49_1; + pol ARK_49_2 = B_49_0 + poseidon2_params.C_49_2; + pol ARK_49_3 = B_49_0 + poseidon2_params.C_49_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_49_0 = ARK_49_0 * ARK_49_0 * ARK_49_0 * ARK_49_0 * ARK_49_0; + pol A_49_1 = ARK_49_1; + pol A_49_2 = ARK_49_2; + pol A_49_3 = ARK_49_3; + + // MATRIX (Partial round uses the external matrix) + pol B_49_0 = poseidon2_params.MU_0 * A_49_0 + A_49_1 + A_49_2 + A_49_3; + pol B_49_1 = poseidon2_params.MU_1 * A_49_1 + A_49_0 + A_49_2 + A_49_3; + pol B_49_2 = poseidon2_params.MU_2 * A_49_2 + A_49_0 + A_49_1 + A_49_3; + pol B_49_3 = poseidon2_params.MU_3 * A_49_3 + A_49_0 + A_49_1 + A_49_2; + + // Round 51 (Partial Round) + // ARK (Add Round Constant) + pol ARK_50_0 = B_50_0 + poseidon2_params.C_50_0; + pol ARK_50_1 = B_50_0 + poseidon2_params.C_50_1; + pol ARK_50_2 = B_50_0 + poseidon2_params.C_50_2; + pol ARK_50_3 = B_50_0 + poseidon2_params.C_50_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_50_0 = ARK_50_0 * ARK_50_0 * ARK_50_0 * ARK_50_0 * ARK_50_0; + pol A_50_1 = ARK_50_1; + pol A_50_2 = ARK_50_2; + pol A_50_3 = ARK_50_3; + + // MATRIX (Partial round uses the external matrix) + pol B_50_0 = poseidon2_params.MU_0 * A_50_0 + A_50_1 + A_50_2 + A_50_3; + pol B_50_1 = poseidon2_params.MU_1 * A_50_1 + A_50_0 + A_50_2 + A_50_3; + pol B_50_2 = poseidon2_params.MU_2 * A_50_2 + A_50_0 + A_50_1 + A_50_3; + pol B_50_3 = poseidon2_params.MU_3 * A_50_3 + A_50_0 + A_50_1 + A_50_2; + + // Round 52 (Partial Round) + // ARK (Add Round Constant) + pol ARK_51_0 = B_51_0 + poseidon2_params.C_51_0; + pol ARK_51_1 = B_51_0 + poseidon2_params.C_51_1; + pol ARK_51_2 = B_51_0 + poseidon2_params.C_51_2; + pol ARK_51_3 = B_51_0 + poseidon2_params.C_51_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_51_0 = ARK_51_0 * ARK_51_0 * ARK_51_0 * ARK_51_0 * ARK_51_0; + pol A_51_1 = ARK_51_1; + pol A_51_2 = ARK_51_2; + pol A_51_3 = ARK_51_3; + + // MATRIX (Partial round uses the external matrix) + pol B_51_0 = poseidon2_params.MU_0 * A_51_0 + A_51_1 + A_51_2 + A_51_3; + pol B_51_1 = poseidon2_params.MU_1 * A_51_1 + A_51_0 + A_51_2 + A_51_3; + pol B_51_2 = poseidon2_params.MU_2 * A_51_2 + A_51_0 + A_51_1 + A_51_3; + pol B_51_3 = poseidon2_params.MU_3 * A_51_3 + A_51_0 + A_51_1 + A_51_2; + + // Round 53 (Partial Round) + // ARK (Add Round Constant) + pol ARK_52_0 = B_52_0 + poseidon2_params.C_52_0; + pol ARK_52_1 = B_52_0 + poseidon2_params.C_52_1; + pol ARK_52_2 = B_52_0 + poseidon2_params.C_52_2; + pol ARK_52_3 = B_52_0 + poseidon2_params.C_52_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_52_0 = ARK_52_0 * ARK_52_0 * ARK_52_0 * ARK_52_0 * ARK_52_0; + pol A_52_1 = ARK_52_1; + pol A_52_2 = ARK_52_2; + pol A_52_3 = ARK_52_3; + + // MATRIX (Partial round uses the external matrix) + pol B_52_0 = poseidon2_params.MU_0 * A_52_0 + A_52_1 + A_52_2 + A_52_3; + pol B_52_1 = poseidon2_params.MU_1 * A_52_1 + A_52_0 + A_52_2 + A_52_3; + pol B_52_2 = poseidon2_params.MU_2 * A_52_2 + A_52_0 + A_52_1 + A_52_3; + pol B_52_3 = poseidon2_params.MU_3 * A_52_3 + A_52_0 + A_52_1 + A_52_2; + + // Round 54 (Partial Round) + // ARK (Add Round Constant) + pol ARK_53_0 = B_53_0 + poseidon2_params.C_53_0; + pol ARK_53_1 = B_53_0 + poseidon2_params.C_53_1; + pol ARK_53_2 = B_53_0 + poseidon2_params.C_53_2; + pol ARK_53_3 = B_53_0 + poseidon2_params.C_53_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_53_0 = ARK_53_0 * ARK_53_0 * ARK_53_0 * ARK_53_0 * ARK_53_0; + pol A_53_1 = ARK_53_1; + pol A_53_2 = ARK_53_2; + pol A_53_3 = ARK_53_3; + + // MATRIX (Partial round uses the external matrix) + pol B_53_0 = poseidon2_params.MU_0 * A_53_0 + A_53_1 + A_53_2 + A_53_3; + pol B_53_1 = poseidon2_params.MU_1 * A_53_1 + A_53_0 + A_53_2 + A_53_3; + pol B_53_2 = poseidon2_params.MU_2 * A_53_2 + A_53_0 + A_53_1 + A_53_3; + pol B_53_3 = poseidon2_params.MU_3 * A_53_3 + A_53_0 + A_53_1 + A_53_2; + + // Round 55 (Partial Round) + // ARK (Add Round Constant) + pol ARK_54_0 = B_54_0 + poseidon2_params.C_54_0; + pol ARK_54_1 = B_54_0 + poseidon2_params.C_54_1; + pol ARK_54_2 = B_54_0 + poseidon2_params.C_54_2; + pol ARK_54_3 = B_54_0 + poseidon2_params.C_54_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_54_0 = ARK_54_0 * ARK_54_0 * ARK_54_0 * ARK_54_0 * ARK_54_0; + pol A_54_1 = ARK_54_1; + pol A_54_2 = ARK_54_2; + pol A_54_3 = ARK_54_3; + + // MATRIX (Partial round uses the external matrix) + pol B_54_0 = poseidon2_params.MU_0 * A_54_0 + A_54_1 + A_54_2 + A_54_3; + pol B_54_1 = poseidon2_params.MU_1 * A_54_1 + A_54_0 + A_54_2 + A_54_3; + pol B_54_2 = poseidon2_params.MU_2 * A_54_2 + A_54_0 + A_54_1 + A_54_3; + pol B_54_3 = poseidon2_params.MU_3 * A_54_3 + A_54_0 + A_54_1 + A_54_2; + + // Round 56 (Partial Round) + // ARK (Add Round Constant) + pol ARK_55_0 = B_55_0 + poseidon2_params.C_55_0; + pol ARK_55_1 = B_55_0 + poseidon2_params.C_55_1; + pol ARK_55_2 = B_55_0 + poseidon2_params.C_55_2; + pol ARK_55_3 = B_55_0 + poseidon2_params.C_55_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_55_0 = ARK_55_0 * ARK_55_0 * ARK_55_0 * ARK_55_0 * ARK_55_0; + pol A_55_1 = ARK_55_1; + pol A_55_2 = ARK_55_2; + pol A_55_3 = ARK_55_3; + + // MATRIX (Partial round uses the external matrix) + pol B_55_0 = poseidon2_params.MU_0 * A_55_0 + A_55_1 + A_55_2 + A_55_3; + pol B_55_1 = poseidon2_params.MU_1 * A_55_1 + A_55_0 + A_55_2 + A_55_3; + pol B_55_2 = poseidon2_params.MU_2 * A_55_2 + A_55_0 + A_55_1 + A_55_3; + pol B_55_3 = poseidon2_params.MU_3 * A_55_3 + A_55_0 + A_55_1 + A_55_2; + + // Round 57 (Partial Round) + // ARK (Add Round Constant) + pol ARK_56_0 = B_56_0 + poseidon2_params.C_56_0; + pol ARK_56_1 = B_56_0 + poseidon2_params.C_56_1; + pol ARK_56_2 = B_56_0 + poseidon2_params.C_56_2; + pol ARK_56_3 = B_56_0 + poseidon2_params.C_56_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_56_0 = ARK_56_0 * ARK_56_0 * ARK_56_0 * ARK_56_0 * ARK_56_0; + pol A_56_1 = ARK_56_1; + pol A_56_2 = ARK_56_2; + pol A_56_3 = ARK_56_3; + + // MATRIX (Partial round uses the external matrix) + pol B_56_0 = poseidon2_params.MU_0 * A_56_0 + A_56_1 + A_56_2 + A_56_3; + pol B_56_1 = poseidon2_params.MU_1 * A_56_1 + A_56_0 + A_56_2 + A_56_3; + pol B_56_2 = poseidon2_params.MU_2 * A_56_2 + A_56_0 + A_56_1 + A_56_3; + pol B_56_3 = poseidon2_params.MU_3 * A_56_3 + A_56_0 + A_56_1 + A_56_2; + + // Round 58 (Partial Round) + // ARK (Add Round Constant) + pol ARK_57_0 = B_57_0 + poseidon2_params.C_57_0; + pol ARK_57_1 = B_57_0 + poseidon2_params.C_57_1; + pol ARK_57_2 = B_57_0 + poseidon2_params.C_57_2; + pol ARK_57_3 = B_57_0 + poseidon2_params.C_57_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_57_0 = ARK_57_0 * ARK_57_0 * ARK_57_0 * ARK_57_0 * ARK_57_0; + pol A_57_1 = ARK_57_1; + pol A_57_2 = ARK_57_2; + pol A_57_3 = ARK_57_3; + + // MATRIX (Partial round uses the external matrix) + pol B_57_0 = poseidon2_params.MU_0 * A_57_0 + A_57_1 + A_57_2 + A_57_3; + pol B_57_1 = poseidon2_params.MU_1 * A_57_1 + A_57_0 + A_57_2 + A_57_3; + pol B_57_2 = poseidon2_params.MU_2 * A_57_2 + A_57_0 + A_57_1 + A_57_3; + pol B_57_3 = poseidon2_params.MU_3 * A_57_3 + A_57_0 + A_57_1 + A_57_2; + + // Round 59 (Partial Round) + // ARK (Add Round Constant) + pol ARK_58_0 = B_58_0 + poseidon2_params.C_58_0; + pol ARK_58_1 = B_58_0 + poseidon2_params.C_58_1; + pol ARK_58_2 = B_58_0 + poseidon2_params.C_58_2; + pol ARK_58_3 = B_58_0 + poseidon2_params.C_58_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_58_0 = ARK_58_0 * ARK_58_0 * ARK_58_0 * ARK_58_0 * ARK_58_0; + pol A_58_1 = ARK_58_1; + pol A_58_2 = ARK_58_2; + pol A_58_3 = ARK_58_3; + + // MATRIX (Partial round uses the external matrix) + pol B_58_0 = poseidon2_params.MU_0 * A_58_0 + A_58_1 + A_58_2 + A_58_3; + pol B_58_1 = poseidon2_params.MU_1 * A_58_1 + A_58_0 + A_58_2 + A_58_3; + pol B_58_2 = poseidon2_params.MU_2 * A_58_2 + A_58_0 + A_58_1 + A_58_3; + pol B_58_3 = poseidon2_params.MU_3 * A_58_3 + A_58_0 + A_58_1 + A_58_2; + + // Round 60 (Partial Round) + // ARK (Add Round Constant) + pol ARK_59_0 = B_59_0 + poseidon2_params.C_59_0; + pol ARK_59_1 = B_59_0 + poseidon2_params.C_59_1; + pol ARK_59_2 = B_59_0 + poseidon2_params.C_59_2; + pol ARK_59_3 = B_59_0 + poseidon2_params.C_59_3; + + // S-BOX (In partial round only first input is exponentiated) + pol A_59_0 = ARK_59_0 * ARK_59_0 * ARK_59_0 * ARK_59_0 * ARK_59_0; + pol A_59_1 = ARK_59_1; + pol A_59_2 = ARK_59_2; + pol A_59_3 = ARK_59_3; + + // MATRIX (Partial round uses the external matrix) + pol B_59_0 = poseidon2_params.MU_0 * A_59_0 + A_59_1 + A_59_2 + A_59_3; + pol B_59_1 = poseidon2_params.MU_1 * A_59_1 + A_59_0 + A_59_2 + A_59_3; + pol B_59_2 = poseidon2_params.MU_2 * A_59_2 + A_59_0 + A_59_1 + A_59_3; + pol B_59_3 = poseidon2_params.MU_3 * A_59_3 + A_59_0 + A_59_1 + A_59_2; + + ///////////////////////////////////////////////////// + // FINAL FULL ROUND (4 ROUNDS) + ///////////////////////////////////////////////////// + // Round 61 (Full Round) + // ARK (Add Round Constant) + pol ARK_60_0 = B_59_0 + poseidon2_params.C_60_0; + pol ARK_60_1 = B_59_1 + poseidon2_params.C_60_1; + pol ARK_60_2 = B_59_2 + poseidon2_params.C_60_2; + pol ARK_60_3 = B_59_3 + poseidon2_params.C_60_3; + + // S-BOX (In full round all inputs are exponentiated) + pol A_60_0 = ARK_60_0 * ARK_60_0 * ARK_60_0 * ARK_60_0 * ARK_60_0; + pol A_60_1 = ARK_60_1 * ARK_60_1 * ARK_60_1 * ARK_60_1 * ARK_60_1; + pol A_60_2 = ARK_60_2 * ARK_60_2 * ARK_60_2 * ARK_60_2 * ARK_60_2; + pol A_60_3 = ARK_60_3 * ARK_60_3 * ARK_60_3 * ARK_60_3 * ARK_60_3; + + // MATRIX (Full round uses the external matrix) + pol T_60_0 = A_60_0 + A_60_1; + pol T_60_1 = A_60_2 + A_60_3; + pol T_60_2 = 2 * A_60_1 + T_60_0; + pol T_60_3 = 2 * A_60_3 + T_60_0; + pol T_60_4 = 4 * T_60_1 + T_60_3; + pol T_60_5 = 4 * T_60_0 + T_60_2; + pol T_60_6 = T_60_3 + T_60_5; + pol T_60_7 = T_60_2 + T_60_4; + + // Round 62 (Full Round) + // ARK (Add Round Constant) + pol ARK_61_0 = T_60_6 + poseidon2_params.C_61_0; + pol ARK_61_1 = T_60_5 + poseidon2_params.C_61_1; + pol ARK_61_2 = T_60_7 + poseidon2_params.C_61_2; + pol ARK_61_3 = T_60_4 + poseidon2_params.C_61_3; + + // S-BOX (In full round all inputs are exponentiated) + pol A_61_0 = ARK_61_0 * ARK_61_0 * ARK_61_0 * ARK_61_0 * ARK_61_0; + pol A_61_1 = ARK_61_1 * ARK_61_1 * ARK_61_1 * ARK_61_1 * ARK_61_1; + pol A_61_2 = ARK_61_2 * ARK_61_2 * ARK_61_2 * ARK_61_2 * ARK_61_2; + pol A_61_3 = ARK_61_3 * ARK_61_3 * ARK_61_3 * ARK_61_3 * ARK_61_3; + + // MATRIX (Full round uses the external matrix) + pol T_61_0 = A_61_0 + A_61_1; + pol T_61_1 = A_61_2 + A_61_3; + pol T_61_2 = 2 * A_61_1 + T_61_0; + pol T_61_3 = 2 * A_61_3 + T_61_0; + pol T_61_4 = 4 * T_61_1 + T_61_3; + pol T_61_5 = 4 * T_61_0 + T_61_2; + pol T_61_6 = T_61_3 + T_61_5; + pol T_61_7 = T_61_2 + T_61_4; + + // Round 63 (Full Round) + // ARK (Add Round Constant) + pol ARK_62_0 = T_61_6 + poseidon2_params.C_62_0; + pol ARK_62_1 = T_61_5 + poseidon2_params.C_62_1; + pol ARK_62_2 = T_61_7 + poseidon2_params.C_62_2; + pol ARK_62_3 = T_61_4 + poseidon2_params.C_62_3; + + // S-BOX (In full round all inputs are exponentiated) + pol A_62_0 = ARK_62_0 * ARK_62_0 * ARK_62_0 * ARK_62_0 * ARK_62_0; + pol A_62_1 = ARK_62_1 * ARK_62_1 * ARK_62_1 * ARK_62_1 * ARK_62_1; + pol A_62_2 = ARK_62_2 * ARK_62_2 * ARK_62_2 * ARK_62_2 * ARK_62_2; + pol A_62_3 = ARK_62_3 * ARK_62_3 * ARK_62_3 * ARK_62_3 * ARK_62_3; + + // MATRIX (Full round uses the external matrix) + pol T_62_0 = A_62_0 + A_62_1; + pol T_62_1 = A_62_2 + A_62_3; + pol T_62_2 = 2 * A_62_1 + T_62_0; + pol T_62_3 = 2 * A_62_3 + T_62_0; + pol T_62_4 = 4 * T_62_1 + T_62_3; + pol T_62_5 = 4 * T_62_0 + T_62_2; + pol T_62_6 = T_62_3 + T_62_5; + pol T_62_7 = T_62_2 + T_62_4; + + // Round 64 (Full Round) + // ARK (Add Round Constant) + pol ARK_63_0 = T_62_6 + poseidon2_params.C_63_0; + pol ARK_63_1 = T_62_5 + poseidon2_params.C_63_1; + pol ARK_63_2 = T_62_7 + poseidon2_params.C_63_2; + pol ARK_63_3 = T_62_4 + poseidon2_params.C_63_3; + + // S-BOX (In full round all inputs are exponentiated) + pol A_63_0 = ARK_63_0 * ARK_63_0 * ARK_63_0 * ARK_63_0 * ARK_63_0; + pol A_63_1 = ARK_63_1 * ARK_63_1 * ARK_63_1 * ARK_63_1 * ARK_63_1; + pol A_63_2 = ARK_63_2 * ARK_63_2 * ARK_63_2 * ARK_63_2 * ARK_63_2; + pol A_63_3 = ARK_63_3 * ARK_63_3 * ARK_63_3 * ARK_63_3 * ARK_63_3; + + // MATRIX (Full round uses the external matrix) + pol T_63_0 = A_63_0 + A_63_1; + pol T_63_1 = A_63_2 + A_63_3; + pol T_63_2 = 2 * A_63_1 + T_63_0; + pol T_63_3 = 2 * A_63_3 + T_63_0; + pol T_63_4 = 4 * T_63_1 + T_63_3; + pol T_63_5 = 4 * T_63_0 + T_63_2; + pol T_63_6 = T_63_3 + T_63_5; + pol T_63_7 = T_63_2 + T_63_4; + + ///////////////////////////////////////////////////// + // PERMUTATION END + ///////////////////////////////////////////////////// + // Check output against claimed output + // b_0 - T_63_6 = 0; + // b_1 - T_63_5 = 0; + // b_2 - T_63_7 = 0; + // b_2 - T_63_4 = 0; diff --git a/barretenberg/cpp/pil/avm/gadgets/poseidon2_params.pil b/barretenberg/cpp/pil/avm/gadgets/poseidon2_params.pil new file mode 100644 index 000000000000..195363af7944 --- /dev/null +++ b/barretenberg/cpp/pil/avm/gadgets/poseidon2_params.pil @@ -0,0 +1,336 @@ + + +// Parameters for Poseidon for bn254. +// 64 total rounds (8 full rounds and 56 partial rounds) +// Total rate (t) of 4; +// Alpha (exponentiation): 5 +namespace poseidon2_params(256); + // Internal Matrix Diagonal (for partial rounds) + pol MU_0 = 7626475329478847982857743246276194948757851985510858890691733676098590062311; + pol MU_1 = 5498568565063849786384470689962419967523752476452646391422913716315471115275; + pol MU_2 = 148936322117705719734052984176402258788283488576388928671173547788498414613; + pol MU_3 = 15456385653678559339152734484033356164266089951521103188900320352052358038155; + + // Round constants + // Naming scheme is c_{round_count}_{input_count} where the counts are zero-indexed + // So the round constant applied in the 5th round to the 3rd input is c_4_2 + // Round 1 constants + pol C_0_0 = 11633431549750490989983886834189948010834808234699737327785600195936805266405; + pol C_0_1 = 17353750182810071758476407404624088842693631054828301270920107619055744005334; + pol C_0_2 = 11575173631114898451293296430061690731976535592475236587664058405912382527658; + pol C_0_3 = 9724643380371653925020965751082872123058642683375812487991079305063678725624; + // Round 2 constants + pol C_1_0 = 20936725237749945635418633443468987188819556232926135747685274666391889856770; + pol C_1_1 = 6427758822462294912934022562310355233516927282963039741999349770315205779230; + pol C_1_2 = 16782979953202249973699352594809882974187694538612412531558950864304931387798; + pol C_1_3 = 8979171037234948998646722737761679613767384188475887657669871981433930833742; + // Round 3 constants + pol C_2_0 = 5428827536651017352121626533783677797977876323745420084354839999137145767736; + pol C_2_1 = 507241738797493565802569310165979445570507129759637903167193063764556368390; + pol C_2_2 = 6711578168107599474498163409443059675558516582274824463959700553865920673097; + pol C_2_3 = 2197359304646916921018958991647650011119043556688567376178243393652789311643; + // Round 4 constants + pol C_3_0 = 4634703622846121403803831560584049007806112989824652272428991253572845447400; + pol C_3_1 = 17008376818199175111793852447685303011746023680921106348278379453039148937791; + pol C_3_2 = 18430784755956196942937899353653692286521408688385681805132578732731487278753; + pol C_3_3 = 4573768376486344895797915946239137669624900197544620153250805961657870918727; + // Round 5 constants + pol C_4_0 = 5624865188680173294191042415227598609140934495743721047183803859030618890703; + pol C_4_1 = 0; + pol C_4_2 = 0; + pol C_4_3 = 0; + // Round 6 constants + pol C_5_0 = 8228252753786907198149068514193371173033070694924002912950645971088002709521; + pol C_5_1 = 0; + pol C_5_2 = 0; + pol C_5_3 = 0; + // Round 7 constants + pol C_6_0 = 17586714789554691446538331362711502394998837215506284064347036653995353304693; + pol C_6_1 = 0; + pol C_6_2 = 0; + pol C_6_3 = 0; + // Round 8 constants + pol C_7_0 = 12985198716830497423350597750558817467658937953000235442251074063454897365701; + pol C_7_1 = 0; + pol C_7_2 = 0; + pol C_7_3 = 0; + // Round 9 constants + pol C_8_0 = 13480076116139680784838493959937969792577589073830107110893279354229821035984; + pol C_8_1 = 0; + pol C_8_2 = 0; + pol C_8_3 = 0; + // Round 10 constants + pol C_9_0 = 480609231761423388761863647137314056373740727639536352979673303078459561332; + pol C_9_1 = 0; + pol C_9_2 = 0; + pol C_9_3 = 0; + // Round 11 constants + pol C_10_0 = 19503345496799249258956440299354839375920540225688429628121751361906635419276; + pol C_10_1 = 0; + pol C_10_2 = 0; + pol C_10_3 = 0; + // Round 12 constants + pol C_11_0 = 16837818502122887883669221005435922946567532037624537243846974433811447595173; + pol C_11_1 = 0; + pol C_11_2 = 0; + pol C_11_3 = 0; + // Round 13 constants + pol C_12_0 = 5492108497278641078569490709794391352213168666744080628008171695469579703581; + pol C_12_1 = 0; + pol C_12_2 = 0; + pol C_12_3 = 0; + // Round 14 constants + pol C_13_0 = 11365311159988448419785032079155356000691294261495515880484003277443744617083; + pol C_13_1 = 0; + pol C_13_2 = 0; + pol C_13_3 = 0; + // Round 15 constants + pol C_14_0 = 13876891705632851072613751905778242936713392247975808888614530203269491723653; + pol C_14_1 = 0; + pol C_14_2 = 0; + pol C_14_3 = 0; + // Round 16 constants + pol C_15_0 = 10660388389107698747692475159023710744797290186015856503629656779989214850043; + pol C_15_1 = 0; + pol C_15_2 = 0; + pol C_15_3 = 0; + // Round 17 constants + pol C_16_0 = 18876318870401623474401728758498150977988613254023317877612912724282285739292; + pol C_16_1 = 0; + pol C_16_2 = 0; + pol C_16_3 = 0; + // Round 18 constants + pol C_17_0 = 15543349138237018307536452195922365893694804703361435879256942490123776892424; + pol C_17_1 = 0; + pol C_17_2 = 0; + pol C_17_3 = 0; + // Round 19 constants + pol C_18_0 = 2839988449157209999638903652853828318645773519300826410959678570041742458201; + pol C_18_1 = 0; + pol C_18_2 = 0; + pol C_18_3 = 0; + // Round 20 constants + pol C_19_0 = 7566039810305694135184226097163626060317478635973510706368412858136696413063; + pol C_19_1 = 0; + pol C_19_2 = 0; + pol C_19_3 = 0; + // Round 21 constants + pol C_20_0 = 6344830340705033582410486810600848473125256338903726340728639711688240744220; + pol C_20_1 = 0; + pol C_20_2 = 0; + pol C_20_3 = 0; + // Round 22 constants + pol C_21_0 = 12475357769019880256619207099578191648078162511547701737481203260317463892731; + pol C_21_1 = 0; + pol C_21_2 = 0; + pol C_21_3 = 0; + // Round 23 constants + pol C_22_0 = 13337401254840718303633782478677852514218549070508887338718446132574012311307; + pol C_22_1 = 0; + pol C_22_2 = 0; + pol C_22_3 = 0; + // Round 24 constants + pol C_23_0 = 21161869193849404954234950798647336336709035097706159414187214758702055364571; + pol C_23_1 = 0; + pol C_23_2 = 0; + pol C_23_3 = 0; + // Round 25 constants + pol C_24_0 = 20671052961616073313397254362345395594858011165315285344464242404604146448678; + pol C_24_1 = 0; + pol C_24_2 = 0; + pol C_24_3 = 0; + // Round 26 constants + pol C_25_0 = 2772189387845778213446441819361180378678387127454165972767013098872140927416; + pol C_25_1 = 0; + pol C_25_2 = 0; + pol C_25_3 = 0; + // Round 27 constants + pol C_26_0 = 3339032002224218054945450150550795352855387702520990006196627537441898997147; + pol C_26_1 = 0; + pol C_26_2 = 0; + pol C_26_3 = 0; + // Round 28 constants + pol C_27_0 = 14919705931281848425960108279746818433850049439186607267862213649460469542157; + pol C_27_1 = 0; + pol C_27_2 = 0; + pol C_27_3 = 0; + // Round 29 constants + pol C_28_0 = 17056699976793486403099510941807022658662936611123286147276760381688934087770; + pol C_28_1 = 0; + pol C_28_2 = 0; + pol C_28_3 = 0; + // Round 30 constants + pol C_29_0 = 16144580075268719403964467603213740327573316872987042261854346306108421013323; + pol C_29_1 = 0; + pol C_29_2 = 0; + pol C_29_3 = 0; + // Round 31 constants + pol C_30_0 = 15582343953927413680541644067712456296539774919658221087452235772880573393376; + pol C_30_1 = 0; + pol C_30_2 = 0; + pol C_30_3 = 0; + // Round 32 constants + pol C_31_0 = 17528510080741946423534916423363640132610906812668323263058626230135522155749; + pol C_31_1 = 0; + pol C_31_2 = 0; + pol C_31_3 = 0; + // Round 33 constants + pol C_32_0 = 3190600034239022251529646836642735752388641846393941612827022280601486805721; + pol C_32_1 = 0; + pol C_32_2 = 0; + pol C_32_3 = 0; + // Round 34 constants + pol C_33_0 = 8463814172152682468446984305780323150741498069701538916468821815030498611418; + pol C_33_1 = 0; + pol C_33_2 = 0; + pol C_33_3 = 0; + // Round 35 constants + pol C_34_0 = 16533435971270903741871235576178437313873873358463959658178441562520661055273; + pol C_34_1 = 0; + pol C_34_2 = 0; + pol C_34_3 = 0; + // Round 36 constants + pol C_35_0 = 11845696835505436397913764735273748291716405946246049903478361223369666046634; + pol C_35_1 = 0; + pol C_35_2 = 0; + pol C_35_3 = 0; + // Round 37 constants + pol C_36_0 = 18391057370973634202531308463652130631065370546571735004701144829951670507215; + pol C_36_1 = 0; + pol C_36_2 = 0; + pol C_36_3 = 0; + // Round 38 constants + pol C_37_0 = 262537877325812689820791215463881982531707709719292538608229687240243203710; + pol C_37_1 = 0; + pol C_37_2 = 0; + pol C_37_3 = 0; + // Round 39 constants + pol C_38_0 = 2187234489894387585309965540987639130975753519805550941279098789852422770021; + pol C_38_1 = 0; + pol C_38_2 = 0; + pol C_38_3 = 0; + // Round 40 constants + pol C_39_0 = 19189656350920455659006418422409390013967064310525314160026356916172976152967; + pol C_39_1 = 0; + pol C_39_2 = 0; + pol C_39_3 = 0; + // Round 41 constants + pol C_40_0 = 15839474183930359560478122372067744245080413846070743460407578046890458719219; + pol C_40_1 = 0; + pol C_40_2 = 0; + pol C_40_3 = 0; + // Round 42 constants + pol C_41_0 = 1805019124769763805045852541831585930225376844141668951787801647576910524592; + pol C_41_1 = 0; + pol C_41_2 = 0; + pol C_41_3 = 0; + // Round 43 constants + pol C_42_0 = 323592203814803486950280155834638828455175703393817797003361354810251742052; + pol C_42_1 = 0; + pol C_42_2 = 0; + pol C_42_3 = 0; + // Round 44 constants + pol C_43_0 = 9780393509796825017346015868945480913627956475147371732521398519483580624282; + pol C_43_1 = 0; + pol C_43_2 = 0; + pol C_43_3 = 0; + // Round 45 constants + pol C_44_0 = 14009429785059642386335012561867511048847749030947687313594053997432177705759; + pol C_44_1 = 0; + pol C_44_2 = 0; + pol C_44_3 = 0; + // Round 46 constants + pol C_45_0 = 13749550162460745037234826077137388777330401847577727796245150843898019635981; + pol C_45_1 = 0; + pol C_45_2 = 0; + pol C_45_3 = 0; + // Round 47 constants + pol C_46_0 = 19497187499283431845443758879472819384797584633472792651343926414232528405311; + pol C_46_1 = 0; + pol C_46_2 = 0; + pol C_46_3 = 0; + // Round 48 constants + pol C_47_0 = 3708428802547661961864524194762556064568867603968214870300574294082023305587; + pol C_47_1 = 0; + pol C_47_2 = 0; + pol C_47_3 = 0; + // Round 49 constants + pol C_48_0 = 1339414413482882567499652761996854155383863472782829777976929310155400981782; + pol C_48_1 = 0; + pol C_48_2 = 0; + pol C_48_3 = 0; + // Round 50 constants + pol C_49_0 = 6396261245879814100794661157306877072718690153118140891315137894471052482309; + pol C_49_1 = 0; + pol C_49_2 = 0; + pol C_49_3 = 0; + // Round 51 constants + pol C_50_0 = 2069661495404347929962833138824526893650803079024564477269192079629046031674; + pol C_50_1 = 0; + pol C_50_2 = 0; + pol C_50_3 = 0; + // Round 52 constants + pol C_51_0 = 15793521554502133342917616035884588152451122589545915605459159078589855944361; + pol C_51_1 = 0; + pol C_51_2 = 0; + pol C_51_3 = 0; + // Round 53 constants + pol C_52_0 = 17053424498357819626596285492499512504457128907932827007302385782133229252374; + pol C_52_1 = 0; + pol C_52_2 = 0; + pol C_52_3 = 0; + // Round 54 constants + pol C_53_0 = 13658536470391360399708067455536748955260723760813498481671323619545320978896; + pol C_53_1 = 0; + pol C_53_2 = 0; + pol C_53_3 = 0; + // Round 55 constants + pol C_54_0 = 21546095668130239633971575351786704948662094117932406102037724221634677838565; + pol C_54_1 = 0; + pol C_54_2 = 0; + pol C_54_3 = 0; + // Round 56 constants + pol C_55_0 = 21411726238386979516934941789127061362496195649331822900487557574597304399109; + pol C_55_1 = 0; + pol C_55_2 = 0; + pol C_55_3 = 0; + // Round 57 constants + pol C_56_0 = 1944776378988765673004063363506638781964264107780425928778257145151172817981; + pol C_56_1 = 0; + pol C_56_2 = 0; + pol C_56_3 = 0; + // Round 58 constants + pol C_57_0 = 15590719714223718537172639598316570285163081746016049278954513732528516468773; + pol C_57_1 = 0; + pol C_57_2 = 0; + pol C_57_3 = 0; + // Round 59 constants + pol C_58_0 = 1351266421179051765004709939353170430290500926943038391678843253157009556309; + pol C_58_1 = 0; + pol C_58_2 = 0; + pol C_58_3 = 0; + // Round 60 constants + pol C_59_0 = 6772476224477167317130064764757502335545080109882028900432703947986275397548; + pol C_59_1 = 0; + pol C_59_2 = 0; + pol C_59_3 = 0; + // Round 61 constants + pol C_60_0 = 10670120969725161535937685539136065944959698664551200616467222887025111751992; + pol C_60_1 = 4731853626374224678749618809759140702342195350742653173378450474772131006181; + pol C_60_2 = 14473527495914528513885847341981310373531349450901830749157165104135412062812; + pol C_60_3 = 16937191362061486658876740597821783333355021670608822932942683228741190786143; + // Round 62 constants + pol C_61_0 = 5656559696428674390125424316117443507583679061659043998559560535270557939546; + pol C_61_1 = 8897648276515725841133578021896617755369443750194849587616503841335248902806; + pol C_61_2 = 14938684446722672719637788054570691068799510611164812175626676768545923371470; + pol C_61_3 = 15284149043690546115252102390417391226617211133644099356880071475803043461465; + // Round 63 constants + pol C_62_0 = 2623479025068612775740107497276979457946709347831661908218182874823658838107; + pol C_62_1 = 6809791961761836061129379546794905411734858375517368211894790874813684813988; + pol C_62_2 = 2417620338751920563196799065781703780495622795713803712576790485412779971775; + pol C_62_3 = 4445143310792944321746901285176579692343442786777464604312772017806735512661; + // Round 64 constants + pol C_63_0 = 1429019233589939118995503267516676481141938536269008901607126781291273208629; + pol C_63_1 = 19874283200702583165110559932895904979843482162236139561356679724680604144459; + pol C_63_2 = 13426632171723830006915194799390005513190035492503509233177687891041405113055; + pol C_63_3 = 10582332261829184460912611488470654685922576576939233092337240630493625631748; diff --git a/barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp b/barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp new file mode 100644 index 000000000000..0fe23d36ff60 --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp @@ -0,0 +1,512 @@ +#pragma once + +#define Avm_DECLARE_VIEWS(index) \ + using Accumulator = typename std::tuple_element::type; \ + using View = typename Accumulator::View; \ + [[maybe_unused]] auto main_clk = View(new_term.main_clk); \ + [[maybe_unused]] auto main_sel_first = View(new_term.main_sel_first); \ + [[maybe_unused]] auto kernel_kernel_inputs = View(new_term.kernel_kernel_inputs); \ + [[maybe_unused]] auto kernel_kernel_value_out = View(new_term.kernel_kernel_value_out); \ + [[maybe_unused]] auto kernel_kernel_side_effect_out = View(new_term.kernel_kernel_side_effect_out); \ + [[maybe_unused]] auto kernel_kernel_metadata_out = View(new_term.kernel_kernel_metadata_out); \ + [[maybe_unused]] auto main_calldata = View(new_term.main_calldata); \ + [[maybe_unused]] auto main_returndata = View(new_term.main_returndata); \ + [[maybe_unused]] auto alu_a_hi = View(new_term.alu_a_hi); \ + [[maybe_unused]] auto alu_a_lo = View(new_term.alu_a_lo); \ + [[maybe_unused]] auto alu_b_hi = View(new_term.alu_b_hi); \ + [[maybe_unused]] auto alu_b_lo = View(new_term.alu_b_lo); \ + [[maybe_unused]] auto alu_borrow = View(new_term.alu_borrow); \ + [[maybe_unused]] auto alu_cf = View(new_term.alu_cf); \ + [[maybe_unused]] auto alu_clk = View(new_term.alu_clk); \ + [[maybe_unused]] auto alu_cmp_rng_ctr = View(new_term.alu_cmp_rng_ctr); \ + [[maybe_unused]] auto alu_div_u16_r0 = View(new_term.alu_div_u16_r0); \ + [[maybe_unused]] auto alu_div_u16_r1 = View(new_term.alu_div_u16_r1); \ + [[maybe_unused]] auto alu_div_u16_r2 = View(new_term.alu_div_u16_r2); \ + [[maybe_unused]] auto alu_div_u16_r3 = View(new_term.alu_div_u16_r3); \ + [[maybe_unused]] auto alu_div_u16_r4 = View(new_term.alu_div_u16_r4); \ + [[maybe_unused]] auto alu_div_u16_r5 = View(new_term.alu_div_u16_r5); \ + [[maybe_unused]] auto alu_div_u16_r6 = View(new_term.alu_div_u16_r6); \ + [[maybe_unused]] auto alu_div_u16_r7 = View(new_term.alu_div_u16_r7); \ + [[maybe_unused]] auto alu_divisor_hi = View(new_term.alu_divisor_hi); \ + [[maybe_unused]] auto alu_divisor_lo = View(new_term.alu_divisor_lo); \ + [[maybe_unused]] auto alu_ff_tag = View(new_term.alu_ff_tag); \ + [[maybe_unused]] auto alu_ia = View(new_term.alu_ia); \ + [[maybe_unused]] auto alu_ib = View(new_term.alu_ib); \ + [[maybe_unused]] auto alu_ic = View(new_term.alu_ic); \ + [[maybe_unused]] auto alu_in_tag = View(new_term.alu_in_tag); \ + [[maybe_unused]] auto alu_op_add = View(new_term.alu_op_add); \ + [[maybe_unused]] auto alu_op_cast = View(new_term.alu_op_cast); \ + [[maybe_unused]] auto alu_op_cast_prev = View(new_term.alu_op_cast_prev); \ + [[maybe_unused]] auto alu_op_div = View(new_term.alu_op_div); \ + [[maybe_unused]] auto alu_op_div_a_lt_b = View(new_term.alu_op_div_a_lt_b); \ + [[maybe_unused]] auto alu_op_div_std = View(new_term.alu_op_div_std); \ + [[maybe_unused]] auto alu_op_eq = View(new_term.alu_op_eq); \ + [[maybe_unused]] auto alu_op_eq_diff_inv = View(new_term.alu_op_eq_diff_inv); \ + [[maybe_unused]] auto alu_op_lt = View(new_term.alu_op_lt); \ + [[maybe_unused]] auto alu_op_lte = View(new_term.alu_op_lte); \ + [[maybe_unused]] auto alu_op_mul = View(new_term.alu_op_mul); \ + [[maybe_unused]] auto alu_op_not = View(new_term.alu_op_not); \ + [[maybe_unused]] auto alu_op_shl = View(new_term.alu_op_shl); \ + [[maybe_unused]] auto alu_op_shr = View(new_term.alu_op_shr); \ + [[maybe_unused]] auto alu_op_sub = View(new_term.alu_op_sub); \ + [[maybe_unused]] auto alu_p_a_borrow = View(new_term.alu_p_a_borrow); \ + [[maybe_unused]] auto alu_p_b_borrow = View(new_term.alu_p_b_borrow); \ + [[maybe_unused]] auto alu_p_sub_a_hi = View(new_term.alu_p_sub_a_hi); \ + [[maybe_unused]] auto alu_p_sub_a_lo = View(new_term.alu_p_sub_a_lo); \ + [[maybe_unused]] auto alu_p_sub_b_hi = View(new_term.alu_p_sub_b_hi); \ + [[maybe_unused]] auto alu_p_sub_b_lo = View(new_term.alu_p_sub_b_lo); \ + [[maybe_unused]] auto alu_partial_prod_hi = View(new_term.alu_partial_prod_hi); \ + [[maybe_unused]] auto alu_partial_prod_lo = View(new_term.alu_partial_prod_lo); \ + [[maybe_unused]] auto alu_quotient_hi = View(new_term.alu_quotient_hi); \ + [[maybe_unused]] auto alu_quotient_lo = View(new_term.alu_quotient_lo); \ + [[maybe_unused]] auto alu_remainder = View(new_term.alu_remainder); \ + [[maybe_unused]] auto alu_res_hi = View(new_term.alu_res_hi); \ + [[maybe_unused]] auto alu_res_lo = View(new_term.alu_res_lo); \ + [[maybe_unused]] auto alu_sel_alu = View(new_term.alu_sel_alu); \ + [[maybe_unused]] auto alu_sel_cmp = View(new_term.alu_sel_cmp); \ + [[maybe_unused]] auto alu_sel_div_rng_chk = View(new_term.alu_sel_div_rng_chk); \ + [[maybe_unused]] auto alu_sel_rng_chk = View(new_term.alu_sel_rng_chk); \ + [[maybe_unused]] auto alu_sel_rng_chk_lookup = View(new_term.alu_sel_rng_chk_lookup); \ + [[maybe_unused]] auto alu_sel_shift_which = View(new_term.alu_sel_shift_which); \ + [[maybe_unused]] auto alu_shift_lt_bit_len = View(new_term.alu_shift_lt_bit_len); \ + [[maybe_unused]] auto alu_t_sub_s_bits = View(new_term.alu_t_sub_s_bits); \ + [[maybe_unused]] auto alu_two_pow_s = View(new_term.alu_two_pow_s); \ + [[maybe_unused]] auto alu_two_pow_t_sub_s = View(new_term.alu_two_pow_t_sub_s); \ + [[maybe_unused]] auto alu_u128_tag = View(new_term.alu_u128_tag); \ + [[maybe_unused]] auto alu_u16_r0 = View(new_term.alu_u16_r0); \ + [[maybe_unused]] auto alu_u16_r1 = View(new_term.alu_u16_r1); \ + [[maybe_unused]] auto alu_u16_r10 = View(new_term.alu_u16_r10); \ + [[maybe_unused]] auto alu_u16_r11 = View(new_term.alu_u16_r11); \ + [[maybe_unused]] auto alu_u16_r12 = View(new_term.alu_u16_r12); \ + [[maybe_unused]] auto alu_u16_r13 = View(new_term.alu_u16_r13); \ + [[maybe_unused]] auto alu_u16_r14 = View(new_term.alu_u16_r14); \ + [[maybe_unused]] auto alu_u16_r2 = View(new_term.alu_u16_r2); \ + [[maybe_unused]] auto alu_u16_r3 = View(new_term.alu_u16_r3); \ + [[maybe_unused]] auto alu_u16_r4 = View(new_term.alu_u16_r4); \ + [[maybe_unused]] auto alu_u16_r5 = View(new_term.alu_u16_r5); \ + [[maybe_unused]] auto alu_u16_r6 = View(new_term.alu_u16_r6); \ + [[maybe_unused]] auto alu_u16_r7 = View(new_term.alu_u16_r7); \ + [[maybe_unused]] auto alu_u16_r8 = View(new_term.alu_u16_r8); \ + [[maybe_unused]] auto alu_u16_r9 = View(new_term.alu_u16_r9); \ + [[maybe_unused]] auto alu_u16_tag = View(new_term.alu_u16_tag); \ + [[maybe_unused]] auto alu_u32_tag = View(new_term.alu_u32_tag); \ + [[maybe_unused]] auto alu_u64_tag = View(new_term.alu_u64_tag); \ + [[maybe_unused]] auto alu_u8_r0 = View(new_term.alu_u8_r0); \ + [[maybe_unused]] auto alu_u8_r1 = View(new_term.alu_u8_r1); \ + [[maybe_unused]] auto alu_u8_tag = View(new_term.alu_u8_tag); \ + [[maybe_unused]] auto binary_acc_ia = View(new_term.binary_acc_ia); \ + [[maybe_unused]] auto binary_acc_ib = View(new_term.binary_acc_ib); \ + [[maybe_unused]] auto binary_acc_ic = View(new_term.binary_acc_ic); \ + [[maybe_unused]] auto binary_clk = View(new_term.binary_clk); \ + [[maybe_unused]] auto binary_ia_bytes = View(new_term.binary_ia_bytes); \ + [[maybe_unused]] auto binary_ib_bytes = View(new_term.binary_ib_bytes); \ + [[maybe_unused]] auto binary_ic_bytes = View(new_term.binary_ic_bytes); \ + [[maybe_unused]] auto binary_in_tag = View(new_term.binary_in_tag); \ + [[maybe_unused]] auto binary_mem_tag_ctr = View(new_term.binary_mem_tag_ctr); \ + [[maybe_unused]] auto binary_mem_tag_ctr_inv = View(new_term.binary_mem_tag_ctr_inv); \ + [[maybe_unused]] auto binary_op_id = View(new_term.binary_op_id); \ + [[maybe_unused]] auto binary_sel_bin = View(new_term.binary_sel_bin); \ + [[maybe_unused]] auto binary_start = View(new_term.binary_start); \ + [[maybe_unused]] auto byte_lookup_sel_bin = View(new_term.byte_lookup_sel_bin); \ + [[maybe_unused]] auto byte_lookup_table_byte_lengths = View(new_term.byte_lookup_table_byte_lengths); \ + [[maybe_unused]] auto byte_lookup_table_in_tags = View(new_term.byte_lookup_table_in_tags); \ + [[maybe_unused]] auto byte_lookup_table_input_a = View(new_term.byte_lookup_table_input_a); \ + [[maybe_unused]] auto byte_lookup_table_input_b = View(new_term.byte_lookup_table_input_b); \ + [[maybe_unused]] auto byte_lookup_table_op_id = View(new_term.byte_lookup_table_op_id); \ + [[maybe_unused]] auto byte_lookup_table_output = View(new_term.byte_lookup_table_output); \ + [[maybe_unused]] auto conversion_clk = View(new_term.conversion_clk); \ + [[maybe_unused]] auto conversion_input = View(new_term.conversion_input); \ + [[maybe_unused]] auto conversion_num_limbs = View(new_term.conversion_num_limbs); \ + [[maybe_unused]] auto conversion_radix = View(new_term.conversion_radix); \ + [[maybe_unused]] auto conversion_sel_to_radix_le = View(new_term.conversion_sel_to_radix_le); \ + [[maybe_unused]] auto gas_da_gas_fixed_table = View(new_term.gas_da_gas_fixed_table); \ + [[maybe_unused]] auto gas_l2_gas_fixed_table = View(new_term.gas_l2_gas_fixed_table); \ + [[maybe_unused]] auto gas_sel_gas_cost = View(new_term.gas_sel_gas_cost); \ + [[maybe_unused]] auto keccakf1600_clk = View(new_term.keccakf1600_clk); \ + [[maybe_unused]] auto keccakf1600_input = View(new_term.keccakf1600_input); \ + [[maybe_unused]] auto keccakf1600_output = View(new_term.keccakf1600_output); \ + [[maybe_unused]] auto keccakf1600_sel_keccakf1600 = View(new_term.keccakf1600_sel_keccakf1600); \ + [[maybe_unused]] auto kernel_emit_l2_to_l1_msg_write_offset = \ + View(new_term.kernel_emit_l2_to_l1_msg_write_offset); \ + [[maybe_unused]] auto kernel_emit_note_hash_write_offset = View(new_term.kernel_emit_note_hash_write_offset); \ + [[maybe_unused]] auto kernel_emit_nullifier_write_offset = View(new_term.kernel_emit_nullifier_write_offset); \ + [[maybe_unused]] auto kernel_emit_unencrypted_log_write_offset = \ + View(new_term.kernel_emit_unencrypted_log_write_offset); \ + [[maybe_unused]] auto kernel_kernel_in_offset = View(new_term.kernel_kernel_in_offset); \ + [[maybe_unused]] auto kernel_kernel_out_offset = View(new_term.kernel_kernel_out_offset); \ + [[maybe_unused]] auto kernel_l1_to_l2_msg_exists_write_offset = \ + View(new_term.kernel_l1_to_l2_msg_exists_write_offset); \ + [[maybe_unused]] auto kernel_note_hash_exist_write_offset = View(new_term.kernel_note_hash_exist_write_offset); \ + [[maybe_unused]] auto kernel_nullifier_exists_write_offset = View(new_term.kernel_nullifier_exists_write_offset); \ + [[maybe_unused]] auto kernel_nullifier_non_exists_write_offset = \ + View(new_term.kernel_nullifier_non_exists_write_offset); \ + [[maybe_unused]] auto kernel_q_public_input_kernel_add_to_table = \ + View(new_term.kernel_q_public_input_kernel_add_to_table); \ + [[maybe_unused]] auto kernel_q_public_input_kernel_out_add_to_table = \ + View(new_term.kernel_q_public_input_kernel_out_add_to_table); \ + [[maybe_unused]] auto kernel_side_effect_counter = View(new_term.kernel_side_effect_counter); \ + [[maybe_unused]] auto kernel_sload_write_offset = View(new_term.kernel_sload_write_offset); \ + [[maybe_unused]] auto kernel_sstore_write_offset = View(new_term.kernel_sstore_write_offset); \ + [[maybe_unused]] auto main_abs_da_rem_gas_hi = View(new_term.main_abs_da_rem_gas_hi); \ + [[maybe_unused]] auto main_abs_da_rem_gas_lo = View(new_term.main_abs_da_rem_gas_lo); \ + [[maybe_unused]] auto main_abs_l2_rem_gas_hi = View(new_term.main_abs_l2_rem_gas_hi); \ + [[maybe_unused]] auto main_abs_l2_rem_gas_lo = View(new_term.main_abs_l2_rem_gas_lo); \ + [[maybe_unused]] auto main_alu_in_tag = View(new_term.main_alu_in_tag); \ + [[maybe_unused]] auto main_bin_op_id = View(new_term.main_bin_op_id); \ + [[maybe_unused]] auto main_call_ptr = View(new_term.main_call_ptr); \ + [[maybe_unused]] auto main_da_gas_op_cost = View(new_term.main_da_gas_op_cost); \ + [[maybe_unused]] auto main_da_gas_remaining = View(new_term.main_da_gas_remaining); \ + [[maybe_unused]] auto main_da_out_of_gas = View(new_term.main_da_out_of_gas); \ + [[maybe_unused]] auto main_ia = View(new_term.main_ia); \ + [[maybe_unused]] auto main_ib = View(new_term.main_ib); \ + [[maybe_unused]] auto main_ic = View(new_term.main_ic); \ + [[maybe_unused]] auto main_id = View(new_term.main_id); \ + [[maybe_unused]] auto main_id_zero = View(new_term.main_id_zero); \ + [[maybe_unused]] auto main_ind_addr_a = View(new_term.main_ind_addr_a); \ + [[maybe_unused]] auto main_ind_addr_b = View(new_term.main_ind_addr_b); \ + [[maybe_unused]] auto main_ind_addr_c = View(new_term.main_ind_addr_c); \ + [[maybe_unused]] auto main_ind_addr_d = View(new_term.main_ind_addr_d); \ + [[maybe_unused]] auto main_internal_return_ptr = View(new_term.main_internal_return_ptr); \ + [[maybe_unused]] auto main_inv = View(new_term.main_inv); \ + [[maybe_unused]] auto main_l2_gas_op_cost = View(new_term.main_l2_gas_op_cost); \ + [[maybe_unused]] auto main_l2_gas_remaining = View(new_term.main_l2_gas_remaining); \ + [[maybe_unused]] auto main_l2_out_of_gas = View(new_term.main_l2_out_of_gas); \ + [[maybe_unused]] auto main_mem_addr_a = View(new_term.main_mem_addr_a); \ + [[maybe_unused]] auto main_mem_addr_b = View(new_term.main_mem_addr_b); \ + [[maybe_unused]] auto main_mem_addr_c = View(new_term.main_mem_addr_c); \ + [[maybe_unused]] auto main_mem_addr_d = View(new_term.main_mem_addr_d); \ + [[maybe_unused]] auto main_op_err = View(new_term.main_op_err); \ + [[maybe_unused]] auto main_opcode_val = View(new_term.main_opcode_val); \ + [[maybe_unused]] auto main_pc = View(new_term.main_pc); \ + [[maybe_unused]] auto main_r_in_tag = View(new_term.main_r_in_tag); \ + [[maybe_unused]] auto main_rwa = View(new_term.main_rwa); \ + [[maybe_unused]] auto main_rwb = View(new_term.main_rwb); \ + [[maybe_unused]] auto main_rwc = View(new_term.main_rwc); \ + [[maybe_unused]] auto main_rwd = View(new_term.main_rwd); \ + [[maybe_unused]] auto main_sel_alu = View(new_term.main_sel_alu); \ + [[maybe_unused]] auto main_sel_bin = View(new_term.main_sel_bin); \ + [[maybe_unused]] auto main_sel_calldata = View(new_term.main_sel_calldata); \ + [[maybe_unused]] auto main_sel_gas_accounting_active = View(new_term.main_sel_gas_accounting_active); \ + [[maybe_unused]] auto main_sel_last = View(new_term.main_sel_last); \ + [[maybe_unused]] auto main_sel_mem_op_a = View(new_term.main_sel_mem_op_a); \ + [[maybe_unused]] auto main_sel_mem_op_activate_gas = View(new_term.main_sel_mem_op_activate_gas); \ + [[maybe_unused]] auto main_sel_mem_op_b = View(new_term.main_sel_mem_op_b); \ + [[maybe_unused]] auto main_sel_mem_op_c = View(new_term.main_sel_mem_op_c); \ + [[maybe_unused]] auto main_sel_mem_op_d = View(new_term.main_sel_mem_op_d); \ + [[maybe_unused]] auto main_sel_mov_ia_to_ic = View(new_term.main_sel_mov_ia_to_ic); \ + [[maybe_unused]] auto main_sel_mov_ib_to_ic = View(new_term.main_sel_mov_ib_to_ic); \ + [[maybe_unused]] auto main_sel_op_add = View(new_term.main_sel_op_add); \ + [[maybe_unused]] auto main_sel_op_address = View(new_term.main_sel_op_address); \ + [[maybe_unused]] auto main_sel_op_and = View(new_term.main_sel_op_and); \ + [[maybe_unused]] auto main_sel_op_block_number = View(new_term.main_sel_op_block_number); \ + [[maybe_unused]] auto main_sel_op_calldata_copy = View(new_term.main_sel_op_calldata_copy); \ + [[maybe_unused]] auto main_sel_op_cast = View(new_term.main_sel_op_cast); \ + [[maybe_unused]] auto main_sel_op_chain_id = View(new_term.main_sel_op_chain_id); \ + [[maybe_unused]] auto main_sel_op_cmov = View(new_term.main_sel_op_cmov); \ + [[maybe_unused]] auto main_sel_op_coinbase = View(new_term.main_sel_op_coinbase); \ + [[maybe_unused]] auto main_sel_op_dagasleft = View(new_term.main_sel_op_dagasleft); \ + [[maybe_unused]] auto main_sel_op_div = View(new_term.main_sel_op_div); \ + [[maybe_unused]] auto main_sel_op_emit_l2_to_l1_msg = View(new_term.main_sel_op_emit_l2_to_l1_msg); \ + [[maybe_unused]] auto main_sel_op_emit_note_hash = View(new_term.main_sel_op_emit_note_hash); \ + [[maybe_unused]] auto main_sel_op_emit_nullifier = View(new_term.main_sel_op_emit_nullifier); \ + [[maybe_unused]] auto main_sel_op_emit_unencrypted_log = View(new_term.main_sel_op_emit_unencrypted_log); \ + [[maybe_unused]] auto main_sel_op_eq = View(new_term.main_sel_op_eq); \ + [[maybe_unused]] auto main_sel_op_external_call = View(new_term.main_sel_op_external_call); \ + [[maybe_unused]] auto main_sel_op_external_return = View(new_term.main_sel_op_external_return); \ + [[maybe_unused]] auto main_sel_op_fdiv = View(new_term.main_sel_op_fdiv); \ + [[maybe_unused]] auto main_sel_op_fee_per_da_gas = View(new_term.main_sel_op_fee_per_da_gas); \ + [[maybe_unused]] auto main_sel_op_fee_per_l2_gas = View(new_term.main_sel_op_fee_per_l2_gas); \ + [[maybe_unused]] auto main_sel_op_function_selector = View(new_term.main_sel_op_function_selector); \ + [[maybe_unused]] auto main_sel_op_get_contract_instance = View(new_term.main_sel_op_get_contract_instance); \ + [[maybe_unused]] auto main_sel_op_halt = View(new_term.main_sel_op_halt); \ + [[maybe_unused]] auto main_sel_op_internal_call = View(new_term.main_sel_op_internal_call); \ + [[maybe_unused]] auto main_sel_op_internal_return = View(new_term.main_sel_op_internal_return); \ + [[maybe_unused]] auto main_sel_op_jump = View(new_term.main_sel_op_jump); \ + [[maybe_unused]] auto main_sel_op_jumpi = View(new_term.main_sel_op_jumpi); \ + [[maybe_unused]] auto main_sel_op_keccak = View(new_term.main_sel_op_keccak); \ + [[maybe_unused]] auto main_sel_op_l1_to_l2_msg_exists = View(new_term.main_sel_op_l1_to_l2_msg_exists); \ + [[maybe_unused]] auto main_sel_op_l2gasleft = View(new_term.main_sel_op_l2gasleft); \ + [[maybe_unused]] auto main_sel_op_lt = View(new_term.main_sel_op_lt); \ + [[maybe_unused]] auto main_sel_op_lte = View(new_term.main_sel_op_lte); \ + [[maybe_unused]] auto main_sel_op_mov = View(new_term.main_sel_op_mov); \ + [[maybe_unused]] auto main_sel_op_mul = View(new_term.main_sel_op_mul); \ + [[maybe_unused]] auto main_sel_op_not = View(new_term.main_sel_op_not); \ + [[maybe_unused]] auto main_sel_op_note_hash_exists = View(new_term.main_sel_op_note_hash_exists); \ + [[maybe_unused]] auto main_sel_op_nullifier_exists = View(new_term.main_sel_op_nullifier_exists); \ + [[maybe_unused]] auto main_sel_op_or = View(new_term.main_sel_op_or); \ + [[maybe_unused]] auto main_sel_op_pedersen = View(new_term.main_sel_op_pedersen); \ + [[maybe_unused]] auto main_sel_op_poseidon2 = View(new_term.main_sel_op_poseidon2); \ + [[maybe_unused]] auto main_sel_op_radix_le = View(new_term.main_sel_op_radix_le); \ + [[maybe_unused]] auto main_sel_op_sender = View(new_term.main_sel_op_sender); \ + [[maybe_unused]] auto main_sel_op_sha256 = View(new_term.main_sel_op_sha256); \ + [[maybe_unused]] auto main_sel_op_shl = View(new_term.main_sel_op_shl); \ + [[maybe_unused]] auto main_sel_op_shr = View(new_term.main_sel_op_shr); \ + [[maybe_unused]] auto main_sel_op_sload = View(new_term.main_sel_op_sload); \ + [[maybe_unused]] auto main_sel_op_sstore = View(new_term.main_sel_op_sstore); \ + [[maybe_unused]] auto main_sel_op_storage_address = View(new_term.main_sel_op_storage_address); \ + [[maybe_unused]] auto main_sel_op_sub = View(new_term.main_sel_op_sub); \ + [[maybe_unused]] auto main_sel_op_timestamp = View(new_term.main_sel_op_timestamp); \ + [[maybe_unused]] auto main_sel_op_transaction_fee = View(new_term.main_sel_op_transaction_fee); \ + [[maybe_unused]] auto main_sel_op_version = View(new_term.main_sel_op_version); \ + [[maybe_unused]] auto main_sel_op_xor = View(new_term.main_sel_op_xor); \ + [[maybe_unused]] auto main_sel_q_kernel_lookup = View(new_term.main_sel_q_kernel_lookup); \ + [[maybe_unused]] auto main_sel_q_kernel_output_lookup = View(new_term.main_sel_q_kernel_output_lookup); \ + [[maybe_unused]] auto main_sel_resolve_ind_addr_a = View(new_term.main_sel_resolve_ind_addr_a); \ + [[maybe_unused]] auto main_sel_resolve_ind_addr_b = View(new_term.main_sel_resolve_ind_addr_b); \ + [[maybe_unused]] auto main_sel_resolve_ind_addr_c = View(new_term.main_sel_resolve_ind_addr_c); \ + [[maybe_unused]] auto main_sel_resolve_ind_addr_d = View(new_term.main_sel_resolve_ind_addr_d); \ + [[maybe_unused]] auto main_sel_returndata = View(new_term.main_sel_returndata); \ + [[maybe_unused]] auto main_sel_rng_16 = View(new_term.main_sel_rng_16); \ + [[maybe_unused]] auto main_sel_rng_8 = View(new_term.main_sel_rng_8); \ + [[maybe_unused]] auto main_sel_slice_gadget = View(new_term.main_sel_slice_gadget); \ + [[maybe_unused]] auto main_space_id = View(new_term.main_space_id); \ + [[maybe_unused]] auto main_tag_err = View(new_term.main_tag_err); \ + [[maybe_unused]] auto main_w_in_tag = View(new_term.main_w_in_tag); \ + [[maybe_unused]] auto mem_addr = View(new_term.mem_addr); \ + [[maybe_unused]] auto mem_clk = View(new_term.mem_clk); \ + [[maybe_unused]] auto mem_diff_hi = View(new_term.mem_diff_hi); \ + [[maybe_unused]] auto mem_diff_lo = View(new_term.mem_diff_lo); \ + [[maybe_unused]] auto mem_diff_mid = View(new_term.mem_diff_mid); \ + [[maybe_unused]] auto mem_glob_addr = View(new_term.mem_glob_addr); \ + [[maybe_unused]] auto mem_last = View(new_term.mem_last); \ + [[maybe_unused]] auto mem_lastAccess = View(new_term.mem_lastAccess); \ + [[maybe_unused]] auto mem_one_min_inv = View(new_term.mem_one_min_inv); \ + [[maybe_unused]] auto mem_r_in_tag = View(new_term.mem_r_in_tag); \ + [[maybe_unused]] auto mem_rw = View(new_term.mem_rw); \ + [[maybe_unused]] auto mem_sel_mem = View(new_term.mem_sel_mem); \ + [[maybe_unused]] auto mem_sel_mov_ia_to_ic = View(new_term.mem_sel_mov_ia_to_ic); \ + [[maybe_unused]] auto mem_sel_mov_ib_to_ic = View(new_term.mem_sel_mov_ib_to_ic); \ + [[maybe_unused]] auto mem_sel_op_a = View(new_term.mem_sel_op_a); \ + [[maybe_unused]] auto mem_sel_op_b = View(new_term.mem_sel_op_b); \ + [[maybe_unused]] auto mem_sel_op_c = View(new_term.mem_sel_op_c); \ + [[maybe_unused]] auto mem_sel_op_cmov = View(new_term.mem_sel_op_cmov); \ + [[maybe_unused]] auto mem_sel_op_d = View(new_term.mem_sel_op_d); \ + [[maybe_unused]] auto mem_sel_op_slice = View(new_term.mem_sel_op_slice); \ + [[maybe_unused]] auto mem_sel_resolve_ind_addr_a = View(new_term.mem_sel_resolve_ind_addr_a); \ + [[maybe_unused]] auto mem_sel_resolve_ind_addr_b = View(new_term.mem_sel_resolve_ind_addr_b); \ + [[maybe_unused]] auto mem_sel_resolve_ind_addr_c = View(new_term.mem_sel_resolve_ind_addr_c); \ + [[maybe_unused]] auto mem_sel_resolve_ind_addr_d = View(new_term.mem_sel_resolve_ind_addr_d); \ + [[maybe_unused]] auto mem_sel_rng_chk = View(new_term.mem_sel_rng_chk); \ + [[maybe_unused]] auto mem_skip_check_tag = View(new_term.mem_skip_check_tag); \ + [[maybe_unused]] auto mem_space_id = View(new_term.mem_space_id); \ + [[maybe_unused]] auto mem_tag = View(new_term.mem_tag); \ + [[maybe_unused]] auto mem_tag_err = View(new_term.mem_tag_err); \ + [[maybe_unused]] auto mem_tsp = View(new_term.mem_tsp); \ + [[maybe_unused]] auto mem_val = View(new_term.mem_val); \ + [[maybe_unused]] auto mem_w_in_tag = View(new_term.mem_w_in_tag); \ + [[maybe_unused]] auto pedersen_clk = View(new_term.pedersen_clk); \ + [[maybe_unused]] auto pedersen_input = View(new_term.pedersen_input); \ + [[maybe_unused]] auto pedersen_output = View(new_term.pedersen_output); \ + [[maybe_unused]] auto pedersen_sel_pedersen = View(new_term.pedersen_sel_pedersen); \ + [[maybe_unused]] auto poseidon2_a_0 = View(new_term.poseidon2_a_0); \ + [[maybe_unused]] auto poseidon2_a_1 = View(new_term.poseidon2_a_1); \ + [[maybe_unused]] auto poseidon2_a_2 = View(new_term.poseidon2_a_2); \ + [[maybe_unused]] auto poseidon2_a_3 = View(new_term.poseidon2_a_3); \ + [[maybe_unused]] auto poseidon2_b_0 = View(new_term.poseidon2_b_0); \ + [[maybe_unused]] auto poseidon2_b_1 = View(new_term.poseidon2_b_1); \ + [[maybe_unused]] auto poseidon2_b_2 = View(new_term.poseidon2_b_2); \ + [[maybe_unused]] auto poseidon2_b_3 = View(new_term.poseidon2_b_3); \ + [[maybe_unused]] auto poseidon2_clk = View(new_term.poseidon2_clk); \ + [[maybe_unused]] auto poseidon2_input = View(new_term.poseidon2_input); \ + [[maybe_unused]] auto poseidon2_output = View(new_term.poseidon2_output); \ + [[maybe_unused]] auto poseidon2_sel_poseidon_perm = View(new_term.poseidon2_sel_poseidon_perm); \ + [[maybe_unused]] auto powers_power_of_2 = View(new_term.powers_power_of_2); \ + [[maybe_unused]] auto sha256_clk = View(new_term.sha256_clk); \ + [[maybe_unused]] auto sha256_input = View(new_term.sha256_input); \ + [[maybe_unused]] auto sha256_output = View(new_term.sha256_output); \ + [[maybe_unused]] auto sha256_sel_sha256_compression = View(new_term.sha256_sel_sha256_compression); \ + [[maybe_unused]] auto sha256_state = View(new_term.sha256_state); \ + [[maybe_unused]] auto slice_addr = View(new_term.slice_addr); \ + [[maybe_unused]] auto slice_clk = View(new_term.slice_clk); \ + [[maybe_unused]] auto slice_cnt = View(new_term.slice_cnt); \ + [[maybe_unused]] auto slice_col_offset = View(new_term.slice_col_offset); \ + [[maybe_unused]] auto slice_one_min_inv = View(new_term.slice_one_min_inv); \ + [[maybe_unused]] auto slice_sel_cd_cpy = View(new_term.slice_sel_cd_cpy); \ + [[maybe_unused]] auto slice_sel_mem_active = View(new_term.slice_sel_mem_active); \ + [[maybe_unused]] auto slice_sel_return = View(new_term.slice_sel_return); \ + [[maybe_unused]] auto slice_sel_start = View(new_term.slice_sel_start); \ + [[maybe_unused]] auto slice_space_id = View(new_term.slice_space_id); \ + [[maybe_unused]] auto slice_val = View(new_term.slice_val); \ + [[maybe_unused]] auto perm_slice_mem = View(new_term.perm_slice_mem); \ + [[maybe_unused]] auto perm_main_alu = View(new_term.perm_main_alu); \ + [[maybe_unused]] auto perm_main_bin = View(new_term.perm_main_bin); \ + [[maybe_unused]] auto perm_main_conv = View(new_term.perm_main_conv); \ + [[maybe_unused]] auto perm_main_pos2_perm = View(new_term.perm_main_pos2_perm); \ + [[maybe_unused]] auto perm_main_pedersen = View(new_term.perm_main_pedersen); \ + [[maybe_unused]] auto perm_main_slice = View(new_term.perm_main_slice); \ + [[maybe_unused]] auto perm_main_mem_a = View(new_term.perm_main_mem_a); \ + [[maybe_unused]] auto perm_main_mem_b = View(new_term.perm_main_mem_b); \ + [[maybe_unused]] auto perm_main_mem_c = View(new_term.perm_main_mem_c); \ + [[maybe_unused]] auto perm_main_mem_d = View(new_term.perm_main_mem_d); \ + [[maybe_unused]] auto perm_main_mem_ind_addr_a = View(new_term.perm_main_mem_ind_addr_a); \ + [[maybe_unused]] auto perm_main_mem_ind_addr_b = View(new_term.perm_main_mem_ind_addr_b); \ + [[maybe_unused]] auto perm_main_mem_ind_addr_c = View(new_term.perm_main_mem_ind_addr_c); \ + [[maybe_unused]] auto perm_main_mem_ind_addr_d = View(new_term.perm_main_mem_ind_addr_d); \ + [[maybe_unused]] auto lookup_byte_lengths = View(new_term.lookup_byte_lengths); \ + [[maybe_unused]] auto lookup_byte_operations = View(new_term.lookup_byte_operations); \ + [[maybe_unused]] auto lookup_cd_value = View(new_term.lookup_cd_value); \ + [[maybe_unused]] auto lookup_ret_value = View(new_term.lookup_ret_value); \ + [[maybe_unused]] auto lookup_opcode_gas = View(new_term.lookup_opcode_gas); \ + [[maybe_unused]] auto range_check_l2_gas_hi = View(new_term.range_check_l2_gas_hi); \ + [[maybe_unused]] auto range_check_l2_gas_lo = View(new_term.range_check_l2_gas_lo); \ + [[maybe_unused]] auto range_check_da_gas_hi = View(new_term.range_check_da_gas_hi); \ + [[maybe_unused]] auto range_check_da_gas_lo = View(new_term.range_check_da_gas_lo); \ + [[maybe_unused]] auto kernel_output_lookup = View(new_term.kernel_output_lookup); \ + [[maybe_unused]] auto lookup_into_kernel = View(new_term.lookup_into_kernel); \ + [[maybe_unused]] auto incl_main_tag_err = View(new_term.incl_main_tag_err); \ + [[maybe_unused]] auto incl_mem_tag_err = View(new_term.incl_mem_tag_err); \ + [[maybe_unused]] auto lookup_mem_rng_chk_lo = View(new_term.lookup_mem_rng_chk_lo); \ + [[maybe_unused]] auto lookup_mem_rng_chk_mid = View(new_term.lookup_mem_rng_chk_mid); \ + [[maybe_unused]] auto lookup_mem_rng_chk_hi = View(new_term.lookup_mem_rng_chk_hi); \ + [[maybe_unused]] auto lookup_pow_2_0 = View(new_term.lookup_pow_2_0); \ + [[maybe_unused]] auto lookup_pow_2_1 = View(new_term.lookup_pow_2_1); \ + [[maybe_unused]] auto lookup_u8_0 = View(new_term.lookup_u8_0); \ + [[maybe_unused]] auto lookup_u8_1 = View(new_term.lookup_u8_1); \ + [[maybe_unused]] auto lookup_u16_0 = View(new_term.lookup_u16_0); \ + [[maybe_unused]] auto lookup_u16_1 = View(new_term.lookup_u16_1); \ + [[maybe_unused]] auto lookup_u16_2 = View(new_term.lookup_u16_2); \ + [[maybe_unused]] auto lookup_u16_3 = View(new_term.lookup_u16_3); \ + [[maybe_unused]] auto lookup_u16_4 = View(new_term.lookup_u16_4); \ + [[maybe_unused]] auto lookup_u16_5 = View(new_term.lookup_u16_5); \ + [[maybe_unused]] auto lookup_u16_6 = View(new_term.lookup_u16_6); \ + [[maybe_unused]] auto lookup_u16_7 = View(new_term.lookup_u16_7); \ + [[maybe_unused]] auto lookup_u16_8 = View(new_term.lookup_u16_8); \ + [[maybe_unused]] auto lookup_u16_9 = View(new_term.lookup_u16_9); \ + [[maybe_unused]] auto lookup_u16_10 = View(new_term.lookup_u16_10); \ + [[maybe_unused]] auto lookup_u16_11 = View(new_term.lookup_u16_11); \ + [[maybe_unused]] auto lookup_u16_12 = View(new_term.lookup_u16_12); \ + [[maybe_unused]] auto lookup_u16_13 = View(new_term.lookup_u16_13); \ + [[maybe_unused]] auto lookup_u16_14 = View(new_term.lookup_u16_14); \ + [[maybe_unused]] auto lookup_div_u16_0 = View(new_term.lookup_div_u16_0); \ + [[maybe_unused]] auto lookup_div_u16_1 = View(new_term.lookup_div_u16_1); \ + [[maybe_unused]] auto lookup_div_u16_2 = View(new_term.lookup_div_u16_2); \ + [[maybe_unused]] auto lookup_div_u16_3 = View(new_term.lookup_div_u16_3); \ + [[maybe_unused]] auto lookup_div_u16_4 = View(new_term.lookup_div_u16_4); \ + [[maybe_unused]] auto lookup_div_u16_5 = View(new_term.lookup_div_u16_5); \ + [[maybe_unused]] auto lookup_div_u16_6 = View(new_term.lookup_div_u16_6); \ + [[maybe_unused]] auto lookup_div_u16_7 = View(new_term.lookup_div_u16_7); \ + [[maybe_unused]] auto lookup_byte_lengths_counts = View(new_term.lookup_byte_lengths_counts); \ + [[maybe_unused]] auto lookup_byte_operations_counts = View(new_term.lookup_byte_operations_counts); \ + [[maybe_unused]] auto lookup_cd_value_counts = View(new_term.lookup_cd_value_counts); \ + [[maybe_unused]] auto lookup_ret_value_counts = View(new_term.lookup_ret_value_counts); \ + [[maybe_unused]] auto lookup_opcode_gas_counts = View(new_term.lookup_opcode_gas_counts); \ + [[maybe_unused]] auto range_check_l2_gas_hi_counts = View(new_term.range_check_l2_gas_hi_counts); \ + [[maybe_unused]] auto range_check_l2_gas_lo_counts = View(new_term.range_check_l2_gas_lo_counts); \ + [[maybe_unused]] auto range_check_da_gas_hi_counts = View(new_term.range_check_da_gas_hi_counts); \ + [[maybe_unused]] auto range_check_da_gas_lo_counts = View(new_term.range_check_da_gas_lo_counts); \ + [[maybe_unused]] auto kernel_output_lookup_counts = View(new_term.kernel_output_lookup_counts); \ + [[maybe_unused]] auto lookup_into_kernel_counts = View(new_term.lookup_into_kernel_counts); \ + [[maybe_unused]] auto incl_main_tag_err_counts = View(new_term.incl_main_tag_err_counts); \ + [[maybe_unused]] auto incl_mem_tag_err_counts = View(new_term.incl_mem_tag_err_counts); \ + [[maybe_unused]] auto lookup_mem_rng_chk_lo_counts = View(new_term.lookup_mem_rng_chk_lo_counts); \ + [[maybe_unused]] auto lookup_mem_rng_chk_mid_counts = View(new_term.lookup_mem_rng_chk_mid_counts); \ + [[maybe_unused]] auto lookup_mem_rng_chk_hi_counts = View(new_term.lookup_mem_rng_chk_hi_counts); \ + [[maybe_unused]] auto lookup_pow_2_0_counts = View(new_term.lookup_pow_2_0_counts); \ + [[maybe_unused]] auto lookup_pow_2_1_counts = View(new_term.lookup_pow_2_1_counts); \ + [[maybe_unused]] auto lookup_u8_0_counts = View(new_term.lookup_u8_0_counts); \ + [[maybe_unused]] auto lookup_u8_1_counts = View(new_term.lookup_u8_1_counts); \ + [[maybe_unused]] auto lookup_u16_0_counts = View(new_term.lookup_u16_0_counts); \ + [[maybe_unused]] auto lookup_u16_1_counts = View(new_term.lookup_u16_1_counts); \ + [[maybe_unused]] auto lookup_u16_2_counts = View(new_term.lookup_u16_2_counts); \ + [[maybe_unused]] auto lookup_u16_3_counts = View(new_term.lookup_u16_3_counts); \ + [[maybe_unused]] auto lookup_u16_4_counts = View(new_term.lookup_u16_4_counts); \ + [[maybe_unused]] auto lookup_u16_5_counts = View(new_term.lookup_u16_5_counts); \ + [[maybe_unused]] auto lookup_u16_6_counts = View(new_term.lookup_u16_6_counts); \ + [[maybe_unused]] auto lookup_u16_7_counts = View(new_term.lookup_u16_7_counts); \ + [[maybe_unused]] auto lookup_u16_8_counts = View(new_term.lookup_u16_8_counts); \ + [[maybe_unused]] auto lookup_u16_9_counts = View(new_term.lookup_u16_9_counts); \ + [[maybe_unused]] auto lookup_u16_10_counts = View(new_term.lookup_u16_10_counts); \ + [[maybe_unused]] auto lookup_u16_11_counts = View(new_term.lookup_u16_11_counts); \ + [[maybe_unused]] auto lookup_u16_12_counts = View(new_term.lookup_u16_12_counts); \ + [[maybe_unused]] auto lookup_u16_13_counts = View(new_term.lookup_u16_13_counts); \ + [[maybe_unused]] auto lookup_u16_14_counts = View(new_term.lookup_u16_14_counts); \ + [[maybe_unused]] auto lookup_div_u16_0_counts = View(new_term.lookup_div_u16_0_counts); \ + [[maybe_unused]] auto lookup_div_u16_1_counts = View(new_term.lookup_div_u16_1_counts); \ + [[maybe_unused]] auto lookup_div_u16_2_counts = View(new_term.lookup_div_u16_2_counts); \ + [[maybe_unused]] auto lookup_div_u16_3_counts = View(new_term.lookup_div_u16_3_counts); \ + [[maybe_unused]] auto lookup_div_u16_4_counts = View(new_term.lookup_div_u16_4_counts); \ + [[maybe_unused]] auto lookup_div_u16_5_counts = View(new_term.lookup_div_u16_5_counts); \ + [[maybe_unused]] auto lookup_div_u16_6_counts = View(new_term.lookup_div_u16_6_counts); \ + [[maybe_unused]] auto lookup_div_u16_7_counts = View(new_term.lookup_div_u16_7_counts); \ + [[maybe_unused]] auto alu_a_hi_shift = View(new_term.alu_a_hi_shift); \ + [[maybe_unused]] auto alu_a_lo_shift = View(new_term.alu_a_lo_shift); \ + [[maybe_unused]] auto alu_b_hi_shift = View(new_term.alu_b_hi_shift); \ + [[maybe_unused]] auto alu_b_lo_shift = View(new_term.alu_b_lo_shift); \ + [[maybe_unused]] auto alu_cmp_rng_ctr_shift = View(new_term.alu_cmp_rng_ctr_shift); \ + [[maybe_unused]] auto alu_div_u16_r0_shift = View(new_term.alu_div_u16_r0_shift); \ + [[maybe_unused]] auto alu_div_u16_r1_shift = View(new_term.alu_div_u16_r1_shift); \ + [[maybe_unused]] auto alu_div_u16_r2_shift = View(new_term.alu_div_u16_r2_shift); \ + [[maybe_unused]] auto alu_div_u16_r3_shift = View(new_term.alu_div_u16_r3_shift); \ + [[maybe_unused]] auto alu_div_u16_r4_shift = View(new_term.alu_div_u16_r4_shift); \ + [[maybe_unused]] auto alu_div_u16_r5_shift = View(new_term.alu_div_u16_r5_shift); \ + [[maybe_unused]] auto alu_div_u16_r6_shift = View(new_term.alu_div_u16_r6_shift); \ + [[maybe_unused]] auto alu_div_u16_r7_shift = View(new_term.alu_div_u16_r7_shift); \ + [[maybe_unused]] auto alu_op_add_shift = View(new_term.alu_op_add_shift); \ + [[maybe_unused]] auto alu_op_cast_prev_shift = View(new_term.alu_op_cast_prev_shift); \ + [[maybe_unused]] auto alu_op_cast_shift = View(new_term.alu_op_cast_shift); \ + [[maybe_unused]] auto alu_op_div_shift = View(new_term.alu_op_div_shift); \ + [[maybe_unused]] auto alu_op_mul_shift = View(new_term.alu_op_mul_shift); \ + [[maybe_unused]] auto alu_op_shl_shift = View(new_term.alu_op_shl_shift); \ + [[maybe_unused]] auto alu_op_shr_shift = View(new_term.alu_op_shr_shift); \ + [[maybe_unused]] auto alu_op_sub_shift = View(new_term.alu_op_sub_shift); \ + [[maybe_unused]] auto alu_p_sub_a_hi_shift = View(new_term.alu_p_sub_a_hi_shift); \ + [[maybe_unused]] auto alu_p_sub_a_lo_shift = View(new_term.alu_p_sub_a_lo_shift); \ + [[maybe_unused]] auto alu_p_sub_b_hi_shift = View(new_term.alu_p_sub_b_hi_shift); \ + [[maybe_unused]] auto alu_p_sub_b_lo_shift = View(new_term.alu_p_sub_b_lo_shift); \ + [[maybe_unused]] auto alu_sel_alu_shift = View(new_term.alu_sel_alu_shift); \ + [[maybe_unused]] auto alu_sel_cmp_shift = View(new_term.alu_sel_cmp_shift); \ + [[maybe_unused]] auto alu_sel_div_rng_chk_shift = View(new_term.alu_sel_div_rng_chk_shift); \ + [[maybe_unused]] auto alu_sel_rng_chk_lookup_shift = View(new_term.alu_sel_rng_chk_lookup_shift); \ + [[maybe_unused]] auto alu_sel_rng_chk_shift = View(new_term.alu_sel_rng_chk_shift); \ + [[maybe_unused]] auto alu_u16_r0_shift = View(new_term.alu_u16_r0_shift); \ + [[maybe_unused]] auto alu_u16_r1_shift = View(new_term.alu_u16_r1_shift); \ + [[maybe_unused]] auto alu_u16_r2_shift = View(new_term.alu_u16_r2_shift); \ + [[maybe_unused]] auto alu_u16_r3_shift = View(new_term.alu_u16_r3_shift); \ + [[maybe_unused]] auto alu_u16_r4_shift = View(new_term.alu_u16_r4_shift); \ + [[maybe_unused]] auto alu_u16_r5_shift = View(new_term.alu_u16_r5_shift); \ + [[maybe_unused]] auto alu_u16_r6_shift = View(new_term.alu_u16_r6_shift); \ + [[maybe_unused]] auto alu_u8_r0_shift = View(new_term.alu_u8_r0_shift); \ + [[maybe_unused]] auto alu_u8_r1_shift = View(new_term.alu_u8_r1_shift); \ + [[maybe_unused]] auto binary_acc_ia_shift = View(new_term.binary_acc_ia_shift); \ + [[maybe_unused]] auto binary_acc_ib_shift = View(new_term.binary_acc_ib_shift); \ + [[maybe_unused]] auto binary_acc_ic_shift = View(new_term.binary_acc_ic_shift); \ + [[maybe_unused]] auto binary_mem_tag_ctr_shift = View(new_term.binary_mem_tag_ctr_shift); \ + [[maybe_unused]] auto binary_op_id_shift = View(new_term.binary_op_id_shift); \ + [[maybe_unused]] auto kernel_emit_l2_to_l1_msg_write_offset_shift = \ + View(new_term.kernel_emit_l2_to_l1_msg_write_offset_shift); \ + [[maybe_unused]] auto kernel_emit_note_hash_write_offset_shift = \ + View(new_term.kernel_emit_note_hash_write_offset_shift); \ + [[maybe_unused]] auto kernel_emit_nullifier_write_offset_shift = \ + View(new_term.kernel_emit_nullifier_write_offset_shift); \ + [[maybe_unused]] auto kernel_emit_unencrypted_log_write_offset_shift = \ + View(new_term.kernel_emit_unencrypted_log_write_offset_shift); \ + [[maybe_unused]] auto kernel_l1_to_l2_msg_exists_write_offset_shift = \ + View(new_term.kernel_l1_to_l2_msg_exists_write_offset_shift); \ + [[maybe_unused]] auto kernel_note_hash_exist_write_offset_shift = \ + View(new_term.kernel_note_hash_exist_write_offset_shift); \ + [[maybe_unused]] auto kernel_nullifier_exists_write_offset_shift = \ + View(new_term.kernel_nullifier_exists_write_offset_shift); \ + [[maybe_unused]] auto kernel_nullifier_non_exists_write_offset_shift = \ + View(new_term.kernel_nullifier_non_exists_write_offset_shift); \ + [[maybe_unused]] auto kernel_side_effect_counter_shift = View(new_term.kernel_side_effect_counter_shift); \ + [[maybe_unused]] auto kernel_sload_write_offset_shift = View(new_term.kernel_sload_write_offset_shift); \ + [[maybe_unused]] auto kernel_sstore_write_offset_shift = View(new_term.kernel_sstore_write_offset_shift); \ + [[maybe_unused]] auto main_da_gas_remaining_shift = View(new_term.main_da_gas_remaining_shift); \ + [[maybe_unused]] auto main_internal_return_ptr_shift = View(new_term.main_internal_return_ptr_shift); \ + [[maybe_unused]] auto main_l2_gas_remaining_shift = View(new_term.main_l2_gas_remaining_shift); \ + [[maybe_unused]] auto main_pc_shift = View(new_term.main_pc_shift); \ + [[maybe_unused]] auto mem_glob_addr_shift = View(new_term.mem_glob_addr_shift); \ + [[maybe_unused]] auto mem_rw_shift = View(new_term.mem_rw_shift); \ + [[maybe_unused]] auto mem_sel_mem_shift = View(new_term.mem_sel_mem_shift); \ + [[maybe_unused]] auto mem_tag_shift = View(new_term.mem_tag_shift); \ + [[maybe_unused]] auto mem_tsp_shift = View(new_term.mem_tsp_shift); \ + [[maybe_unused]] auto mem_val_shift = View(new_term.mem_val_shift); \ + [[maybe_unused]] auto slice_addr_shift = View(new_term.slice_addr_shift); \ + [[maybe_unused]] auto slice_clk_shift = View(new_term.slice_clk_shift); \ + [[maybe_unused]] auto slice_cnt_shift = View(new_term.slice_cnt_shift); \ + [[maybe_unused]] auto slice_col_offset_shift = View(new_term.slice_col_offset_shift); \ + [[maybe_unused]] auto slice_sel_cd_cpy_shift = View(new_term.slice_sel_cd_cpy_shift); \ + [[maybe_unused]] auto slice_sel_mem_active_shift = View(new_term.slice_sel_mem_active_shift); \ + [[maybe_unused]] auto slice_sel_return_shift = View(new_term.slice_sel_return_shift); \ + [[maybe_unused]] auto slice_sel_start_shift = View(new_term.slice_sel_start_shift); \ + [[maybe_unused]] auto slice_space_id_shift = View(new_term.slice_space_id_shift); diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp index 74c387f6be39..d5aad15f69a8 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp @@ -308,6 +308,14 @@ template std::vector AvmFullRow::names() "pedersen_input", "pedersen_output", "pedersen_sel_pedersen", + "poseidon2_a_0", + "poseidon2_a_1", + "poseidon2_a_2", + "poseidon2_a_3", + "poseidon2_b_0", + "poseidon2_b_1", + "poseidon2_b_2", + "poseidon2_b_3", "poseidon2_clk", "poseidon2_input", "poseidon2_output", @@ -851,10 +859,644 @@ template RefVector AvmFullRow::as_vector() const template std::ostream& operator<<(std::ostream& os, AvmFullRow const& row) { +<<<<<<< HEAD for (const auto& ff : row.as_vector()) { os << field_to_string(ff) << ", "; } return os; +======= +<<<<<<< HEAD + return os << field_to_string(row.main_clk) // + << "," << field_to_string(row.main_sel_first) // + << "," << field_to_string(row.kernel_kernel_inputs) // + << "," << field_to_string(row.kernel_kernel_value_out) // + << "," << field_to_string(row.kernel_kernel_side_effect_out) // + << "," << field_to_string(row.kernel_kernel_metadata_out) // + << "," << field_to_string(row.main_calldata) // + << "," << field_to_string(row.main_returndata) // + << "," << field_to_string(row.alu_a_hi) // + << "," << field_to_string(row.alu_a_lo) // + << "," << field_to_string(row.alu_b_hi) // + << "," << field_to_string(row.alu_b_lo) // + << "," << field_to_string(row.alu_borrow) // + << "," << field_to_string(row.alu_cf) // + << "," << field_to_string(row.alu_clk) // + << "," << field_to_string(row.alu_cmp_rng_ctr) // + << "," << field_to_string(row.alu_div_u16_r0) // + << "," << field_to_string(row.alu_div_u16_r1) // + << "," << field_to_string(row.alu_div_u16_r2) // + << "," << field_to_string(row.alu_div_u16_r3) // + << "," << field_to_string(row.alu_div_u16_r4) // + << "," << field_to_string(row.alu_div_u16_r5) // + << "," << field_to_string(row.alu_div_u16_r6) // + << "," << field_to_string(row.alu_div_u16_r7) // + << "," << field_to_string(row.alu_divisor_hi) // + << "," << field_to_string(row.alu_divisor_lo) // + << "," << field_to_string(row.alu_ff_tag) // + << "," << field_to_string(row.alu_ia) // + << "," << field_to_string(row.alu_ib) // + << "," << field_to_string(row.alu_ic) // + << "," << field_to_string(row.alu_in_tag) // + << "," << field_to_string(row.alu_op_add) // + << "," << field_to_string(row.alu_op_cast) // + << "," << field_to_string(row.alu_op_cast_prev) // + << "," << field_to_string(row.alu_op_div) // + << "," << field_to_string(row.alu_op_div_a_lt_b) // + << "," << field_to_string(row.alu_op_div_std) // + << "," << field_to_string(row.alu_op_eq) // + << "," << field_to_string(row.alu_op_eq_diff_inv) // + << "," << field_to_string(row.alu_op_lt) // + << "," << field_to_string(row.alu_op_lte) // + << "," << field_to_string(row.alu_op_mul) // + << "," << field_to_string(row.alu_op_not) // + << "," << field_to_string(row.alu_op_shl) // + << "," << field_to_string(row.alu_op_shr) // + << "," << field_to_string(row.alu_op_sub) // + << "," << field_to_string(row.alu_p_a_borrow) // + << "," << field_to_string(row.alu_p_b_borrow) // + << "," << field_to_string(row.alu_p_sub_a_hi) // + << "," << field_to_string(row.alu_p_sub_a_lo) // + << "," << field_to_string(row.alu_p_sub_b_hi) // + << "," << field_to_string(row.alu_p_sub_b_lo) // + << "," << field_to_string(row.alu_partial_prod_hi) // + << "," << field_to_string(row.alu_partial_prod_lo) // + << "," << field_to_string(row.alu_quotient_hi) // + << "," << field_to_string(row.alu_quotient_lo) // + << "," << field_to_string(row.alu_remainder) // + << "," << field_to_string(row.alu_res_hi) // + << "," << field_to_string(row.alu_res_lo) // + << "," << field_to_string(row.alu_sel_alu) // + << "," << field_to_string(row.alu_sel_cmp) // + << "," << field_to_string(row.alu_sel_div_rng_chk) // + << "," << field_to_string(row.alu_sel_rng_chk) // + << "," << field_to_string(row.alu_sel_rng_chk_lookup) // + << "," << field_to_string(row.alu_sel_shift_which) // + << "," << field_to_string(row.alu_shift_lt_bit_len) // + << "," << field_to_string(row.alu_t_sub_s_bits) // + << "," << field_to_string(row.alu_two_pow_s) // + << "," << field_to_string(row.alu_two_pow_t_sub_s) // + << "," << field_to_string(row.alu_u128_tag) // + << "," << field_to_string(row.alu_u16_r0) // + << "," << field_to_string(row.alu_u16_r1) // + << "," << field_to_string(row.alu_u16_r10) // + << "," << field_to_string(row.alu_u16_r11) // + << "," << field_to_string(row.alu_u16_r12) // + << "," << field_to_string(row.alu_u16_r13) // + << "," << field_to_string(row.alu_u16_r14) // + << "," << field_to_string(row.alu_u16_r2) // + << "," << field_to_string(row.alu_u16_r3) // + << "," << field_to_string(row.alu_u16_r4) // + << "," << field_to_string(row.alu_u16_r5) // + << "," << field_to_string(row.alu_u16_r6) // + << "," << field_to_string(row.alu_u16_r7) // + << "," << field_to_string(row.alu_u16_r8) // + << "," << field_to_string(row.alu_u16_r9) // + << "," << field_to_string(row.alu_u16_tag) // + << "," << field_to_string(row.alu_u32_tag) // + << "," << field_to_string(row.alu_u64_tag) // + << "," << field_to_string(row.alu_u8_r0) // + << "," << field_to_string(row.alu_u8_r1) // + << "," << field_to_string(row.alu_u8_tag) // + << "," << field_to_string(row.binary_acc_ia) // + << "," << field_to_string(row.binary_acc_ib) // + << "," << field_to_string(row.binary_acc_ic) // + << "," << field_to_string(row.binary_clk) // + << "," << field_to_string(row.binary_ia_bytes) // + << "," << field_to_string(row.binary_ib_bytes) // + << "," << field_to_string(row.binary_ic_bytes) // + << "," << field_to_string(row.binary_in_tag) // + << "," << field_to_string(row.binary_mem_tag_ctr) // + << "," << field_to_string(row.binary_mem_tag_ctr_inv) // + << "," << field_to_string(row.binary_op_id) // + << "," << field_to_string(row.binary_sel_bin) // + << "," << field_to_string(row.binary_start) // + << "," << field_to_string(row.byte_lookup_sel_bin) // + << "," << field_to_string(row.byte_lookup_table_byte_lengths) // + << "," << field_to_string(row.byte_lookup_table_in_tags) // + << "," << field_to_string(row.byte_lookup_table_input_a) // + << "," << field_to_string(row.byte_lookup_table_input_b) // + << "," << field_to_string(row.byte_lookup_table_op_id) // + << "," << field_to_string(row.byte_lookup_table_output) // + << "," << field_to_string(row.conversion_clk) // + << "," << field_to_string(row.conversion_input) // + << "," << field_to_string(row.conversion_num_limbs) // + << "," << field_to_string(row.conversion_radix) // + << "," << field_to_string(row.conversion_sel_to_radix_le) // + << "," << field_to_string(row.gas_da_gas_fixed_table) // + << "," << field_to_string(row.gas_l2_gas_fixed_table) // + << "," << field_to_string(row.gas_sel_gas_cost) // + << "," << field_to_string(row.keccakf1600_clk) // + << "," << field_to_string(row.keccakf1600_input) // + << "," << field_to_string(row.keccakf1600_output) // + << "," << field_to_string(row.keccakf1600_sel_keccakf1600) // + << "," << field_to_string(row.kernel_emit_l2_to_l1_msg_write_offset) // + << "," << field_to_string(row.kernel_emit_note_hash_write_offset) // + << "," << field_to_string(row.kernel_emit_nullifier_write_offset) // + << "," << field_to_string(row.kernel_emit_unencrypted_log_write_offset) // + << "," << field_to_string(row.kernel_kernel_in_offset) // + << "," << field_to_string(row.kernel_kernel_out_offset) // + << "," << field_to_string(row.kernel_l1_to_l2_msg_exists_write_offset) // + << "," << field_to_string(row.kernel_note_hash_exist_write_offset) // + << "," << field_to_string(row.kernel_nullifier_exists_write_offset) // + << "," << field_to_string(row.kernel_nullifier_non_exists_write_offset) // + << "," << field_to_string(row.kernel_q_public_input_kernel_add_to_table) // + << "," << field_to_string(row.kernel_q_public_input_kernel_out_add_to_table) // + << "," << field_to_string(row.kernel_side_effect_counter) // + << "," << field_to_string(row.kernel_sload_write_offset) // + << "," << field_to_string(row.kernel_sstore_write_offset) // + << "," << field_to_string(row.main_abs_da_rem_gas_hi) // + << "," << field_to_string(row.main_abs_da_rem_gas_lo) // + << "," << field_to_string(row.main_abs_l2_rem_gas_hi) // + << "," << field_to_string(row.main_abs_l2_rem_gas_lo) // + << "," << field_to_string(row.main_alu_in_tag) // + << "," << field_to_string(row.main_bin_op_id) // + << "," << field_to_string(row.main_call_ptr) // + << "," << field_to_string(row.main_da_gas_op_cost) // + << "," << field_to_string(row.main_da_gas_remaining) // + << "," << field_to_string(row.main_da_out_of_gas) // + << "," << field_to_string(row.main_ia) // + << "," << field_to_string(row.main_ib) // + << "," << field_to_string(row.main_ic) // + << "," << field_to_string(row.main_id) // + << "," << field_to_string(row.main_id_zero) // + << "," << field_to_string(row.main_ind_addr_a) // + << "," << field_to_string(row.main_ind_addr_b) // + << "," << field_to_string(row.main_ind_addr_c) // + << "," << field_to_string(row.main_ind_addr_d) // + << "," << field_to_string(row.main_internal_return_ptr) // + << "," << field_to_string(row.main_inv) // + << "," << field_to_string(row.main_l2_gas_op_cost) // + << "," << field_to_string(row.main_l2_gas_remaining) // + << "," << field_to_string(row.main_l2_out_of_gas) // + << "," << field_to_string(row.main_mem_addr_a) // + << "," << field_to_string(row.main_mem_addr_b) // + << "," << field_to_string(row.main_mem_addr_c) // + << "," << field_to_string(row.main_mem_addr_d) // + << "," << field_to_string(row.main_op_err) // + << "," << field_to_string(row.main_opcode_val) // + << "," << field_to_string(row.main_pc) // + << "," << field_to_string(row.main_r_in_tag) // + << "," << field_to_string(row.main_rwa) // + << "," << field_to_string(row.main_rwb) // + << "," << field_to_string(row.main_rwc) // + << "," << field_to_string(row.main_rwd) // + << "," << field_to_string(row.main_sel_alu) // + << "," << field_to_string(row.main_sel_bin) // + << "," << field_to_string(row.main_sel_calldata) // + << "," << field_to_string(row.main_sel_gas_accounting_active) // + << "," << field_to_string(row.main_sel_last) // + << "," << field_to_string(row.main_sel_mem_op_a) // + << "," << field_to_string(row.main_sel_mem_op_activate_gas) // + << "," << field_to_string(row.main_sel_mem_op_b) // + << "," << field_to_string(row.main_sel_mem_op_c) // + << "," << field_to_string(row.main_sel_mem_op_d) // + << "," << field_to_string(row.main_sel_mov_ia_to_ic) // + << "," << field_to_string(row.main_sel_mov_ib_to_ic) // + << "," << field_to_string(row.main_sel_op_add) // + << "," << field_to_string(row.main_sel_op_address) // + << "," << field_to_string(row.main_sel_op_and) // + << "," << field_to_string(row.main_sel_op_block_number) // + << "," << field_to_string(row.main_sel_op_calldata_copy) // + << "," << field_to_string(row.main_sel_op_cast) // + << "," << field_to_string(row.main_sel_op_chain_id) // + << "," << field_to_string(row.main_sel_op_cmov) // + << "," << field_to_string(row.main_sel_op_coinbase) // + << "," << field_to_string(row.main_sel_op_dagasleft) // + << "," << field_to_string(row.main_sel_op_div) // + << "," << field_to_string(row.main_sel_op_emit_l2_to_l1_msg) // + << "," << field_to_string(row.main_sel_op_emit_note_hash) // + << "," << field_to_string(row.main_sel_op_emit_nullifier) // + << "," << field_to_string(row.main_sel_op_emit_unencrypted_log) // + << "," << field_to_string(row.main_sel_op_eq) // + << "," << field_to_string(row.main_sel_op_external_call) // + << "," << field_to_string(row.main_sel_op_external_return) // + << "," << field_to_string(row.main_sel_op_fdiv) // + << "," << field_to_string(row.main_sel_op_fee_per_da_gas) // + << "," << field_to_string(row.main_sel_op_fee_per_l2_gas) // + << "," << field_to_string(row.main_sel_op_function_selector) // + << "," << field_to_string(row.main_sel_op_get_contract_instance) // + << "," << field_to_string(row.main_sel_op_halt) // + << "," << field_to_string(row.main_sel_op_internal_call) // + << "," << field_to_string(row.main_sel_op_internal_return) // + << "," << field_to_string(row.main_sel_op_jump) // + << "," << field_to_string(row.main_sel_op_jumpi) // + << "," << field_to_string(row.main_sel_op_keccak) // + << "," << field_to_string(row.main_sel_op_l1_to_l2_msg_exists) // + << "," << field_to_string(row.main_sel_op_l2gasleft) // + << "," << field_to_string(row.main_sel_op_lt) // + << "," << field_to_string(row.main_sel_op_lte) // + << "," << field_to_string(row.main_sel_op_mov) // + << "," << field_to_string(row.main_sel_op_mul) // + << "," << field_to_string(row.main_sel_op_not) // + << "," << field_to_string(row.main_sel_op_note_hash_exists) // + << "," << field_to_string(row.main_sel_op_nullifier_exists) // + << "," << field_to_string(row.main_sel_op_or) // + << "," << field_to_string(row.main_sel_op_pedersen) // + << "," << field_to_string(row.main_sel_op_poseidon2) // + << "," << field_to_string(row.main_sel_op_radix_le) // + << "," << field_to_string(row.main_sel_op_sender) // + << "," << field_to_string(row.main_sel_op_sha256) // + << "," << field_to_string(row.main_sel_op_shl) // + << "," << field_to_string(row.main_sel_op_shr) // + << "," << field_to_string(row.main_sel_op_sload) // + << "," << field_to_string(row.main_sel_op_sstore) // + << "," << field_to_string(row.main_sel_op_storage_address) // + << "," << field_to_string(row.main_sel_op_sub) // + << "," << field_to_string(row.main_sel_op_timestamp) // + << "," << field_to_string(row.main_sel_op_transaction_fee) // + << "," << field_to_string(row.main_sel_op_version) // + << "," << field_to_string(row.main_sel_op_xor) // + << "," << field_to_string(row.main_sel_q_kernel_lookup) // + << "," << field_to_string(row.main_sel_q_kernel_output_lookup) // + << "," << field_to_string(row.main_sel_resolve_ind_addr_a) // + << "," << field_to_string(row.main_sel_resolve_ind_addr_b) // + << "," << field_to_string(row.main_sel_resolve_ind_addr_c) // + << "," << field_to_string(row.main_sel_resolve_ind_addr_d) // + << "," << field_to_string(row.main_sel_returndata) // + << "," << field_to_string(row.main_sel_rng_16) // + << "," << field_to_string(row.main_sel_rng_8) // + << "," << field_to_string(row.main_sel_slice_gadget) // + << "," << field_to_string(row.main_space_id) // + << "," << field_to_string(row.main_tag_err) // + << "," << field_to_string(row.main_w_in_tag) // + << "," << field_to_string(row.mem_addr) // + << "," << field_to_string(row.mem_clk) // + << "," << field_to_string(row.mem_diff_hi) // + << "," << field_to_string(row.mem_diff_lo) // + << "," << field_to_string(row.mem_diff_mid) // + << "," << field_to_string(row.mem_glob_addr) // + << "," << field_to_string(row.mem_last) // + << "," << field_to_string(row.mem_lastAccess) // + << "," << field_to_string(row.mem_one_min_inv) // + << "," << field_to_string(row.mem_r_in_tag) // + << "," << field_to_string(row.mem_rw) // + << "," << field_to_string(row.mem_sel_mem) // + << "," << field_to_string(row.mem_sel_mov_ia_to_ic) // + << "," << field_to_string(row.mem_sel_mov_ib_to_ic) // + << "," << field_to_string(row.mem_sel_op_a) // + << "," << field_to_string(row.mem_sel_op_b) // + << "," << field_to_string(row.mem_sel_op_c) // + << "," << field_to_string(row.mem_sel_op_cmov) // + << "," << field_to_string(row.mem_sel_op_d) // + << "," << field_to_string(row.mem_sel_op_slice) // + << "," << field_to_string(row.mem_sel_resolve_ind_addr_a) // + << "," << field_to_string(row.mem_sel_resolve_ind_addr_b) // + << "," << field_to_string(row.mem_sel_resolve_ind_addr_c) // + << "," << field_to_string(row.mem_sel_resolve_ind_addr_d) // + << "," << field_to_string(row.mem_sel_rng_chk) // + << "," << field_to_string(row.mem_skip_check_tag) // + << "," << field_to_string(row.mem_space_id) // + << "," << field_to_string(row.mem_tag) // + << "," << field_to_string(row.mem_tag_err) // + << "," << field_to_string(row.mem_tsp) // + << "," << field_to_string(row.mem_val) // + << "," << field_to_string(row.mem_w_in_tag) // + << "," << field_to_string(row.pedersen_clk) // + << "," << field_to_string(row.pedersen_input) // + << "," << field_to_string(row.pedersen_output) // + << "," << field_to_string(row.pedersen_sel_pedersen) // + << "," << field_to_string(row.poseidon2_clk) // + << "," << field_to_string(row.poseidon2_input) // + << "," << field_to_string(row.poseidon2_output) // + << "," << field_to_string(row.poseidon2_sel_poseidon_perm) // + << "," << field_to_string(row.powers_power_of_2) // + << "," << field_to_string(row.sha256_clk) // + << "," << field_to_string(row.sha256_input) // + << "," << field_to_string(row.sha256_output) // + << "," << field_to_string(row.sha256_sel_sha256_compression) // + << "," << field_to_string(row.sha256_state) // + << "," << field_to_string(row.slice_addr) // + << "," << field_to_string(row.slice_clk) // + << "," << field_to_string(row.slice_cnt) // + << "," << field_to_string(row.slice_col_offset) // + << "," << field_to_string(row.slice_one_min_inv) // + << "," << field_to_string(row.slice_sel_cd_cpy) // + << "," << field_to_string(row.slice_sel_mem_active) // + << "," << field_to_string(row.slice_sel_return) // + << "," << field_to_string(row.slice_sel_start) // + << "," << field_to_string(row.slice_space_id) // + << "," << field_to_string(row.slice_val) // + << "," << field_to_string(row.perm_slice_mem) // + << "," << field_to_string(row.perm_main_alu) // + << "," << field_to_string(row.perm_main_bin) // + << "," << field_to_string(row.perm_main_conv) // + << "," << field_to_string(row.perm_main_pos2_perm) // + << "," << field_to_string(row.perm_main_pedersen) // + << "," << field_to_string(row.perm_main_slice) // + << "," << field_to_string(row.perm_main_mem_a) // + << "," << field_to_string(row.perm_main_mem_b) // + << "," << field_to_string(row.perm_main_mem_c) // + << "," << field_to_string(row.perm_main_mem_d) // + << "," << field_to_string(row.perm_main_mem_ind_addr_a) // + << "," << field_to_string(row.perm_main_mem_ind_addr_b) // + << "," << field_to_string(row.perm_main_mem_ind_addr_c) // + << "," << field_to_string(row.perm_main_mem_ind_addr_d) // + << "," << field_to_string(row.lookup_byte_lengths) // + << "," << field_to_string(row.lookup_byte_operations) // + << "," << field_to_string(row.lookup_cd_value) // + << "," << field_to_string(row.lookup_ret_value) // + << "," << field_to_string(row.lookup_opcode_gas) // + << "," << field_to_string(row.range_check_l2_gas_hi) // + << "," << field_to_string(row.range_check_l2_gas_lo) // + << "," << field_to_string(row.range_check_da_gas_hi) // + << "," << field_to_string(row.range_check_da_gas_lo) // + << "," << field_to_string(row.kernel_output_lookup) // + << "," << field_to_string(row.lookup_into_kernel) // + << "," << field_to_string(row.incl_main_tag_err) // + << "," << field_to_string(row.incl_mem_tag_err) // + << "," << field_to_string(row.lookup_mem_rng_chk_lo) // + << "," << field_to_string(row.lookup_mem_rng_chk_mid) // + << "," << field_to_string(row.lookup_mem_rng_chk_hi) // + << "," << field_to_string(row.lookup_pow_2_0) // + << "," << field_to_string(row.lookup_pow_2_1) // + << "," << field_to_string(row.lookup_u8_0) // + << "," << field_to_string(row.lookup_u8_1) // + << "," << field_to_string(row.lookup_u16_0) // + << "," << field_to_string(row.lookup_u16_1) // + << "," << field_to_string(row.lookup_u16_2) // + << "," << field_to_string(row.lookup_u16_3) // + << "," << field_to_string(row.lookup_u16_4) // + << "," << field_to_string(row.lookup_u16_5) // + << "," << field_to_string(row.lookup_u16_6) // + << "," << field_to_string(row.lookup_u16_7) // + << "," << field_to_string(row.lookup_u16_8) // + << "," << field_to_string(row.lookup_u16_9) // + << "," << field_to_string(row.lookup_u16_10) // + << "," << field_to_string(row.lookup_u16_11) // + << "," << field_to_string(row.lookup_u16_12) // + << "," << field_to_string(row.lookup_u16_13) // + << "," << field_to_string(row.lookup_u16_14) // + << "," << field_to_string(row.lookup_div_u16_0) // + << "," << field_to_string(row.lookup_div_u16_1) // + << "," << field_to_string(row.lookup_div_u16_2) // + << "," << field_to_string(row.lookup_div_u16_3) // + << "," << field_to_string(row.lookup_div_u16_4) // + << "," << field_to_string(row.lookup_div_u16_5) // + << "," << field_to_string(row.lookup_div_u16_6) // + << "," << field_to_string(row.lookup_div_u16_7) // + << "," << field_to_string(row.lookup_byte_lengths_counts) // + << "," << field_to_string(row.lookup_byte_operations_counts) // + << "," << field_to_string(row.lookup_cd_value_counts) // + << "," << field_to_string(row.lookup_ret_value_counts) // + << "," << field_to_string(row.lookup_opcode_gas_counts) // + << "," << field_to_string(row.range_check_l2_gas_hi_counts) // + << "," << field_to_string(row.range_check_l2_gas_lo_counts) // + << "," << field_to_string(row.range_check_da_gas_hi_counts) // + << "," << field_to_string(row.range_check_da_gas_lo_counts) // + << "," << field_to_string(row.kernel_output_lookup_counts) // + << "," << field_to_string(row.lookup_into_kernel_counts) // + << "," << field_to_string(row.incl_main_tag_err_counts) // + << "," << field_to_string(row.incl_mem_tag_err_counts) // + << "," << field_to_string(row.lookup_mem_rng_chk_lo_counts) // + << "," << field_to_string(row.lookup_mem_rng_chk_mid_counts) // + << "," << field_to_string(row.lookup_mem_rng_chk_hi_counts) // + << "," << field_to_string(row.lookup_pow_2_0_counts) // + << "," << field_to_string(row.lookup_pow_2_1_counts) // + << "," << field_to_string(row.lookup_u8_0_counts) // + << "," << field_to_string(row.lookup_u8_1_counts) // + << "," << field_to_string(row.lookup_u16_0_counts) // + << "," << field_to_string(row.lookup_u16_1_counts) // + << "," << field_to_string(row.lookup_u16_2_counts) // + << "," << field_to_string(row.lookup_u16_3_counts) // + << "," << field_to_string(row.lookup_u16_4_counts) // + << "," << field_to_string(row.lookup_u16_5_counts) // + << "," << field_to_string(row.lookup_u16_6_counts) // + << "," << field_to_string(row.lookup_u16_7_counts) // + << "," << field_to_string(row.lookup_u16_8_counts) // + << "," << field_to_string(row.lookup_u16_9_counts) // + << "," << field_to_string(row.lookup_u16_10_counts) // + << "," << field_to_string(row.lookup_u16_11_counts) // + << "," << field_to_string(row.lookup_u16_12_counts) // + << "," << field_to_string(row.lookup_u16_13_counts) // + << "," << field_to_string(row.lookup_u16_14_counts) // + << "," << field_to_string(row.lookup_div_u16_0_counts) // + << "," << field_to_string(row.lookup_div_u16_1_counts) // + << "," << field_to_string(row.lookup_div_u16_2_counts) // + << "," << field_to_string(row.lookup_div_u16_3_counts) // + << "," << field_to_string(row.lookup_div_u16_4_counts) // + << "," << field_to_string(row.lookup_div_u16_5_counts) // + << "," << field_to_string(row.lookup_div_u16_6_counts) // + << "," << field_to_string(row.lookup_div_u16_7_counts) // + ; +======= + return os + << field_to_string(row.main_clk) << "," << field_to_string(row.main_sel_first) << "," + << field_to_string(row.kernel_kernel_inputs) << "," << field_to_string(row.kernel_kernel_value_out) << "," + << field_to_string(row.kernel_kernel_side_effect_out) << "," + << field_to_string(row.kernel_kernel_metadata_out) << "," << field_to_string(row.main_calldata) << "," + << field_to_string(row.alu_a_hi) << "," << field_to_string(row.alu_a_lo) << "," + << field_to_string(row.alu_b_hi) << "," << field_to_string(row.alu_b_lo) << "," + << field_to_string(row.alu_borrow) << "," << field_to_string(row.alu_cf) << "," + << field_to_string(row.alu_clk) << "," << field_to_string(row.alu_cmp_rng_ctr) << "," + << field_to_string(row.alu_div_u16_r0) << "," << field_to_string(row.alu_div_u16_r1) << "," + << field_to_string(row.alu_div_u16_r2) << "," << field_to_string(row.alu_div_u16_r3) << "," + << field_to_string(row.alu_div_u16_r4) << "," << field_to_string(row.alu_div_u16_r5) << "," + << field_to_string(row.alu_div_u16_r6) << "," << field_to_string(row.alu_div_u16_r7) << "," + << field_to_string(row.alu_divisor_hi) << "," << field_to_string(row.alu_divisor_lo) << "," + << field_to_string(row.alu_ff_tag) << "," << field_to_string(row.alu_ia) << "," + << field_to_string(row.alu_ib) << "," << field_to_string(row.alu_ic) << "," + << field_to_string(row.alu_in_tag) << "," << field_to_string(row.alu_op_add) << "," + << field_to_string(row.alu_op_cast) << "," << field_to_string(row.alu_op_cast_prev) << "," + << field_to_string(row.alu_op_div) << "," << field_to_string(row.alu_op_div_a_lt_b) << "," + << field_to_string(row.alu_op_div_std) << "," << field_to_string(row.alu_op_eq) << "," + << field_to_string(row.alu_op_eq_diff_inv) << "," << field_to_string(row.alu_op_lt) << "," + << field_to_string(row.alu_op_lte) << "," << field_to_string(row.alu_op_mul) << "," + << field_to_string(row.alu_op_not) << "," << field_to_string(row.alu_op_shl) << "," + << field_to_string(row.alu_op_shr) << "," << field_to_string(row.alu_op_sub) << "," + << field_to_string(row.alu_p_a_borrow) << "," << field_to_string(row.alu_p_b_borrow) << "," + << field_to_string(row.alu_p_sub_a_hi) << "," << field_to_string(row.alu_p_sub_a_lo) << "," + << field_to_string(row.alu_p_sub_b_hi) << "," << field_to_string(row.alu_p_sub_b_lo) << "," + << field_to_string(row.alu_partial_prod_hi) << "," << field_to_string(row.alu_partial_prod_lo) << "," + << field_to_string(row.alu_quotient_hi) << "," << field_to_string(row.alu_quotient_lo) << "," + << field_to_string(row.alu_remainder) << "," << field_to_string(row.alu_res_hi) << "," + << field_to_string(row.alu_res_lo) << "," << field_to_string(row.alu_sel_alu) << "," + << field_to_string(row.alu_sel_cmp) << "," << field_to_string(row.alu_sel_div_rng_chk) << "," + << field_to_string(row.alu_sel_rng_chk) << "," << field_to_string(row.alu_sel_rng_chk_lookup) << "," + << field_to_string(row.alu_sel_shift_which) << "," << field_to_string(row.alu_shift_lt_bit_len) << "," + << field_to_string(row.alu_t_sub_s_bits) << "," << field_to_string(row.alu_two_pow_s) << "," + << field_to_string(row.alu_two_pow_t_sub_s) << "," << field_to_string(row.alu_u128_tag) << "," + << field_to_string(row.alu_u16_r0) << "," << field_to_string(row.alu_u16_r1) << "," + << field_to_string(row.alu_u16_r10) << "," << field_to_string(row.alu_u16_r11) << "," + << field_to_string(row.alu_u16_r12) << "," << field_to_string(row.alu_u16_r13) << "," + << field_to_string(row.alu_u16_r14) << "," << field_to_string(row.alu_u16_r2) << "," + << field_to_string(row.alu_u16_r3) << "," << field_to_string(row.alu_u16_r4) << "," + << field_to_string(row.alu_u16_r5) << "," << field_to_string(row.alu_u16_r6) << "," + << field_to_string(row.alu_u16_r7) << "," << field_to_string(row.alu_u16_r8) << "," + << field_to_string(row.alu_u16_r9) << "," << field_to_string(row.alu_u16_tag) << "," + << field_to_string(row.alu_u32_tag) << "," << field_to_string(row.alu_u64_tag) << "," + << field_to_string(row.alu_u8_r0) << "," << field_to_string(row.alu_u8_r1) << "," + << field_to_string(row.alu_u8_tag) << "," << field_to_string(row.binary_acc_ia) << "," + << field_to_string(row.binary_acc_ib) << "," << field_to_string(row.binary_acc_ic) << "," + << field_to_string(row.binary_clk) << "," << field_to_string(row.binary_ia_bytes) << "," + << field_to_string(row.binary_ib_bytes) << "," << field_to_string(row.binary_ic_bytes) << "," + << field_to_string(row.binary_in_tag) << "," << field_to_string(row.binary_mem_tag_ctr) << "," + << field_to_string(row.binary_mem_tag_ctr_inv) << "," << field_to_string(row.binary_op_id) << "," + << field_to_string(row.binary_sel_bin) << "," << field_to_string(row.binary_start) << "," + << field_to_string(row.byte_lookup_sel_bin) << "," << field_to_string(row.byte_lookup_table_byte_lengths) + << "," << field_to_string(row.byte_lookup_table_in_tags) << "," + << field_to_string(row.byte_lookup_table_input_a) << "," << field_to_string(row.byte_lookup_table_input_b) + << "," << field_to_string(row.byte_lookup_table_op_id) << "," + << field_to_string(row.byte_lookup_table_output) << "," << field_to_string(row.conversion_clk) << "," + << field_to_string(row.conversion_input) << "," << field_to_string(row.conversion_num_limbs) << "," + << field_to_string(row.conversion_radix) << "," << field_to_string(row.conversion_sel_to_radix_le) << "," + << field_to_string(row.gas_da_gas_fixed_table) << "," << field_to_string(row.gas_l2_gas_fixed_table) << "," + << field_to_string(row.gas_sel_gas_cost) << "," << field_to_string(row.keccakf1600_clk) << "," + << field_to_string(row.keccakf1600_input) << "," << field_to_string(row.keccakf1600_output) << "," + << field_to_string(row.keccakf1600_sel_keccakf1600) << "," + << field_to_string(row.kernel_emit_l2_to_l1_msg_write_offset) << "," + << field_to_string(row.kernel_emit_note_hash_write_offset) << "," + << field_to_string(row.kernel_emit_nullifier_write_offset) << "," + << field_to_string(row.kernel_emit_unencrypted_log_write_offset) << "," + << field_to_string(row.kernel_kernel_in_offset) << "," << field_to_string(row.kernel_kernel_out_offset) + << "," << field_to_string(row.kernel_l1_to_l2_msg_exists_write_offset) << "," + << field_to_string(row.kernel_note_hash_exist_write_offset) << "," + << field_to_string(row.kernel_nullifier_exists_write_offset) << "," + << field_to_string(row.kernel_nullifier_non_exists_write_offset) << "," + << field_to_string(row.kernel_q_public_input_kernel_add_to_table) << "," + << field_to_string(row.kernel_q_public_input_kernel_out_add_to_table) << "," + << field_to_string(row.kernel_side_effect_counter) << "," << field_to_string(row.kernel_sload_write_offset) + << "," << field_to_string(row.kernel_sstore_write_offset) << "," + << field_to_string(row.main_abs_da_rem_gas_hi) << "," << field_to_string(row.main_abs_da_rem_gas_lo) << "," + << field_to_string(row.main_abs_l2_rem_gas_hi) << "," << field_to_string(row.main_abs_l2_rem_gas_lo) << "," + << field_to_string(row.main_alu_in_tag) << "," << field_to_string(row.main_bin_op_id) << "," + << field_to_string(row.main_call_ptr) << "," << field_to_string(row.main_da_gas_op_cost) << "," + << field_to_string(row.main_da_gas_remaining) << "," << field_to_string(row.main_da_out_of_gas) << "," + << field_to_string(row.main_ia) << "," << field_to_string(row.main_ib) << "," << field_to_string(row.main_ic) + << "," << field_to_string(row.main_id) << "," << field_to_string(row.main_id_zero) << "," + << field_to_string(row.main_ind_addr_a) << "," << field_to_string(row.main_ind_addr_b) << "," + << field_to_string(row.main_ind_addr_c) << "," << field_to_string(row.main_ind_addr_d) << "," + << field_to_string(row.main_internal_return_ptr) << "," << field_to_string(row.main_inv) << "," + << field_to_string(row.main_l2_gas_op_cost) << "," << field_to_string(row.main_l2_gas_remaining) << "," + << field_to_string(row.main_l2_out_of_gas) << "," << field_to_string(row.main_mem_addr_a) << "," + << field_to_string(row.main_mem_addr_b) << "," << field_to_string(row.main_mem_addr_c) << "," + << field_to_string(row.main_mem_addr_d) << "," << field_to_string(row.main_op_err) << "," + << field_to_string(row.main_opcode_val) << "," << field_to_string(row.main_pc) << "," + << field_to_string(row.main_r_in_tag) << "," << field_to_string(row.main_rwa) << "," + << field_to_string(row.main_rwb) << "," << field_to_string(row.main_rwc) << "," + << field_to_string(row.main_rwd) << "," << field_to_string(row.main_sel_alu) << "," + << field_to_string(row.main_sel_bin) << "," << field_to_string(row.main_sel_gas_accounting_active) << "," + << field_to_string(row.main_sel_last) << "," << field_to_string(row.main_sel_mem_op_a) << "," + << field_to_string(row.main_sel_mem_op_activate_gas) << "," << field_to_string(row.main_sel_mem_op_b) << "," + << field_to_string(row.main_sel_mem_op_c) << "," << field_to_string(row.main_sel_mem_op_d) << "," + << field_to_string(row.main_sel_mov_ia_to_ic) << "," << field_to_string(row.main_sel_mov_ib_to_ic) << "," + << field_to_string(row.main_sel_op_add) << "," << field_to_string(row.main_sel_op_address) << "," + << field_to_string(row.main_sel_op_and) << "," << field_to_string(row.main_sel_op_block_number) << "," + << field_to_string(row.main_sel_op_cast) << "," << field_to_string(row.main_sel_op_chain_id) << "," + << field_to_string(row.main_sel_op_cmov) << "," << field_to_string(row.main_sel_op_coinbase) << "," + << field_to_string(row.main_sel_op_dagasleft) << "," << field_to_string(row.main_sel_op_div) << "," + << field_to_string(row.main_sel_op_emit_l2_to_l1_msg) << "," + << field_to_string(row.main_sel_op_emit_note_hash) << "," << field_to_string(row.main_sel_op_emit_nullifier) + << "," << field_to_string(row.main_sel_op_emit_unencrypted_log) << "," << field_to_string(row.main_sel_op_eq) + << "," << field_to_string(row.main_sel_op_external_call) << "," << field_to_string(row.main_sel_op_fdiv) + << "," << field_to_string(row.main_sel_op_fee_per_da_gas) << "," + << field_to_string(row.main_sel_op_fee_per_l2_gas) << "," + << field_to_string(row.main_sel_op_function_selector) << "," + << field_to_string(row.main_sel_op_get_contract_instance) << "," << field_to_string(row.main_sel_op_halt) + << "," << field_to_string(row.main_sel_op_internal_call) << "," + << field_to_string(row.main_sel_op_internal_return) << "," << field_to_string(row.main_sel_op_jump) << "," + << field_to_string(row.main_sel_op_jumpi) << "," << field_to_string(row.main_sel_op_keccak) << "," + << field_to_string(row.main_sel_op_l1_to_l2_msg_exists) << "," << field_to_string(row.main_sel_op_l2gasleft) + << "," << field_to_string(row.main_sel_op_lt) << "," << field_to_string(row.main_sel_op_lte) << "," + << field_to_string(row.main_sel_op_mov) << "," << field_to_string(row.main_sel_op_mul) << "," + << field_to_string(row.main_sel_op_not) << "," << field_to_string(row.main_sel_op_note_hash_exists) << "," + << field_to_string(row.main_sel_op_nullifier_exists) << "," << field_to_string(row.main_sel_op_or) << "," + << field_to_string(row.main_sel_op_pedersen) << "," << field_to_string(row.main_sel_op_poseidon2) << "," + << field_to_string(row.main_sel_op_radix_le) << "," << field_to_string(row.main_sel_op_sender) << "," + << field_to_string(row.main_sel_op_sha256) << "," << field_to_string(row.main_sel_op_shl) << "," + << field_to_string(row.main_sel_op_shr) << "," << field_to_string(row.main_sel_op_sload) << "," + << field_to_string(row.main_sel_op_sstore) << "," << field_to_string(row.main_sel_op_storage_address) << "," + << field_to_string(row.main_sel_op_sub) << "," << field_to_string(row.main_sel_op_timestamp) << "," + << field_to_string(row.main_sel_op_transaction_fee) << "," << field_to_string(row.main_sel_op_version) << "," + << field_to_string(row.main_sel_op_xor) << "," << field_to_string(row.main_sel_q_kernel_lookup) << "," + << field_to_string(row.main_sel_q_kernel_output_lookup) << "," + << field_to_string(row.main_sel_resolve_ind_addr_a) << "," + << field_to_string(row.main_sel_resolve_ind_addr_b) << "," + << field_to_string(row.main_sel_resolve_ind_addr_c) << "," + << field_to_string(row.main_sel_resolve_ind_addr_d) << "," << field_to_string(row.main_sel_rng_16) << "," + << field_to_string(row.main_sel_rng_8) << "," << field_to_string(row.main_space_id) << "," + << field_to_string(row.main_tag_err) << "," << field_to_string(row.main_w_in_tag) << "," + << field_to_string(row.mem_addr) << "," << field_to_string(row.mem_clk) << "," + << field_to_string(row.mem_diff_hi) << "," << field_to_string(row.mem_diff_lo) << "," + << field_to_string(row.mem_diff_mid) << "," << field_to_string(row.mem_glob_addr) << "," + << field_to_string(row.mem_last) << "," << field_to_string(row.mem_lastAccess) << "," + << field_to_string(row.mem_one_min_inv) << "," << field_to_string(row.mem_r_in_tag) << "," + << field_to_string(row.mem_rw) << "," << field_to_string(row.mem_sel_mem) << "," + << field_to_string(row.mem_sel_mov_ia_to_ic) << "," << field_to_string(row.mem_sel_mov_ib_to_ic) << "," + << field_to_string(row.mem_sel_op_a) << "," << field_to_string(row.mem_sel_op_b) << "," + << field_to_string(row.mem_sel_op_c) << "," << field_to_string(row.mem_sel_op_cmov) << "," + << field_to_string(row.mem_sel_op_d) << "," << field_to_string(row.mem_sel_resolve_ind_addr_a) << "," + << field_to_string(row.mem_sel_resolve_ind_addr_b) << "," << field_to_string(row.mem_sel_resolve_ind_addr_c) + << "," << field_to_string(row.mem_sel_resolve_ind_addr_d) << "," << field_to_string(row.mem_sel_rng_chk) + << "," << field_to_string(row.mem_skip_check_tag) << "," << field_to_string(row.mem_space_id) << "," + << field_to_string(row.mem_tag) << "," << field_to_string(row.mem_tag_err) << "," + << field_to_string(row.mem_tsp) << "," << field_to_string(row.mem_val) << "," + << field_to_string(row.mem_w_in_tag) << "," << field_to_string(row.pedersen_clk) << "," + << field_to_string(row.pedersen_input) << "," << field_to_string(row.pedersen_output) << "," + << field_to_string(row.pedersen_sel_pedersen) << "," << field_to_string(row.poseidon2_a_0) << "," + << field_to_string(row.poseidon2_a_1) << "," << field_to_string(row.poseidon2_a_2) << "," + << field_to_string(row.poseidon2_a_3) << "," << field_to_string(row.poseidon2_b_0) << "," + << field_to_string(row.poseidon2_b_1) << "," << field_to_string(row.poseidon2_b_2) << "," + << field_to_string(row.poseidon2_b_3) << "," << field_to_string(row.poseidon2_clk) << "," + << field_to_string(row.poseidon2_input) << "," << field_to_string(row.poseidon2_output) << "," + << field_to_string(row.poseidon2_sel_poseidon_perm) << "," << field_to_string(row.powers_power_of_2) << "," + << field_to_string(row.sha256_clk) << "," << field_to_string(row.sha256_input) << "," + << field_to_string(row.sha256_output) << "," << field_to_string(row.sha256_sel_sha256_compression) << "," + << field_to_string(row.sha256_state) << "," << field_to_string(row.perm_main_alu) << "," + << field_to_string(row.perm_main_bin) << "," << field_to_string(row.perm_main_conv) << "," + << field_to_string(row.perm_main_pos2_perm) << "," << field_to_string(row.perm_main_pedersen) << "," + << field_to_string(row.perm_main_mem_a) << "," << field_to_string(row.perm_main_mem_b) << "," + << field_to_string(row.perm_main_mem_c) << "," << field_to_string(row.perm_main_mem_d) << "," + << field_to_string(row.perm_main_mem_ind_addr_a) << "," << field_to_string(row.perm_main_mem_ind_addr_b) + << "," << field_to_string(row.perm_main_mem_ind_addr_c) << "," + << field_to_string(row.perm_main_mem_ind_addr_d) << "," << field_to_string(row.lookup_byte_lengths) << "," + << field_to_string(row.lookup_byte_operations) << "," << field_to_string(row.lookup_opcode_gas) << "," + << field_to_string(row.range_check_l2_gas_hi) << "," << field_to_string(row.range_check_l2_gas_lo) << "," + << field_to_string(row.range_check_da_gas_hi) << "," << field_to_string(row.range_check_da_gas_lo) << "," + << field_to_string(row.kernel_output_lookup) << "," << field_to_string(row.lookup_into_kernel) << "," + << field_to_string(row.incl_main_tag_err) << "," << field_to_string(row.incl_mem_tag_err) << "," + << field_to_string(row.lookup_mem_rng_chk_lo) << "," << field_to_string(row.lookup_mem_rng_chk_mid) << "," + << field_to_string(row.lookup_mem_rng_chk_hi) << "," << field_to_string(row.lookup_pow_2_0) << "," + << field_to_string(row.lookup_pow_2_1) << "," << field_to_string(row.lookup_u8_0) << "," + << field_to_string(row.lookup_u8_1) << "," << field_to_string(row.lookup_u16_0) << "," + << field_to_string(row.lookup_u16_1) << "," << field_to_string(row.lookup_u16_2) << "," + << field_to_string(row.lookup_u16_3) << "," << field_to_string(row.lookup_u16_4) << "," + << field_to_string(row.lookup_u16_5) << "," << field_to_string(row.lookup_u16_6) << "," + << field_to_string(row.lookup_u16_7) << "," << field_to_string(row.lookup_u16_8) << "," + << field_to_string(row.lookup_u16_9) << "," << field_to_string(row.lookup_u16_10) << "," + << field_to_string(row.lookup_u16_11) << "," << field_to_string(row.lookup_u16_12) << "," + << field_to_string(row.lookup_u16_13) << "," << field_to_string(row.lookup_u16_14) << "," + << field_to_string(row.lookup_div_u16_0) << "," << field_to_string(row.lookup_div_u16_1) << "," + << field_to_string(row.lookup_div_u16_2) << "," << field_to_string(row.lookup_div_u16_3) << "," + << field_to_string(row.lookup_div_u16_4) << "," << field_to_string(row.lookup_div_u16_5) << "," + << field_to_string(row.lookup_div_u16_6) << "," << field_to_string(row.lookup_div_u16_7) << "," + << field_to_string(row.lookup_byte_lengths_counts) << "," + << field_to_string(row.lookup_byte_operations_counts) << "," << field_to_string(row.lookup_opcode_gas_counts) + << "," << field_to_string(row.range_check_l2_gas_hi_counts) << "," + << field_to_string(row.range_check_l2_gas_lo_counts) << "," + << field_to_string(row.range_check_da_gas_hi_counts) << "," + << field_to_string(row.range_check_da_gas_lo_counts) << "," + << field_to_string(row.kernel_output_lookup_counts) << "," << field_to_string(row.lookup_into_kernel_counts) + << "," << field_to_string(row.incl_main_tag_err_counts) << "," + << field_to_string(row.incl_mem_tag_err_counts) << "," << field_to_string(row.lookup_mem_rng_chk_lo_counts) + << "," << field_to_string(row.lookup_mem_rng_chk_mid_counts) << "," + << field_to_string(row.lookup_mem_rng_chk_hi_counts) << "," << field_to_string(row.lookup_pow_2_0_counts) + << "," << field_to_string(row.lookup_pow_2_1_counts) << "," << field_to_string(row.lookup_u8_0_counts) << "," + << field_to_string(row.lookup_u8_1_counts) << "," << field_to_string(row.lookup_u16_0_counts) << "," + << field_to_string(row.lookup_u16_1_counts) << "," << field_to_string(row.lookup_u16_2_counts) << "," + << field_to_string(row.lookup_u16_3_counts) << "," << field_to_string(row.lookup_u16_4_counts) << "," + << field_to_string(row.lookup_u16_5_counts) << "," << field_to_string(row.lookup_u16_6_counts) << "," + << field_to_string(row.lookup_u16_7_counts) << "," << field_to_string(row.lookup_u16_8_counts) << "," + << field_to_string(row.lookup_u16_9_counts) << "," << field_to_string(row.lookup_u16_10_counts) << "," + << field_to_string(row.lookup_u16_11_counts) << "," << field_to_string(row.lookup_u16_12_counts) << "," + << field_to_string(row.lookup_u16_13_counts) << "," << field_to_string(row.lookup_u16_14_counts) << "," + << field_to_string(row.lookup_div_u16_0_counts) << "," << field_to_string(row.lookup_div_u16_1_counts) << "," + << field_to_string(row.lookup_div_u16_2_counts) << "," << field_to_string(row.lookup_div_u16_3_counts) << "," + << field_to_string(row.lookup_div_u16_4_counts) << "," << field_to_string(row.lookup_div_u16_5_counts) << "," + << field_to_string(row.lookup_div_u16_6_counts) << "," << field_to_string(row.lookup_div_u16_7_counts) + << "," + ""; +>>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) +>>>>>>> 822f92e90 (feat(avm): poseidon2 constraints) } // Explicit template instantiation. diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/prover.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/prover.cpp index d5cbab1767e0..efea2c734f19 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/prover.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/prover.cpp @@ -61,11 +61,786 @@ void AvmProver::execute_wire_commitments_round() { // Commit to all polynomials (apart from logderivative inverse polynomials, which are committed to in the later // logderivative phase) +<<<<<<< HEAD auto wire_polys = prover_polynomials.get_wires(); auto labels = commitment_labels.get_wires(); for (size_t idx = 0; idx < wire_polys.size(); ++idx) { transcript->send_to_verifier(labels[idx], commitment_key->commit_sparse(wire_polys[idx])); } +======= + witness_commitments.kernel_kernel_inputs = commitment_key->commit(key->kernel_kernel_inputs); + witness_commitments.kernel_kernel_value_out = commitment_key->commit(key->kernel_kernel_value_out); + witness_commitments.kernel_kernel_side_effect_out = commitment_key->commit(key->kernel_kernel_side_effect_out); + witness_commitments.kernel_kernel_metadata_out = commitment_key->commit(key->kernel_kernel_metadata_out); + witness_commitments.main_calldata = commitment_key->commit(key->main_calldata); + witness_commitments.alu_a_hi = commitment_key->commit(key->alu_a_hi); + witness_commitments.alu_a_lo = commitment_key->commit(key->alu_a_lo); + witness_commitments.alu_b_hi = commitment_key->commit(key->alu_b_hi); + witness_commitments.alu_b_lo = commitment_key->commit(key->alu_b_lo); + witness_commitments.alu_borrow = commitment_key->commit(key->alu_borrow); + witness_commitments.alu_cf = commitment_key->commit(key->alu_cf); + witness_commitments.alu_clk = commitment_key->commit(key->alu_clk); + witness_commitments.alu_cmp_rng_ctr = commitment_key->commit(key->alu_cmp_rng_ctr); + witness_commitments.alu_div_u16_r0 = commitment_key->commit(key->alu_div_u16_r0); + witness_commitments.alu_div_u16_r1 = commitment_key->commit(key->alu_div_u16_r1); + witness_commitments.alu_div_u16_r2 = commitment_key->commit(key->alu_div_u16_r2); + witness_commitments.alu_div_u16_r3 = commitment_key->commit(key->alu_div_u16_r3); + witness_commitments.alu_div_u16_r4 = commitment_key->commit(key->alu_div_u16_r4); + witness_commitments.alu_div_u16_r5 = commitment_key->commit(key->alu_div_u16_r5); + witness_commitments.alu_div_u16_r6 = commitment_key->commit(key->alu_div_u16_r6); + witness_commitments.alu_div_u16_r7 = commitment_key->commit(key->alu_div_u16_r7); + witness_commitments.alu_divisor_hi = commitment_key->commit(key->alu_divisor_hi); + witness_commitments.alu_divisor_lo = commitment_key->commit(key->alu_divisor_lo); + witness_commitments.alu_ff_tag = commitment_key->commit(key->alu_ff_tag); + witness_commitments.alu_ia = commitment_key->commit(key->alu_ia); + witness_commitments.alu_ib = commitment_key->commit(key->alu_ib); + witness_commitments.alu_ic = commitment_key->commit(key->alu_ic); + witness_commitments.alu_in_tag = commitment_key->commit(key->alu_in_tag); + witness_commitments.alu_op_add = commitment_key->commit(key->alu_op_add); + witness_commitments.alu_op_cast = commitment_key->commit(key->alu_op_cast); + witness_commitments.alu_op_cast_prev = commitment_key->commit(key->alu_op_cast_prev); + witness_commitments.alu_op_div = commitment_key->commit(key->alu_op_div); + witness_commitments.alu_op_div_a_lt_b = commitment_key->commit(key->alu_op_div_a_lt_b); + witness_commitments.alu_op_div_std = commitment_key->commit(key->alu_op_div_std); + witness_commitments.alu_op_eq = commitment_key->commit(key->alu_op_eq); + witness_commitments.alu_op_eq_diff_inv = commitment_key->commit(key->alu_op_eq_diff_inv); + witness_commitments.alu_op_lt = commitment_key->commit(key->alu_op_lt); + witness_commitments.alu_op_lte = commitment_key->commit(key->alu_op_lte); + witness_commitments.alu_op_mul = commitment_key->commit(key->alu_op_mul); + witness_commitments.alu_op_not = commitment_key->commit(key->alu_op_not); + witness_commitments.alu_op_shl = commitment_key->commit(key->alu_op_shl); + witness_commitments.alu_op_shr = commitment_key->commit(key->alu_op_shr); + witness_commitments.alu_op_sub = commitment_key->commit(key->alu_op_sub); + witness_commitments.alu_p_a_borrow = commitment_key->commit(key->alu_p_a_borrow); + witness_commitments.alu_p_b_borrow = commitment_key->commit(key->alu_p_b_borrow); + witness_commitments.alu_p_sub_a_hi = commitment_key->commit(key->alu_p_sub_a_hi); + witness_commitments.alu_p_sub_a_lo = commitment_key->commit(key->alu_p_sub_a_lo); + witness_commitments.alu_p_sub_b_hi = commitment_key->commit(key->alu_p_sub_b_hi); + witness_commitments.alu_p_sub_b_lo = commitment_key->commit(key->alu_p_sub_b_lo); + witness_commitments.alu_partial_prod_hi = commitment_key->commit(key->alu_partial_prod_hi); + witness_commitments.alu_partial_prod_lo = commitment_key->commit(key->alu_partial_prod_lo); + witness_commitments.alu_quotient_hi = commitment_key->commit(key->alu_quotient_hi); + witness_commitments.alu_quotient_lo = commitment_key->commit(key->alu_quotient_lo); + witness_commitments.alu_remainder = commitment_key->commit(key->alu_remainder); + witness_commitments.alu_res_hi = commitment_key->commit(key->alu_res_hi); + witness_commitments.alu_res_lo = commitment_key->commit(key->alu_res_lo); + witness_commitments.alu_sel_alu = commitment_key->commit(key->alu_sel_alu); + witness_commitments.alu_sel_cmp = commitment_key->commit(key->alu_sel_cmp); + witness_commitments.alu_sel_div_rng_chk = commitment_key->commit(key->alu_sel_div_rng_chk); + witness_commitments.alu_sel_rng_chk = commitment_key->commit(key->alu_sel_rng_chk); + witness_commitments.alu_sel_rng_chk_lookup = commitment_key->commit(key->alu_sel_rng_chk_lookup); + witness_commitments.alu_sel_shift_which = commitment_key->commit(key->alu_sel_shift_which); + witness_commitments.alu_shift_lt_bit_len = commitment_key->commit(key->alu_shift_lt_bit_len); + witness_commitments.alu_t_sub_s_bits = commitment_key->commit(key->alu_t_sub_s_bits); + witness_commitments.alu_two_pow_s = commitment_key->commit(key->alu_two_pow_s); + witness_commitments.alu_two_pow_t_sub_s = commitment_key->commit(key->alu_two_pow_t_sub_s); + witness_commitments.alu_u128_tag = commitment_key->commit(key->alu_u128_tag); + witness_commitments.alu_u16_r0 = commitment_key->commit(key->alu_u16_r0); + witness_commitments.alu_u16_r1 = commitment_key->commit(key->alu_u16_r1); + witness_commitments.alu_u16_r10 = commitment_key->commit(key->alu_u16_r10); + witness_commitments.alu_u16_r11 = commitment_key->commit(key->alu_u16_r11); + witness_commitments.alu_u16_r12 = commitment_key->commit(key->alu_u16_r12); + witness_commitments.alu_u16_r13 = commitment_key->commit(key->alu_u16_r13); + witness_commitments.alu_u16_r14 = commitment_key->commit(key->alu_u16_r14); + witness_commitments.alu_u16_r2 = commitment_key->commit(key->alu_u16_r2); + witness_commitments.alu_u16_r3 = commitment_key->commit(key->alu_u16_r3); + witness_commitments.alu_u16_r4 = commitment_key->commit(key->alu_u16_r4); + witness_commitments.alu_u16_r5 = commitment_key->commit(key->alu_u16_r5); + witness_commitments.alu_u16_r6 = commitment_key->commit(key->alu_u16_r6); + witness_commitments.alu_u16_r7 = commitment_key->commit(key->alu_u16_r7); + witness_commitments.alu_u16_r8 = commitment_key->commit(key->alu_u16_r8); + witness_commitments.alu_u16_r9 = commitment_key->commit(key->alu_u16_r9); + witness_commitments.alu_u16_tag = commitment_key->commit(key->alu_u16_tag); + witness_commitments.alu_u32_tag = commitment_key->commit(key->alu_u32_tag); + witness_commitments.alu_u64_tag = commitment_key->commit(key->alu_u64_tag); + witness_commitments.alu_u8_r0 = commitment_key->commit(key->alu_u8_r0); + witness_commitments.alu_u8_r1 = commitment_key->commit(key->alu_u8_r1); + witness_commitments.alu_u8_tag = commitment_key->commit(key->alu_u8_tag); + witness_commitments.binary_acc_ia = commitment_key->commit(key->binary_acc_ia); + witness_commitments.binary_acc_ib = commitment_key->commit(key->binary_acc_ib); + witness_commitments.binary_acc_ic = commitment_key->commit(key->binary_acc_ic); + witness_commitments.binary_clk = commitment_key->commit(key->binary_clk); + witness_commitments.binary_ia_bytes = commitment_key->commit(key->binary_ia_bytes); + witness_commitments.binary_ib_bytes = commitment_key->commit(key->binary_ib_bytes); + witness_commitments.binary_ic_bytes = commitment_key->commit(key->binary_ic_bytes); + witness_commitments.binary_in_tag = commitment_key->commit(key->binary_in_tag); + witness_commitments.binary_mem_tag_ctr = commitment_key->commit(key->binary_mem_tag_ctr); + witness_commitments.binary_mem_tag_ctr_inv = commitment_key->commit(key->binary_mem_tag_ctr_inv); + witness_commitments.binary_op_id = commitment_key->commit(key->binary_op_id); + witness_commitments.binary_sel_bin = commitment_key->commit(key->binary_sel_bin); + witness_commitments.binary_start = commitment_key->commit(key->binary_start); + witness_commitments.byte_lookup_sel_bin = commitment_key->commit(key->byte_lookup_sel_bin); + witness_commitments.byte_lookup_table_byte_lengths = commitment_key->commit(key->byte_lookup_table_byte_lengths); + witness_commitments.byte_lookup_table_in_tags = commitment_key->commit(key->byte_lookup_table_in_tags); + witness_commitments.byte_lookup_table_input_a = commitment_key->commit(key->byte_lookup_table_input_a); + witness_commitments.byte_lookup_table_input_b = commitment_key->commit(key->byte_lookup_table_input_b); + witness_commitments.byte_lookup_table_op_id = commitment_key->commit(key->byte_lookup_table_op_id); + witness_commitments.byte_lookup_table_output = commitment_key->commit(key->byte_lookup_table_output); + witness_commitments.conversion_clk = commitment_key->commit(key->conversion_clk); + witness_commitments.conversion_input = commitment_key->commit(key->conversion_input); + witness_commitments.conversion_num_limbs = commitment_key->commit(key->conversion_num_limbs); + witness_commitments.conversion_radix = commitment_key->commit(key->conversion_radix); + witness_commitments.conversion_sel_to_radix_le = commitment_key->commit(key->conversion_sel_to_radix_le); + witness_commitments.gas_da_gas_fixed_table = commitment_key->commit(key->gas_da_gas_fixed_table); + witness_commitments.gas_l2_gas_fixed_table = commitment_key->commit(key->gas_l2_gas_fixed_table); + witness_commitments.gas_sel_gas_cost = commitment_key->commit(key->gas_sel_gas_cost); + witness_commitments.keccakf1600_clk = commitment_key->commit(key->keccakf1600_clk); + witness_commitments.keccakf1600_input = commitment_key->commit(key->keccakf1600_input); + witness_commitments.keccakf1600_output = commitment_key->commit(key->keccakf1600_output); + witness_commitments.keccakf1600_sel_keccakf1600 = commitment_key->commit(key->keccakf1600_sel_keccakf1600); + witness_commitments.kernel_emit_l2_to_l1_msg_write_offset = + commitment_key->commit(key->kernel_emit_l2_to_l1_msg_write_offset); + witness_commitments.kernel_emit_note_hash_write_offset = + commitment_key->commit(key->kernel_emit_note_hash_write_offset); + witness_commitments.kernel_emit_nullifier_write_offset = + commitment_key->commit(key->kernel_emit_nullifier_write_offset); + witness_commitments.kernel_emit_unencrypted_log_write_offset = + commitment_key->commit(key->kernel_emit_unencrypted_log_write_offset); + witness_commitments.kernel_kernel_in_offset = commitment_key->commit(key->kernel_kernel_in_offset); + witness_commitments.kernel_kernel_out_offset = commitment_key->commit(key->kernel_kernel_out_offset); + witness_commitments.kernel_l1_to_l2_msg_exists_write_offset = + commitment_key->commit(key->kernel_l1_to_l2_msg_exists_write_offset); + witness_commitments.kernel_note_hash_exist_write_offset = + commitment_key->commit(key->kernel_note_hash_exist_write_offset); + witness_commitments.kernel_nullifier_exists_write_offset = + commitment_key->commit(key->kernel_nullifier_exists_write_offset); + witness_commitments.kernel_nullifier_non_exists_write_offset = + commitment_key->commit(key->kernel_nullifier_non_exists_write_offset); + witness_commitments.kernel_q_public_input_kernel_add_to_table = + commitment_key->commit(key->kernel_q_public_input_kernel_add_to_table); + witness_commitments.kernel_q_public_input_kernel_out_add_to_table = + commitment_key->commit(key->kernel_q_public_input_kernel_out_add_to_table); + witness_commitments.kernel_side_effect_counter = commitment_key->commit(key->kernel_side_effect_counter); + witness_commitments.kernel_sload_write_offset = commitment_key->commit(key->kernel_sload_write_offset); + witness_commitments.kernel_sstore_write_offset = commitment_key->commit(key->kernel_sstore_write_offset); + witness_commitments.main_abs_da_rem_gas_hi = commitment_key->commit(key->main_abs_da_rem_gas_hi); + witness_commitments.main_abs_da_rem_gas_lo = commitment_key->commit(key->main_abs_da_rem_gas_lo); + witness_commitments.main_abs_l2_rem_gas_hi = commitment_key->commit(key->main_abs_l2_rem_gas_hi); + witness_commitments.main_abs_l2_rem_gas_lo = commitment_key->commit(key->main_abs_l2_rem_gas_lo); + witness_commitments.main_alu_in_tag = commitment_key->commit(key->main_alu_in_tag); + witness_commitments.main_bin_op_id = commitment_key->commit(key->main_bin_op_id); + witness_commitments.main_call_ptr = commitment_key->commit(key->main_call_ptr); + witness_commitments.main_da_gas_op_cost = commitment_key->commit(key->main_da_gas_op_cost); + witness_commitments.main_da_gas_remaining = commitment_key->commit(key->main_da_gas_remaining); + witness_commitments.main_da_out_of_gas = commitment_key->commit(key->main_da_out_of_gas); + witness_commitments.main_ia = commitment_key->commit(key->main_ia); + witness_commitments.main_ib = commitment_key->commit(key->main_ib); + witness_commitments.main_ic = commitment_key->commit(key->main_ic); + witness_commitments.main_id = commitment_key->commit(key->main_id); + witness_commitments.main_id_zero = commitment_key->commit(key->main_id_zero); + witness_commitments.main_ind_addr_a = commitment_key->commit(key->main_ind_addr_a); + witness_commitments.main_ind_addr_b = commitment_key->commit(key->main_ind_addr_b); + witness_commitments.main_ind_addr_c = commitment_key->commit(key->main_ind_addr_c); + witness_commitments.main_ind_addr_d = commitment_key->commit(key->main_ind_addr_d); + witness_commitments.main_internal_return_ptr = commitment_key->commit(key->main_internal_return_ptr); + witness_commitments.main_inv = commitment_key->commit(key->main_inv); + witness_commitments.main_l2_gas_op_cost = commitment_key->commit(key->main_l2_gas_op_cost); + witness_commitments.main_l2_gas_remaining = commitment_key->commit(key->main_l2_gas_remaining); + witness_commitments.main_l2_out_of_gas = commitment_key->commit(key->main_l2_out_of_gas); + witness_commitments.main_mem_addr_a = commitment_key->commit(key->main_mem_addr_a); + witness_commitments.main_mem_addr_b = commitment_key->commit(key->main_mem_addr_b); + witness_commitments.main_mem_addr_c = commitment_key->commit(key->main_mem_addr_c); + witness_commitments.main_mem_addr_d = commitment_key->commit(key->main_mem_addr_d); + witness_commitments.main_op_err = commitment_key->commit(key->main_op_err); + witness_commitments.main_opcode_val = commitment_key->commit(key->main_opcode_val); + witness_commitments.main_pc = commitment_key->commit(key->main_pc); + witness_commitments.main_r_in_tag = commitment_key->commit(key->main_r_in_tag); + witness_commitments.main_rwa = commitment_key->commit(key->main_rwa); + witness_commitments.main_rwb = commitment_key->commit(key->main_rwb); + witness_commitments.main_rwc = commitment_key->commit(key->main_rwc); + witness_commitments.main_rwd = commitment_key->commit(key->main_rwd); + witness_commitments.main_sel_alu = commitment_key->commit(key->main_sel_alu); + witness_commitments.main_sel_bin = commitment_key->commit(key->main_sel_bin); + witness_commitments.main_sel_gas_accounting_active = commitment_key->commit(key->main_sel_gas_accounting_active); + witness_commitments.main_sel_last = commitment_key->commit(key->main_sel_last); + witness_commitments.main_sel_mem_op_a = commitment_key->commit(key->main_sel_mem_op_a); + witness_commitments.main_sel_mem_op_activate_gas = commitment_key->commit(key->main_sel_mem_op_activate_gas); + witness_commitments.main_sel_mem_op_b = commitment_key->commit(key->main_sel_mem_op_b); + witness_commitments.main_sel_mem_op_c = commitment_key->commit(key->main_sel_mem_op_c); + witness_commitments.main_sel_mem_op_d = commitment_key->commit(key->main_sel_mem_op_d); + witness_commitments.main_sel_mov_ia_to_ic = commitment_key->commit(key->main_sel_mov_ia_to_ic); + witness_commitments.main_sel_mov_ib_to_ic = commitment_key->commit(key->main_sel_mov_ib_to_ic); + witness_commitments.main_sel_op_add = commitment_key->commit(key->main_sel_op_add); + witness_commitments.main_sel_op_address = commitment_key->commit(key->main_sel_op_address); + witness_commitments.main_sel_op_and = commitment_key->commit(key->main_sel_op_and); + witness_commitments.main_sel_op_block_number = commitment_key->commit(key->main_sel_op_block_number); + witness_commitments.main_sel_op_cast = commitment_key->commit(key->main_sel_op_cast); + witness_commitments.main_sel_op_chain_id = commitment_key->commit(key->main_sel_op_chain_id); + witness_commitments.main_sel_op_cmov = commitment_key->commit(key->main_sel_op_cmov); + witness_commitments.main_sel_op_coinbase = commitment_key->commit(key->main_sel_op_coinbase); + witness_commitments.main_sel_op_dagasleft = commitment_key->commit(key->main_sel_op_dagasleft); + witness_commitments.main_sel_op_div = commitment_key->commit(key->main_sel_op_div); + witness_commitments.main_sel_op_emit_l2_to_l1_msg = commitment_key->commit(key->main_sel_op_emit_l2_to_l1_msg); + witness_commitments.main_sel_op_emit_note_hash = commitment_key->commit(key->main_sel_op_emit_note_hash); + witness_commitments.main_sel_op_emit_nullifier = commitment_key->commit(key->main_sel_op_emit_nullifier); + witness_commitments.main_sel_op_emit_unencrypted_log = + commitment_key->commit(key->main_sel_op_emit_unencrypted_log); + witness_commitments.main_sel_op_eq = commitment_key->commit(key->main_sel_op_eq); + witness_commitments.main_sel_op_external_call = commitment_key->commit(key->main_sel_op_external_call); + witness_commitments.main_sel_op_fdiv = commitment_key->commit(key->main_sel_op_fdiv); + witness_commitments.main_sel_op_fee_per_da_gas = commitment_key->commit(key->main_sel_op_fee_per_da_gas); + witness_commitments.main_sel_op_fee_per_l2_gas = commitment_key->commit(key->main_sel_op_fee_per_l2_gas); + witness_commitments.main_sel_op_function_selector = commitment_key->commit(key->main_sel_op_function_selector); + witness_commitments.main_sel_op_get_contract_instance = + commitment_key->commit(key->main_sel_op_get_contract_instance); + witness_commitments.main_sel_op_halt = commitment_key->commit(key->main_sel_op_halt); + witness_commitments.main_sel_op_internal_call = commitment_key->commit(key->main_sel_op_internal_call); + witness_commitments.main_sel_op_internal_return = commitment_key->commit(key->main_sel_op_internal_return); + witness_commitments.main_sel_op_jump = commitment_key->commit(key->main_sel_op_jump); + witness_commitments.main_sel_op_jumpi = commitment_key->commit(key->main_sel_op_jumpi); + witness_commitments.main_sel_op_keccak = commitment_key->commit(key->main_sel_op_keccak); + witness_commitments.main_sel_op_l1_to_l2_msg_exists = commitment_key->commit(key->main_sel_op_l1_to_l2_msg_exists); + witness_commitments.main_sel_op_l2gasleft = commitment_key->commit(key->main_sel_op_l2gasleft); + witness_commitments.main_sel_op_lt = commitment_key->commit(key->main_sel_op_lt); + witness_commitments.main_sel_op_lte = commitment_key->commit(key->main_sel_op_lte); + witness_commitments.main_sel_op_mov = commitment_key->commit(key->main_sel_op_mov); + witness_commitments.main_sel_op_mul = commitment_key->commit(key->main_sel_op_mul); + witness_commitments.main_sel_op_not = commitment_key->commit(key->main_sel_op_not); + witness_commitments.main_sel_op_note_hash_exists = commitment_key->commit(key->main_sel_op_note_hash_exists); + witness_commitments.main_sel_op_nullifier_exists = commitment_key->commit(key->main_sel_op_nullifier_exists); + witness_commitments.main_sel_op_or = commitment_key->commit(key->main_sel_op_or); + witness_commitments.main_sel_op_pedersen = commitment_key->commit(key->main_sel_op_pedersen); + witness_commitments.main_sel_op_poseidon2 = commitment_key->commit(key->main_sel_op_poseidon2); + witness_commitments.main_sel_op_radix_le = commitment_key->commit(key->main_sel_op_radix_le); + witness_commitments.main_sel_op_sender = commitment_key->commit(key->main_sel_op_sender); + witness_commitments.main_sel_op_sha256 = commitment_key->commit(key->main_sel_op_sha256); + witness_commitments.main_sel_op_shl = commitment_key->commit(key->main_sel_op_shl); + witness_commitments.main_sel_op_shr = commitment_key->commit(key->main_sel_op_shr); + witness_commitments.main_sel_op_sload = commitment_key->commit(key->main_sel_op_sload); + witness_commitments.main_sel_op_sstore = commitment_key->commit(key->main_sel_op_sstore); + witness_commitments.main_sel_op_storage_address = commitment_key->commit(key->main_sel_op_storage_address); + witness_commitments.main_sel_op_sub = commitment_key->commit(key->main_sel_op_sub); + witness_commitments.main_sel_op_timestamp = commitment_key->commit(key->main_sel_op_timestamp); + witness_commitments.main_sel_op_transaction_fee = commitment_key->commit(key->main_sel_op_transaction_fee); + witness_commitments.main_sel_op_version = commitment_key->commit(key->main_sel_op_version); + witness_commitments.main_sel_op_xor = commitment_key->commit(key->main_sel_op_xor); + witness_commitments.main_sel_q_kernel_lookup = commitment_key->commit(key->main_sel_q_kernel_lookup); + witness_commitments.main_sel_q_kernel_output_lookup = commitment_key->commit(key->main_sel_q_kernel_output_lookup); + witness_commitments.main_sel_resolve_ind_addr_a = commitment_key->commit(key->main_sel_resolve_ind_addr_a); + witness_commitments.main_sel_resolve_ind_addr_b = commitment_key->commit(key->main_sel_resolve_ind_addr_b); + witness_commitments.main_sel_resolve_ind_addr_c = commitment_key->commit(key->main_sel_resolve_ind_addr_c); + witness_commitments.main_sel_resolve_ind_addr_d = commitment_key->commit(key->main_sel_resolve_ind_addr_d); + witness_commitments.main_sel_rng_16 = commitment_key->commit(key->main_sel_rng_16); + witness_commitments.main_sel_rng_8 = commitment_key->commit(key->main_sel_rng_8); + witness_commitments.main_space_id = commitment_key->commit(key->main_space_id); + witness_commitments.main_tag_err = commitment_key->commit(key->main_tag_err); + witness_commitments.main_w_in_tag = commitment_key->commit(key->main_w_in_tag); + witness_commitments.mem_addr = commitment_key->commit(key->mem_addr); + witness_commitments.mem_clk = commitment_key->commit(key->mem_clk); + witness_commitments.mem_diff_hi = commitment_key->commit(key->mem_diff_hi); + witness_commitments.mem_diff_lo = commitment_key->commit(key->mem_diff_lo); + witness_commitments.mem_diff_mid = commitment_key->commit(key->mem_diff_mid); + witness_commitments.mem_glob_addr = commitment_key->commit(key->mem_glob_addr); + witness_commitments.mem_last = commitment_key->commit(key->mem_last); + witness_commitments.mem_lastAccess = commitment_key->commit(key->mem_lastAccess); + witness_commitments.mem_one_min_inv = commitment_key->commit(key->mem_one_min_inv); + witness_commitments.mem_r_in_tag = commitment_key->commit(key->mem_r_in_tag); + witness_commitments.mem_rw = commitment_key->commit(key->mem_rw); + witness_commitments.mem_sel_mem = commitment_key->commit(key->mem_sel_mem); + witness_commitments.mem_sel_mov_ia_to_ic = commitment_key->commit(key->mem_sel_mov_ia_to_ic); + witness_commitments.mem_sel_mov_ib_to_ic = commitment_key->commit(key->mem_sel_mov_ib_to_ic); + witness_commitments.mem_sel_op_a = commitment_key->commit(key->mem_sel_op_a); + witness_commitments.mem_sel_op_b = commitment_key->commit(key->mem_sel_op_b); + witness_commitments.mem_sel_op_c = commitment_key->commit(key->mem_sel_op_c); + witness_commitments.mem_sel_op_cmov = commitment_key->commit(key->mem_sel_op_cmov); + witness_commitments.mem_sel_op_d = commitment_key->commit(key->mem_sel_op_d); + witness_commitments.mem_sel_resolve_ind_addr_a = commitment_key->commit(key->mem_sel_resolve_ind_addr_a); + witness_commitments.mem_sel_resolve_ind_addr_b = commitment_key->commit(key->mem_sel_resolve_ind_addr_b); + witness_commitments.mem_sel_resolve_ind_addr_c = commitment_key->commit(key->mem_sel_resolve_ind_addr_c); + witness_commitments.mem_sel_resolve_ind_addr_d = commitment_key->commit(key->mem_sel_resolve_ind_addr_d); + witness_commitments.mem_sel_rng_chk = commitment_key->commit(key->mem_sel_rng_chk); + witness_commitments.mem_skip_check_tag = commitment_key->commit(key->mem_skip_check_tag); + witness_commitments.mem_space_id = commitment_key->commit(key->mem_space_id); + witness_commitments.mem_tag = commitment_key->commit(key->mem_tag); + witness_commitments.mem_tag_err = commitment_key->commit(key->mem_tag_err); + witness_commitments.mem_tsp = commitment_key->commit(key->mem_tsp); + witness_commitments.mem_val = commitment_key->commit(key->mem_val); + witness_commitments.mem_w_in_tag = commitment_key->commit(key->mem_w_in_tag); + witness_commitments.pedersen_clk = commitment_key->commit(key->pedersen_clk); + witness_commitments.pedersen_input = commitment_key->commit(key->pedersen_input); + witness_commitments.pedersen_output = commitment_key->commit(key->pedersen_output); + witness_commitments.pedersen_sel_pedersen = commitment_key->commit(key->pedersen_sel_pedersen); + witness_commitments.poseidon2_a_0 = commitment_key->commit(key->poseidon2_a_0); + witness_commitments.poseidon2_a_1 = commitment_key->commit(key->poseidon2_a_1); + witness_commitments.poseidon2_a_2 = commitment_key->commit(key->poseidon2_a_2); + witness_commitments.poseidon2_a_3 = commitment_key->commit(key->poseidon2_a_3); + witness_commitments.poseidon2_b_0 = commitment_key->commit(key->poseidon2_b_0); + witness_commitments.poseidon2_b_1 = commitment_key->commit(key->poseidon2_b_1); + witness_commitments.poseidon2_b_2 = commitment_key->commit(key->poseidon2_b_2); + witness_commitments.poseidon2_b_3 = commitment_key->commit(key->poseidon2_b_3); + witness_commitments.poseidon2_clk = commitment_key->commit(key->poseidon2_clk); + witness_commitments.poseidon2_input = commitment_key->commit(key->poseidon2_input); + witness_commitments.poseidon2_output = commitment_key->commit(key->poseidon2_output); + witness_commitments.poseidon2_sel_poseidon_perm = commitment_key->commit(key->poseidon2_sel_poseidon_perm); + witness_commitments.powers_power_of_2 = commitment_key->commit(key->powers_power_of_2); + witness_commitments.sha256_clk = commitment_key->commit(key->sha256_clk); + witness_commitments.sha256_input = commitment_key->commit(key->sha256_input); + witness_commitments.sha256_output = commitment_key->commit(key->sha256_output); + witness_commitments.sha256_sel_sha256_compression = commitment_key->commit(key->sha256_sel_sha256_compression); + witness_commitments.sha256_state = commitment_key->commit(key->sha256_state); + witness_commitments.lookup_byte_lengths_counts = commitment_key->commit(key->lookup_byte_lengths_counts); + witness_commitments.lookup_byte_operations_counts = commitment_key->commit(key->lookup_byte_operations_counts); + witness_commitments.lookup_opcode_gas_counts = commitment_key->commit(key->lookup_opcode_gas_counts); + witness_commitments.range_check_l2_gas_hi_counts = commitment_key->commit(key->range_check_l2_gas_hi_counts); + witness_commitments.range_check_l2_gas_lo_counts = commitment_key->commit(key->range_check_l2_gas_lo_counts); + witness_commitments.range_check_da_gas_hi_counts = commitment_key->commit(key->range_check_da_gas_hi_counts); + witness_commitments.range_check_da_gas_lo_counts = commitment_key->commit(key->range_check_da_gas_lo_counts); + witness_commitments.kernel_output_lookup_counts = commitment_key->commit(key->kernel_output_lookup_counts); + witness_commitments.lookup_into_kernel_counts = commitment_key->commit(key->lookup_into_kernel_counts); + witness_commitments.incl_main_tag_err_counts = commitment_key->commit(key->incl_main_tag_err_counts); + witness_commitments.incl_mem_tag_err_counts = commitment_key->commit(key->incl_mem_tag_err_counts); + witness_commitments.lookup_mem_rng_chk_lo_counts = commitment_key->commit(key->lookup_mem_rng_chk_lo_counts); + witness_commitments.lookup_mem_rng_chk_mid_counts = commitment_key->commit(key->lookup_mem_rng_chk_mid_counts); + witness_commitments.lookup_mem_rng_chk_hi_counts = commitment_key->commit(key->lookup_mem_rng_chk_hi_counts); + witness_commitments.lookup_pow_2_0_counts = commitment_key->commit(key->lookup_pow_2_0_counts); + witness_commitments.lookup_pow_2_1_counts = commitment_key->commit(key->lookup_pow_2_1_counts); + witness_commitments.lookup_u8_0_counts = commitment_key->commit(key->lookup_u8_0_counts); + witness_commitments.lookup_u8_1_counts = commitment_key->commit(key->lookup_u8_1_counts); + witness_commitments.lookup_u16_0_counts = commitment_key->commit(key->lookup_u16_0_counts); + witness_commitments.lookup_u16_1_counts = commitment_key->commit(key->lookup_u16_1_counts); + witness_commitments.lookup_u16_2_counts = commitment_key->commit(key->lookup_u16_2_counts); + witness_commitments.lookup_u16_3_counts = commitment_key->commit(key->lookup_u16_3_counts); + witness_commitments.lookup_u16_4_counts = commitment_key->commit(key->lookup_u16_4_counts); + witness_commitments.lookup_u16_5_counts = commitment_key->commit(key->lookup_u16_5_counts); + witness_commitments.lookup_u16_6_counts = commitment_key->commit(key->lookup_u16_6_counts); + witness_commitments.lookup_u16_7_counts = commitment_key->commit(key->lookup_u16_7_counts); + witness_commitments.lookup_u16_8_counts = commitment_key->commit(key->lookup_u16_8_counts); + witness_commitments.lookup_u16_9_counts = commitment_key->commit(key->lookup_u16_9_counts); + witness_commitments.lookup_u16_10_counts = commitment_key->commit(key->lookup_u16_10_counts); + witness_commitments.lookup_u16_11_counts = commitment_key->commit(key->lookup_u16_11_counts); + witness_commitments.lookup_u16_12_counts = commitment_key->commit(key->lookup_u16_12_counts); + witness_commitments.lookup_u16_13_counts = commitment_key->commit(key->lookup_u16_13_counts); + witness_commitments.lookup_u16_14_counts = commitment_key->commit(key->lookup_u16_14_counts); + witness_commitments.lookup_div_u16_0_counts = commitment_key->commit(key->lookup_div_u16_0_counts); + witness_commitments.lookup_div_u16_1_counts = commitment_key->commit(key->lookup_div_u16_1_counts); + witness_commitments.lookup_div_u16_2_counts = commitment_key->commit(key->lookup_div_u16_2_counts); + witness_commitments.lookup_div_u16_3_counts = commitment_key->commit(key->lookup_div_u16_3_counts); + witness_commitments.lookup_div_u16_4_counts = commitment_key->commit(key->lookup_div_u16_4_counts); + witness_commitments.lookup_div_u16_5_counts = commitment_key->commit(key->lookup_div_u16_5_counts); + witness_commitments.lookup_div_u16_6_counts = commitment_key->commit(key->lookup_div_u16_6_counts); + witness_commitments.lookup_div_u16_7_counts = commitment_key->commit(key->lookup_div_u16_7_counts); + + // Send all commitments to the verifier + transcript->send_to_verifier(commitment_labels.kernel_kernel_inputs, witness_commitments.kernel_kernel_inputs); + transcript->send_to_verifier(commitment_labels.kernel_kernel_value_out, + witness_commitments.kernel_kernel_value_out); + transcript->send_to_verifier(commitment_labels.kernel_kernel_side_effect_out, + witness_commitments.kernel_kernel_side_effect_out); + transcript->send_to_verifier(commitment_labels.kernel_kernel_metadata_out, + witness_commitments.kernel_kernel_metadata_out); + transcript->send_to_verifier(commitment_labels.main_calldata, witness_commitments.main_calldata); + transcript->send_to_verifier(commitment_labels.alu_a_hi, witness_commitments.alu_a_hi); + transcript->send_to_verifier(commitment_labels.alu_a_lo, witness_commitments.alu_a_lo); + transcript->send_to_verifier(commitment_labels.alu_b_hi, witness_commitments.alu_b_hi); + transcript->send_to_verifier(commitment_labels.alu_b_lo, witness_commitments.alu_b_lo); + transcript->send_to_verifier(commitment_labels.alu_borrow, witness_commitments.alu_borrow); + transcript->send_to_verifier(commitment_labels.alu_cf, witness_commitments.alu_cf); + transcript->send_to_verifier(commitment_labels.alu_clk, witness_commitments.alu_clk); + transcript->send_to_verifier(commitment_labels.alu_cmp_rng_ctr, witness_commitments.alu_cmp_rng_ctr); + transcript->send_to_verifier(commitment_labels.alu_div_u16_r0, witness_commitments.alu_div_u16_r0); + transcript->send_to_verifier(commitment_labels.alu_div_u16_r1, witness_commitments.alu_div_u16_r1); + transcript->send_to_verifier(commitment_labels.alu_div_u16_r2, witness_commitments.alu_div_u16_r2); + transcript->send_to_verifier(commitment_labels.alu_div_u16_r3, witness_commitments.alu_div_u16_r3); + transcript->send_to_verifier(commitment_labels.alu_div_u16_r4, witness_commitments.alu_div_u16_r4); + transcript->send_to_verifier(commitment_labels.alu_div_u16_r5, witness_commitments.alu_div_u16_r5); + transcript->send_to_verifier(commitment_labels.alu_div_u16_r6, witness_commitments.alu_div_u16_r6); + transcript->send_to_verifier(commitment_labels.alu_div_u16_r7, witness_commitments.alu_div_u16_r7); + transcript->send_to_verifier(commitment_labels.alu_divisor_hi, witness_commitments.alu_divisor_hi); + transcript->send_to_verifier(commitment_labels.alu_divisor_lo, witness_commitments.alu_divisor_lo); + transcript->send_to_verifier(commitment_labels.alu_ff_tag, witness_commitments.alu_ff_tag); + transcript->send_to_verifier(commitment_labels.alu_ia, witness_commitments.alu_ia); + transcript->send_to_verifier(commitment_labels.alu_ib, witness_commitments.alu_ib); + transcript->send_to_verifier(commitment_labels.alu_ic, witness_commitments.alu_ic); + transcript->send_to_verifier(commitment_labels.alu_in_tag, witness_commitments.alu_in_tag); + transcript->send_to_verifier(commitment_labels.alu_op_add, witness_commitments.alu_op_add); + transcript->send_to_verifier(commitment_labels.alu_op_cast, witness_commitments.alu_op_cast); + transcript->send_to_verifier(commitment_labels.alu_op_cast_prev, witness_commitments.alu_op_cast_prev); + transcript->send_to_verifier(commitment_labels.alu_op_div, witness_commitments.alu_op_div); + transcript->send_to_verifier(commitment_labels.alu_op_div_a_lt_b, witness_commitments.alu_op_div_a_lt_b); + transcript->send_to_verifier(commitment_labels.alu_op_div_std, witness_commitments.alu_op_div_std); + transcript->send_to_verifier(commitment_labels.alu_op_eq, witness_commitments.alu_op_eq); + transcript->send_to_verifier(commitment_labels.alu_op_eq_diff_inv, witness_commitments.alu_op_eq_diff_inv); + transcript->send_to_verifier(commitment_labels.alu_op_lt, witness_commitments.alu_op_lt); + transcript->send_to_verifier(commitment_labels.alu_op_lte, witness_commitments.alu_op_lte); + transcript->send_to_verifier(commitment_labels.alu_op_mul, witness_commitments.alu_op_mul); + transcript->send_to_verifier(commitment_labels.alu_op_not, witness_commitments.alu_op_not); + transcript->send_to_verifier(commitment_labels.alu_op_shl, witness_commitments.alu_op_shl); + transcript->send_to_verifier(commitment_labels.alu_op_shr, witness_commitments.alu_op_shr); + transcript->send_to_verifier(commitment_labels.alu_op_sub, witness_commitments.alu_op_sub); + transcript->send_to_verifier(commitment_labels.alu_p_a_borrow, witness_commitments.alu_p_a_borrow); + transcript->send_to_verifier(commitment_labels.alu_p_b_borrow, witness_commitments.alu_p_b_borrow); + transcript->send_to_verifier(commitment_labels.alu_p_sub_a_hi, witness_commitments.alu_p_sub_a_hi); + transcript->send_to_verifier(commitment_labels.alu_p_sub_a_lo, witness_commitments.alu_p_sub_a_lo); + transcript->send_to_verifier(commitment_labels.alu_p_sub_b_hi, witness_commitments.alu_p_sub_b_hi); + transcript->send_to_verifier(commitment_labels.alu_p_sub_b_lo, witness_commitments.alu_p_sub_b_lo); + transcript->send_to_verifier(commitment_labels.alu_partial_prod_hi, witness_commitments.alu_partial_prod_hi); + transcript->send_to_verifier(commitment_labels.alu_partial_prod_lo, witness_commitments.alu_partial_prod_lo); + transcript->send_to_verifier(commitment_labels.alu_quotient_hi, witness_commitments.alu_quotient_hi); + transcript->send_to_verifier(commitment_labels.alu_quotient_lo, witness_commitments.alu_quotient_lo); + transcript->send_to_verifier(commitment_labels.alu_remainder, witness_commitments.alu_remainder); + transcript->send_to_verifier(commitment_labels.alu_res_hi, witness_commitments.alu_res_hi); + transcript->send_to_verifier(commitment_labels.alu_res_lo, witness_commitments.alu_res_lo); + transcript->send_to_verifier(commitment_labels.alu_sel_alu, witness_commitments.alu_sel_alu); + transcript->send_to_verifier(commitment_labels.alu_sel_cmp, witness_commitments.alu_sel_cmp); + transcript->send_to_verifier(commitment_labels.alu_sel_div_rng_chk, witness_commitments.alu_sel_div_rng_chk); + transcript->send_to_verifier(commitment_labels.alu_sel_rng_chk, witness_commitments.alu_sel_rng_chk); + transcript->send_to_verifier(commitment_labels.alu_sel_rng_chk_lookup, witness_commitments.alu_sel_rng_chk_lookup); + transcript->send_to_verifier(commitment_labels.alu_sel_shift_which, witness_commitments.alu_sel_shift_which); + transcript->send_to_verifier(commitment_labels.alu_shift_lt_bit_len, witness_commitments.alu_shift_lt_bit_len); + transcript->send_to_verifier(commitment_labels.alu_t_sub_s_bits, witness_commitments.alu_t_sub_s_bits); + transcript->send_to_verifier(commitment_labels.alu_two_pow_s, witness_commitments.alu_two_pow_s); + transcript->send_to_verifier(commitment_labels.alu_two_pow_t_sub_s, witness_commitments.alu_two_pow_t_sub_s); + transcript->send_to_verifier(commitment_labels.alu_u128_tag, witness_commitments.alu_u128_tag); + transcript->send_to_verifier(commitment_labels.alu_u16_r0, witness_commitments.alu_u16_r0); + transcript->send_to_verifier(commitment_labels.alu_u16_r1, witness_commitments.alu_u16_r1); + transcript->send_to_verifier(commitment_labels.alu_u16_r10, witness_commitments.alu_u16_r10); + transcript->send_to_verifier(commitment_labels.alu_u16_r11, witness_commitments.alu_u16_r11); + transcript->send_to_verifier(commitment_labels.alu_u16_r12, witness_commitments.alu_u16_r12); + transcript->send_to_verifier(commitment_labels.alu_u16_r13, witness_commitments.alu_u16_r13); + transcript->send_to_verifier(commitment_labels.alu_u16_r14, witness_commitments.alu_u16_r14); + transcript->send_to_verifier(commitment_labels.alu_u16_r2, witness_commitments.alu_u16_r2); + transcript->send_to_verifier(commitment_labels.alu_u16_r3, witness_commitments.alu_u16_r3); + transcript->send_to_verifier(commitment_labels.alu_u16_r4, witness_commitments.alu_u16_r4); + transcript->send_to_verifier(commitment_labels.alu_u16_r5, witness_commitments.alu_u16_r5); + transcript->send_to_verifier(commitment_labels.alu_u16_r6, witness_commitments.alu_u16_r6); + transcript->send_to_verifier(commitment_labels.alu_u16_r7, witness_commitments.alu_u16_r7); + transcript->send_to_verifier(commitment_labels.alu_u16_r8, witness_commitments.alu_u16_r8); + transcript->send_to_verifier(commitment_labels.alu_u16_r9, witness_commitments.alu_u16_r9); + transcript->send_to_verifier(commitment_labels.alu_u16_tag, witness_commitments.alu_u16_tag); + transcript->send_to_verifier(commitment_labels.alu_u32_tag, witness_commitments.alu_u32_tag); + transcript->send_to_verifier(commitment_labels.alu_u64_tag, witness_commitments.alu_u64_tag); + transcript->send_to_verifier(commitment_labels.alu_u8_r0, witness_commitments.alu_u8_r0); + transcript->send_to_verifier(commitment_labels.alu_u8_r1, witness_commitments.alu_u8_r1); + transcript->send_to_verifier(commitment_labels.alu_u8_tag, witness_commitments.alu_u8_tag); + transcript->send_to_verifier(commitment_labels.binary_acc_ia, witness_commitments.binary_acc_ia); + transcript->send_to_verifier(commitment_labels.binary_acc_ib, witness_commitments.binary_acc_ib); + transcript->send_to_verifier(commitment_labels.binary_acc_ic, witness_commitments.binary_acc_ic); + transcript->send_to_verifier(commitment_labels.binary_clk, witness_commitments.binary_clk); + transcript->send_to_verifier(commitment_labels.binary_ia_bytes, witness_commitments.binary_ia_bytes); + transcript->send_to_verifier(commitment_labels.binary_ib_bytes, witness_commitments.binary_ib_bytes); + transcript->send_to_verifier(commitment_labels.binary_ic_bytes, witness_commitments.binary_ic_bytes); + transcript->send_to_verifier(commitment_labels.binary_in_tag, witness_commitments.binary_in_tag); + transcript->send_to_verifier(commitment_labels.binary_mem_tag_ctr, witness_commitments.binary_mem_tag_ctr); + transcript->send_to_verifier(commitment_labels.binary_mem_tag_ctr_inv, witness_commitments.binary_mem_tag_ctr_inv); + transcript->send_to_verifier(commitment_labels.binary_op_id, witness_commitments.binary_op_id); + transcript->send_to_verifier(commitment_labels.binary_sel_bin, witness_commitments.binary_sel_bin); + transcript->send_to_verifier(commitment_labels.binary_start, witness_commitments.binary_start); + transcript->send_to_verifier(commitment_labels.byte_lookup_sel_bin, witness_commitments.byte_lookup_sel_bin); + transcript->send_to_verifier(commitment_labels.byte_lookup_table_byte_lengths, + witness_commitments.byte_lookup_table_byte_lengths); + transcript->send_to_verifier(commitment_labels.byte_lookup_table_in_tags, + witness_commitments.byte_lookup_table_in_tags); + transcript->send_to_verifier(commitment_labels.byte_lookup_table_input_a, + witness_commitments.byte_lookup_table_input_a); + transcript->send_to_verifier(commitment_labels.byte_lookup_table_input_b, + witness_commitments.byte_lookup_table_input_b); + transcript->send_to_verifier(commitment_labels.byte_lookup_table_op_id, + witness_commitments.byte_lookup_table_op_id); + transcript->send_to_verifier(commitment_labels.byte_lookup_table_output, + witness_commitments.byte_lookup_table_output); + transcript->send_to_verifier(commitment_labels.conversion_clk, witness_commitments.conversion_clk); + transcript->send_to_verifier(commitment_labels.conversion_input, witness_commitments.conversion_input); + transcript->send_to_verifier(commitment_labels.conversion_num_limbs, witness_commitments.conversion_num_limbs); + transcript->send_to_verifier(commitment_labels.conversion_radix, witness_commitments.conversion_radix); + transcript->send_to_verifier(commitment_labels.conversion_sel_to_radix_le, + witness_commitments.conversion_sel_to_radix_le); + transcript->send_to_verifier(commitment_labels.gas_da_gas_fixed_table, witness_commitments.gas_da_gas_fixed_table); + transcript->send_to_verifier(commitment_labels.gas_l2_gas_fixed_table, witness_commitments.gas_l2_gas_fixed_table); + transcript->send_to_verifier(commitment_labels.gas_sel_gas_cost, witness_commitments.gas_sel_gas_cost); + transcript->send_to_verifier(commitment_labels.keccakf1600_clk, witness_commitments.keccakf1600_clk); + transcript->send_to_verifier(commitment_labels.keccakf1600_input, witness_commitments.keccakf1600_input); + transcript->send_to_verifier(commitment_labels.keccakf1600_output, witness_commitments.keccakf1600_output); + transcript->send_to_verifier(commitment_labels.keccakf1600_sel_keccakf1600, + witness_commitments.keccakf1600_sel_keccakf1600); + transcript->send_to_verifier(commitment_labels.kernel_emit_l2_to_l1_msg_write_offset, + witness_commitments.kernel_emit_l2_to_l1_msg_write_offset); + transcript->send_to_verifier(commitment_labels.kernel_emit_note_hash_write_offset, + witness_commitments.kernel_emit_note_hash_write_offset); + transcript->send_to_verifier(commitment_labels.kernel_emit_nullifier_write_offset, + witness_commitments.kernel_emit_nullifier_write_offset); + transcript->send_to_verifier(commitment_labels.kernel_emit_unencrypted_log_write_offset, + witness_commitments.kernel_emit_unencrypted_log_write_offset); + transcript->send_to_verifier(commitment_labels.kernel_kernel_in_offset, + witness_commitments.kernel_kernel_in_offset); + transcript->send_to_verifier(commitment_labels.kernel_kernel_out_offset, + witness_commitments.kernel_kernel_out_offset); + transcript->send_to_verifier(commitment_labels.kernel_l1_to_l2_msg_exists_write_offset, + witness_commitments.kernel_l1_to_l2_msg_exists_write_offset); + transcript->send_to_verifier(commitment_labels.kernel_note_hash_exist_write_offset, + witness_commitments.kernel_note_hash_exist_write_offset); + transcript->send_to_verifier(commitment_labels.kernel_nullifier_exists_write_offset, + witness_commitments.kernel_nullifier_exists_write_offset); + transcript->send_to_verifier(commitment_labels.kernel_nullifier_non_exists_write_offset, + witness_commitments.kernel_nullifier_non_exists_write_offset); + transcript->send_to_verifier(commitment_labels.kernel_q_public_input_kernel_add_to_table, + witness_commitments.kernel_q_public_input_kernel_add_to_table); + transcript->send_to_verifier(commitment_labels.kernel_q_public_input_kernel_out_add_to_table, + witness_commitments.kernel_q_public_input_kernel_out_add_to_table); + transcript->send_to_verifier(commitment_labels.kernel_side_effect_counter, + witness_commitments.kernel_side_effect_counter); + transcript->send_to_verifier(commitment_labels.kernel_sload_write_offset, + witness_commitments.kernel_sload_write_offset); + transcript->send_to_verifier(commitment_labels.kernel_sstore_write_offset, + witness_commitments.kernel_sstore_write_offset); + transcript->send_to_verifier(commitment_labels.main_abs_da_rem_gas_hi, witness_commitments.main_abs_da_rem_gas_hi); + transcript->send_to_verifier(commitment_labels.main_abs_da_rem_gas_lo, witness_commitments.main_abs_da_rem_gas_lo); + transcript->send_to_verifier(commitment_labels.main_abs_l2_rem_gas_hi, witness_commitments.main_abs_l2_rem_gas_hi); + transcript->send_to_verifier(commitment_labels.main_abs_l2_rem_gas_lo, witness_commitments.main_abs_l2_rem_gas_lo); + transcript->send_to_verifier(commitment_labels.main_alu_in_tag, witness_commitments.main_alu_in_tag); + transcript->send_to_verifier(commitment_labels.main_bin_op_id, witness_commitments.main_bin_op_id); + transcript->send_to_verifier(commitment_labels.main_call_ptr, witness_commitments.main_call_ptr); + transcript->send_to_verifier(commitment_labels.main_da_gas_op_cost, witness_commitments.main_da_gas_op_cost); + transcript->send_to_verifier(commitment_labels.main_da_gas_remaining, witness_commitments.main_da_gas_remaining); + transcript->send_to_verifier(commitment_labels.main_da_out_of_gas, witness_commitments.main_da_out_of_gas); + transcript->send_to_verifier(commitment_labels.main_ia, witness_commitments.main_ia); + transcript->send_to_verifier(commitment_labels.main_ib, witness_commitments.main_ib); + transcript->send_to_verifier(commitment_labels.main_ic, witness_commitments.main_ic); + transcript->send_to_verifier(commitment_labels.main_id, witness_commitments.main_id); + transcript->send_to_verifier(commitment_labels.main_id_zero, witness_commitments.main_id_zero); + transcript->send_to_verifier(commitment_labels.main_ind_addr_a, witness_commitments.main_ind_addr_a); + transcript->send_to_verifier(commitment_labels.main_ind_addr_b, witness_commitments.main_ind_addr_b); + transcript->send_to_verifier(commitment_labels.main_ind_addr_c, witness_commitments.main_ind_addr_c); + transcript->send_to_verifier(commitment_labels.main_ind_addr_d, witness_commitments.main_ind_addr_d); + transcript->send_to_verifier(commitment_labels.main_internal_return_ptr, + witness_commitments.main_internal_return_ptr); + transcript->send_to_verifier(commitment_labels.main_inv, witness_commitments.main_inv); + transcript->send_to_verifier(commitment_labels.main_l2_gas_op_cost, witness_commitments.main_l2_gas_op_cost); + transcript->send_to_verifier(commitment_labels.main_l2_gas_remaining, witness_commitments.main_l2_gas_remaining); + transcript->send_to_verifier(commitment_labels.main_l2_out_of_gas, witness_commitments.main_l2_out_of_gas); + transcript->send_to_verifier(commitment_labels.main_mem_addr_a, witness_commitments.main_mem_addr_a); + transcript->send_to_verifier(commitment_labels.main_mem_addr_b, witness_commitments.main_mem_addr_b); + transcript->send_to_verifier(commitment_labels.main_mem_addr_c, witness_commitments.main_mem_addr_c); + transcript->send_to_verifier(commitment_labels.main_mem_addr_d, witness_commitments.main_mem_addr_d); + transcript->send_to_verifier(commitment_labels.main_op_err, witness_commitments.main_op_err); + transcript->send_to_verifier(commitment_labels.main_opcode_val, witness_commitments.main_opcode_val); + transcript->send_to_verifier(commitment_labels.main_pc, witness_commitments.main_pc); + transcript->send_to_verifier(commitment_labels.main_r_in_tag, witness_commitments.main_r_in_tag); + transcript->send_to_verifier(commitment_labels.main_rwa, witness_commitments.main_rwa); + transcript->send_to_verifier(commitment_labels.main_rwb, witness_commitments.main_rwb); + transcript->send_to_verifier(commitment_labels.main_rwc, witness_commitments.main_rwc); + transcript->send_to_verifier(commitment_labels.main_rwd, witness_commitments.main_rwd); + transcript->send_to_verifier(commitment_labels.main_sel_alu, witness_commitments.main_sel_alu); + transcript->send_to_verifier(commitment_labels.main_sel_bin, witness_commitments.main_sel_bin); + transcript->send_to_verifier(commitment_labels.main_sel_gas_accounting_active, + witness_commitments.main_sel_gas_accounting_active); + transcript->send_to_verifier(commitment_labels.main_sel_last, witness_commitments.main_sel_last); + transcript->send_to_verifier(commitment_labels.main_sel_mem_op_a, witness_commitments.main_sel_mem_op_a); + transcript->send_to_verifier(commitment_labels.main_sel_mem_op_activate_gas, + witness_commitments.main_sel_mem_op_activate_gas); + transcript->send_to_verifier(commitment_labels.main_sel_mem_op_b, witness_commitments.main_sel_mem_op_b); + transcript->send_to_verifier(commitment_labels.main_sel_mem_op_c, witness_commitments.main_sel_mem_op_c); + transcript->send_to_verifier(commitment_labels.main_sel_mem_op_d, witness_commitments.main_sel_mem_op_d); + transcript->send_to_verifier(commitment_labels.main_sel_mov_ia_to_ic, witness_commitments.main_sel_mov_ia_to_ic); + transcript->send_to_verifier(commitment_labels.main_sel_mov_ib_to_ic, witness_commitments.main_sel_mov_ib_to_ic); + transcript->send_to_verifier(commitment_labels.main_sel_op_add, witness_commitments.main_sel_op_add); + transcript->send_to_verifier(commitment_labels.main_sel_op_address, witness_commitments.main_sel_op_address); + transcript->send_to_verifier(commitment_labels.main_sel_op_and, witness_commitments.main_sel_op_and); + transcript->send_to_verifier(commitment_labels.main_sel_op_block_number, + witness_commitments.main_sel_op_block_number); + transcript->send_to_verifier(commitment_labels.main_sel_op_cast, witness_commitments.main_sel_op_cast); + transcript->send_to_verifier(commitment_labels.main_sel_op_chain_id, witness_commitments.main_sel_op_chain_id); + transcript->send_to_verifier(commitment_labels.main_sel_op_cmov, witness_commitments.main_sel_op_cmov); + transcript->send_to_verifier(commitment_labels.main_sel_op_coinbase, witness_commitments.main_sel_op_coinbase); + transcript->send_to_verifier(commitment_labels.main_sel_op_dagasleft, witness_commitments.main_sel_op_dagasleft); + transcript->send_to_verifier(commitment_labels.main_sel_op_div, witness_commitments.main_sel_op_div); + transcript->send_to_verifier(commitment_labels.main_sel_op_emit_l2_to_l1_msg, + witness_commitments.main_sel_op_emit_l2_to_l1_msg); + transcript->send_to_verifier(commitment_labels.main_sel_op_emit_note_hash, + witness_commitments.main_sel_op_emit_note_hash); + transcript->send_to_verifier(commitment_labels.main_sel_op_emit_nullifier, + witness_commitments.main_sel_op_emit_nullifier); + transcript->send_to_verifier(commitment_labels.main_sel_op_emit_unencrypted_log, + witness_commitments.main_sel_op_emit_unencrypted_log); + transcript->send_to_verifier(commitment_labels.main_sel_op_eq, witness_commitments.main_sel_op_eq); + transcript->send_to_verifier(commitment_labels.main_sel_op_external_call, + witness_commitments.main_sel_op_external_call); + transcript->send_to_verifier(commitment_labels.main_sel_op_fdiv, witness_commitments.main_sel_op_fdiv); + transcript->send_to_verifier(commitment_labels.main_sel_op_fee_per_da_gas, + witness_commitments.main_sel_op_fee_per_da_gas); + transcript->send_to_verifier(commitment_labels.main_sel_op_fee_per_l2_gas, + witness_commitments.main_sel_op_fee_per_l2_gas); + transcript->send_to_verifier(commitment_labels.main_sel_op_function_selector, + witness_commitments.main_sel_op_function_selector); + transcript->send_to_verifier(commitment_labels.main_sel_op_get_contract_instance, + witness_commitments.main_sel_op_get_contract_instance); + transcript->send_to_verifier(commitment_labels.main_sel_op_halt, witness_commitments.main_sel_op_halt); + transcript->send_to_verifier(commitment_labels.main_sel_op_internal_call, + witness_commitments.main_sel_op_internal_call); + transcript->send_to_verifier(commitment_labels.main_sel_op_internal_return, + witness_commitments.main_sel_op_internal_return); + transcript->send_to_verifier(commitment_labels.main_sel_op_jump, witness_commitments.main_sel_op_jump); + transcript->send_to_verifier(commitment_labels.main_sel_op_jumpi, witness_commitments.main_sel_op_jumpi); + transcript->send_to_verifier(commitment_labels.main_sel_op_keccak, witness_commitments.main_sel_op_keccak); + transcript->send_to_verifier(commitment_labels.main_sel_op_l1_to_l2_msg_exists, + witness_commitments.main_sel_op_l1_to_l2_msg_exists); + transcript->send_to_verifier(commitment_labels.main_sel_op_l2gasleft, witness_commitments.main_sel_op_l2gasleft); + transcript->send_to_verifier(commitment_labels.main_sel_op_lt, witness_commitments.main_sel_op_lt); + transcript->send_to_verifier(commitment_labels.main_sel_op_lte, witness_commitments.main_sel_op_lte); + transcript->send_to_verifier(commitment_labels.main_sel_op_mov, witness_commitments.main_sel_op_mov); + transcript->send_to_verifier(commitment_labels.main_sel_op_mul, witness_commitments.main_sel_op_mul); + transcript->send_to_verifier(commitment_labels.main_sel_op_not, witness_commitments.main_sel_op_not); + transcript->send_to_verifier(commitment_labels.main_sel_op_note_hash_exists, + witness_commitments.main_sel_op_note_hash_exists); + transcript->send_to_verifier(commitment_labels.main_sel_op_nullifier_exists, + witness_commitments.main_sel_op_nullifier_exists); + transcript->send_to_verifier(commitment_labels.main_sel_op_or, witness_commitments.main_sel_op_or); + transcript->send_to_verifier(commitment_labels.main_sel_op_pedersen, witness_commitments.main_sel_op_pedersen); + transcript->send_to_verifier(commitment_labels.main_sel_op_poseidon2, witness_commitments.main_sel_op_poseidon2); + transcript->send_to_verifier(commitment_labels.main_sel_op_radix_le, witness_commitments.main_sel_op_radix_le); + transcript->send_to_verifier(commitment_labels.main_sel_op_sender, witness_commitments.main_sel_op_sender); + transcript->send_to_verifier(commitment_labels.main_sel_op_sha256, witness_commitments.main_sel_op_sha256); + transcript->send_to_verifier(commitment_labels.main_sel_op_shl, witness_commitments.main_sel_op_shl); + transcript->send_to_verifier(commitment_labels.main_sel_op_shr, witness_commitments.main_sel_op_shr); + transcript->send_to_verifier(commitment_labels.main_sel_op_sload, witness_commitments.main_sel_op_sload); + transcript->send_to_verifier(commitment_labels.main_sel_op_sstore, witness_commitments.main_sel_op_sstore); + transcript->send_to_verifier(commitment_labels.main_sel_op_storage_address, + witness_commitments.main_sel_op_storage_address); + transcript->send_to_verifier(commitment_labels.main_sel_op_sub, witness_commitments.main_sel_op_sub); + transcript->send_to_verifier(commitment_labels.main_sel_op_timestamp, witness_commitments.main_sel_op_timestamp); + transcript->send_to_verifier(commitment_labels.main_sel_op_transaction_fee, + witness_commitments.main_sel_op_transaction_fee); + transcript->send_to_verifier(commitment_labels.main_sel_op_version, witness_commitments.main_sel_op_version); + transcript->send_to_verifier(commitment_labels.main_sel_op_xor, witness_commitments.main_sel_op_xor); + transcript->send_to_verifier(commitment_labels.main_sel_q_kernel_lookup, + witness_commitments.main_sel_q_kernel_lookup); + transcript->send_to_verifier(commitment_labels.main_sel_q_kernel_output_lookup, + witness_commitments.main_sel_q_kernel_output_lookup); + transcript->send_to_verifier(commitment_labels.main_sel_resolve_ind_addr_a, + witness_commitments.main_sel_resolve_ind_addr_a); + transcript->send_to_verifier(commitment_labels.main_sel_resolve_ind_addr_b, + witness_commitments.main_sel_resolve_ind_addr_b); + transcript->send_to_verifier(commitment_labels.main_sel_resolve_ind_addr_c, + witness_commitments.main_sel_resolve_ind_addr_c); + transcript->send_to_verifier(commitment_labels.main_sel_resolve_ind_addr_d, + witness_commitments.main_sel_resolve_ind_addr_d); + transcript->send_to_verifier(commitment_labels.main_sel_rng_16, witness_commitments.main_sel_rng_16); + transcript->send_to_verifier(commitment_labels.main_sel_rng_8, witness_commitments.main_sel_rng_8); + transcript->send_to_verifier(commitment_labels.main_space_id, witness_commitments.main_space_id); + transcript->send_to_verifier(commitment_labels.main_tag_err, witness_commitments.main_tag_err); + transcript->send_to_verifier(commitment_labels.main_w_in_tag, witness_commitments.main_w_in_tag); + transcript->send_to_verifier(commitment_labels.mem_addr, witness_commitments.mem_addr); + transcript->send_to_verifier(commitment_labels.mem_clk, witness_commitments.mem_clk); + transcript->send_to_verifier(commitment_labels.mem_diff_hi, witness_commitments.mem_diff_hi); + transcript->send_to_verifier(commitment_labels.mem_diff_lo, witness_commitments.mem_diff_lo); + transcript->send_to_verifier(commitment_labels.mem_diff_mid, witness_commitments.mem_diff_mid); + transcript->send_to_verifier(commitment_labels.mem_glob_addr, witness_commitments.mem_glob_addr); + transcript->send_to_verifier(commitment_labels.mem_last, witness_commitments.mem_last); + transcript->send_to_verifier(commitment_labels.mem_lastAccess, witness_commitments.mem_lastAccess); + transcript->send_to_verifier(commitment_labels.mem_one_min_inv, witness_commitments.mem_one_min_inv); + transcript->send_to_verifier(commitment_labels.mem_r_in_tag, witness_commitments.mem_r_in_tag); + transcript->send_to_verifier(commitment_labels.mem_rw, witness_commitments.mem_rw); + transcript->send_to_verifier(commitment_labels.mem_sel_mem, witness_commitments.mem_sel_mem); + transcript->send_to_verifier(commitment_labels.mem_sel_mov_ia_to_ic, witness_commitments.mem_sel_mov_ia_to_ic); + transcript->send_to_verifier(commitment_labels.mem_sel_mov_ib_to_ic, witness_commitments.mem_sel_mov_ib_to_ic); + transcript->send_to_verifier(commitment_labels.mem_sel_op_a, witness_commitments.mem_sel_op_a); + transcript->send_to_verifier(commitment_labels.mem_sel_op_b, witness_commitments.mem_sel_op_b); + transcript->send_to_verifier(commitment_labels.mem_sel_op_c, witness_commitments.mem_sel_op_c); + transcript->send_to_verifier(commitment_labels.mem_sel_op_cmov, witness_commitments.mem_sel_op_cmov); + transcript->send_to_verifier(commitment_labels.mem_sel_op_d, witness_commitments.mem_sel_op_d); + transcript->send_to_verifier(commitment_labels.mem_sel_resolve_ind_addr_a, + witness_commitments.mem_sel_resolve_ind_addr_a); + transcript->send_to_verifier(commitment_labels.mem_sel_resolve_ind_addr_b, + witness_commitments.mem_sel_resolve_ind_addr_b); + transcript->send_to_verifier(commitment_labels.mem_sel_resolve_ind_addr_c, + witness_commitments.mem_sel_resolve_ind_addr_c); + transcript->send_to_verifier(commitment_labels.mem_sel_resolve_ind_addr_d, + witness_commitments.mem_sel_resolve_ind_addr_d); + transcript->send_to_verifier(commitment_labels.mem_sel_rng_chk, witness_commitments.mem_sel_rng_chk); + transcript->send_to_verifier(commitment_labels.mem_skip_check_tag, witness_commitments.mem_skip_check_tag); + transcript->send_to_verifier(commitment_labels.mem_space_id, witness_commitments.mem_space_id); + transcript->send_to_verifier(commitment_labels.mem_tag, witness_commitments.mem_tag); + transcript->send_to_verifier(commitment_labels.mem_tag_err, witness_commitments.mem_tag_err); + transcript->send_to_verifier(commitment_labels.mem_tsp, witness_commitments.mem_tsp); + transcript->send_to_verifier(commitment_labels.mem_val, witness_commitments.mem_val); + transcript->send_to_verifier(commitment_labels.mem_w_in_tag, witness_commitments.mem_w_in_tag); + transcript->send_to_verifier(commitment_labels.pedersen_clk, witness_commitments.pedersen_clk); + transcript->send_to_verifier(commitment_labels.pedersen_input, witness_commitments.pedersen_input); + transcript->send_to_verifier(commitment_labels.pedersen_output, witness_commitments.pedersen_output); + transcript->send_to_verifier(commitment_labels.pedersen_sel_pedersen, witness_commitments.pedersen_sel_pedersen); + transcript->send_to_verifier(commitment_labels.poseidon2_a_0, witness_commitments.poseidon2_a_0); + transcript->send_to_verifier(commitment_labels.poseidon2_a_1, witness_commitments.poseidon2_a_1); + transcript->send_to_verifier(commitment_labels.poseidon2_a_2, witness_commitments.poseidon2_a_2); + transcript->send_to_verifier(commitment_labels.poseidon2_a_3, witness_commitments.poseidon2_a_3); + transcript->send_to_verifier(commitment_labels.poseidon2_b_0, witness_commitments.poseidon2_b_0); + transcript->send_to_verifier(commitment_labels.poseidon2_b_1, witness_commitments.poseidon2_b_1); + transcript->send_to_verifier(commitment_labels.poseidon2_b_2, witness_commitments.poseidon2_b_2); + transcript->send_to_verifier(commitment_labels.poseidon2_b_3, witness_commitments.poseidon2_b_3); + transcript->send_to_verifier(commitment_labels.poseidon2_clk, witness_commitments.poseidon2_clk); + transcript->send_to_verifier(commitment_labels.poseidon2_input, witness_commitments.poseidon2_input); + transcript->send_to_verifier(commitment_labels.poseidon2_output, witness_commitments.poseidon2_output); + transcript->send_to_verifier(commitment_labels.poseidon2_sel_poseidon_perm, + witness_commitments.poseidon2_sel_poseidon_perm); + transcript->send_to_verifier(commitment_labels.powers_power_of_2, witness_commitments.powers_power_of_2); + transcript->send_to_verifier(commitment_labels.sha256_clk, witness_commitments.sha256_clk); + transcript->send_to_verifier(commitment_labels.sha256_input, witness_commitments.sha256_input); + transcript->send_to_verifier(commitment_labels.sha256_output, witness_commitments.sha256_output); + transcript->send_to_verifier(commitment_labels.sha256_sel_sha256_compression, + witness_commitments.sha256_sel_sha256_compression); + transcript->send_to_verifier(commitment_labels.sha256_state, witness_commitments.sha256_state); + transcript->send_to_verifier(commitment_labels.lookup_byte_lengths_counts, + witness_commitments.lookup_byte_lengths_counts); + transcript->send_to_verifier(commitment_labels.lookup_byte_operations_counts, + witness_commitments.lookup_byte_operations_counts); + transcript->send_to_verifier(commitment_labels.lookup_opcode_gas_counts, + witness_commitments.lookup_opcode_gas_counts); + transcript->send_to_verifier(commitment_labels.range_check_l2_gas_hi_counts, + witness_commitments.range_check_l2_gas_hi_counts); + transcript->send_to_verifier(commitment_labels.range_check_l2_gas_lo_counts, + witness_commitments.range_check_l2_gas_lo_counts); + transcript->send_to_verifier(commitment_labels.range_check_da_gas_hi_counts, + witness_commitments.range_check_da_gas_hi_counts); + transcript->send_to_verifier(commitment_labels.range_check_da_gas_lo_counts, + witness_commitments.range_check_da_gas_lo_counts); + transcript->send_to_verifier(commitment_labels.kernel_output_lookup_counts, + witness_commitments.kernel_output_lookup_counts); + transcript->send_to_verifier(commitment_labels.lookup_into_kernel_counts, + witness_commitments.lookup_into_kernel_counts); + transcript->send_to_verifier(commitment_labels.incl_main_tag_err_counts, + witness_commitments.incl_main_tag_err_counts); + transcript->send_to_verifier(commitment_labels.incl_mem_tag_err_counts, + witness_commitments.incl_mem_tag_err_counts); + transcript->send_to_verifier(commitment_labels.lookup_mem_rng_chk_lo_counts, + witness_commitments.lookup_mem_rng_chk_lo_counts); + transcript->send_to_verifier(commitment_labels.lookup_mem_rng_chk_mid_counts, + witness_commitments.lookup_mem_rng_chk_mid_counts); + transcript->send_to_verifier(commitment_labels.lookup_mem_rng_chk_hi_counts, + witness_commitments.lookup_mem_rng_chk_hi_counts); + transcript->send_to_verifier(commitment_labels.lookup_pow_2_0_counts, witness_commitments.lookup_pow_2_0_counts); + transcript->send_to_verifier(commitment_labels.lookup_pow_2_1_counts, witness_commitments.lookup_pow_2_1_counts); + transcript->send_to_verifier(commitment_labels.lookup_u8_0_counts, witness_commitments.lookup_u8_0_counts); + transcript->send_to_verifier(commitment_labels.lookup_u8_1_counts, witness_commitments.lookup_u8_1_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_0_counts, witness_commitments.lookup_u16_0_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_1_counts, witness_commitments.lookup_u16_1_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_2_counts, witness_commitments.lookup_u16_2_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_3_counts, witness_commitments.lookup_u16_3_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_4_counts, witness_commitments.lookup_u16_4_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_5_counts, witness_commitments.lookup_u16_5_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_6_counts, witness_commitments.lookup_u16_6_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_7_counts, witness_commitments.lookup_u16_7_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_8_counts, witness_commitments.lookup_u16_8_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_9_counts, witness_commitments.lookup_u16_9_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_10_counts, witness_commitments.lookup_u16_10_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_11_counts, witness_commitments.lookup_u16_11_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_12_counts, witness_commitments.lookup_u16_12_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_13_counts, witness_commitments.lookup_u16_13_counts); + transcript->send_to_verifier(commitment_labels.lookup_u16_14_counts, witness_commitments.lookup_u16_14_counts); + transcript->send_to_verifier(commitment_labels.lookup_div_u16_0_counts, + witness_commitments.lookup_div_u16_0_counts); + transcript->send_to_verifier(commitment_labels.lookup_div_u16_1_counts, + witness_commitments.lookup_div_u16_1_counts); + transcript->send_to_verifier(commitment_labels.lookup_div_u16_2_counts, + witness_commitments.lookup_div_u16_2_counts); + transcript->send_to_verifier(commitment_labels.lookup_div_u16_3_counts, + witness_commitments.lookup_div_u16_3_counts); + transcript->send_to_verifier(commitment_labels.lookup_div_u16_4_counts, + witness_commitments.lookup_div_u16_4_counts); + transcript->send_to_verifier(commitment_labels.lookup_div_u16_5_counts, + witness_commitments.lookup_div_u16_5_counts); + transcript->send_to_verifier(commitment_labels.lookup_div_u16_6_counts, + witness_commitments.lookup_div_u16_6_counts); + transcript->send_to_verifier(commitment_labels.lookup_div_u16_7_counts, + witness_commitments.lookup_div_u16_7_counts); +>>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) } void AvmProver::execute_log_derivative_inverse_round() diff --git a/barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp b/barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp new file mode 100644 index 000000000000..114cf3bbc711 --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp @@ -0,0 +1,941 @@ +// AUTOGENERATED FILE +#pragma once + +#include +#include + +#include "barretenberg/common/constexpr_utils.hpp" +#include "barretenberg/common/thread.hpp" +#include "barretenberg/common/throw_or_abort.hpp" +#include "barretenberg/ecc/curves/bn254/fr.hpp" +#include "barretenberg/honk/proof_system/logderivative_library.hpp" +#include "barretenberg/relations/generic_lookup/generic_lookup_relation.hpp" +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" +#include "barretenberg/stdlib_circuit_builders/circuit_builder_base.hpp" + +#include "barretenberg/vm/generated/avm_flavor.hpp" +#include "barretenberg/vm/generated/avm_full_row.hpp" + +namespace bb { + +<<<<<<< HEAD +======= +template struct AvmFullRow { + FF main_clk{}; + FF main_sel_first{}; + FF kernel_kernel_inputs{}; + FF kernel_kernel_value_out{}; + FF kernel_kernel_side_effect_out{}; + FF kernel_kernel_metadata_out{}; + FF main_calldata{}; + FF alu_a_hi{}; + FF alu_a_lo{}; + FF alu_b_hi{}; + FF alu_b_lo{}; + FF alu_borrow{}; + FF alu_cf{}; + FF alu_clk{}; + FF alu_cmp_rng_ctr{}; + FF alu_div_u16_r0{}; + FF alu_div_u16_r1{}; + FF alu_div_u16_r2{}; + FF alu_div_u16_r3{}; + FF alu_div_u16_r4{}; + FF alu_div_u16_r5{}; + FF alu_div_u16_r6{}; + FF alu_div_u16_r7{}; + FF alu_divisor_hi{}; + FF alu_divisor_lo{}; + FF alu_ff_tag{}; + FF alu_ia{}; + FF alu_ib{}; + FF alu_ic{}; + FF alu_in_tag{}; + FF alu_op_add{}; + FF alu_op_cast{}; + FF alu_op_cast_prev{}; + FF alu_op_div{}; + FF alu_op_div_a_lt_b{}; + FF alu_op_div_std{}; + FF alu_op_eq{}; + FF alu_op_eq_diff_inv{}; + FF alu_op_lt{}; + FF alu_op_lte{}; + FF alu_op_mul{}; + FF alu_op_not{}; + FF alu_op_shl{}; + FF alu_op_shr{}; + FF alu_op_sub{}; + FF alu_p_a_borrow{}; + FF alu_p_b_borrow{}; + FF alu_p_sub_a_hi{}; + FF alu_p_sub_a_lo{}; + FF alu_p_sub_b_hi{}; + FF alu_p_sub_b_lo{}; + FF alu_partial_prod_hi{}; + FF alu_partial_prod_lo{}; + FF alu_quotient_hi{}; + FF alu_quotient_lo{}; + FF alu_remainder{}; + FF alu_res_hi{}; + FF alu_res_lo{}; + FF alu_sel_alu{}; + FF alu_sel_cmp{}; + FF alu_sel_div_rng_chk{}; + FF alu_sel_rng_chk{}; + FF alu_sel_rng_chk_lookup{}; + FF alu_sel_shift_which{}; + FF alu_shift_lt_bit_len{}; + FF alu_t_sub_s_bits{}; + FF alu_two_pow_s{}; + FF alu_two_pow_t_sub_s{}; + FF alu_u128_tag{}; + FF alu_u16_r0{}; + FF alu_u16_r1{}; + FF alu_u16_r10{}; + FF alu_u16_r11{}; + FF alu_u16_r12{}; + FF alu_u16_r13{}; + FF alu_u16_r14{}; + FF alu_u16_r2{}; + FF alu_u16_r3{}; + FF alu_u16_r4{}; + FF alu_u16_r5{}; + FF alu_u16_r6{}; + FF alu_u16_r7{}; + FF alu_u16_r8{}; + FF alu_u16_r9{}; + FF alu_u16_tag{}; + FF alu_u32_tag{}; + FF alu_u64_tag{}; + FF alu_u8_r0{}; + FF alu_u8_r1{}; + FF alu_u8_tag{}; + FF binary_acc_ia{}; + FF binary_acc_ib{}; + FF binary_acc_ic{}; + FF binary_clk{}; + FF binary_ia_bytes{}; + FF binary_ib_bytes{}; + FF binary_ic_bytes{}; + FF binary_in_tag{}; + FF binary_mem_tag_ctr{}; + FF binary_mem_tag_ctr_inv{}; + FF binary_op_id{}; + FF binary_sel_bin{}; + FF binary_start{}; + FF byte_lookup_sel_bin{}; + FF byte_lookup_table_byte_lengths{}; + FF byte_lookup_table_in_tags{}; + FF byte_lookup_table_input_a{}; + FF byte_lookup_table_input_b{}; + FF byte_lookup_table_op_id{}; + FF byte_lookup_table_output{}; + FF conversion_clk{}; + FF conversion_input{}; + FF conversion_num_limbs{}; + FF conversion_radix{}; + FF conversion_sel_to_radix_le{}; + FF gas_da_gas_fixed_table{}; + FF gas_l2_gas_fixed_table{}; + FF gas_sel_gas_cost{}; + FF keccakf1600_clk{}; + FF keccakf1600_input{}; + FF keccakf1600_output{}; + FF keccakf1600_sel_keccakf1600{}; + FF kernel_emit_l2_to_l1_msg_write_offset{}; + FF kernel_emit_note_hash_write_offset{}; + FF kernel_emit_nullifier_write_offset{}; + FF kernel_emit_unencrypted_log_write_offset{}; + FF kernel_kernel_in_offset{}; + FF kernel_kernel_out_offset{}; + FF kernel_l1_to_l2_msg_exists_write_offset{}; + FF kernel_note_hash_exist_write_offset{}; + FF kernel_nullifier_exists_write_offset{}; + FF kernel_nullifier_non_exists_write_offset{}; + FF kernel_q_public_input_kernel_add_to_table{}; + FF kernel_q_public_input_kernel_out_add_to_table{}; + FF kernel_side_effect_counter{}; + FF kernel_sload_write_offset{}; + FF kernel_sstore_write_offset{}; + FF main_abs_da_rem_gas_hi{}; + FF main_abs_da_rem_gas_lo{}; + FF main_abs_l2_rem_gas_hi{}; + FF main_abs_l2_rem_gas_lo{}; + FF main_alu_in_tag{}; + FF main_bin_op_id{}; + FF main_call_ptr{}; + FF main_da_gas_op_cost{}; + FF main_da_gas_remaining{}; + FF main_da_out_of_gas{}; + FF main_ia{}; + FF main_ib{}; + FF main_ic{}; + FF main_id{}; + FF main_id_zero{}; + FF main_ind_addr_a{}; + FF main_ind_addr_b{}; + FF main_ind_addr_c{}; + FF main_ind_addr_d{}; + FF main_internal_return_ptr{}; + FF main_inv{}; + FF main_l2_gas_op_cost{}; + FF main_l2_gas_remaining{}; + FF main_l2_out_of_gas{}; + FF main_mem_addr_a{}; + FF main_mem_addr_b{}; + FF main_mem_addr_c{}; + FF main_mem_addr_d{}; + FF main_op_err{}; + FF main_opcode_val{}; + FF main_pc{}; + FF main_r_in_tag{}; + FF main_rwa{}; + FF main_rwb{}; + FF main_rwc{}; + FF main_rwd{}; + FF main_sel_alu{}; + FF main_sel_bin{}; + FF main_sel_gas_accounting_active{}; + FF main_sel_last{}; + FF main_sel_mem_op_a{}; + FF main_sel_mem_op_activate_gas{}; + FF main_sel_mem_op_b{}; + FF main_sel_mem_op_c{}; + FF main_sel_mem_op_d{}; + FF main_sel_mov_ia_to_ic{}; + FF main_sel_mov_ib_to_ic{}; + FF main_sel_op_add{}; + FF main_sel_op_address{}; + FF main_sel_op_and{}; + FF main_sel_op_block_number{}; + FF main_sel_op_cast{}; + FF main_sel_op_chain_id{}; + FF main_sel_op_cmov{}; + FF main_sel_op_coinbase{}; + FF main_sel_op_dagasleft{}; + FF main_sel_op_div{}; + FF main_sel_op_emit_l2_to_l1_msg{}; + FF main_sel_op_emit_note_hash{}; + FF main_sel_op_emit_nullifier{}; + FF main_sel_op_emit_unencrypted_log{}; + FF main_sel_op_eq{}; + FF main_sel_op_external_call{}; + FF main_sel_op_fdiv{}; + FF main_sel_op_fee_per_da_gas{}; + FF main_sel_op_fee_per_l2_gas{}; + FF main_sel_op_function_selector{}; + FF main_sel_op_get_contract_instance{}; + FF main_sel_op_halt{}; + FF main_sel_op_internal_call{}; + FF main_sel_op_internal_return{}; + FF main_sel_op_jump{}; + FF main_sel_op_jumpi{}; + FF main_sel_op_keccak{}; + FF main_sel_op_l1_to_l2_msg_exists{}; + FF main_sel_op_l2gasleft{}; + FF main_sel_op_lt{}; + FF main_sel_op_lte{}; + FF main_sel_op_mov{}; + FF main_sel_op_mul{}; + FF main_sel_op_not{}; + FF main_sel_op_note_hash_exists{}; + FF main_sel_op_nullifier_exists{}; + FF main_sel_op_or{}; + FF main_sel_op_pedersen{}; + FF main_sel_op_poseidon2{}; + FF main_sel_op_radix_le{}; + FF main_sel_op_sender{}; + FF main_sel_op_sha256{}; + FF main_sel_op_shl{}; + FF main_sel_op_shr{}; + FF main_sel_op_sload{}; + FF main_sel_op_sstore{}; + FF main_sel_op_storage_address{}; + FF main_sel_op_sub{}; + FF main_sel_op_timestamp{}; + FF main_sel_op_transaction_fee{}; + FF main_sel_op_version{}; + FF main_sel_op_xor{}; + FF main_sel_q_kernel_lookup{}; + FF main_sel_q_kernel_output_lookup{}; + FF main_sel_resolve_ind_addr_a{}; + FF main_sel_resolve_ind_addr_b{}; + FF main_sel_resolve_ind_addr_c{}; + FF main_sel_resolve_ind_addr_d{}; + FF main_sel_rng_16{}; + FF main_sel_rng_8{}; + FF main_space_id{}; + FF main_tag_err{}; + FF main_w_in_tag{}; + FF mem_addr{}; + FF mem_clk{}; + FF mem_diff_hi{}; + FF mem_diff_lo{}; + FF mem_diff_mid{}; + FF mem_glob_addr{}; + FF mem_last{}; + FF mem_lastAccess{}; + FF mem_one_min_inv{}; + FF mem_r_in_tag{}; + FF mem_rw{}; + FF mem_sel_mem{}; + FF mem_sel_mov_ia_to_ic{}; + FF mem_sel_mov_ib_to_ic{}; + FF mem_sel_op_a{}; + FF mem_sel_op_b{}; + FF mem_sel_op_c{}; + FF mem_sel_op_cmov{}; + FF mem_sel_op_d{}; + FF mem_sel_resolve_ind_addr_a{}; + FF mem_sel_resolve_ind_addr_b{}; + FF mem_sel_resolve_ind_addr_c{}; + FF mem_sel_resolve_ind_addr_d{}; + FF mem_sel_rng_chk{}; + FF mem_skip_check_tag{}; + FF mem_space_id{}; + FF mem_tag{}; + FF mem_tag_err{}; + FF mem_tsp{}; + FF mem_val{}; + FF mem_w_in_tag{}; + FF pedersen_clk{}; + FF pedersen_input{}; + FF pedersen_output{}; + FF pedersen_sel_pedersen{}; + FF poseidon2_a_0{}; + FF poseidon2_a_1{}; + FF poseidon2_a_2{}; + FF poseidon2_a_3{}; + FF poseidon2_b_0{}; + FF poseidon2_b_1{}; + FF poseidon2_b_2{}; + FF poseidon2_b_3{}; + FF poseidon2_clk{}; + FF poseidon2_input{}; + FF poseidon2_output{}; + FF poseidon2_sel_poseidon_perm{}; + FF powers_power_of_2{}; + FF sha256_clk{}; + FF sha256_input{}; + FF sha256_output{}; + FF sha256_sel_sha256_compression{}; + FF sha256_state{}; + FF perm_main_alu{}; + FF perm_main_bin{}; + FF perm_main_conv{}; + FF perm_main_pos2_perm{}; + FF perm_main_pedersen{}; + FF perm_main_mem_a{}; + FF perm_main_mem_b{}; + FF perm_main_mem_c{}; + FF perm_main_mem_d{}; + FF perm_main_mem_ind_addr_a{}; + FF perm_main_mem_ind_addr_b{}; + FF perm_main_mem_ind_addr_c{}; + FF perm_main_mem_ind_addr_d{}; + FF lookup_byte_lengths{}; + FF lookup_byte_operations{}; + FF lookup_opcode_gas{}; + FF range_check_l2_gas_hi{}; + FF range_check_l2_gas_lo{}; + FF range_check_da_gas_hi{}; + FF range_check_da_gas_lo{}; + FF kernel_output_lookup{}; + FF lookup_into_kernel{}; + FF incl_main_tag_err{}; + FF incl_mem_tag_err{}; + FF lookup_mem_rng_chk_lo{}; + FF lookup_mem_rng_chk_mid{}; + FF lookup_mem_rng_chk_hi{}; + FF lookup_pow_2_0{}; + FF lookup_pow_2_1{}; + FF lookup_u8_0{}; + FF lookup_u8_1{}; + FF lookup_u16_0{}; + FF lookup_u16_1{}; + FF lookup_u16_2{}; + FF lookup_u16_3{}; + FF lookup_u16_4{}; + FF lookup_u16_5{}; + FF lookup_u16_6{}; + FF lookup_u16_7{}; + FF lookup_u16_8{}; + FF lookup_u16_9{}; + FF lookup_u16_10{}; + FF lookup_u16_11{}; + FF lookup_u16_12{}; + FF lookup_u16_13{}; + FF lookup_u16_14{}; + FF lookup_div_u16_0{}; + FF lookup_div_u16_1{}; + FF lookup_div_u16_2{}; + FF lookup_div_u16_3{}; + FF lookup_div_u16_4{}; + FF lookup_div_u16_5{}; + FF lookup_div_u16_6{}; + FF lookup_div_u16_7{}; + FF lookup_byte_lengths_counts{}; + FF lookup_byte_operations_counts{}; + FF lookup_opcode_gas_counts{}; + FF range_check_l2_gas_hi_counts{}; + FF range_check_l2_gas_lo_counts{}; + FF range_check_da_gas_hi_counts{}; + FF range_check_da_gas_lo_counts{}; + FF kernel_output_lookup_counts{}; + FF lookup_into_kernel_counts{}; + FF incl_main_tag_err_counts{}; + FF incl_mem_tag_err_counts{}; + FF lookup_mem_rng_chk_lo_counts{}; + FF lookup_mem_rng_chk_mid_counts{}; + FF lookup_mem_rng_chk_hi_counts{}; + FF lookup_pow_2_0_counts{}; + FF lookup_pow_2_1_counts{}; + FF lookup_u8_0_counts{}; + FF lookup_u8_1_counts{}; + FF lookup_u16_0_counts{}; + FF lookup_u16_1_counts{}; + FF lookup_u16_2_counts{}; + FF lookup_u16_3_counts{}; + FF lookup_u16_4_counts{}; + FF lookup_u16_5_counts{}; + FF lookup_u16_6_counts{}; + FF lookup_u16_7_counts{}; + FF lookup_u16_8_counts{}; + FF lookup_u16_9_counts{}; + FF lookup_u16_10_counts{}; + FF lookup_u16_11_counts{}; + FF lookup_u16_12_counts{}; + FF lookup_u16_13_counts{}; + FF lookup_u16_14_counts{}; + FF lookup_div_u16_0_counts{}; + FF lookup_div_u16_1_counts{}; + FF lookup_div_u16_2_counts{}; + FF lookup_div_u16_3_counts{}; + FF lookup_div_u16_4_counts{}; + FF lookup_div_u16_5_counts{}; + FF lookup_div_u16_6_counts{}; + FF lookup_div_u16_7_counts{}; + + [[maybe_unused]] static std::vector names(); +}; + +template std::ostream& operator<<(std::ostream& os, AvmFullRow const& row); + +>>>>>>> 520b7216c (feat(avm): poseidon2 constraints) +class AvmCircuitBuilder { + public: + using Flavor = bb::AvmFlavor; + using FF = Flavor::FF; + using Row = AvmFullRow; + + // TODO: template + using Polynomial = Flavor::Polynomial; + using ProverPolynomials = Flavor::ProverPolynomials; + +<<<<<<< HEAD + static constexpr size_t num_fixed_columns = 411; + static constexpr size_t num_polys = 411 + 74; +======= +<<<<<<< HEAD + static constexpr size_t num_fixed_columns = 387; + static constexpr size_t num_polys = 387 + 65; +======= +<<<<<<< HEAD + static constexpr size_t num_fixed_columns = 452; + static constexpr size_t num_polys = 387; +======= +<<<<<<< HEAD + static constexpr size_t num_fixed_columns = 451; + static constexpr size_t num_polys = 386; +======= + static constexpr size_t num_fixed_columns = 458; + static constexpr size_t num_polys = 393; +>>>>>>> 91347fba1 (feat(avm): poseidon2 constraints) +>>>>>>> dfd3ca77d (feat(avm): poseidon2 constraints) +>>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) +>>>>>>> 804a62263 (feat(avm): poseidon2 constraints) + std::vector rows; + + void set_trace(std::vector&& trace) { rows = std::move(trace); } + + ProverPolynomials compute_polynomials() + { + const auto num_rows = get_circuit_subgroup_size(); + ProverPolynomials polys; + + // Allocate mem for each column + for (auto& poly : polys.get_all()) { + poly = Polynomial(num_rows); + } + + for (size_t i = 0; i < rows.size(); i++) { + polys.main_clk[i] = rows[i].main_clk; + polys.main_sel_first[i] = rows[i].main_sel_first; + polys.kernel_kernel_inputs[i] = rows[i].kernel_kernel_inputs; + polys.kernel_kernel_value_out[i] = rows[i].kernel_kernel_value_out; + polys.kernel_kernel_side_effect_out[i] = rows[i].kernel_kernel_side_effect_out; + polys.kernel_kernel_metadata_out[i] = rows[i].kernel_kernel_metadata_out; + polys.main_calldata[i] = rows[i].main_calldata; + polys.main_returndata[i] = rows[i].main_returndata; + polys.alu_a_hi[i] = rows[i].alu_a_hi; + polys.alu_a_lo[i] = rows[i].alu_a_lo; + polys.alu_b_hi[i] = rows[i].alu_b_hi; + polys.alu_b_lo[i] = rows[i].alu_b_lo; + polys.alu_borrow[i] = rows[i].alu_borrow; + polys.alu_cf[i] = rows[i].alu_cf; + polys.alu_clk[i] = rows[i].alu_clk; + polys.alu_cmp_rng_ctr[i] = rows[i].alu_cmp_rng_ctr; + polys.alu_div_u16_r0[i] = rows[i].alu_div_u16_r0; + polys.alu_div_u16_r1[i] = rows[i].alu_div_u16_r1; + polys.alu_div_u16_r2[i] = rows[i].alu_div_u16_r2; + polys.alu_div_u16_r3[i] = rows[i].alu_div_u16_r3; + polys.alu_div_u16_r4[i] = rows[i].alu_div_u16_r4; + polys.alu_div_u16_r5[i] = rows[i].alu_div_u16_r5; + polys.alu_div_u16_r6[i] = rows[i].alu_div_u16_r6; + polys.alu_div_u16_r7[i] = rows[i].alu_div_u16_r7; + polys.alu_divisor_hi[i] = rows[i].alu_divisor_hi; + polys.alu_divisor_lo[i] = rows[i].alu_divisor_lo; + polys.alu_ff_tag[i] = rows[i].alu_ff_tag; + polys.alu_ia[i] = rows[i].alu_ia; + polys.alu_ib[i] = rows[i].alu_ib; + polys.alu_ic[i] = rows[i].alu_ic; + polys.alu_in_tag[i] = rows[i].alu_in_tag; + polys.alu_op_add[i] = rows[i].alu_op_add; + polys.alu_op_cast[i] = rows[i].alu_op_cast; + polys.alu_op_cast_prev[i] = rows[i].alu_op_cast_prev; + polys.alu_op_div[i] = rows[i].alu_op_div; + polys.alu_op_div_a_lt_b[i] = rows[i].alu_op_div_a_lt_b; + polys.alu_op_div_std[i] = rows[i].alu_op_div_std; + polys.alu_op_eq[i] = rows[i].alu_op_eq; + polys.alu_op_eq_diff_inv[i] = rows[i].alu_op_eq_diff_inv; + polys.alu_op_lt[i] = rows[i].alu_op_lt; + polys.alu_op_lte[i] = rows[i].alu_op_lte; + polys.alu_op_mul[i] = rows[i].alu_op_mul; + polys.alu_op_not[i] = rows[i].alu_op_not; + polys.alu_op_shl[i] = rows[i].alu_op_shl; + polys.alu_op_shr[i] = rows[i].alu_op_shr; + polys.alu_op_sub[i] = rows[i].alu_op_sub; + polys.alu_p_a_borrow[i] = rows[i].alu_p_a_borrow; + polys.alu_p_b_borrow[i] = rows[i].alu_p_b_borrow; + polys.alu_p_sub_a_hi[i] = rows[i].alu_p_sub_a_hi; + polys.alu_p_sub_a_lo[i] = rows[i].alu_p_sub_a_lo; + polys.alu_p_sub_b_hi[i] = rows[i].alu_p_sub_b_hi; + polys.alu_p_sub_b_lo[i] = rows[i].alu_p_sub_b_lo; + polys.alu_partial_prod_hi[i] = rows[i].alu_partial_prod_hi; + polys.alu_partial_prod_lo[i] = rows[i].alu_partial_prod_lo; + polys.alu_quotient_hi[i] = rows[i].alu_quotient_hi; + polys.alu_quotient_lo[i] = rows[i].alu_quotient_lo; + polys.alu_remainder[i] = rows[i].alu_remainder; + polys.alu_res_hi[i] = rows[i].alu_res_hi; + polys.alu_res_lo[i] = rows[i].alu_res_lo; + polys.alu_sel_alu[i] = rows[i].alu_sel_alu; + polys.alu_sel_cmp[i] = rows[i].alu_sel_cmp; + polys.alu_sel_div_rng_chk[i] = rows[i].alu_sel_div_rng_chk; + polys.alu_sel_rng_chk[i] = rows[i].alu_sel_rng_chk; + polys.alu_sel_rng_chk_lookup[i] = rows[i].alu_sel_rng_chk_lookup; + polys.alu_sel_shift_which[i] = rows[i].alu_sel_shift_which; + polys.alu_shift_lt_bit_len[i] = rows[i].alu_shift_lt_bit_len; + polys.alu_t_sub_s_bits[i] = rows[i].alu_t_sub_s_bits; + polys.alu_two_pow_s[i] = rows[i].alu_two_pow_s; + polys.alu_two_pow_t_sub_s[i] = rows[i].alu_two_pow_t_sub_s; + polys.alu_u128_tag[i] = rows[i].alu_u128_tag; + polys.alu_u16_r0[i] = rows[i].alu_u16_r0; + polys.alu_u16_r1[i] = rows[i].alu_u16_r1; + polys.alu_u16_r10[i] = rows[i].alu_u16_r10; + polys.alu_u16_r11[i] = rows[i].alu_u16_r11; + polys.alu_u16_r12[i] = rows[i].alu_u16_r12; + polys.alu_u16_r13[i] = rows[i].alu_u16_r13; + polys.alu_u16_r14[i] = rows[i].alu_u16_r14; + polys.alu_u16_r2[i] = rows[i].alu_u16_r2; + polys.alu_u16_r3[i] = rows[i].alu_u16_r3; + polys.alu_u16_r4[i] = rows[i].alu_u16_r4; + polys.alu_u16_r5[i] = rows[i].alu_u16_r5; + polys.alu_u16_r6[i] = rows[i].alu_u16_r6; + polys.alu_u16_r7[i] = rows[i].alu_u16_r7; + polys.alu_u16_r8[i] = rows[i].alu_u16_r8; + polys.alu_u16_r9[i] = rows[i].alu_u16_r9; + polys.alu_u16_tag[i] = rows[i].alu_u16_tag; + polys.alu_u32_tag[i] = rows[i].alu_u32_tag; + polys.alu_u64_tag[i] = rows[i].alu_u64_tag; + polys.alu_u8_r0[i] = rows[i].alu_u8_r0; + polys.alu_u8_r1[i] = rows[i].alu_u8_r1; + polys.alu_u8_tag[i] = rows[i].alu_u8_tag; + polys.binary_acc_ia[i] = rows[i].binary_acc_ia; + polys.binary_acc_ib[i] = rows[i].binary_acc_ib; + polys.binary_acc_ic[i] = rows[i].binary_acc_ic; + polys.binary_clk[i] = rows[i].binary_clk; + polys.binary_ia_bytes[i] = rows[i].binary_ia_bytes; + polys.binary_ib_bytes[i] = rows[i].binary_ib_bytes; + polys.binary_ic_bytes[i] = rows[i].binary_ic_bytes; + polys.binary_in_tag[i] = rows[i].binary_in_tag; + polys.binary_mem_tag_ctr[i] = rows[i].binary_mem_tag_ctr; + polys.binary_mem_tag_ctr_inv[i] = rows[i].binary_mem_tag_ctr_inv; + polys.binary_op_id[i] = rows[i].binary_op_id; + polys.binary_sel_bin[i] = rows[i].binary_sel_bin; + polys.binary_start[i] = rows[i].binary_start; + polys.byte_lookup_sel_bin[i] = rows[i].byte_lookup_sel_bin; + polys.byte_lookup_table_byte_lengths[i] = rows[i].byte_lookup_table_byte_lengths; + polys.byte_lookup_table_in_tags[i] = rows[i].byte_lookup_table_in_tags; + polys.byte_lookup_table_input_a[i] = rows[i].byte_lookup_table_input_a; + polys.byte_lookup_table_input_b[i] = rows[i].byte_lookup_table_input_b; + polys.byte_lookup_table_op_id[i] = rows[i].byte_lookup_table_op_id; + polys.byte_lookup_table_output[i] = rows[i].byte_lookup_table_output; + polys.conversion_clk[i] = rows[i].conversion_clk; + polys.conversion_input[i] = rows[i].conversion_input; + polys.conversion_num_limbs[i] = rows[i].conversion_num_limbs; + polys.conversion_radix[i] = rows[i].conversion_radix; + polys.conversion_sel_to_radix_le[i] = rows[i].conversion_sel_to_radix_le; + polys.gas_da_gas_fixed_table[i] = rows[i].gas_da_gas_fixed_table; + polys.gas_l2_gas_fixed_table[i] = rows[i].gas_l2_gas_fixed_table; + polys.gas_sel_gas_cost[i] = rows[i].gas_sel_gas_cost; + polys.keccakf1600_clk[i] = rows[i].keccakf1600_clk; + polys.keccakf1600_input[i] = rows[i].keccakf1600_input; + polys.keccakf1600_output[i] = rows[i].keccakf1600_output; + polys.keccakf1600_sel_keccakf1600[i] = rows[i].keccakf1600_sel_keccakf1600; + polys.kernel_emit_l2_to_l1_msg_write_offset[i] = rows[i].kernel_emit_l2_to_l1_msg_write_offset; + polys.kernel_emit_note_hash_write_offset[i] = rows[i].kernel_emit_note_hash_write_offset; + polys.kernel_emit_nullifier_write_offset[i] = rows[i].kernel_emit_nullifier_write_offset; + polys.kernel_emit_unencrypted_log_write_offset[i] = rows[i].kernel_emit_unencrypted_log_write_offset; + polys.kernel_kernel_in_offset[i] = rows[i].kernel_kernel_in_offset; + polys.kernel_kernel_out_offset[i] = rows[i].kernel_kernel_out_offset; + polys.kernel_l1_to_l2_msg_exists_write_offset[i] = rows[i].kernel_l1_to_l2_msg_exists_write_offset; + polys.kernel_note_hash_exist_write_offset[i] = rows[i].kernel_note_hash_exist_write_offset; + polys.kernel_nullifier_exists_write_offset[i] = rows[i].kernel_nullifier_exists_write_offset; + polys.kernel_nullifier_non_exists_write_offset[i] = rows[i].kernel_nullifier_non_exists_write_offset; + polys.kernel_q_public_input_kernel_add_to_table[i] = rows[i].kernel_q_public_input_kernel_add_to_table; + polys.kernel_q_public_input_kernel_out_add_to_table[i] = + rows[i].kernel_q_public_input_kernel_out_add_to_table; + polys.kernel_side_effect_counter[i] = rows[i].kernel_side_effect_counter; + polys.kernel_sload_write_offset[i] = rows[i].kernel_sload_write_offset; + polys.kernel_sstore_write_offset[i] = rows[i].kernel_sstore_write_offset; + polys.main_abs_da_rem_gas_hi[i] = rows[i].main_abs_da_rem_gas_hi; + polys.main_abs_da_rem_gas_lo[i] = rows[i].main_abs_da_rem_gas_lo; + polys.main_abs_l2_rem_gas_hi[i] = rows[i].main_abs_l2_rem_gas_hi; + polys.main_abs_l2_rem_gas_lo[i] = rows[i].main_abs_l2_rem_gas_lo; + polys.main_alu_in_tag[i] = rows[i].main_alu_in_tag; + polys.main_bin_op_id[i] = rows[i].main_bin_op_id; + polys.main_call_ptr[i] = rows[i].main_call_ptr; + polys.main_da_gas_op_cost[i] = rows[i].main_da_gas_op_cost; + polys.main_da_gas_remaining[i] = rows[i].main_da_gas_remaining; + polys.main_da_out_of_gas[i] = rows[i].main_da_out_of_gas; + polys.main_ia[i] = rows[i].main_ia; + polys.main_ib[i] = rows[i].main_ib; + polys.main_ic[i] = rows[i].main_ic; + polys.main_id[i] = rows[i].main_id; + polys.main_id_zero[i] = rows[i].main_id_zero; + polys.main_ind_addr_a[i] = rows[i].main_ind_addr_a; + polys.main_ind_addr_b[i] = rows[i].main_ind_addr_b; + polys.main_ind_addr_c[i] = rows[i].main_ind_addr_c; + polys.main_ind_addr_d[i] = rows[i].main_ind_addr_d; + polys.main_internal_return_ptr[i] = rows[i].main_internal_return_ptr; + polys.main_inv[i] = rows[i].main_inv; + polys.main_l2_gas_op_cost[i] = rows[i].main_l2_gas_op_cost; + polys.main_l2_gas_remaining[i] = rows[i].main_l2_gas_remaining; + polys.main_l2_out_of_gas[i] = rows[i].main_l2_out_of_gas; + polys.main_mem_addr_a[i] = rows[i].main_mem_addr_a; + polys.main_mem_addr_b[i] = rows[i].main_mem_addr_b; + polys.main_mem_addr_c[i] = rows[i].main_mem_addr_c; + polys.main_mem_addr_d[i] = rows[i].main_mem_addr_d; + polys.main_op_err[i] = rows[i].main_op_err; + polys.main_opcode_val[i] = rows[i].main_opcode_val; + polys.main_pc[i] = rows[i].main_pc; + polys.main_r_in_tag[i] = rows[i].main_r_in_tag; + polys.main_rwa[i] = rows[i].main_rwa; + polys.main_rwb[i] = rows[i].main_rwb; + polys.main_rwc[i] = rows[i].main_rwc; + polys.main_rwd[i] = rows[i].main_rwd; + polys.main_sel_alu[i] = rows[i].main_sel_alu; + polys.main_sel_bin[i] = rows[i].main_sel_bin; + polys.main_sel_calldata[i] = rows[i].main_sel_calldata; + polys.main_sel_gas_accounting_active[i] = rows[i].main_sel_gas_accounting_active; + polys.main_sel_last[i] = rows[i].main_sel_last; + polys.main_sel_mem_op_a[i] = rows[i].main_sel_mem_op_a; + polys.main_sel_mem_op_activate_gas[i] = rows[i].main_sel_mem_op_activate_gas; + polys.main_sel_mem_op_b[i] = rows[i].main_sel_mem_op_b; + polys.main_sel_mem_op_c[i] = rows[i].main_sel_mem_op_c; + polys.main_sel_mem_op_d[i] = rows[i].main_sel_mem_op_d; + polys.main_sel_mov_ia_to_ic[i] = rows[i].main_sel_mov_ia_to_ic; + polys.main_sel_mov_ib_to_ic[i] = rows[i].main_sel_mov_ib_to_ic; + polys.main_sel_op_add[i] = rows[i].main_sel_op_add; + polys.main_sel_op_address[i] = rows[i].main_sel_op_address; + polys.main_sel_op_and[i] = rows[i].main_sel_op_and; + polys.main_sel_op_block_number[i] = rows[i].main_sel_op_block_number; + polys.main_sel_op_calldata_copy[i] = rows[i].main_sel_op_calldata_copy; + polys.main_sel_op_cast[i] = rows[i].main_sel_op_cast; + polys.main_sel_op_chain_id[i] = rows[i].main_sel_op_chain_id; + polys.main_sel_op_cmov[i] = rows[i].main_sel_op_cmov; + polys.main_sel_op_coinbase[i] = rows[i].main_sel_op_coinbase; + polys.main_sel_op_dagasleft[i] = rows[i].main_sel_op_dagasleft; + polys.main_sel_op_div[i] = rows[i].main_sel_op_div; + polys.main_sel_op_emit_l2_to_l1_msg[i] = rows[i].main_sel_op_emit_l2_to_l1_msg; + polys.main_sel_op_emit_note_hash[i] = rows[i].main_sel_op_emit_note_hash; + polys.main_sel_op_emit_nullifier[i] = rows[i].main_sel_op_emit_nullifier; + polys.main_sel_op_emit_unencrypted_log[i] = rows[i].main_sel_op_emit_unencrypted_log; + polys.main_sel_op_eq[i] = rows[i].main_sel_op_eq; + polys.main_sel_op_external_call[i] = rows[i].main_sel_op_external_call; + polys.main_sel_op_external_return[i] = rows[i].main_sel_op_external_return; + polys.main_sel_op_fdiv[i] = rows[i].main_sel_op_fdiv; + polys.main_sel_op_fee_per_da_gas[i] = rows[i].main_sel_op_fee_per_da_gas; + polys.main_sel_op_fee_per_l2_gas[i] = rows[i].main_sel_op_fee_per_l2_gas; + polys.main_sel_op_function_selector[i] = rows[i].main_sel_op_function_selector; + polys.main_sel_op_get_contract_instance[i] = rows[i].main_sel_op_get_contract_instance; + polys.main_sel_op_halt[i] = rows[i].main_sel_op_halt; + polys.main_sel_op_internal_call[i] = rows[i].main_sel_op_internal_call; + polys.main_sel_op_internal_return[i] = rows[i].main_sel_op_internal_return; + polys.main_sel_op_jump[i] = rows[i].main_sel_op_jump; + polys.main_sel_op_jumpi[i] = rows[i].main_sel_op_jumpi; + polys.main_sel_op_keccak[i] = rows[i].main_sel_op_keccak; + polys.main_sel_op_l1_to_l2_msg_exists[i] = rows[i].main_sel_op_l1_to_l2_msg_exists; + polys.main_sel_op_l2gasleft[i] = rows[i].main_sel_op_l2gasleft; + polys.main_sel_op_lt[i] = rows[i].main_sel_op_lt; + polys.main_sel_op_lte[i] = rows[i].main_sel_op_lte; + polys.main_sel_op_mov[i] = rows[i].main_sel_op_mov; + polys.main_sel_op_mul[i] = rows[i].main_sel_op_mul; + polys.main_sel_op_not[i] = rows[i].main_sel_op_not; + polys.main_sel_op_note_hash_exists[i] = rows[i].main_sel_op_note_hash_exists; + polys.main_sel_op_nullifier_exists[i] = rows[i].main_sel_op_nullifier_exists; + polys.main_sel_op_or[i] = rows[i].main_sel_op_or; + polys.main_sel_op_pedersen[i] = rows[i].main_sel_op_pedersen; + polys.main_sel_op_poseidon2[i] = rows[i].main_sel_op_poseidon2; + polys.main_sel_op_radix_le[i] = rows[i].main_sel_op_radix_le; + polys.main_sel_op_sender[i] = rows[i].main_sel_op_sender; + polys.main_sel_op_sha256[i] = rows[i].main_sel_op_sha256; + polys.main_sel_op_shl[i] = rows[i].main_sel_op_shl; + polys.main_sel_op_shr[i] = rows[i].main_sel_op_shr; + polys.main_sel_op_sload[i] = rows[i].main_sel_op_sload; + polys.main_sel_op_sstore[i] = rows[i].main_sel_op_sstore; + polys.main_sel_op_storage_address[i] = rows[i].main_sel_op_storage_address; + polys.main_sel_op_sub[i] = rows[i].main_sel_op_sub; + polys.main_sel_op_timestamp[i] = rows[i].main_sel_op_timestamp; + polys.main_sel_op_transaction_fee[i] = rows[i].main_sel_op_transaction_fee; + polys.main_sel_op_version[i] = rows[i].main_sel_op_version; + polys.main_sel_op_xor[i] = rows[i].main_sel_op_xor; + polys.main_sel_q_kernel_lookup[i] = rows[i].main_sel_q_kernel_lookup; + polys.main_sel_q_kernel_output_lookup[i] = rows[i].main_sel_q_kernel_output_lookup; + polys.main_sel_resolve_ind_addr_a[i] = rows[i].main_sel_resolve_ind_addr_a; + polys.main_sel_resolve_ind_addr_b[i] = rows[i].main_sel_resolve_ind_addr_b; + polys.main_sel_resolve_ind_addr_c[i] = rows[i].main_sel_resolve_ind_addr_c; + polys.main_sel_resolve_ind_addr_d[i] = rows[i].main_sel_resolve_ind_addr_d; + polys.main_sel_returndata[i] = rows[i].main_sel_returndata; + polys.main_sel_rng_16[i] = rows[i].main_sel_rng_16; + polys.main_sel_rng_8[i] = rows[i].main_sel_rng_8; + polys.main_sel_slice_gadget[i] = rows[i].main_sel_slice_gadget; + polys.main_space_id[i] = rows[i].main_space_id; + polys.main_tag_err[i] = rows[i].main_tag_err; + polys.main_w_in_tag[i] = rows[i].main_w_in_tag; + polys.mem_addr[i] = rows[i].mem_addr; + polys.mem_clk[i] = rows[i].mem_clk; + polys.mem_diff_hi[i] = rows[i].mem_diff_hi; + polys.mem_diff_lo[i] = rows[i].mem_diff_lo; + polys.mem_diff_mid[i] = rows[i].mem_diff_mid; + polys.mem_glob_addr[i] = rows[i].mem_glob_addr; + polys.mem_last[i] = rows[i].mem_last; + polys.mem_lastAccess[i] = rows[i].mem_lastAccess; + polys.mem_one_min_inv[i] = rows[i].mem_one_min_inv; + polys.mem_r_in_tag[i] = rows[i].mem_r_in_tag; + polys.mem_rw[i] = rows[i].mem_rw; + polys.mem_sel_mem[i] = rows[i].mem_sel_mem; + polys.mem_sel_mov_ia_to_ic[i] = rows[i].mem_sel_mov_ia_to_ic; + polys.mem_sel_mov_ib_to_ic[i] = rows[i].mem_sel_mov_ib_to_ic; + polys.mem_sel_op_a[i] = rows[i].mem_sel_op_a; + polys.mem_sel_op_b[i] = rows[i].mem_sel_op_b; + polys.mem_sel_op_c[i] = rows[i].mem_sel_op_c; + polys.mem_sel_op_cmov[i] = rows[i].mem_sel_op_cmov; + polys.mem_sel_op_d[i] = rows[i].mem_sel_op_d; + polys.mem_sel_op_slice[i] = rows[i].mem_sel_op_slice; + polys.mem_sel_resolve_ind_addr_a[i] = rows[i].mem_sel_resolve_ind_addr_a; + polys.mem_sel_resolve_ind_addr_b[i] = rows[i].mem_sel_resolve_ind_addr_b; + polys.mem_sel_resolve_ind_addr_c[i] = rows[i].mem_sel_resolve_ind_addr_c; + polys.mem_sel_resolve_ind_addr_d[i] = rows[i].mem_sel_resolve_ind_addr_d; + polys.mem_sel_rng_chk[i] = rows[i].mem_sel_rng_chk; + polys.mem_skip_check_tag[i] = rows[i].mem_skip_check_tag; + polys.mem_space_id[i] = rows[i].mem_space_id; + polys.mem_tag[i] = rows[i].mem_tag; + polys.mem_tag_err[i] = rows[i].mem_tag_err; + polys.mem_tsp[i] = rows[i].mem_tsp; + polys.mem_val[i] = rows[i].mem_val; + polys.mem_w_in_tag[i] = rows[i].mem_w_in_tag; + polys.pedersen_clk[i] = rows[i].pedersen_clk; + polys.pedersen_input[i] = rows[i].pedersen_input; + polys.pedersen_output[i] = rows[i].pedersen_output; + polys.pedersen_sel_pedersen[i] = rows[i].pedersen_sel_pedersen; + polys.poseidon2_a_0[i] = rows[i].poseidon2_a_0; + polys.poseidon2_a_1[i] = rows[i].poseidon2_a_1; + polys.poseidon2_a_2[i] = rows[i].poseidon2_a_2; + polys.poseidon2_a_3[i] = rows[i].poseidon2_a_3; + polys.poseidon2_b_0[i] = rows[i].poseidon2_b_0; + polys.poseidon2_b_1[i] = rows[i].poseidon2_b_1; + polys.poseidon2_b_2[i] = rows[i].poseidon2_b_2; + polys.poseidon2_b_3[i] = rows[i].poseidon2_b_3; + polys.poseidon2_clk[i] = rows[i].poseidon2_clk; + polys.poseidon2_input[i] = rows[i].poseidon2_input; + polys.poseidon2_output[i] = rows[i].poseidon2_output; + polys.poseidon2_sel_poseidon_perm[i] = rows[i].poseidon2_sel_poseidon_perm; + polys.powers_power_of_2[i] = rows[i].powers_power_of_2; + polys.sha256_clk[i] = rows[i].sha256_clk; + polys.sha256_input[i] = rows[i].sha256_input; + polys.sha256_output[i] = rows[i].sha256_output; + polys.sha256_sel_sha256_compression[i] = rows[i].sha256_sel_sha256_compression; + polys.sha256_state[i] = rows[i].sha256_state; + polys.slice_addr[i] = rows[i].slice_addr; + polys.slice_clk[i] = rows[i].slice_clk; + polys.slice_cnt[i] = rows[i].slice_cnt; + polys.slice_col_offset[i] = rows[i].slice_col_offset; + polys.slice_one_min_inv[i] = rows[i].slice_one_min_inv; + polys.slice_sel_cd_cpy[i] = rows[i].slice_sel_cd_cpy; + polys.slice_sel_mem_active[i] = rows[i].slice_sel_mem_active; + polys.slice_sel_return[i] = rows[i].slice_sel_return; + polys.slice_sel_start[i] = rows[i].slice_sel_start; + polys.slice_space_id[i] = rows[i].slice_space_id; + polys.slice_val[i] = rows[i].slice_val; + polys.lookup_byte_lengths_counts[i] = rows[i].lookup_byte_lengths_counts; + polys.lookup_byte_operations_counts[i] = rows[i].lookup_byte_operations_counts; + polys.lookup_cd_value_counts[i] = rows[i].lookup_cd_value_counts; + polys.lookup_ret_value_counts[i] = rows[i].lookup_ret_value_counts; + polys.lookup_opcode_gas_counts[i] = rows[i].lookup_opcode_gas_counts; + polys.range_check_l2_gas_hi_counts[i] = rows[i].range_check_l2_gas_hi_counts; + polys.range_check_l2_gas_lo_counts[i] = rows[i].range_check_l2_gas_lo_counts; + polys.range_check_da_gas_hi_counts[i] = rows[i].range_check_da_gas_hi_counts; + polys.range_check_da_gas_lo_counts[i] = rows[i].range_check_da_gas_lo_counts; + polys.kernel_output_lookup_counts[i] = rows[i].kernel_output_lookup_counts; + polys.lookup_into_kernel_counts[i] = rows[i].lookup_into_kernel_counts; + polys.incl_main_tag_err_counts[i] = rows[i].incl_main_tag_err_counts; + polys.incl_mem_tag_err_counts[i] = rows[i].incl_mem_tag_err_counts; + polys.lookup_mem_rng_chk_lo_counts[i] = rows[i].lookup_mem_rng_chk_lo_counts; + polys.lookup_mem_rng_chk_mid_counts[i] = rows[i].lookup_mem_rng_chk_mid_counts; + polys.lookup_mem_rng_chk_hi_counts[i] = rows[i].lookup_mem_rng_chk_hi_counts; + polys.lookup_pow_2_0_counts[i] = rows[i].lookup_pow_2_0_counts; + polys.lookup_pow_2_1_counts[i] = rows[i].lookup_pow_2_1_counts; + polys.lookup_u8_0_counts[i] = rows[i].lookup_u8_0_counts; + polys.lookup_u8_1_counts[i] = rows[i].lookup_u8_1_counts; + polys.lookup_u16_0_counts[i] = rows[i].lookup_u16_0_counts; + polys.lookup_u16_1_counts[i] = rows[i].lookup_u16_1_counts; + polys.lookup_u16_2_counts[i] = rows[i].lookup_u16_2_counts; + polys.lookup_u16_3_counts[i] = rows[i].lookup_u16_3_counts; + polys.lookup_u16_4_counts[i] = rows[i].lookup_u16_4_counts; + polys.lookup_u16_5_counts[i] = rows[i].lookup_u16_5_counts; + polys.lookup_u16_6_counts[i] = rows[i].lookup_u16_6_counts; + polys.lookup_u16_7_counts[i] = rows[i].lookup_u16_7_counts; + polys.lookup_u16_8_counts[i] = rows[i].lookup_u16_8_counts; + polys.lookup_u16_9_counts[i] = rows[i].lookup_u16_9_counts; + polys.lookup_u16_10_counts[i] = rows[i].lookup_u16_10_counts; + polys.lookup_u16_11_counts[i] = rows[i].lookup_u16_11_counts; + polys.lookup_u16_12_counts[i] = rows[i].lookup_u16_12_counts; + polys.lookup_u16_13_counts[i] = rows[i].lookup_u16_13_counts; + polys.lookup_u16_14_counts[i] = rows[i].lookup_u16_14_counts; + polys.lookup_div_u16_0_counts[i] = rows[i].lookup_div_u16_0_counts; + polys.lookup_div_u16_1_counts[i] = rows[i].lookup_div_u16_1_counts; + polys.lookup_div_u16_2_counts[i] = rows[i].lookup_div_u16_2_counts; + polys.lookup_div_u16_3_counts[i] = rows[i].lookup_div_u16_3_counts; + polys.lookup_div_u16_4_counts[i] = rows[i].lookup_div_u16_4_counts; + polys.lookup_div_u16_5_counts[i] = rows[i].lookup_div_u16_5_counts; + polys.lookup_div_u16_6_counts[i] = rows[i].lookup_div_u16_6_counts; + polys.lookup_div_u16_7_counts[i] = rows[i].lookup_div_u16_7_counts; + } + + for (auto [shifted, to_be_shifted] : zip_view(polys.get_shifted(), polys.get_to_be_shifted())) { + shifted = to_be_shifted.shifted(); + } + + return polys; + } + + [[maybe_unused]] bool check_circuit() + { + const FF gamma = FF::random_element(); + const FF beta = FF::random_element(); + bb::RelationParameters params{ + .eta = 0, + .beta = beta, + .gamma = gamma, + .public_input_delta = 0, + .lookup_grand_product_delta = 0, + .beta_sqr = 0, + .beta_cube = 0, + .eccvm_set_permutation_delta = 0, + }; + + auto polys = compute_polynomials(); + const size_t num_rows = polys.get_polynomial_size(); + + // Checks that we will run. + using SignalErrorFn = const std::function&; + std::vector> checks; + + // Add relation checks. + bb::constexpr_for<0, std::tuple_size_v, 1>([&]() { + using Relation = std::tuple_element_t; + checks.push_back([&](SignalErrorFn signal_error) { + typename Relation::SumcheckArrayOfValuesOverSubrelations result; + for (auto& r : result) { + r = 0; + } + constexpr size_t NUM_SUBRELATIONS = result.size(); + + for (size_t r = 0; r < num_rows; ++r) { + Relation::accumulate(result, polys.get_row(r), {}, 1); + for (size_t j = 0; j < NUM_SUBRELATIONS; ++j) { + if (result[j] != 0) { + signal_error(format("Relation ", + Relation::NAME, + ", subrelation ", + Relation::get_subrelation_label(j), + " failed at row ", + r)); + } + } + } + }); + }); + + // Add calculation of logderivatives and lookup/permutation checks. + bb::constexpr_for<0, std::tuple_size_v, 1>([&]() { + using Relation = std::tuple_element_t; + checks.push_back([&, num_rows](SignalErrorFn signal_error) { + // Check the logderivative relation + bb::compute_logderivative_inverse(polys, params, num_rows); + + typename Relation::SumcheckArrayOfValuesOverSubrelations lookup_result; + + for (auto& r : lookup_result) { + r = 0; + } + for (size_t r = 0; r < num_rows; ++r) { + Relation::accumulate(lookup_result, polys.get_row(r), params, 1); + } + for (auto r : lookup_result) { + if (r != 0) { + signal_error(format("Lookup ", Relation::NAME, " failed.")); + } + } + }); + }); + + std::string errors; + auto signal_error = [&](const std::string& error) { + // Thread safety first! + static std::mutex m; + std::lock_guard lock(m); + errors += error + "\n"; + }; + bb::parallel_for(checks.size(), [&](size_t i) { checks[i](signal_error); }); + if (!errors.empty()) { + throw_or_abort(errors); + } + + return errors.empty(); + } + + [[nodiscard]] size_t get_num_gates() const { return rows.size(); } + + [[nodiscard]] size_t get_circuit_subgroup_size() const + { + const size_t num_rows = get_num_gates(); + const auto num_rows_log2 = static_cast(numeric::get_msb64(num_rows)); + size_t num_rows_pow2 = 1UL << (num_rows_log2 + (1UL << num_rows_log2 == num_rows ? 0 : 1)); + return num_rows_pow2; + } +}; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp b/barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp new file mode 100644 index 000000000000..9d19571b59b8 --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp @@ -0,0 +1,5191 @@ +#pragma once + +#include "barretenberg/commitment_schemes/kzg/kzg.hpp" +#include "barretenberg/ecc/curves/bn254/g1.hpp" +#include "barretenberg/flavor/relation_definitions.hpp" +#include "barretenberg/polynomials/barycentric.hpp" +#include "barretenberg/polynomials/univariate.hpp" + +#include "barretenberg/flavor/flavor.hpp" +#include "barretenberg/flavor/flavor_macros.hpp" +#include "barretenberg/polynomials/evaluation_domain.hpp" +#include "barretenberg/polynomials/polynomial.hpp" +#include "barretenberg/transcript/transcript.hpp" + +#include "barretenberg/vm/generated/avm_flavor_settings.hpp" + +// Relations +#include "barretenberg/relations/generated/avm/alu.hpp" +#include "barretenberg/relations/generated/avm/binary.hpp" +#include "barretenberg/relations/generated/avm/conversion.hpp" +#include "barretenberg/relations/generated/avm/gas.hpp" +#include "barretenberg/relations/generated/avm/keccakf1600.hpp" +#include "barretenberg/relations/generated/avm/kernel.hpp" +#include "barretenberg/relations/generated/avm/main.hpp" +#include "barretenberg/relations/generated/avm/mem.hpp" +#include "barretenberg/relations/generated/avm/mem_slice.hpp" +#include "barretenberg/relations/generated/avm/pedersen.hpp" +#include "barretenberg/relations/generated/avm/poseidon2.hpp" +#include "barretenberg/relations/generated/avm/powers.hpp" +#include "barretenberg/relations/generated/avm/sha256.hpp" + +// Lookup and permutation relations +#include "barretenberg/relations/generated/avm/incl_main_tag_err.hpp" +#include "barretenberg/relations/generated/avm/incl_mem_tag_err.hpp" +#include "barretenberg/relations/generated/avm/kernel_output_lookup.hpp" +#include "barretenberg/relations/generated/avm/lookup_byte_lengths.hpp" +#include "barretenberg/relations/generated/avm/lookup_byte_operations.hpp" +#include "barretenberg/relations/generated/avm/lookup_cd_value.hpp" +#include "barretenberg/relations/generated/avm/lookup_div_u16_0.hpp" +#include "barretenberg/relations/generated/avm/lookup_div_u16_1.hpp" +#include "barretenberg/relations/generated/avm/lookup_div_u16_2.hpp" +#include "barretenberg/relations/generated/avm/lookup_div_u16_3.hpp" +#include "barretenberg/relations/generated/avm/lookup_div_u16_4.hpp" +#include "barretenberg/relations/generated/avm/lookup_div_u16_5.hpp" +#include "barretenberg/relations/generated/avm/lookup_div_u16_6.hpp" +#include "barretenberg/relations/generated/avm/lookup_div_u16_7.hpp" +#include "barretenberg/relations/generated/avm/lookup_into_kernel.hpp" +#include "barretenberg/relations/generated/avm/lookup_mem_rng_chk_hi.hpp" +#include "barretenberg/relations/generated/avm/lookup_mem_rng_chk_lo.hpp" +#include "barretenberg/relations/generated/avm/lookup_mem_rng_chk_mid.hpp" +#include "barretenberg/relations/generated/avm/lookup_opcode_gas.hpp" +#include "barretenberg/relations/generated/avm/lookup_pow_2_0.hpp" +#include "barretenberg/relations/generated/avm/lookup_pow_2_1.hpp" +#include "barretenberg/relations/generated/avm/lookup_ret_value.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_0.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_1.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_10.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_11.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_12.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_13.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_14.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_2.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_3.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_4.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_5.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_6.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_7.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_8.hpp" +#include "barretenberg/relations/generated/avm/lookup_u16_9.hpp" +#include "barretenberg/relations/generated/avm/lookup_u8_0.hpp" +#include "barretenberg/relations/generated/avm/lookup_u8_1.hpp" +#include "barretenberg/relations/generated/avm/perm_main_alu.hpp" +#include "barretenberg/relations/generated/avm/perm_main_bin.hpp" +#include "barretenberg/relations/generated/avm/perm_main_conv.hpp" +#include "barretenberg/relations/generated/avm/perm_main_mem_a.hpp" +#include "barretenberg/relations/generated/avm/perm_main_mem_b.hpp" +#include "barretenberg/relations/generated/avm/perm_main_mem_c.hpp" +#include "barretenberg/relations/generated/avm/perm_main_mem_d.hpp" +#include "barretenberg/relations/generated/avm/perm_main_mem_ind_addr_a.hpp" +#include "barretenberg/relations/generated/avm/perm_main_mem_ind_addr_b.hpp" +#include "barretenberg/relations/generated/avm/perm_main_mem_ind_addr_c.hpp" +#include "barretenberg/relations/generated/avm/perm_main_mem_ind_addr_d.hpp" +#include "barretenberg/relations/generated/avm/perm_main_pedersen.hpp" +#include "barretenberg/relations/generated/avm/perm_main_pos2_perm.hpp" +#include "barretenberg/relations/generated/avm/perm_main_slice.hpp" +#include "barretenberg/relations/generated/avm/perm_slice_mem.hpp" +#include "barretenberg/relations/generated/avm/range_check_da_gas_hi.hpp" +#include "barretenberg/relations/generated/avm/range_check_da_gas_lo.hpp" +#include "barretenberg/relations/generated/avm/range_check_l2_gas_hi.hpp" +#include "barretenberg/relations/generated/avm/range_check_l2_gas_lo.hpp" + +// Metaprogramming to concatenate tuple types. +template using tuple_cat_t = decltype(std::tuple_cat(std::declval()...)); + +// The entities that will be used in the flavor. +// clang-format off +#define PRECOMPUTED_ENTITIES main_clk, main_sel_first +#define WIRE_ENTITIES kernel_kernel_inputs, kernel_kernel_value_out, kernel_kernel_side_effect_out, kernel_kernel_metadata_out, main_calldata, main_returndata, alu_a_hi, alu_a_lo, alu_b_hi, alu_b_lo, alu_borrow, alu_cf, alu_clk, alu_cmp_rng_ctr, alu_div_u16_r0, alu_div_u16_r1, alu_div_u16_r2, alu_div_u16_r3, alu_div_u16_r4, alu_div_u16_r5, alu_div_u16_r6, alu_div_u16_r7, alu_divisor_hi, alu_divisor_lo, alu_ff_tag, alu_ia, alu_ib, alu_ic, alu_in_tag, alu_op_add, alu_op_cast, alu_op_cast_prev, alu_op_div, alu_op_div_a_lt_b, alu_op_div_std, alu_op_eq, alu_op_eq_diff_inv, alu_op_lt, alu_op_lte, alu_op_mul, alu_op_not, alu_op_shl, alu_op_shr, alu_op_sub, alu_p_a_borrow, alu_p_b_borrow, alu_p_sub_a_hi, alu_p_sub_a_lo, alu_p_sub_b_hi, alu_p_sub_b_lo, alu_partial_prod_hi, alu_partial_prod_lo, alu_quotient_hi, alu_quotient_lo, alu_remainder, alu_res_hi, alu_res_lo, alu_sel_alu, alu_sel_cmp, alu_sel_div_rng_chk, alu_sel_rng_chk, alu_sel_rng_chk_lookup, alu_sel_shift_which, alu_shift_lt_bit_len, alu_t_sub_s_bits, alu_two_pow_s, alu_two_pow_t_sub_s, alu_u128_tag, alu_u16_r0, alu_u16_r1, alu_u16_r10, alu_u16_r11, alu_u16_r12, alu_u16_r13, alu_u16_r14, alu_u16_r2, alu_u16_r3, alu_u16_r4, alu_u16_r5, alu_u16_r6, alu_u16_r7, alu_u16_r8, alu_u16_r9, alu_u16_tag, alu_u32_tag, alu_u64_tag, alu_u8_r0, alu_u8_r1, alu_u8_tag, binary_acc_ia, binary_acc_ib, binary_acc_ic, binary_clk, binary_ia_bytes, binary_ib_bytes, binary_ic_bytes, binary_in_tag, binary_mem_tag_ctr, binary_mem_tag_ctr_inv, binary_op_id, binary_sel_bin, binary_start, byte_lookup_sel_bin, byte_lookup_table_byte_lengths, byte_lookup_table_in_tags, byte_lookup_table_input_a, byte_lookup_table_input_b, byte_lookup_table_op_id, byte_lookup_table_output, conversion_clk, conversion_input, conversion_num_limbs, conversion_radix, conversion_sel_to_radix_le, gas_da_gas_fixed_table, gas_l2_gas_fixed_table, gas_sel_gas_cost, keccakf1600_clk, keccakf1600_input, keccakf1600_output, keccakf1600_sel_keccakf1600, kernel_emit_l2_to_l1_msg_write_offset, kernel_emit_note_hash_write_offset, kernel_emit_nullifier_write_offset, kernel_emit_unencrypted_log_write_offset, kernel_kernel_in_offset, kernel_kernel_out_offset, kernel_l1_to_l2_msg_exists_write_offset, kernel_note_hash_exist_write_offset, kernel_nullifier_exists_write_offset, kernel_nullifier_non_exists_write_offset, kernel_q_public_input_kernel_add_to_table, kernel_q_public_input_kernel_out_add_to_table, kernel_side_effect_counter, kernel_sload_write_offset, kernel_sstore_write_offset, main_abs_da_rem_gas_hi, main_abs_da_rem_gas_lo, main_abs_l2_rem_gas_hi, main_abs_l2_rem_gas_lo, main_alu_in_tag, main_bin_op_id, main_call_ptr, main_da_gas_op_cost, main_da_gas_remaining, main_da_out_of_gas, main_ia, main_ib, main_ic, main_id, main_id_zero, main_ind_addr_a, main_ind_addr_b, main_ind_addr_c, main_ind_addr_d, main_internal_return_ptr, main_inv, main_l2_gas_op_cost, main_l2_gas_remaining, main_l2_out_of_gas, main_mem_addr_a, main_mem_addr_b, main_mem_addr_c, main_mem_addr_d, main_op_err, main_opcode_val, main_pc, main_r_in_tag, main_rwa, main_rwb, main_rwc, main_rwd, main_sel_alu, main_sel_bin, main_sel_calldata, main_sel_gas_accounting_active, main_sel_last, main_sel_mem_op_a, main_sel_mem_op_activate_gas, main_sel_mem_op_b, main_sel_mem_op_c, main_sel_mem_op_d, main_sel_mov_ia_to_ic, main_sel_mov_ib_to_ic, main_sel_op_add, main_sel_op_address, main_sel_op_and, main_sel_op_block_number, main_sel_op_calldata_copy, main_sel_op_cast, main_sel_op_chain_id, main_sel_op_cmov, main_sel_op_coinbase, main_sel_op_dagasleft, main_sel_op_div, main_sel_op_emit_l2_to_l1_msg, main_sel_op_emit_note_hash, main_sel_op_emit_nullifier, main_sel_op_emit_unencrypted_log, main_sel_op_eq, main_sel_op_external_call, main_sel_op_external_return, main_sel_op_fdiv, main_sel_op_fee_per_da_gas, main_sel_op_fee_per_l2_gas, main_sel_op_function_selector, main_sel_op_get_contract_instance, main_sel_op_halt, main_sel_op_internal_call, main_sel_op_internal_return, main_sel_op_jump, main_sel_op_jumpi, main_sel_op_keccak, main_sel_op_l1_to_l2_msg_exists, main_sel_op_l2gasleft, main_sel_op_lt, main_sel_op_lte, main_sel_op_mov, main_sel_op_mul, main_sel_op_not, main_sel_op_note_hash_exists, main_sel_op_nullifier_exists, main_sel_op_or, main_sel_op_pedersen, main_sel_op_poseidon2, main_sel_op_radix_le, main_sel_op_sender, main_sel_op_sha256, main_sel_op_shl, main_sel_op_shr, main_sel_op_sload, main_sel_op_sstore, main_sel_op_storage_address, main_sel_op_sub, main_sel_op_timestamp, main_sel_op_transaction_fee, main_sel_op_version, main_sel_op_xor, main_sel_q_kernel_lookup, main_sel_q_kernel_output_lookup, main_sel_resolve_ind_addr_a, main_sel_resolve_ind_addr_b, main_sel_resolve_ind_addr_c, main_sel_resolve_ind_addr_d, main_sel_returndata, main_sel_rng_16, main_sel_rng_8, main_sel_slice_gadget, main_space_id, main_tag_err, main_w_in_tag, mem_addr, mem_clk, mem_diff_hi, mem_diff_lo, mem_diff_mid, mem_glob_addr, mem_last, mem_lastAccess, mem_one_min_inv, mem_r_in_tag, mem_rw, mem_sel_mem, mem_sel_mov_ia_to_ic, mem_sel_mov_ib_to_ic, mem_sel_op_a, mem_sel_op_b, mem_sel_op_c, mem_sel_op_cmov, mem_sel_op_d, mem_sel_op_slice, mem_sel_resolve_ind_addr_a, mem_sel_resolve_ind_addr_b, mem_sel_resolve_ind_addr_c, mem_sel_resolve_ind_addr_d, mem_sel_rng_chk, mem_skip_check_tag, mem_space_id, mem_tag, mem_tag_err, mem_tsp, mem_val, mem_w_in_tag, pedersen_clk, pedersen_input, pedersen_output, pedersen_sel_pedersen, poseidon2_clk, poseidon2_input, poseidon2_output, poseidon2_sel_poseidon_perm, powers_power_of_2, sha256_clk, sha256_input, sha256_output, sha256_sel_sha256_compression, sha256_state, slice_addr, slice_clk, slice_cnt, slice_col_offset, slice_one_min_inv, slice_sel_cd_cpy, slice_sel_mem_active, slice_sel_return, slice_sel_start, slice_space_id, slice_val, lookup_byte_lengths_counts, lookup_byte_operations_counts, lookup_cd_value_counts, lookup_ret_value_counts, lookup_opcode_gas_counts, range_check_l2_gas_hi_counts, range_check_l2_gas_lo_counts, range_check_da_gas_hi_counts, range_check_da_gas_lo_counts, kernel_output_lookup_counts, lookup_into_kernel_counts, incl_main_tag_err_counts, incl_mem_tag_err_counts, lookup_mem_rng_chk_lo_counts, lookup_mem_rng_chk_mid_counts, lookup_mem_rng_chk_hi_counts, lookup_pow_2_0_counts, lookup_pow_2_1_counts, lookup_u8_0_counts, lookup_u8_1_counts, lookup_u16_0_counts, lookup_u16_1_counts, lookup_u16_2_counts, lookup_u16_3_counts, lookup_u16_4_counts, lookup_u16_5_counts, lookup_u16_6_counts, lookup_u16_7_counts, lookup_u16_8_counts, lookup_u16_9_counts, lookup_u16_10_counts, lookup_u16_11_counts, lookup_u16_12_counts, lookup_u16_13_counts, lookup_u16_14_counts, lookup_div_u16_0_counts, lookup_div_u16_1_counts, lookup_div_u16_2_counts, lookup_div_u16_3_counts, lookup_div_u16_4_counts, lookup_div_u16_5_counts, lookup_div_u16_6_counts, lookup_div_u16_7_counts +#define DERIVED_WITNESS_ENTITIES perm_slice_mem, perm_main_alu, perm_main_bin, perm_main_conv, perm_main_pos2_perm, perm_main_pedersen, perm_main_slice, perm_main_mem_a, perm_main_mem_b, perm_main_mem_c, perm_main_mem_d, perm_main_mem_ind_addr_a, perm_main_mem_ind_addr_b, perm_main_mem_ind_addr_c, perm_main_mem_ind_addr_d, lookup_byte_lengths, lookup_byte_operations, lookup_cd_value, lookup_ret_value, lookup_opcode_gas, range_check_l2_gas_hi, range_check_l2_gas_lo, range_check_da_gas_hi, range_check_da_gas_lo, kernel_output_lookup, lookup_into_kernel, incl_main_tag_err, incl_mem_tag_err, lookup_mem_rng_chk_lo, lookup_mem_rng_chk_mid, lookup_mem_rng_chk_hi, lookup_pow_2_0, lookup_pow_2_1, lookup_u8_0, lookup_u8_1, lookup_u16_0, lookup_u16_1, lookup_u16_2, lookup_u16_3, lookup_u16_4, lookup_u16_5, lookup_u16_6, lookup_u16_7, lookup_u16_8, lookup_u16_9, lookup_u16_10, lookup_u16_11, lookup_u16_12, lookup_u16_13, lookup_u16_14, lookup_div_u16_0, lookup_div_u16_1, lookup_div_u16_2, lookup_div_u16_3, lookup_div_u16_4, lookup_div_u16_5, lookup_div_u16_6, lookup_div_u16_7 +#define SHIFTED_ENTITIES alu_a_hi_shift, alu_a_lo_shift, alu_b_hi_shift, alu_b_lo_shift, alu_cmp_rng_ctr_shift, alu_div_u16_r0_shift, alu_div_u16_r1_shift, alu_div_u16_r2_shift, alu_div_u16_r3_shift, alu_div_u16_r4_shift, alu_div_u16_r5_shift, alu_div_u16_r6_shift, alu_div_u16_r7_shift, alu_op_add_shift, alu_op_cast_prev_shift, alu_op_cast_shift, alu_op_div_shift, alu_op_mul_shift, alu_op_shl_shift, alu_op_shr_shift, alu_op_sub_shift, alu_p_sub_a_hi_shift, alu_p_sub_a_lo_shift, alu_p_sub_b_hi_shift, alu_p_sub_b_lo_shift, alu_sel_alu_shift, alu_sel_cmp_shift, alu_sel_div_rng_chk_shift, alu_sel_rng_chk_lookup_shift, alu_sel_rng_chk_shift, alu_u16_r0_shift, alu_u16_r1_shift, alu_u16_r2_shift, alu_u16_r3_shift, alu_u16_r4_shift, alu_u16_r5_shift, alu_u16_r6_shift, alu_u8_r0_shift, alu_u8_r1_shift, binary_acc_ia_shift, binary_acc_ib_shift, binary_acc_ic_shift, binary_mem_tag_ctr_shift, binary_op_id_shift, kernel_emit_l2_to_l1_msg_write_offset_shift, kernel_emit_note_hash_write_offset_shift, kernel_emit_nullifier_write_offset_shift, kernel_emit_unencrypted_log_write_offset_shift, kernel_l1_to_l2_msg_exists_write_offset_shift, kernel_note_hash_exist_write_offset_shift, kernel_nullifier_exists_write_offset_shift, kernel_nullifier_non_exists_write_offset_shift, kernel_side_effect_counter_shift, kernel_sload_write_offset_shift, kernel_sstore_write_offset_shift, main_da_gas_remaining_shift, main_internal_return_ptr_shift, main_l2_gas_remaining_shift, main_pc_shift, mem_glob_addr_shift, mem_rw_shift, mem_sel_mem_shift, mem_tag_shift, mem_tsp_shift, mem_val_shift, slice_addr_shift, slice_clk_shift, slice_cnt_shift, slice_col_offset_shift, slice_sel_cd_cpy_shift, slice_sel_mem_active_shift, slice_sel_return_shift, slice_sel_start_shift, slice_space_id_shift +#define TO_BE_SHIFTED(e) e.alu_a_hi, e.alu_a_lo, e.alu_b_hi, e.alu_b_lo, e.alu_cmp_rng_ctr, e.alu_div_u16_r0, e.alu_div_u16_r1, e.alu_div_u16_r2, e.alu_div_u16_r3, e.alu_div_u16_r4, e.alu_div_u16_r5, e.alu_div_u16_r6, e.alu_div_u16_r7, e.alu_op_add, e.alu_op_cast_prev, e.alu_op_cast, e.alu_op_div, e.alu_op_mul, e.alu_op_shl, e.alu_op_shr, e.alu_op_sub, e.alu_p_sub_a_hi, e.alu_p_sub_a_lo, e.alu_p_sub_b_hi, e.alu_p_sub_b_lo, e.alu_sel_alu, e.alu_sel_cmp, e.alu_sel_div_rng_chk, e.alu_sel_rng_chk_lookup, e.alu_sel_rng_chk, e.alu_u16_r0, e.alu_u16_r1, e.alu_u16_r2, e.alu_u16_r3, e.alu_u16_r4, e.alu_u16_r5, e.alu_u16_r6, e.alu_u8_r0, e.alu_u8_r1, e.binary_acc_ia, e.binary_acc_ib, e.binary_acc_ic, e.binary_mem_tag_ctr, e.binary_op_id, e.kernel_emit_l2_to_l1_msg_write_offset, e.kernel_emit_note_hash_write_offset, e.kernel_emit_nullifier_write_offset, e.kernel_emit_unencrypted_log_write_offset, e.kernel_l1_to_l2_msg_exists_write_offset, e.kernel_note_hash_exist_write_offset, e.kernel_nullifier_exists_write_offset, e.kernel_nullifier_non_exists_write_offset, e.kernel_side_effect_counter, e.kernel_sload_write_offset, e.kernel_sstore_write_offset, e.main_da_gas_remaining, e.main_internal_return_ptr, e.main_l2_gas_remaining, e.main_pc, e.mem_glob_addr, e.mem_rw, e.mem_sel_mem, e.mem_tag, e.mem_tsp, e.mem_val, e.slice_addr, e.slice_clk, e.slice_cnt, e.slice_col_offset, e.slice_sel_cd_cpy, e.slice_sel_mem_active, e.slice_sel_return, e.slice_sel_start, e.slice_space_id +#define ALL_ENTITIES PRECOMPUTED_ENTITIES, WIRE_ENTITIES, DERIVED_WITNESS_ENTITIES, SHIFTED_ENTITIES +// clang-format on + +namespace bb { + +class AvmFlavor { + public: + using Curve = AvmFlavorSettings::Curve; + using G1 = AvmFlavorSettings::G1; + using PCS = AvmFlavorSettings::PCS; + + using FF = AvmFlavorSettings::FF; + using Polynomial = AvmFlavorSettings::Polynomial; + using PolynomialHandle = AvmFlavorSettings::PolynomialHandle; + using GroupElement = AvmFlavorSettings::GroupElement; + using Commitment = AvmFlavorSettings::Commitment; + using CommitmentHandle = AvmFlavorSettings::CommitmentHandle; + using CommitmentKey = AvmFlavorSettings::CommitmentKey; + using VerifierCommitmentKey = AvmFlavorSettings::VerifierCommitmentKey; + using RelationSeparator = AvmFlavorSettings::RelationSeparator; + + static constexpr size_t NUM_PRECOMPUTED_ENTITIES = 2; +<<<<<<< HEAD + static constexpr size_t NUM_WITNESS_ENTITIES = 409; + static constexpr size_t NUM_WIRES = NUM_WITNESS_ENTITIES + NUM_PRECOMPUTED_ENTITIES; + // We have two copies of the witness entities, so we subtract the number of fixed ones (they have no shift), one for + // the unshifted and one for the shifted + static constexpr size_t NUM_ALL_ENTITIES = 485; +======= +<<<<<<< HEAD + static constexpr size_t NUM_WITNESS_ENTITIES = 385; + static constexpr size_t NUM_WIRES = NUM_WITNESS_ENTITIES + NUM_PRECOMPUTED_ENTITIES; + // We have two copies of the witness entities, so we subtract the number of fixed ones (they have no shift), one for + // the unshifted and one for the shifted + static constexpr size_t NUM_ALL_ENTITIES = 452; +======= +<<<<<<< HEAD + static constexpr size_t NUM_WITNESS_ENTITIES = 384; + static constexpr size_t NUM_WIRES = NUM_WITNESS_ENTITIES + NUM_PRECOMPUTED_ENTITIES; + // We have two copies of the witness entities, so we subtract the number of fixed ones (they have no shift), one for + // the unshifted and one for the shifted + static constexpr size_t NUM_ALL_ENTITIES = 451; +======= + static constexpr size_t NUM_WITNESS_ENTITIES = 391; + static constexpr size_t NUM_WIRES = NUM_WITNESS_ENTITIES + NUM_PRECOMPUTED_ENTITIES; + // We have two copies of the witness entities, so we subtract the number of fixed ones (they have no shift), one for + // the unshifted and one for the shifted + static constexpr size_t NUM_ALL_ENTITIES = 458; +>>>>>>> 91347fba1 (feat(avm): poseidon2 constraints) +>>>>>>> dfd3ca77d (feat(avm): poseidon2 constraints) +>>>>>>> 804a62263 (feat(avm): poseidon2 constraints) + + using MainRelations = std::tuple< + // Relations + Avm_vm::alu, + Avm_vm::binary, + Avm_vm::conversion, + Avm_vm::gas, + Avm_vm::keccakf1600, + Avm_vm::kernel, + Avm_vm::main, + Avm_vm::mem, + Avm_vm::mem_slice, + Avm_vm::pedersen, + Avm_vm::poseidon2, + Avm_vm::powers, + Avm_vm::sha256>; + + using LookupRelations = std::tuple< + // Lookups + perm_slice_mem_relation, + perm_main_alu_relation, + perm_main_bin_relation, + perm_main_conv_relation, + perm_main_pos2_perm_relation, + perm_main_pedersen_relation, + perm_main_slice_relation, + perm_main_mem_a_relation, + perm_main_mem_b_relation, + perm_main_mem_c_relation, + perm_main_mem_d_relation, + perm_main_mem_ind_addr_a_relation, + perm_main_mem_ind_addr_b_relation, + perm_main_mem_ind_addr_c_relation, + perm_main_mem_ind_addr_d_relation, + lookup_byte_lengths_relation, + lookup_byte_operations_relation, + lookup_cd_value_relation, + lookup_ret_value_relation, + lookup_opcode_gas_relation, + range_check_l2_gas_hi_relation, + range_check_l2_gas_lo_relation, + range_check_da_gas_hi_relation, + range_check_da_gas_lo_relation, + kernel_output_lookup_relation, + lookup_into_kernel_relation, + incl_main_tag_err_relation, + incl_mem_tag_err_relation, + lookup_mem_rng_chk_lo_relation, + lookup_mem_rng_chk_mid_relation, + lookup_mem_rng_chk_hi_relation, + lookup_pow_2_0_relation, + lookup_pow_2_1_relation, + lookup_u8_0_relation, + lookup_u8_1_relation, + lookup_u16_0_relation, + lookup_u16_1_relation, + lookup_u16_2_relation, + lookup_u16_3_relation, + lookup_u16_4_relation, + lookup_u16_5_relation, + lookup_u16_6_relation, + lookup_u16_7_relation, + lookup_u16_8_relation, + lookup_u16_9_relation, + lookup_u16_10_relation, + lookup_u16_11_relation, + lookup_u16_12_relation, + lookup_u16_13_relation, + lookup_u16_14_relation, + lookup_div_u16_0_relation, + lookup_div_u16_1_relation, + lookup_div_u16_2_relation, + lookup_div_u16_3_relation, + lookup_div_u16_4_relation, + lookup_div_u16_5_relation, + lookup_div_u16_6_relation, + lookup_div_u16_7_relation>; + + using Relations = tuple_cat_t; + + static constexpr size_t MAX_PARTIAL_RELATION_LENGTH = compute_max_partial_relation_length(); + + // BATCHED_RELATION_PARTIAL_LENGTH = algebraic degree of sumcheck relation *after* multiplying by the `pow_zeta` + // random polynomial e.g. For \sum(x) [A(x) * B(x) + C(x)] * PowZeta(X), relation length = 2 and random relation + // length = 3 + static constexpr size_t BATCHED_RELATION_PARTIAL_LENGTH = MAX_PARTIAL_RELATION_LENGTH + 1; + static constexpr size_t NUM_RELATIONS = std::tuple_size_v; + + template + using ProtogalaxyTupleOfTuplesOfUnivariates = + decltype(create_protogalaxy_tuple_of_tuples_of_univariates()); + using SumcheckTupleOfTuplesOfUnivariates = decltype(create_sumcheck_tuple_of_tuples_of_univariates()); + using TupleOfArraysOfValues = decltype(create_tuple_of_arrays_of_values()); + + static constexpr bool has_zero_row = true; + + private: + template class PrecomputedEntities : public PrecomputedEntitiesBase { + public: + using DataType = DataType_; + + DEFINE_FLAVOR_MEMBERS(DataType, PRECOMPUTED_ENTITIES) + + RefVector get_selectors() { return get_all(); } + RefVector get_sigma_polynomials() { return {}; } + RefVector get_id_polynomials() { return {}; } + RefVector get_table_polynomials() { return {}; } + }; + + template class WireEntities { + public: +<<<<<<< HEAD + DEFINE_FLAVOR_MEMBERS(DataType, WIRE_ENTITIES) +======= + DEFINE_FLAVOR_MEMBERS(DataType, + kernel_kernel_inputs, + kernel_kernel_value_out, + kernel_kernel_side_effect_out, + kernel_kernel_metadata_out, + main_calldata, + alu_a_hi, + alu_a_lo, + alu_b_hi, + alu_b_lo, + alu_borrow, + alu_cf, + alu_clk, + alu_cmp_rng_ctr, + alu_div_u16_r0, + alu_div_u16_r1, + alu_div_u16_r2, + alu_div_u16_r3, + alu_div_u16_r4, + alu_div_u16_r5, + alu_div_u16_r6, + alu_div_u16_r7, + alu_divisor_hi, + alu_divisor_lo, + alu_ff_tag, + alu_ia, + alu_ib, + alu_ic, + alu_in_tag, + alu_op_add, + alu_op_cast, + alu_op_cast_prev, + alu_op_div, + alu_op_div_a_lt_b, + alu_op_div_std, + alu_op_eq, + alu_op_eq_diff_inv, + alu_op_lt, + alu_op_lte, + alu_op_mul, + alu_op_not, + alu_op_shl, + alu_op_shr, + alu_op_sub, + alu_p_a_borrow, + alu_p_b_borrow, + alu_p_sub_a_hi, + alu_p_sub_a_lo, + alu_p_sub_b_hi, + alu_p_sub_b_lo, + alu_partial_prod_hi, + alu_partial_prod_lo, + alu_quotient_hi, + alu_quotient_lo, + alu_remainder, + alu_res_hi, + alu_res_lo, + alu_sel_alu, + alu_sel_cmp, + alu_sel_div_rng_chk, + alu_sel_rng_chk, + alu_sel_rng_chk_lookup, + alu_sel_shift_which, + alu_shift_lt_bit_len, + alu_t_sub_s_bits, + alu_two_pow_s, + alu_two_pow_t_sub_s, + alu_u128_tag, + alu_u16_r0, + alu_u16_r1, + alu_u16_r10, + alu_u16_r11, + alu_u16_r12, + alu_u16_r13, + alu_u16_r14, + alu_u16_r2, + alu_u16_r3, + alu_u16_r4, + alu_u16_r5, + alu_u16_r6, + alu_u16_r7, + alu_u16_r8, + alu_u16_r9, + alu_u16_tag, + alu_u32_tag, + alu_u64_tag, + alu_u8_r0, + alu_u8_r1, + alu_u8_tag, + binary_acc_ia, + binary_acc_ib, + binary_acc_ic, + binary_clk, + binary_ia_bytes, + binary_ib_bytes, + binary_ic_bytes, + binary_in_tag, + binary_mem_tag_ctr, + binary_mem_tag_ctr_inv, + binary_op_id, + binary_sel_bin, + binary_start, + byte_lookup_sel_bin, + byte_lookup_table_byte_lengths, + byte_lookup_table_in_tags, + byte_lookup_table_input_a, + byte_lookup_table_input_b, + byte_lookup_table_op_id, + byte_lookup_table_output, + conversion_clk, + conversion_input, + conversion_num_limbs, + conversion_radix, + conversion_sel_to_radix_le, + gas_da_gas_fixed_table, + gas_l2_gas_fixed_table, + gas_sel_gas_cost, + keccakf1600_clk, + keccakf1600_input, + keccakf1600_output, + keccakf1600_sel_keccakf1600, + kernel_emit_l2_to_l1_msg_write_offset, + kernel_emit_note_hash_write_offset, + kernel_emit_nullifier_write_offset, + kernel_emit_unencrypted_log_write_offset, + kernel_kernel_in_offset, + kernel_kernel_out_offset, + kernel_l1_to_l2_msg_exists_write_offset, + kernel_note_hash_exist_write_offset, + kernel_nullifier_exists_write_offset, + kernel_nullifier_non_exists_write_offset, + kernel_q_public_input_kernel_add_to_table, + kernel_q_public_input_kernel_out_add_to_table, + kernel_side_effect_counter, + kernel_sload_write_offset, + kernel_sstore_write_offset, + main_abs_da_rem_gas_hi, + main_abs_da_rem_gas_lo, + main_abs_l2_rem_gas_hi, + main_abs_l2_rem_gas_lo, + main_alu_in_tag, + main_bin_op_id, + main_call_ptr, + main_da_gas_op_cost, + main_da_gas_remaining, + main_da_out_of_gas, + main_ia, + main_ib, + main_ic, + main_id, + main_id_zero, + main_ind_addr_a, + main_ind_addr_b, + main_ind_addr_c, + main_ind_addr_d, + main_internal_return_ptr, + main_inv, + main_l2_gas_op_cost, + main_l2_gas_remaining, + main_l2_out_of_gas, + main_mem_addr_a, + main_mem_addr_b, + main_mem_addr_c, + main_mem_addr_d, + main_op_err, + main_opcode_val, + main_pc, + main_r_in_tag, + main_rwa, + main_rwb, + main_rwc, + main_rwd, + main_sel_alu, + main_sel_bin, + main_sel_gas_accounting_active, + main_sel_last, + main_sel_mem_op_a, + main_sel_mem_op_activate_gas, + main_sel_mem_op_b, + main_sel_mem_op_c, + main_sel_mem_op_d, + main_sel_mov_ia_to_ic, + main_sel_mov_ib_to_ic, + main_sel_op_add, + main_sel_op_address, + main_sel_op_and, + main_sel_op_block_number, + main_sel_op_cast, + main_sel_op_chain_id, + main_sel_op_cmov, + main_sel_op_coinbase, + main_sel_op_dagasleft, + main_sel_op_div, + main_sel_op_emit_l2_to_l1_msg, + main_sel_op_emit_note_hash, + main_sel_op_emit_nullifier, + main_sel_op_emit_unencrypted_log, + main_sel_op_eq, + main_sel_op_external_call, + main_sel_op_fdiv, + main_sel_op_fee_per_da_gas, + main_sel_op_fee_per_l2_gas, + main_sel_op_function_selector, + main_sel_op_get_contract_instance, + main_sel_op_halt, + main_sel_op_internal_call, + main_sel_op_internal_return, + main_sel_op_jump, + main_sel_op_jumpi, + main_sel_op_keccak, + main_sel_op_l1_to_l2_msg_exists, + main_sel_op_l2gasleft, + main_sel_op_lt, + main_sel_op_lte, + main_sel_op_mov, + main_sel_op_mul, + main_sel_op_not, + main_sel_op_note_hash_exists, + main_sel_op_nullifier_exists, + main_sel_op_or, + main_sel_op_pedersen, + main_sel_op_poseidon2, + main_sel_op_radix_le, + main_sel_op_sender, + main_sel_op_sha256, + main_sel_op_shl, + main_sel_op_shr, + main_sel_op_sload, + main_sel_op_sstore, + main_sel_op_storage_address, + main_sel_op_sub, + main_sel_op_timestamp, + main_sel_op_transaction_fee, + main_sel_op_version, + main_sel_op_xor, + main_sel_q_kernel_lookup, + main_sel_q_kernel_output_lookup, + main_sel_resolve_ind_addr_a, + main_sel_resolve_ind_addr_b, + main_sel_resolve_ind_addr_c, + main_sel_resolve_ind_addr_d, + main_sel_rng_16, + main_sel_rng_8, + main_space_id, + main_tag_err, + main_w_in_tag, + mem_addr, + mem_clk, + mem_diff_hi, + mem_diff_lo, + mem_diff_mid, + mem_glob_addr, + mem_last, + mem_lastAccess, + mem_one_min_inv, + mem_r_in_tag, + mem_rw, + mem_sel_mem, + mem_sel_mov_ia_to_ic, + mem_sel_mov_ib_to_ic, + mem_sel_op_a, + mem_sel_op_b, + mem_sel_op_c, + mem_sel_op_cmov, + mem_sel_op_d, + mem_sel_resolve_ind_addr_a, + mem_sel_resolve_ind_addr_b, + mem_sel_resolve_ind_addr_c, + mem_sel_resolve_ind_addr_d, + mem_sel_rng_chk, + mem_skip_check_tag, + mem_space_id, + mem_tag, + mem_tag_err, + mem_tsp, + mem_val, + mem_w_in_tag, + pedersen_clk, + pedersen_input, + pedersen_output, + pedersen_sel_pedersen, + poseidon2_a_0, + poseidon2_a_1, + poseidon2_a_2, + poseidon2_a_3, + poseidon2_b_0, + poseidon2_b_1, + poseidon2_b_2, + poseidon2_b_3, + poseidon2_clk, + poseidon2_input, + poseidon2_output, + poseidon2_sel_poseidon_perm, + powers_power_of_2, + sha256_clk, + sha256_input, + sha256_output, + sha256_sel_sha256_compression, + sha256_state, + lookup_byte_lengths_counts, + lookup_byte_operations_counts, + lookup_opcode_gas_counts, + range_check_l2_gas_hi_counts, + range_check_l2_gas_lo_counts, + range_check_da_gas_hi_counts, + range_check_da_gas_lo_counts, + kernel_output_lookup_counts, + lookup_into_kernel_counts, + incl_main_tag_err_counts, + incl_mem_tag_err_counts, + lookup_mem_rng_chk_lo_counts, + lookup_mem_rng_chk_mid_counts, + lookup_mem_rng_chk_hi_counts, + lookup_pow_2_0_counts, + lookup_pow_2_1_counts, + lookup_u8_0_counts, + lookup_u8_1_counts, + lookup_u16_0_counts, + lookup_u16_1_counts, + lookup_u16_2_counts, + lookup_u16_3_counts, + lookup_u16_4_counts, + lookup_u16_5_counts, + lookup_u16_6_counts, + lookup_u16_7_counts, + lookup_u16_8_counts, + lookup_u16_9_counts, + lookup_u16_10_counts, + lookup_u16_11_counts, + lookup_u16_12_counts, + lookup_u16_13_counts, + lookup_u16_14_counts, + lookup_div_u16_0_counts, + lookup_div_u16_1_counts, + lookup_div_u16_2_counts, + lookup_div_u16_3_counts, + lookup_div_u16_4_counts, + lookup_div_u16_5_counts, + lookup_div_u16_6_counts, + lookup_div_u16_7_counts) +<<<<<<< HEAD +======= + + RefVector get_wires() + { + return { kernel_kernel_inputs, + kernel_kernel_value_out, + kernel_kernel_side_effect_out, + kernel_kernel_metadata_out, + main_calldata, + alu_a_hi, + alu_a_lo, + alu_b_hi, + alu_b_lo, + alu_borrow, + alu_cf, + alu_clk, + alu_cmp_rng_ctr, + alu_div_u16_r0, + alu_div_u16_r1, + alu_div_u16_r2, + alu_div_u16_r3, + alu_div_u16_r4, + alu_div_u16_r5, + alu_div_u16_r6, + alu_div_u16_r7, + alu_divisor_hi, + alu_divisor_lo, + alu_ff_tag, + alu_ia, + alu_ib, + alu_ic, + alu_in_tag, + alu_op_add, + alu_op_cast, + alu_op_cast_prev, + alu_op_div, + alu_op_div_a_lt_b, + alu_op_div_std, + alu_op_eq, + alu_op_eq_diff_inv, + alu_op_lt, + alu_op_lte, + alu_op_mul, + alu_op_not, + alu_op_shl, + alu_op_shr, + alu_op_sub, + alu_p_a_borrow, + alu_p_b_borrow, + alu_p_sub_a_hi, + alu_p_sub_a_lo, + alu_p_sub_b_hi, + alu_p_sub_b_lo, + alu_partial_prod_hi, + alu_partial_prod_lo, + alu_quotient_hi, + alu_quotient_lo, + alu_remainder, + alu_res_hi, + alu_res_lo, + alu_sel_alu, + alu_sel_cmp, + alu_sel_div_rng_chk, + alu_sel_rng_chk, + alu_sel_rng_chk_lookup, + alu_sel_shift_which, + alu_shift_lt_bit_len, + alu_t_sub_s_bits, + alu_two_pow_s, + alu_two_pow_t_sub_s, + alu_u128_tag, + alu_u16_r0, + alu_u16_r1, + alu_u16_r10, + alu_u16_r11, + alu_u16_r12, + alu_u16_r13, + alu_u16_r14, + alu_u16_r2, + alu_u16_r3, + alu_u16_r4, + alu_u16_r5, + alu_u16_r6, + alu_u16_r7, + alu_u16_r8, + alu_u16_r9, + alu_u16_tag, + alu_u32_tag, + alu_u64_tag, + alu_u8_r0, + alu_u8_r1, + alu_u8_tag, + binary_acc_ia, + binary_acc_ib, + binary_acc_ic, + binary_clk, + binary_ia_bytes, + binary_ib_bytes, + binary_ic_bytes, + binary_in_tag, + binary_mem_tag_ctr, + binary_mem_tag_ctr_inv, + binary_op_id, + binary_sel_bin, + binary_start, + byte_lookup_sel_bin, + byte_lookup_table_byte_lengths, + byte_lookup_table_in_tags, + byte_lookup_table_input_a, + byte_lookup_table_input_b, + byte_lookup_table_op_id, + byte_lookup_table_output, + conversion_clk, + conversion_input, + conversion_num_limbs, + conversion_radix, + conversion_sel_to_radix_le, + gas_da_gas_fixed_table, + gas_l2_gas_fixed_table, + gas_sel_gas_cost, + keccakf1600_clk, + keccakf1600_input, + keccakf1600_output, + keccakf1600_sel_keccakf1600, + kernel_emit_l2_to_l1_msg_write_offset, + kernel_emit_note_hash_write_offset, + kernel_emit_nullifier_write_offset, + kernel_emit_unencrypted_log_write_offset, + kernel_kernel_in_offset, + kernel_kernel_out_offset, + kernel_l1_to_l2_msg_exists_write_offset, + kernel_note_hash_exist_write_offset, + kernel_nullifier_exists_write_offset, + kernel_nullifier_non_exists_write_offset, + kernel_q_public_input_kernel_add_to_table, + kernel_q_public_input_kernel_out_add_to_table, + kernel_side_effect_counter, + kernel_sload_write_offset, + kernel_sstore_write_offset, + main_abs_da_rem_gas_hi, + main_abs_da_rem_gas_lo, + main_abs_l2_rem_gas_hi, + main_abs_l2_rem_gas_lo, + main_alu_in_tag, + main_bin_op_id, + main_call_ptr, + main_da_gas_op_cost, + main_da_gas_remaining, + main_da_out_of_gas, + main_ia, + main_ib, + main_ic, + main_id, + main_id_zero, + main_ind_addr_a, + main_ind_addr_b, + main_ind_addr_c, + main_ind_addr_d, + main_internal_return_ptr, + main_inv, + main_l2_gas_op_cost, + main_l2_gas_remaining, + main_l2_out_of_gas, + main_mem_addr_a, + main_mem_addr_b, + main_mem_addr_c, + main_mem_addr_d, + main_op_err, + main_opcode_val, + main_pc, + main_r_in_tag, + main_rwa, + main_rwb, + main_rwc, + main_rwd, + main_sel_alu, + main_sel_bin, + main_sel_gas_accounting_active, + main_sel_last, + main_sel_mem_op_a, + main_sel_mem_op_activate_gas, + main_sel_mem_op_b, + main_sel_mem_op_c, + main_sel_mem_op_d, + main_sel_mov_ia_to_ic, + main_sel_mov_ib_to_ic, + main_sel_op_add, + main_sel_op_address, + main_sel_op_and, + main_sel_op_block_number, + main_sel_op_cast, + main_sel_op_chain_id, + main_sel_op_cmov, + main_sel_op_coinbase, + main_sel_op_dagasleft, + main_sel_op_div, + main_sel_op_emit_l2_to_l1_msg, + main_sel_op_emit_note_hash, + main_sel_op_emit_nullifier, + main_sel_op_emit_unencrypted_log, + main_sel_op_eq, + main_sel_op_external_call, + main_sel_op_fdiv, + main_sel_op_fee_per_da_gas, + main_sel_op_fee_per_l2_gas, + main_sel_op_function_selector, + main_sel_op_get_contract_instance, + main_sel_op_halt, + main_sel_op_internal_call, + main_sel_op_internal_return, + main_sel_op_jump, + main_sel_op_jumpi, + main_sel_op_keccak, + main_sel_op_l1_to_l2_msg_exists, + main_sel_op_l2gasleft, + main_sel_op_lt, + main_sel_op_lte, + main_sel_op_mov, + main_sel_op_mul, + main_sel_op_not, + main_sel_op_note_hash_exists, + main_sel_op_nullifier_exists, + main_sel_op_or, + main_sel_op_pedersen, + main_sel_op_poseidon2, + main_sel_op_radix_le, + main_sel_op_sender, + main_sel_op_sha256, + main_sel_op_shl, + main_sel_op_shr, + main_sel_op_sload, + main_sel_op_sstore, + main_sel_op_storage_address, + main_sel_op_sub, + main_sel_op_timestamp, + main_sel_op_transaction_fee, + main_sel_op_version, + main_sel_op_xor, + main_sel_q_kernel_lookup, + main_sel_q_kernel_output_lookup, + main_sel_resolve_ind_addr_a, + main_sel_resolve_ind_addr_b, + main_sel_resolve_ind_addr_c, + main_sel_resolve_ind_addr_d, + main_sel_rng_16, + main_sel_rng_8, + main_space_id, + main_tag_err, + main_w_in_tag, + mem_addr, + mem_clk, + mem_diff_hi, + mem_diff_lo, + mem_diff_mid, + mem_glob_addr, + mem_last, + mem_lastAccess, + mem_one_min_inv, + mem_r_in_tag, + mem_rw, + mem_sel_mem, + mem_sel_mov_ia_to_ic, + mem_sel_mov_ib_to_ic, + mem_sel_op_a, + mem_sel_op_b, + mem_sel_op_c, + mem_sel_op_cmov, + mem_sel_op_d, + mem_sel_resolve_ind_addr_a, + mem_sel_resolve_ind_addr_b, + mem_sel_resolve_ind_addr_c, + mem_sel_resolve_ind_addr_d, + mem_sel_rng_chk, + mem_skip_check_tag, + mem_space_id, + mem_tag, + mem_tag_err, + mem_tsp, + mem_val, + mem_w_in_tag, + pedersen_clk, + pedersen_input, + pedersen_output, + pedersen_sel_pedersen, + poseidon2_a_0, + poseidon2_a_1, + poseidon2_a_2, + poseidon2_a_3, + poseidon2_b_0, + poseidon2_b_1, + poseidon2_b_2, + poseidon2_b_3, + poseidon2_clk, + poseidon2_input, + poseidon2_output, + poseidon2_sel_poseidon_perm, + powers_power_of_2, + sha256_clk, + sha256_input, + sha256_output, + sha256_sel_sha256_compression, + sha256_state, + perm_main_alu, + perm_main_bin, + perm_main_conv, + perm_main_pos2_perm, + perm_main_pedersen, + perm_main_mem_a, + perm_main_mem_b, + perm_main_mem_c, + perm_main_mem_d, + perm_main_mem_ind_addr_a, + perm_main_mem_ind_addr_b, + perm_main_mem_ind_addr_c, + perm_main_mem_ind_addr_d, + lookup_byte_lengths, + lookup_byte_operations, + lookup_opcode_gas, + range_check_l2_gas_hi, + range_check_l2_gas_lo, + range_check_da_gas_hi, + range_check_da_gas_lo, + kernel_output_lookup, + lookup_into_kernel, + incl_main_tag_err, + incl_mem_tag_err, + lookup_mem_rng_chk_lo, + lookup_mem_rng_chk_mid, + lookup_mem_rng_chk_hi, + lookup_pow_2_0, + lookup_pow_2_1, + lookup_u8_0, + lookup_u8_1, + lookup_u16_0, + lookup_u16_1, + lookup_u16_2, + lookup_u16_3, + lookup_u16_4, + lookup_u16_5, + lookup_u16_6, + lookup_u16_7, + lookup_u16_8, + lookup_u16_9, + lookup_u16_10, + lookup_u16_11, + lookup_u16_12, + lookup_u16_13, + lookup_u16_14, + lookup_div_u16_0, + lookup_div_u16_1, + lookup_div_u16_2, + lookup_div_u16_3, + lookup_div_u16_4, + lookup_div_u16_5, + lookup_div_u16_6, + lookup_div_u16_7, + lookup_byte_lengths_counts, + lookup_byte_operations_counts, + lookup_opcode_gas_counts, + range_check_l2_gas_hi_counts, + range_check_l2_gas_lo_counts, + range_check_da_gas_hi_counts, + range_check_da_gas_lo_counts, + kernel_output_lookup_counts, + lookup_into_kernel_counts, + incl_main_tag_err_counts, + incl_mem_tag_err_counts, + lookup_mem_rng_chk_lo_counts, + lookup_mem_rng_chk_mid_counts, + lookup_mem_rng_chk_hi_counts, + lookup_pow_2_0_counts, + lookup_pow_2_1_counts, + lookup_u8_0_counts, + lookup_u8_1_counts, + lookup_u16_0_counts, + lookup_u16_1_counts, + lookup_u16_2_counts, + lookup_u16_3_counts, + lookup_u16_4_counts, + lookup_u16_5_counts, + lookup_u16_6_counts, + lookup_u16_7_counts, + lookup_u16_8_counts, + lookup_u16_9_counts, + lookup_u16_10_counts, + lookup_u16_11_counts, + lookup_u16_12_counts, + lookup_u16_13_counts, + lookup_u16_14_counts, + lookup_div_u16_0_counts, + lookup_div_u16_1_counts, + lookup_div_u16_2_counts, + lookup_div_u16_3_counts, + lookup_div_u16_4_counts, + lookup_div_u16_5_counts, + lookup_div_u16_6_counts, + lookup_div_u16_7_counts }; + }; +>>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) +>>>>>>> 804a62263 (feat(avm): poseidon2 constraints) + }; + + template class DerivedWitnessEntities { + public: +<<<<<<< HEAD + DEFINE_FLAVOR_MEMBERS(DataType, DERIVED_WITNESS_ENTITIES) +======= + DEFINE_FLAVOR_MEMBERS(DataType, +<<<<<<< HEAD +======= + main_clk, + main_sel_first, + kernel_kernel_inputs, + kernel_kernel_value_out, + kernel_kernel_side_effect_out, + kernel_kernel_metadata_out, + main_calldata, + alu_a_hi, + alu_a_lo, + alu_b_hi, + alu_b_lo, + alu_borrow, + alu_cf, + alu_clk, + alu_cmp_rng_ctr, + alu_div_u16_r0, + alu_div_u16_r1, + alu_div_u16_r2, + alu_div_u16_r3, + alu_div_u16_r4, + alu_div_u16_r5, + alu_div_u16_r6, + alu_div_u16_r7, + alu_divisor_hi, + alu_divisor_lo, + alu_ff_tag, + alu_ia, + alu_ib, + alu_ic, + alu_in_tag, + alu_op_add, + alu_op_cast, + alu_op_cast_prev, + alu_op_div, + alu_op_div_a_lt_b, + alu_op_div_std, + alu_op_eq, + alu_op_eq_diff_inv, + alu_op_lt, + alu_op_lte, + alu_op_mul, + alu_op_not, + alu_op_shl, + alu_op_shr, + alu_op_sub, + alu_p_a_borrow, + alu_p_b_borrow, + alu_p_sub_a_hi, + alu_p_sub_a_lo, + alu_p_sub_b_hi, + alu_p_sub_b_lo, + alu_partial_prod_hi, + alu_partial_prod_lo, + alu_quotient_hi, + alu_quotient_lo, + alu_remainder, + alu_res_hi, + alu_res_lo, + alu_sel_alu, + alu_sel_cmp, + alu_sel_div_rng_chk, + alu_sel_rng_chk, + alu_sel_rng_chk_lookup, + alu_sel_shift_which, + alu_shift_lt_bit_len, + alu_t_sub_s_bits, + alu_two_pow_s, + alu_two_pow_t_sub_s, + alu_u128_tag, + alu_u16_r0, + alu_u16_r1, + alu_u16_r10, + alu_u16_r11, + alu_u16_r12, + alu_u16_r13, + alu_u16_r14, + alu_u16_r2, + alu_u16_r3, + alu_u16_r4, + alu_u16_r5, + alu_u16_r6, + alu_u16_r7, + alu_u16_r8, + alu_u16_r9, + alu_u16_tag, + alu_u32_tag, + alu_u64_tag, + alu_u8_r0, + alu_u8_r1, + alu_u8_tag, + binary_acc_ia, + binary_acc_ib, + binary_acc_ic, + binary_clk, + binary_ia_bytes, + binary_ib_bytes, + binary_ic_bytes, + binary_in_tag, + binary_mem_tag_ctr, + binary_mem_tag_ctr_inv, + binary_op_id, + binary_sel_bin, + binary_start, + byte_lookup_sel_bin, + byte_lookup_table_byte_lengths, + byte_lookup_table_in_tags, + byte_lookup_table_input_a, + byte_lookup_table_input_b, + byte_lookup_table_op_id, + byte_lookup_table_output, + conversion_clk, + conversion_input, + conversion_num_limbs, + conversion_radix, + conversion_sel_to_radix_le, + gas_da_gas_fixed_table, + gas_l2_gas_fixed_table, + gas_sel_gas_cost, + keccakf1600_clk, + keccakf1600_input, + keccakf1600_output, + keccakf1600_sel_keccakf1600, + kernel_emit_l2_to_l1_msg_write_offset, + kernel_emit_note_hash_write_offset, + kernel_emit_nullifier_write_offset, + kernel_emit_unencrypted_log_write_offset, + kernel_kernel_in_offset, + kernel_kernel_out_offset, + kernel_l1_to_l2_msg_exists_write_offset, + kernel_note_hash_exist_write_offset, + kernel_nullifier_exists_write_offset, + kernel_nullifier_non_exists_write_offset, + kernel_q_public_input_kernel_add_to_table, + kernel_q_public_input_kernel_out_add_to_table, + kernel_side_effect_counter, + kernel_sload_write_offset, + kernel_sstore_write_offset, + main_abs_da_rem_gas_hi, + main_abs_da_rem_gas_lo, + main_abs_l2_rem_gas_hi, + main_abs_l2_rem_gas_lo, + main_alu_in_tag, + main_bin_op_id, + main_call_ptr, + main_da_gas_op_cost, + main_da_gas_remaining, + main_da_out_of_gas, + main_ia, + main_ib, + main_ic, + main_id, + main_id_zero, + main_ind_addr_a, + main_ind_addr_b, + main_ind_addr_c, + main_ind_addr_d, + main_internal_return_ptr, + main_inv, + main_l2_gas_op_cost, + main_l2_gas_remaining, + main_l2_out_of_gas, + main_mem_addr_a, + main_mem_addr_b, + main_mem_addr_c, + main_mem_addr_d, + main_op_err, + main_opcode_val, + main_pc, + main_r_in_tag, + main_rwa, + main_rwb, + main_rwc, + main_rwd, + main_sel_alu, + main_sel_bin, + main_sel_gas_accounting_active, + main_sel_last, + main_sel_mem_op_a, + main_sel_mem_op_activate_gas, + main_sel_mem_op_b, + main_sel_mem_op_c, + main_sel_mem_op_d, + main_sel_mov_ia_to_ic, + main_sel_mov_ib_to_ic, + main_sel_op_add, + main_sel_op_address, + main_sel_op_and, + main_sel_op_block_number, + main_sel_op_cast, + main_sel_op_chain_id, + main_sel_op_cmov, + main_sel_op_coinbase, + main_sel_op_dagasleft, + main_sel_op_div, + main_sel_op_emit_l2_to_l1_msg, + main_sel_op_emit_note_hash, + main_sel_op_emit_nullifier, + main_sel_op_emit_unencrypted_log, + main_sel_op_eq, + main_sel_op_external_call, + main_sel_op_fdiv, + main_sel_op_fee_per_da_gas, + main_sel_op_fee_per_l2_gas, + main_sel_op_function_selector, + main_sel_op_get_contract_instance, + main_sel_op_halt, + main_sel_op_internal_call, + main_sel_op_internal_return, + main_sel_op_jump, + main_sel_op_jumpi, + main_sel_op_keccak, + main_sel_op_l1_to_l2_msg_exists, + main_sel_op_l2gasleft, + main_sel_op_lt, + main_sel_op_lte, + main_sel_op_mov, + main_sel_op_mul, + main_sel_op_not, + main_sel_op_note_hash_exists, + main_sel_op_nullifier_exists, + main_sel_op_or, + main_sel_op_pedersen, + main_sel_op_poseidon2, + main_sel_op_radix_le, + main_sel_op_sender, + main_sel_op_sha256, + main_sel_op_shl, + main_sel_op_shr, + main_sel_op_sload, + main_sel_op_sstore, + main_sel_op_storage_address, + main_sel_op_sub, + main_sel_op_timestamp, + main_sel_op_transaction_fee, + main_sel_op_version, + main_sel_op_xor, + main_sel_q_kernel_lookup, + main_sel_q_kernel_output_lookup, + main_sel_resolve_ind_addr_a, + main_sel_resolve_ind_addr_b, + main_sel_resolve_ind_addr_c, + main_sel_resolve_ind_addr_d, + main_sel_rng_16, + main_sel_rng_8, + main_space_id, + main_tag_err, + main_w_in_tag, + mem_addr, + mem_clk, + mem_diff_hi, + mem_diff_lo, + mem_diff_mid, + mem_glob_addr, + mem_last, + mem_lastAccess, + mem_one_min_inv, + mem_r_in_tag, + mem_rw, + mem_sel_mem, + mem_sel_mov_ia_to_ic, + mem_sel_mov_ib_to_ic, + mem_sel_op_a, + mem_sel_op_b, + mem_sel_op_c, + mem_sel_op_cmov, + mem_sel_op_d, + mem_sel_resolve_ind_addr_a, + mem_sel_resolve_ind_addr_b, + mem_sel_resolve_ind_addr_c, + mem_sel_resolve_ind_addr_d, + mem_sel_rng_chk, + mem_skip_check_tag, + mem_space_id, + mem_tag, + mem_tag_err, + mem_tsp, + mem_val, + mem_w_in_tag, + pedersen_clk, + pedersen_input, + pedersen_output, + pedersen_sel_pedersen, + poseidon2_a_0, + poseidon2_a_1, + poseidon2_a_2, + poseidon2_a_3, + poseidon2_b_0, + poseidon2_b_1, + poseidon2_b_2, + poseidon2_b_3, + poseidon2_clk, + poseidon2_input, + poseidon2_output, + poseidon2_sel_poseidon_perm, + powers_power_of_2, + sha256_clk, + sha256_input, + sha256_output, + sha256_sel_sha256_compression, + sha256_state, +>>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) + perm_main_alu, + perm_main_bin, + perm_main_conv, + perm_main_pos2_perm, + perm_main_pedersen, + perm_main_mem_a, + perm_main_mem_b, + perm_main_mem_c, + perm_main_mem_d, + perm_main_mem_ind_addr_a, + perm_main_mem_ind_addr_b, + perm_main_mem_ind_addr_c, + perm_main_mem_ind_addr_d, + lookup_byte_lengths, + lookup_byte_operations, + lookup_opcode_gas, + range_check_l2_gas_hi, + range_check_l2_gas_lo, + range_check_da_gas_hi, + range_check_da_gas_lo, + kernel_output_lookup, + lookup_into_kernel, + incl_main_tag_err, + incl_mem_tag_err, + lookup_mem_rng_chk_lo, + lookup_mem_rng_chk_mid, + lookup_mem_rng_chk_hi, + lookup_pow_2_0, + lookup_pow_2_1, + lookup_u8_0, + lookup_u8_1, + lookup_u16_0, + lookup_u16_1, + lookup_u16_2, + lookup_u16_3, + lookup_u16_4, + lookup_u16_5, + lookup_u16_6, + lookup_u16_7, + lookup_u16_8, + lookup_u16_9, + lookup_u16_10, + lookup_u16_11, + lookup_u16_12, + lookup_u16_13, + lookup_u16_14, + lookup_div_u16_0, + lookup_div_u16_1, + lookup_div_u16_2, + lookup_div_u16_3, + lookup_div_u16_4, + lookup_div_u16_5, + lookup_div_u16_6, + lookup_div_u16_7) +>>>>>>> 804a62263 (feat(avm): poseidon2 constraints) + }; + + template class ShiftedEntities { + public: + DEFINE_FLAVOR_MEMBERS(DataType, SHIFTED_ENTITIES) + }; + + template + static auto get_to_be_shifted(PrecomputedAndWitnessEntitiesSuperset& entities) + { + return RefArray{ TO_BE_SHIFTED(entities) }; + } + + template + class WitnessEntities : public WireEntities, public DerivedWitnessEntities { + public: + DEFINE_COMPOUND_GET_ALL(WireEntities, DerivedWitnessEntities) + auto get_wires() { return WireEntities::get_all(); } + auto get_derived() { return DerivedWitnessEntities::get_all(); } + }; + + template + class AllEntities : public PrecomputedEntities, + public WitnessEntities, + public ShiftedEntities { + public: + DEFINE_COMPOUND_GET_ALL(PrecomputedEntities, WitnessEntities, ShiftedEntities) + + auto get_unshifted() + { +<<<<<<< HEAD + return concatenate(PrecomputedEntities::get_all(), WitnessEntities::get_all()); + } + auto get_to_be_shifted() { return AvmFlavor::get_to_be_shifted(*this); } + auto get_shifted() { return ShiftedEntities::get_all(); } + auto get_precomputed() { return PrecomputedEntities::get_all(); } +======= + return { main_clk, + main_sel_first, + kernel_kernel_inputs, + kernel_kernel_value_out, + kernel_kernel_side_effect_out, + kernel_kernel_metadata_out, + main_calldata, + alu_a_hi, + alu_a_lo, + alu_b_hi, + alu_b_lo, + alu_borrow, + alu_cf, + alu_clk, + alu_cmp_rng_ctr, + alu_div_u16_r0, + alu_div_u16_r1, + alu_div_u16_r2, + alu_div_u16_r3, + alu_div_u16_r4, + alu_div_u16_r5, + alu_div_u16_r6, + alu_div_u16_r7, + alu_divisor_hi, + alu_divisor_lo, + alu_ff_tag, + alu_ia, + alu_ib, + alu_ic, + alu_in_tag, + alu_op_add, + alu_op_cast, + alu_op_cast_prev, + alu_op_div, + alu_op_div_a_lt_b, + alu_op_div_std, + alu_op_eq, + alu_op_eq_diff_inv, + alu_op_lt, + alu_op_lte, + alu_op_mul, + alu_op_not, + alu_op_shl, + alu_op_shr, + alu_op_sub, + alu_p_a_borrow, + alu_p_b_borrow, + alu_p_sub_a_hi, + alu_p_sub_a_lo, + alu_p_sub_b_hi, + alu_p_sub_b_lo, + alu_partial_prod_hi, + alu_partial_prod_lo, + alu_quotient_hi, + alu_quotient_lo, + alu_remainder, + alu_res_hi, + alu_res_lo, + alu_sel_alu, + alu_sel_cmp, + alu_sel_div_rng_chk, + alu_sel_rng_chk, + alu_sel_rng_chk_lookup, + alu_sel_shift_which, + alu_shift_lt_bit_len, + alu_t_sub_s_bits, + alu_two_pow_s, + alu_two_pow_t_sub_s, + alu_u128_tag, + alu_u16_r0, + alu_u16_r1, + alu_u16_r10, + alu_u16_r11, + alu_u16_r12, + alu_u16_r13, + alu_u16_r14, + alu_u16_r2, + alu_u16_r3, + alu_u16_r4, + alu_u16_r5, + alu_u16_r6, + alu_u16_r7, + alu_u16_r8, + alu_u16_r9, + alu_u16_tag, + alu_u32_tag, + alu_u64_tag, + alu_u8_r0, + alu_u8_r1, + alu_u8_tag, + binary_acc_ia, + binary_acc_ib, + binary_acc_ic, + binary_clk, + binary_ia_bytes, + binary_ib_bytes, + binary_ic_bytes, + binary_in_tag, + binary_mem_tag_ctr, + binary_mem_tag_ctr_inv, + binary_op_id, + binary_sel_bin, + binary_start, + byte_lookup_sel_bin, + byte_lookup_table_byte_lengths, + byte_lookup_table_in_tags, + byte_lookup_table_input_a, + byte_lookup_table_input_b, + byte_lookup_table_op_id, + byte_lookup_table_output, + conversion_clk, + conversion_input, + conversion_num_limbs, + conversion_radix, + conversion_sel_to_radix_le, + gas_da_gas_fixed_table, + gas_l2_gas_fixed_table, + gas_sel_gas_cost, + keccakf1600_clk, + keccakf1600_input, + keccakf1600_output, + keccakf1600_sel_keccakf1600, + kernel_emit_l2_to_l1_msg_write_offset, + kernel_emit_note_hash_write_offset, + kernel_emit_nullifier_write_offset, + kernel_emit_unencrypted_log_write_offset, + kernel_kernel_in_offset, + kernel_kernel_out_offset, + kernel_l1_to_l2_msg_exists_write_offset, + kernel_note_hash_exist_write_offset, + kernel_nullifier_exists_write_offset, + kernel_nullifier_non_exists_write_offset, + kernel_q_public_input_kernel_add_to_table, + kernel_q_public_input_kernel_out_add_to_table, + kernel_side_effect_counter, + kernel_sload_write_offset, + kernel_sstore_write_offset, + main_abs_da_rem_gas_hi, + main_abs_da_rem_gas_lo, + main_abs_l2_rem_gas_hi, + main_abs_l2_rem_gas_lo, + main_alu_in_tag, + main_bin_op_id, + main_call_ptr, + main_da_gas_op_cost, + main_da_gas_remaining, + main_da_out_of_gas, + main_ia, + main_ib, + main_ic, + main_id, + main_id_zero, + main_ind_addr_a, + main_ind_addr_b, + main_ind_addr_c, + main_ind_addr_d, + main_internal_return_ptr, + main_inv, + main_l2_gas_op_cost, + main_l2_gas_remaining, + main_l2_out_of_gas, + main_mem_addr_a, + main_mem_addr_b, + main_mem_addr_c, + main_mem_addr_d, + main_op_err, + main_opcode_val, + main_pc, + main_r_in_tag, + main_rwa, + main_rwb, + main_rwc, + main_rwd, + main_sel_alu, + main_sel_bin, + main_sel_gas_accounting_active, + main_sel_last, + main_sel_mem_op_a, + main_sel_mem_op_activate_gas, + main_sel_mem_op_b, + main_sel_mem_op_c, + main_sel_mem_op_d, + main_sel_mov_ia_to_ic, + main_sel_mov_ib_to_ic, + main_sel_op_add, + main_sel_op_address, + main_sel_op_and, + main_sel_op_block_number, + main_sel_op_cast, + main_sel_op_chain_id, + main_sel_op_cmov, + main_sel_op_coinbase, + main_sel_op_dagasleft, + main_sel_op_div, + main_sel_op_emit_l2_to_l1_msg, + main_sel_op_emit_note_hash, + main_sel_op_emit_nullifier, + main_sel_op_emit_unencrypted_log, + main_sel_op_eq, + main_sel_op_external_call, + main_sel_op_fdiv, + main_sel_op_fee_per_da_gas, + main_sel_op_fee_per_l2_gas, + main_sel_op_function_selector, + main_sel_op_get_contract_instance, + main_sel_op_halt, + main_sel_op_internal_call, + main_sel_op_internal_return, + main_sel_op_jump, + main_sel_op_jumpi, + main_sel_op_keccak, + main_sel_op_l1_to_l2_msg_exists, + main_sel_op_l2gasleft, + main_sel_op_lt, + main_sel_op_lte, + main_sel_op_mov, + main_sel_op_mul, + main_sel_op_not, + main_sel_op_note_hash_exists, + main_sel_op_nullifier_exists, + main_sel_op_or, + main_sel_op_pedersen, + main_sel_op_poseidon2, + main_sel_op_radix_le, + main_sel_op_sender, + main_sel_op_sha256, + main_sel_op_shl, + main_sel_op_shr, + main_sel_op_sload, + main_sel_op_sstore, + main_sel_op_storage_address, + main_sel_op_sub, + main_sel_op_timestamp, + main_sel_op_transaction_fee, + main_sel_op_version, + main_sel_op_xor, + main_sel_q_kernel_lookup, + main_sel_q_kernel_output_lookup, + main_sel_resolve_ind_addr_a, + main_sel_resolve_ind_addr_b, + main_sel_resolve_ind_addr_c, + main_sel_resolve_ind_addr_d, + main_sel_rng_16, + main_sel_rng_8, + main_space_id, + main_tag_err, + main_w_in_tag, + mem_addr, + mem_clk, + mem_diff_hi, + mem_diff_lo, + mem_diff_mid, + mem_glob_addr, + mem_last, + mem_lastAccess, + mem_one_min_inv, + mem_r_in_tag, + mem_rw, + mem_sel_mem, + mem_sel_mov_ia_to_ic, + mem_sel_mov_ib_to_ic, + mem_sel_op_a, + mem_sel_op_b, + mem_sel_op_c, + mem_sel_op_cmov, + mem_sel_op_d, + mem_sel_resolve_ind_addr_a, + mem_sel_resolve_ind_addr_b, + mem_sel_resolve_ind_addr_c, + mem_sel_resolve_ind_addr_d, + mem_sel_rng_chk, + mem_skip_check_tag, + mem_space_id, + mem_tag, + mem_tag_err, + mem_tsp, + mem_val, + mem_w_in_tag, + pedersen_clk, + pedersen_input, + pedersen_output, + pedersen_sel_pedersen, + poseidon2_a_0, + poseidon2_a_1, + poseidon2_a_2, + poseidon2_a_3, + poseidon2_b_0, + poseidon2_b_1, + poseidon2_b_2, + poseidon2_b_3, + poseidon2_clk, + poseidon2_input, + poseidon2_output, + poseidon2_sel_poseidon_perm, + powers_power_of_2, + sha256_clk, + sha256_input, + sha256_output, + sha256_sel_sha256_compression, + sha256_state, + perm_main_alu, + perm_main_bin, + perm_main_conv, + perm_main_pos2_perm, + perm_main_pedersen, + perm_main_mem_a, + perm_main_mem_b, + perm_main_mem_c, + perm_main_mem_d, + perm_main_mem_ind_addr_a, + perm_main_mem_ind_addr_b, + perm_main_mem_ind_addr_c, + perm_main_mem_ind_addr_d, + lookup_byte_lengths, + lookup_byte_operations, + lookup_opcode_gas, + range_check_l2_gas_hi, + range_check_l2_gas_lo, + range_check_da_gas_hi, + range_check_da_gas_lo, + kernel_output_lookup, + lookup_into_kernel, + incl_main_tag_err, + incl_mem_tag_err, + lookup_mem_rng_chk_lo, + lookup_mem_rng_chk_mid, + lookup_mem_rng_chk_hi, + lookup_pow_2_0, + lookup_pow_2_1, + lookup_u8_0, + lookup_u8_1, + lookup_u16_0, + lookup_u16_1, + lookup_u16_2, + lookup_u16_3, + lookup_u16_4, + lookup_u16_5, + lookup_u16_6, + lookup_u16_7, + lookup_u16_8, + lookup_u16_9, + lookup_u16_10, + lookup_u16_11, + lookup_u16_12, + lookup_u16_13, + lookup_u16_14, + lookup_div_u16_0, + lookup_div_u16_1, + lookup_div_u16_2, + lookup_div_u16_3, + lookup_div_u16_4, + lookup_div_u16_5, + lookup_div_u16_6, + lookup_div_u16_7, + lookup_byte_lengths_counts, + lookup_byte_operations_counts, + lookup_opcode_gas_counts, + range_check_l2_gas_hi_counts, + range_check_l2_gas_lo_counts, + range_check_da_gas_hi_counts, + range_check_da_gas_lo_counts, + kernel_output_lookup_counts, + lookup_into_kernel_counts, + incl_main_tag_err_counts, + incl_mem_tag_err_counts, + lookup_mem_rng_chk_lo_counts, + lookup_mem_rng_chk_mid_counts, + lookup_mem_rng_chk_hi_counts, + lookup_pow_2_0_counts, + lookup_pow_2_1_counts, + lookup_u8_0_counts, + lookup_u8_1_counts, + lookup_u16_0_counts, + lookup_u16_1_counts, + lookup_u16_2_counts, + lookup_u16_3_counts, + lookup_u16_4_counts, + lookup_u16_5_counts, + lookup_u16_6_counts, + lookup_u16_7_counts, + lookup_u16_8_counts, + lookup_u16_9_counts, + lookup_u16_10_counts, + lookup_u16_11_counts, + lookup_u16_12_counts, + lookup_u16_13_counts, + lookup_u16_14_counts, + lookup_div_u16_0_counts, + lookup_div_u16_1_counts, + lookup_div_u16_2_counts, + lookup_div_u16_3_counts, + lookup_div_u16_4_counts, + lookup_div_u16_5_counts, + lookup_div_u16_6_counts, + lookup_div_u16_7_counts, + alu_a_hi_shift, + alu_a_lo_shift, + alu_b_hi_shift, + alu_b_lo_shift, + alu_cmp_rng_ctr_shift, + alu_div_u16_r0_shift, + alu_div_u16_r1_shift, + alu_div_u16_r2_shift, + alu_div_u16_r3_shift, + alu_div_u16_r4_shift, + alu_div_u16_r5_shift, + alu_div_u16_r6_shift, + alu_div_u16_r7_shift, + alu_op_add_shift, + alu_op_cast_prev_shift, + alu_op_cast_shift, + alu_op_div_shift, + alu_op_mul_shift, + alu_op_shl_shift, + alu_op_shr_shift, + alu_op_sub_shift, + alu_p_sub_a_hi_shift, + alu_p_sub_a_lo_shift, + alu_p_sub_b_hi_shift, + alu_p_sub_b_lo_shift, + alu_sel_alu_shift, + alu_sel_cmp_shift, + alu_sel_div_rng_chk_shift, + alu_sel_rng_chk_lookup_shift, + alu_sel_rng_chk_shift, + alu_u16_r0_shift, + alu_u16_r1_shift, + alu_u16_r2_shift, + alu_u16_r3_shift, + alu_u16_r4_shift, + alu_u16_r5_shift, + alu_u16_r6_shift, + alu_u8_r0_shift, + alu_u8_r1_shift, + binary_acc_ia_shift, + binary_acc_ib_shift, + binary_acc_ic_shift, + binary_mem_tag_ctr_shift, + binary_op_id_shift, + kernel_emit_l2_to_l1_msg_write_offset_shift, + kernel_emit_note_hash_write_offset_shift, + kernel_emit_nullifier_write_offset_shift, + kernel_emit_unencrypted_log_write_offset_shift, + kernel_l1_to_l2_msg_exists_write_offset_shift, + kernel_note_hash_exist_write_offset_shift, + kernel_nullifier_exists_write_offset_shift, + kernel_nullifier_non_exists_write_offset_shift, + kernel_side_effect_counter_shift, + kernel_sload_write_offset_shift, + kernel_sstore_write_offset_shift, + main_da_gas_remaining_shift, + main_internal_return_ptr_shift, + main_l2_gas_remaining_shift, + main_pc_shift, + mem_glob_addr_shift, + mem_rw_shift, + mem_sel_mem_shift, + mem_tag_shift, + mem_tsp_shift, + mem_val_shift }; + }; + RefVector get_unshifted() + { + return { main_clk, + main_sel_first, + kernel_kernel_inputs, + kernel_kernel_value_out, + kernel_kernel_side_effect_out, + kernel_kernel_metadata_out, + main_calldata, + alu_a_hi, + alu_a_lo, + alu_b_hi, + alu_b_lo, + alu_borrow, + alu_cf, + alu_clk, + alu_cmp_rng_ctr, + alu_div_u16_r0, + alu_div_u16_r1, + alu_div_u16_r2, + alu_div_u16_r3, + alu_div_u16_r4, + alu_div_u16_r5, + alu_div_u16_r6, + alu_div_u16_r7, + alu_divisor_hi, + alu_divisor_lo, + alu_ff_tag, + alu_ia, + alu_ib, + alu_ic, + alu_in_tag, + alu_op_add, + alu_op_cast, + alu_op_cast_prev, + alu_op_div, + alu_op_div_a_lt_b, + alu_op_div_std, + alu_op_eq, + alu_op_eq_diff_inv, + alu_op_lt, + alu_op_lte, + alu_op_mul, + alu_op_not, + alu_op_shl, + alu_op_shr, + alu_op_sub, + alu_p_a_borrow, + alu_p_b_borrow, + alu_p_sub_a_hi, + alu_p_sub_a_lo, + alu_p_sub_b_hi, + alu_p_sub_b_lo, + alu_partial_prod_hi, + alu_partial_prod_lo, + alu_quotient_hi, + alu_quotient_lo, + alu_remainder, + alu_res_hi, + alu_res_lo, + alu_sel_alu, + alu_sel_cmp, + alu_sel_div_rng_chk, + alu_sel_rng_chk, + alu_sel_rng_chk_lookup, + alu_sel_shift_which, + alu_shift_lt_bit_len, + alu_t_sub_s_bits, + alu_two_pow_s, + alu_two_pow_t_sub_s, + alu_u128_tag, + alu_u16_r0, + alu_u16_r1, + alu_u16_r10, + alu_u16_r11, + alu_u16_r12, + alu_u16_r13, + alu_u16_r14, + alu_u16_r2, + alu_u16_r3, + alu_u16_r4, + alu_u16_r5, + alu_u16_r6, + alu_u16_r7, + alu_u16_r8, + alu_u16_r9, + alu_u16_tag, + alu_u32_tag, + alu_u64_tag, + alu_u8_r0, + alu_u8_r1, + alu_u8_tag, + binary_acc_ia, + binary_acc_ib, + binary_acc_ic, + binary_clk, + binary_ia_bytes, + binary_ib_bytes, + binary_ic_bytes, + binary_in_tag, + binary_mem_tag_ctr, + binary_mem_tag_ctr_inv, + binary_op_id, + binary_sel_bin, + binary_start, + byte_lookup_sel_bin, + byte_lookup_table_byte_lengths, + byte_lookup_table_in_tags, + byte_lookup_table_input_a, + byte_lookup_table_input_b, + byte_lookup_table_op_id, + byte_lookup_table_output, + conversion_clk, + conversion_input, + conversion_num_limbs, + conversion_radix, + conversion_sel_to_radix_le, + gas_da_gas_fixed_table, + gas_l2_gas_fixed_table, + gas_sel_gas_cost, + keccakf1600_clk, + keccakf1600_input, + keccakf1600_output, + keccakf1600_sel_keccakf1600, + kernel_emit_l2_to_l1_msg_write_offset, + kernel_emit_note_hash_write_offset, + kernel_emit_nullifier_write_offset, + kernel_emit_unencrypted_log_write_offset, + kernel_kernel_in_offset, + kernel_kernel_out_offset, + kernel_l1_to_l2_msg_exists_write_offset, + kernel_note_hash_exist_write_offset, + kernel_nullifier_exists_write_offset, + kernel_nullifier_non_exists_write_offset, + kernel_q_public_input_kernel_add_to_table, + kernel_q_public_input_kernel_out_add_to_table, + kernel_side_effect_counter, + kernel_sload_write_offset, + kernel_sstore_write_offset, + main_abs_da_rem_gas_hi, + main_abs_da_rem_gas_lo, + main_abs_l2_rem_gas_hi, + main_abs_l2_rem_gas_lo, + main_alu_in_tag, + main_bin_op_id, + main_call_ptr, + main_da_gas_op_cost, + main_da_gas_remaining, + main_da_out_of_gas, + main_ia, + main_ib, + main_ic, + main_id, + main_id_zero, + main_ind_addr_a, + main_ind_addr_b, + main_ind_addr_c, + main_ind_addr_d, + main_internal_return_ptr, + main_inv, + main_l2_gas_op_cost, + main_l2_gas_remaining, + main_l2_out_of_gas, + main_mem_addr_a, + main_mem_addr_b, + main_mem_addr_c, + main_mem_addr_d, + main_op_err, + main_opcode_val, + main_pc, + main_r_in_tag, + main_rwa, + main_rwb, + main_rwc, + main_rwd, + main_sel_alu, + main_sel_bin, + main_sel_gas_accounting_active, + main_sel_last, + main_sel_mem_op_a, + main_sel_mem_op_activate_gas, + main_sel_mem_op_b, + main_sel_mem_op_c, + main_sel_mem_op_d, + main_sel_mov_ia_to_ic, + main_sel_mov_ib_to_ic, + main_sel_op_add, + main_sel_op_address, + main_sel_op_and, + main_sel_op_block_number, + main_sel_op_cast, + main_sel_op_chain_id, + main_sel_op_cmov, + main_sel_op_coinbase, + main_sel_op_dagasleft, + main_sel_op_div, + main_sel_op_emit_l2_to_l1_msg, + main_sel_op_emit_note_hash, + main_sel_op_emit_nullifier, + main_sel_op_emit_unencrypted_log, + main_sel_op_eq, + main_sel_op_external_call, + main_sel_op_fdiv, + main_sel_op_fee_per_da_gas, + main_sel_op_fee_per_l2_gas, + main_sel_op_function_selector, + main_sel_op_get_contract_instance, + main_sel_op_halt, + main_sel_op_internal_call, + main_sel_op_internal_return, + main_sel_op_jump, + main_sel_op_jumpi, + main_sel_op_keccak, + main_sel_op_l1_to_l2_msg_exists, + main_sel_op_l2gasleft, + main_sel_op_lt, + main_sel_op_lte, + main_sel_op_mov, + main_sel_op_mul, + main_sel_op_not, + main_sel_op_note_hash_exists, + main_sel_op_nullifier_exists, + main_sel_op_or, + main_sel_op_pedersen, + main_sel_op_poseidon2, + main_sel_op_radix_le, + main_sel_op_sender, + main_sel_op_sha256, + main_sel_op_shl, + main_sel_op_shr, + main_sel_op_sload, + main_sel_op_sstore, + main_sel_op_storage_address, + main_sel_op_sub, + main_sel_op_timestamp, + main_sel_op_transaction_fee, + main_sel_op_version, + main_sel_op_xor, + main_sel_q_kernel_lookup, + main_sel_q_kernel_output_lookup, + main_sel_resolve_ind_addr_a, + main_sel_resolve_ind_addr_b, + main_sel_resolve_ind_addr_c, + main_sel_resolve_ind_addr_d, + main_sel_rng_16, + main_sel_rng_8, + main_space_id, + main_tag_err, + main_w_in_tag, + mem_addr, + mem_clk, + mem_diff_hi, + mem_diff_lo, + mem_diff_mid, + mem_glob_addr, + mem_last, + mem_lastAccess, + mem_one_min_inv, + mem_r_in_tag, + mem_rw, + mem_sel_mem, + mem_sel_mov_ia_to_ic, + mem_sel_mov_ib_to_ic, + mem_sel_op_a, + mem_sel_op_b, + mem_sel_op_c, + mem_sel_op_cmov, + mem_sel_op_d, + mem_sel_resolve_ind_addr_a, + mem_sel_resolve_ind_addr_b, + mem_sel_resolve_ind_addr_c, + mem_sel_resolve_ind_addr_d, + mem_sel_rng_chk, + mem_skip_check_tag, + mem_space_id, + mem_tag, + mem_tag_err, + mem_tsp, + mem_val, + mem_w_in_tag, + pedersen_clk, + pedersen_input, + pedersen_output, + pedersen_sel_pedersen, + poseidon2_a_0, + poseidon2_a_1, + poseidon2_a_2, + poseidon2_a_3, + poseidon2_b_0, + poseidon2_b_1, + poseidon2_b_2, + poseidon2_b_3, + poseidon2_clk, + poseidon2_input, + poseidon2_output, + poseidon2_sel_poseidon_perm, + powers_power_of_2, + sha256_clk, + sha256_input, + sha256_output, + sha256_sel_sha256_compression, + sha256_state, + perm_main_alu, + perm_main_bin, + perm_main_conv, + perm_main_pos2_perm, + perm_main_pedersen, + perm_main_mem_a, + perm_main_mem_b, + perm_main_mem_c, + perm_main_mem_d, + perm_main_mem_ind_addr_a, + perm_main_mem_ind_addr_b, + perm_main_mem_ind_addr_c, + perm_main_mem_ind_addr_d, + lookup_byte_lengths, + lookup_byte_operations, + lookup_opcode_gas, + range_check_l2_gas_hi, + range_check_l2_gas_lo, + range_check_da_gas_hi, + range_check_da_gas_lo, + kernel_output_lookup, + lookup_into_kernel, + incl_main_tag_err, + incl_mem_tag_err, + lookup_mem_rng_chk_lo, + lookup_mem_rng_chk_mid, + lookup_mem_rng_chk_hi, + lookup_pow_2_0, + lookup_pow_2_1, + lookup_u8_0, + lookup_u8_1, + lookup_u16_0, + lookup_u16_1, + lookup_u16_2, + lookup_u16_3, + lookup_u16_4, + lookup_u16_5, + lookup_u16_6, + lookup_u16_7, + lookup_u16_8, + lookup_u16_9, + lookup_u16_10, + lookup_u16_11, + lookup_u16_12, + lookup_u16_13, + lookup_u16_14, + lookup_div_u16_0, + lookup_div_u16_1, + lookup_div_u16_2, + lookup_div_u16_3, + lookup_div_u16_4, + lookup_div_u16_5, + lookup_div_u16_6, + lookup_div_u16_7, + lookup_byte_lengths_counts, + lookup_byte_operations_counts, + lookup_opcode_gas_counts, + range_check_l2_gas_hi_counts, + range_check_l2_gas_lo_counts, + range_check_da_gas_hi_counts, + range_check_da_gas_lo_counts, + kernel_output_lookup_counts, + lookup_into_kernel_counts, + incl_main_tag_err_counts, + incl_mem_tag_err_counts, + lookup_mem_rng_chk_lo_counts, + lookup_mem_rng_chk_mid_counts, + lookup_mem_rng_chk_hi_counts, + lookup_pow_2_0_counts, + lookup_pow_2_1_counts, + lookup_u8_0_counts, + lookup_u8_1_counts, + lookup_u16_0_counts, + lookup_u16_1_counts, + lookup_u16_2_counts, + lookup_u16_3_counts, + lookup_u16_4_counts, + lookup_u16_5_counts, + lookup_u16_6_counts, + lookup_u16_7_counts, + lookup_u16_8_counts, + lookup_u16_9_counts, + lookup_u16_10_counts, + lookup_u16_11_counts, + lookup_u16_12_counts, + lookup_u16_13_counts, + lookup_u16_14_counts, + lookup_div_u16_0_counts, + lookup_div_u16_1_counts, + lookup_div_u16_2_counts, + lookup_div_u16_3_counts, + lookup_div_u16_4_counts, + lookup_div_u16_5_counts, + lookup_div_u16_6_counts, + lookup_div_u16_7_counts }; + }; + RefVector get_to_be_shifted() + { + return { alu_a_hi, + alu_a_lo, + alu_b_hi, + alu_b_lo, + alu_cmp_rng_ctr, + alu_div_u16_r0, + alu_div_u16_r1, + alu_div_u16_r2, + alu_div_u16_r3, + alu_div_u16_r4, + alu_div_u16_r5, + alu_div_u16_r6, + alu_div_u16_r7, + alu_op_add, + alu_op_cast_prev, + alu_op_cast, + alu_op_div, + alu_op_mul, + alu_op_shl, + alu_op_shr, + alu_op_sub, + alu_p_sub_a_hi, + alu_p_sub_a_lo, + alu_p_sub_b_hi, + alu_p_sub_b_lo, + alu_sel_alu, + alu_sel_cmp, + alu_sel_div_rng_chk, + alu_sel_rng_chk_lookup, + alu_sel_rng_chk, + alu_u16_r0, + alu_u16_r1, + alu_u16_r2, + alu_u16_r3, + alu_u16_r4, + alu_u16_r5, + alu_u16_r6, + alu_u8_r0, + alu_u8_r1, + binary_acc_ia, + binary_acc_ib, + binary_acc_ic, + binary_mem_tag_ctr, + binary_op_id, + kernel_emit_l2_to_l1_msg_write_offset, + kernel_emit_note_hash_write_offset, + kernel_emit_nullifier_write_offset, + kernel_emit_unencrypted_log_write_offset, + kernel_l1_to_l2_msg_exists_write_offset, + kernel_note_hash_exist_write_offset, + kernel_nullifier_exists_write_offset, + kernel_nullifier_non_exists_write_offset, + kernel_side_effect_counter, + kernel_sload_write_offset, + kernel_sstore_write_offset, + main_da_gas_remaining, + main_internal_return_ptr, + main_l2_gas_remaining, + main_pc, + mem_glob_addr, + mem_rw, + mem_sel_mem, + mem_tag, + mem_tsp, + mem_val }; + }; + RefVector get_shifted() + { + return { alu_a_hi_shift, + alu_a_lo_shift, + alu_b_hi_shift, + alu_b_lo_shift, + alu_cmp_rng_ctr_shift, + alu_div_u16_r0_shift, + alu_div_u16_r1_shift, + alu_div_u16_r2_shift, + alu_div_u16_r3_shift, + alu_div_u16_r4_shift, + alu_div_u16_r5_shift, + alu_div_u16_r6_shift, + alu_div_u16_r7_shift, + alu_op_add_shift, + alu_op_cast_prev_shift, + alu_op_cast_shift, + alu_op_div_shift, + alu_op_mul_shift, + alu_op_shl_shift, + alu_op_shr_shift, + alu_op_sub_shift, + alu_p_sub_a_hi_shift, + alu_p_sub_a_lo_shift, + alu_p_sub_b_hi_shift, + alu_p_sub_b_lo_shift, + alu_sel_alu_shift, + alu_sel_cmp_shift, + alu_sel_div_rng_chk_shift, + alu_sel_rng_chk_lookup_shift, + alu_sel_rng_chk_shift, + alu_u16_r0_shift, + alu_u16_r1_shift, + alu_u16_r2_shift, + alu_u16_r3_shift, + alu_u16_r4_shift, + alu_u16_r5_shift, + alu_u16_r6_shift, + alu_u8_r0_shift, + alu_u8_r1_shift, + binary_acc_ia_shift, + binary_acc_ib_shift, + binary_acc_ic_shift, + binary_mem_tag_ctr_shift, + binary_op_id_shift, + kernel_emit_l2_to_l1_msg_write_offset_shift, + kernel_emit_note_hash_write_offset_shift, + kernel_emit_nullifier_write_offset_shift, + kernel_emit_unencrypted_log_write_offset_shift, + kernel_l1_to_l2_msg_exists_write_offset_shift, + kernel_note_hash_exist_write_offset_shift, + kernel_nullifier_exists_write_offset_shift, + kernel_nullifier_non_exists_write_offset_shift, + kernel_side_effect_counter_shift, + kernel_sload_write_offset_shift, + kernel_sstore_write_offset_shift, + main_da_gas_remaining_shift, + main_internal_return_ptr_shift, + main_l2_gas_remaining_shift, + main_pc_shift, + mem_glob_addr_shift, + mem_rw_shift, + mem_sel_mem_shift, + mem_tag_shift, + mem_tsp_shift, + mem_val_shift }; + }; +>>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) + }; + + public: + class ProvingKey + : public ProvingKeyAvm_, WitnessEntities, CommitmentKey> { + public: + // Expose constructors on the base class + using Base = ProvingKeyAvm_, WitnessEntities, CommitmentKey>; + using Base::Base; + + auto get_to_be_shifted() { return AvmFlavor::get_to_be_shifted(*this); } + }; + + using VerificationKey = VerificationKey_, VerifierCommitmentKey>; + + class AllValues : public AllEntities { + public: + using Base = AllEntities; + using Base::Base; + }; + + class AllConstRefValues { + public: + using DataType = const FF&; + + DEFINE_FLAVOR_MEMBERS(DataType, ALL_ENTITIES) + + AllConstRefValues(const RefArray& il) + : main_clk(il[0]) + , main_sel_first(il[1]) + , kernel_kernel_inputs(il[2]) + , kernel_kernel_value_out(il[3]) + , kernel_kernel_side_effect_out(il[4]) + , kernel_kernel_metadata_out(il[5]) + , main_calldata(il[6]) + , main_returndata(il[7]) + , alu_a_hi(il[8]) + , alu_a_lo(il[9]) + , alu_b_hi(il[10]) + , alu_b_lo(il[11]) + , alu_borrow(il[12]) + , alu_cf(il[13]) + , alu_clk(il[14]) + , alu_cmp_rng_ctr(il[15]) + , alu_div_u16_r0(il[16]) + , alu_div_u16_r1(il[17]) + , alu_div_u16_r2(il[18]) + , alu_div_u16_r3(il[19]) + , alu_div_u16_r4(il[20]) + , alu_div_u16_r5(il[21]) + , alu_div_u16_r6(il[22]) + , alu_div_u16_r7(il[23]) + , alu_divisor_hi(il[24]) + , alu_divisor_lo(il[25]) + , alu_ff_tag(il[26]) + , alu_ia(il[27]) + , alu_ib(il[28]) + , alu_ic(il[29]) + , alu_in_tag(il[30]) + , alu_op_add(il[31]) + , alu_op_cast(il[32]) + , alu_op_cast_prev(il[33]) + , alu_op_div(il[34]) + , alu_op_div_a_lt_b(il[35]) + , alu_op_div_std(il[36]) + , alu_op_eq(il[37]) + , alu_op_eq_diff_inv(il[38]) + , alu_op_lt(il[39]) + , alu_op_lte(il[40]) + , alu_op_mul(il[41]) + , alu_op_not(il[42]) + , alu_op_shl(il[43]) + , alu_op_shr(il[44]) + , alu_op_sub(il[45]) + , alu_p_a_borrow(il[46]) + , alu_p_b_borrow(il[47]) + , alu_p_sub_a_hi(il[48]) + , alu_p_sub_a_lo(il[49]) + , alu_p_sub_b_hi(il[50]) + , alu_p_sub_b_lo(il[51]) + , alu_partial_prod_hi(il[52]) + , alu_partial_prod_lo(il[53]) + , alu_quotient_hi(il[54]) + , alu_quotient_lo(il[55]) + , alu_remainder(il[56]) + , alu_res_hi(il[57]) + , alu_res_lo(il[58]) + , alu_sel_alu(il[59]) + , alu_sel_cmp(il[60]) + , alu_sel_div_rng_chk(il[61]) + , alu_sel_rng_chk(il[62]) + , alu_sel_rng_chk_lookup(il[63]) + , alu_sel_shift_which(il[64]) + , alu_shift_lt_bit_len(il[65]) + , alu_t_sub_s_bits(il[66]) + , alu_two_pow_s(il[67]) + , alu_two_pow_t_sub_s(il[68]) + , alu_u128_tag(il[69]) + , alu_u16_r0(il[70]) + , alu_u16_r1(il[71]) + , alu_u16_r10(il[72]) + , alu_u16_r11(il[73]) + , alu_u16_r12(il[74]) + , alu_u16_r13(il[75]) + , alu_u16_r14(il[76]) + , alu_u16_r2(il[77]) + , alu_u16_r3(il[78]) + , alu_u16_r4(il[79]) + , alu_u16_r5(il[80]) + , alu_u16_r6(il[81]) + , alu_u16_r7(il[82]) + , alu_u16_r8(il[83]) + , alu_u16_r9(il[84]) + , alu_u16_tag(il[85]) + , alu_u32_tag(il[86]) + , alu_u64_tag(il[87]) + , alu_u8_r0(il[88]) + , alu_u8_r1(il[89]) + , alu_u8_tag(il[90]) + , binary_acc_ia(il[91]) + , binary_acc_ib(il[92]) + , binary_acc_ic(il[93]) + , binary_clk(il[94]) + , binary_ia_bytes(il[95]) + , binary_ib_bytes(il[96]) + , binary_ic_bytes(il[97]) + , binary_in_tag(il[98]) + , binary_mem_tag_ctr(il[99]) + , binary_mem_tag_ctr_inv(il[100]) + , binary_op_id(il[101]) + , binary_sel_bin(il[102]) + , binary_start(il[103]) + , byte_lookup_sel_bin(il[104]) + , byte_lookup_table_byte_lengths(il[105]) + , byte_lookup_table_in_tags(il[106]) + , byte_lookup_table_input_a(il[107]) + , byte_lookup_table_input_b(il[108]) + , byte_lookup_table_op_id(il[109]) + , byte_lookup_table_output(il[110]) + , conversion_clk(il[111]) + , conversion_input(il[112]) + , conversion_num_limbs(il[113]) + , conversion_radix(il[114]) + , conversion_sel_to_radix_le(il[115]) + , gas_da_gas_fixed_table(il[116]) + , gas_l2_gas_fixed_table(il[117]) + , gas_sel_gas_cost(il[118]) + , keccakf1600_clk(il[119]) + , keccakf1600_input(il[120]) + , keccakf1600_output(il[121]) + , keccakf1600_sel_keccakf1600(il[122]) + , kernel_emit_l2_to_l1_msg_write_offset(il[123]) + , kernel_emit_note_hash_write_offset(il[124]) + , kernel_emit_nullifier_write_offset(il[125]) + , kernel_emit_unencrypted_log_write_offset(il[126]) + , kernel_kernel_in_offset(il[127]) + , kernel_kernel_out_offset(il[128]) + , kernel_l1_to_l2_msg_exists_write_offset(il[129]) + , kernel_note_hash_exist_write_offset(il[130]) + , kernel_nullifier_exists_write_offset(il[131]) + , kernel_nullifier_non_exists_write_offset(il[132]) + , kernel_q_public_input_kernel_add_to_table(il[133]) + , kernel_q_public_input_kernel_out_add_to_table(il[134]) + , kernel_side_effect_counter(il[135]) + , kernel_sload_write_offset(il[136]) + , kernel_sstore_write_offset(il[137]) + , main_abs_da_rem_gas_hi(il[138]) + , main_abs_da_rem_gas_lo(il[139]) + , main_abs_l2_rem_gas_hi(il[140]) + , main_abs_l2_rem_gas_lo(il[141]) + , main_alu_in_tag(il[142]) + , main_bin_op_id(il[143]) + , main_call_ptr(il[144]) + , main_da_gas_op_cost(il[145]) + , main_da_gas_remaining(il[146]) + , main_da_out_of_gas(il[147]) + , main_ia(il[148]) + , main_ib(il[149]) + , main_ic(il[150]) + , main_id(il[151]) + , main_id_zero(il[152]) + , main_ind_addr_a(il[153]) + , main_ind_addr_b(il[154]) + , main_ind_addr_c(il[155]) + , main_ind_addr_d(il[156]) + , main_internal_return_ptr(il[157]) + , main_inv(il[158]) + , main_l2_gas_op_cost(il[159]) + , main_l2_gas_remaining(il[160]) + , main_l2_out_of_gas(il[161]) + , main_mem_addr_a(il[162]) + , main_mem_addr_b(il[163]) + , main_mem_addr_c(il[164]) + , main_mem_addr_d(il[165]) + , main_op_err(il[166]) + , main_opcode_val(il[167]) + , main_pc(il[168]) + , main_r_in_tag(il[169]) + , main_rwa(il[170]) + , main_rwb(il[171]) + , main_rwc(il[172]) + , main_rwd(il[173]) + , main_sel_alu(il[174]) + , main_sel_bin(il[175]) + , main_sel_calldata(il[176]) + , main_sel_gas_accounting_active(il[177]) + , main_sel_last(il[178]) + , main_sel_mem_op_a(il[179]) + , main_sel_mem_op_activate_gas(il[180]) + , main_sel_mem_op_b(il[181]) + , main_sel_mem_op_c(il[182]) + , main_sel_mem_op_d(il[183]) + , main_sel_mov_ia_to_ic(il[184]) + , main_sel_mov_ib_to_ic(il[185]) + , main_sel_op_add(il[186]) + , main_sel_op_address(il[187]) + , main_sel_op_and(il[188]) + , main_sel_op_block_number(il[189]) + , main_sel_op_calldata_copy(il[190]) + , main_sel_op_cast(il[191]) + , main_sel_op_chain_id(il[192]) + , main_sel_op_cmov(il[193]) + , main_sel_op_coinbase(il[194]) + , main_sel_op_dagasleft(il[195]) + , main_sel_op_div(il[196]) + , main_sel_op_emit_l2_to_l1_msg(il[197]) + , main_sel_op_emit_note_hash(il[198]) + , main_sel_op_emit_nullifier(il[199]) + , main_sel_op_emit_unencrypted_log(il[200]) + , main_sel_op_eq(il[201]) + , main_sel_op_external_call(il[202]) + , main_sel_op_external_return(il[203]) + , main_sel_op_fdiv(il[204]) + , main_sel_op_fee_per_da_gas(il[205]) + , main_sel_op_fee_per_l2_gas(il[206]) + , main_sel_op_function_selector(il[207]) + , main_sel_op_get_contract_instance(il[208]) + , main_sel_op_halt(il[209]) + , main_sel_op_internal_call(il[210]) + , main_sel_op_internal_return(il[211]) + , main_sel_op_jump(il[212]) + , main_sel_op_jumpi(il[213]) + , main_sel_op_keccak(il[214]) + , main_sel_op_l1_to_l2_msg_exists(il[215]) + , main_sel_op_l2gasleft(il[216]) + , main_sel_op_lt(il[217]) + , main_sel_op_lte(il[218]) + , main_sel_op_mov(il[219]) + , main_sel_op_mul(il[220]) + , main_sel_op_not(il[221]) + , main_sel_op_note_hash_exists(il[222]) + , main_sel_op_nullifier_exists(il[223]) + , main_sel_op_or(il[224]) + , main_sel_op_pedersen(il[225]) + , main_sel_op_poseidon2(il[226]) + , main_sel_op_radix_le(il[227]) + , main_sel_op_sender(il[228]) + , main_sel_op_sha256(il[229]) + , main_sel_op_shl(il[230]) + , main_sel_op_shr(il[231]) + , main_sel_op_sload(il[232]) + , main_sel_op_sstore(il[233]) + , main_sel_op_storage_address(il[234]) + , main_sel_op_sub(il[235]) + , main_sel_op_timestamp(il[236]) + , main_sel_op_transaction_fee(il[237]) + , main_sel_op_version(il[238]) + , main_sel_op_xor(il[239]) + , main_sel_q_kernel_lookup(il[240]) + , main_sel_q_kernel_output_lookup(il[241]) + , main_sel_resolve_ind_addr_a(il[242]) + , main_sel_resolve_ind_addr_b(il[243]) + , main_sel_resolve_ind_addr_c(il[244]) + , main_sel_resolve_ind_addr_d(il[245]) + , main_sel_returndata(il[246]) + , main_sel_rng_16(il[247]) + , main_sel_rng_8(il[248]) + , main_sel_slice_gadget(il[249]) + , main_space_id(il[250]) + , main_tag_err(il[251]) + , main_w_in_tag(il[252]) + , mem_addr(il[253]) + , mem_clk(il[254]) + , mem_diff_hi(il[255]) + , mem_diff_lo(il[256]) + , mem_diff_mid(il[257]) + , mem_glob_addr(il[258]) + , mem_last(il[259]) + , mem_lastAccess(il[260]) + , mem_one_min_inv(il[261]) + , mem_r_in_tag(il[262]) + , mem_rw(il[263]) + , mem_sel_mem(il[264]) + , mem_sel_mov_ia_to_ic(il[265]) + , mem_sel_mov_ib_to_ic(il[266]) + , mem_sel_op_a(il[267]) + , mem_sel_op_b(il[268]) + , mem_sel_op_c(il[269]) + , mem_sel_op_cmov(il[270]) + , mem_sel_op_d(il[271]) + , mem_sel_op_slice(il[272]) + , mem_sel_resolve_ind_addr_a(il[273]) + , mem_sel_resolve_ind_addr_b(il[274]) + , mem_sel_resolve_ind_addr_c(il[275]) + , mem_sel_resolve_ind_addr_d(il[276]) + , mem_sel_rng_chk(il[277]) + , mem_skip_check_tag(il[278]) + , mem_space_id(il[279]) + , mem_tag(il[280]) + , mem_tag_err(il[281]) + , mem_tsp(il[282]) + , mem_val(il[283]) + , mem_w_in_tag(il[284]) + , pedersen_clk(il[285]) + , pedersen_input(il[286]) + , pedersen_output(il[287]) + , pedersen_sel_pedersen(il[288]) + , poseidon2_clk(il[289]) + , poseidon2_input(il[290]) + , poseidon2_output(il[291]) + , poseidon2_sel_poseidon_perm(il[292]) + , powers_power_of_2(il[293]) + , sha256_clk(il[294]) + , sha256_input(il[295]) + , sha256_output(il[296]) + , sha256_sel_sha256_compression(il[297]) + , sha256_state(il[298]) + , slice_addr(il[299]) + , slice_clk(il[300]) + , slice_cnt(il[301]) + , slice_col_offset(il[302]) + , slice_one_min_inv(il[303]) + , slice_sel_cd_cpy(il[304]) + , slice_sel_mem_active(il[305]) + , slice_sel_return(il[306]) + , slice_sel_start(il[307]) + , slice_space_id(il[308]) + , slice_val(il[309]) + , lookup_byte_lengths_counts(il[310]) + , lookup_byte_operations_counts(il[311]) + , lookup_cd_value_counts(il[312]) + , lookup_ret_value_counts(il[313]) + , lookup_opcode_gas_counts(il[314]) + , range_check_l2_gas_hi_counts(il[315]) + , range_check_l2_gas_lo_counts(il[316]) + , range_check_da_gas_hi_counts(il[317]) + , range_check_da_gas_lo_counts(il[318]) + , kernel_output_lookup_counts(il[319]) + , lookup_into_kernel_counts(il[320]) + , incl_main_tag_err_counts(il[321]) + , incl_mem_tag_err_counts(il[322]) + , lookup_mem_rng_chk_lo_counts(il[323]) + , lookup_mem_rng_chk_mid_counts(il[324]) + , lookup_mem_rng_chk_hi_counts(il[325]) + , lookup_pow_2_0_counts(il[326]) + , lookup_pow_2_1_counts(il[327]) + , lookup_u8_0_counts(il[328]) + , lookup_u8_1_counts(il[329]) + , lookup_u16_0_counts(il[330]) + , lookup_u16_1_counts(il[331]) + , lookup_u16_2_counts(il[332]) + , lookup_u16_3_counts(il[333]) + , lookup_u16_4_counts(il[334]) + , lookup_u16_5_counts(il[335]) + , lookup_u16_6_counts(il[336]) + , lookup_u16_7_counts(il[337]) + , lookup_u16_8_counts(il[338]) + , lookup_u16_9_counts(il[339]) + , lookup_u16_10_counts(il[340]) + , lookup_u16_11_counts(il[341]) + , lookup_u16_12_counts(il[342]) + , lookup_u16_13_counts(il[343]) + , lookup_u16_14_counts(il[344]) + , lookup_div_u16_0_counts(il[345]) + , lookup_div_u16_1_counts(il[346]) + , lookup_div_u16_2_counts(il[347]) + , lookup_div_u16_3_counts(il[348]) + , lookup_div_u16_4_counts(il[349]) + , lookup_div_u16_5_counts(il[350]) + , lookup_div_u16_6_counts(il[351]) + , lookup_div_u16_7_counts(il[352]) + , perm_slice_mem(il[353]) + , perm_main_alu(il[354]) + , perm_main_bin(il[355]) + , perm_main_conv(il[356]) + , perm_main_pos2_perm(il[357]) + , perm_main_pedersen(il[358]) + , perm_main_slice(il[359]) + , perm_main_mem_a(il[360]) + , perm_main_mem_b(il[361]) + , perm_main_mem_c(il[362]) + , perm_main_mem_d(il[363]) + , perm_main_mem_ind_addr_a(il[364]) + , perm_main_mem_ind_addr_b(il[365]) + , perm_main_mem_ind_addr_c(il[366]) + , perm_main_mem_ind_addr_d(il[367]) + , lookup_byte_lengths(il[368]) + , lookup_byte_operations(il[369]) + , lookup_cd_value(il[370]) + , lookup_ret_value(il[371]) + , lookup_opcode_gas(il[372]) + , range_check_l2_gas_hi(il[373]) + , range_check_l2_gas_lo(il[374]) + , range_check_da_gas_hi(il[375]) + , range_check_da_gas_lo(il[376]) + , kernel_output_lookup(il[377]) + , lookup_into_kernel(il[378]) + , incl_main_tag_err(il[379]) + , incl_mem_tag_err(il[380]) + , lookup_mem_rng_chk_lo(il[381]) + , lookup_mem_rng_chk_mid(il[382]) + , lookup_mem_rng_chk_hi(il[383]) + , lookup_pow_2_0(il[384]) + , lookup_pow_2_1(il[385]) + , lookup_u8_0(il[386]) + , lookup_u8_1(il[387]) + , lookup_u16_0(il[388]) + , lookup_u16_1(il[389]) + , lookup_u16_2(il[390]) + , lookup_u16_3(il[391]) + , lookup_u16_4(il[392]) + , lookup_u16_5(il[393]) + , lookup_u16_6(il[394]) + , lookup_u16_7(il[395]) + , lookup_u16_8(il[396]) + , lookup_u16_9(il[397]) + , lookup_u16_10(il[398]) + , lookup_u16_11(il[399]) + , lookup_u16_12(il[400]) + , lookup_u16_13(il[401]) + , lookup_u16_14(il[402]) + , lookup_div_u16_0(il[403]) + , lookup_div_u16_1(il[404]) + , lookup_div_u16_2(il[405]) + , lookup_div_u16_3(il[406]) + , lookup_div_u16_4(il[407]) + , lookup_div_u16_5(il[408]) + , lookup_div_u16_6(il[409]) + , lookup_div_u16_7(il[410]) + , alu_a_hi_shift(il[411]) + , alu_a_lo_shift(il[412]) + , alu_b_hi_shift(il[413]) + , alu_b_lo_shift(il[414]) + , alu_cmp_rng_ctr_shift(il[415]) + , alu_div_u16_r0_shift(il[416]) + , alu_div_u16_r1_shift(il[417]) + , alu_div_u16_r2_shift(il[418]) + , alu_div_u16_r3_shift(il[419]) + , alu_div_u16_r4_shift(il[420]) + , alu_div_u16_r5_shift(il[421]) + , alu_div_u16_r6_shift(il[422]) + , alu_div_u16_r7_shift(il[423]) + , alu_op_add_shift(il[424]) + , alu_op_cast_prev_shift(il[425]) + , alu_op_cast_shift(il[426]) + , alu_op_div_shift(il[427]) + , alu_op_mul_shift(il[428]) + , alu_op_shl_shift(il[429]) + , alu_op_shr_shift(il[430]) + , alu_op_sub_shift(il[431]) + , alu_p_sub_a_hi_shift(il[432]) + , alu_p_sub_a_lo_shift(il[433]) + , alu_p_sub_b_hi_shift(il[434]) + , alu_p_sub_b_lo_shift(il[435]) + , alu_sel_alu_shift(il[436]) + , alu_sel_cmp_shift(il[437]) + , alu_sel_div_rng_chk_shift(il[438]) + , alu_sel_rng_chk_lookup_shift(il[439]) + , alu_sel_rng_chk_shift(il[440]) + , alu_u16_r0_shift(il[441]) + , alu_u16_r1_shift(il[442]) + , alu_u16_r2_shift(il[443]) + , alu_u16_r3_shift(il[444]) + , alu_u16_r4_shift(il[445]) + , alu_u16_r5_shift(il[446]) + , alu_u16_r6_shift(il[447]) + , alu_u8_r0_shift(il[448]) + , alu_u8_r1_shift(il[449]) + , binary_acc_ia_shift(il[450]) + , binary_acc_ib_shift(il[451]) + , binary_acc_ic_shift(il[452]) + , binary_mem_tag_ctr_shift(il[453]) + , binary_op_id_shift(il[454]) + , kernel_emit_l2_to_l1_msg_write_offset_shift(il[455]) + , kernel_emit_note_hash_write_offset_shift(il[456]) + , kernel_emit_nullifier_write_offset_shift(il[457]) + , kernel_emit_unencrypted_log_write_offset_shift(il[458]) + , kernel_l1_to_l2_msg_exists_write_offset_shift(il[459]) + , kernel_note_hash_exist_write_offset_shift(il[460]) + , kernel_nullifier_exists_write_offset_shift(il[461]) + , kernel_nullifier_non_exists_write_offset_shift(il[462]) + , kernel_side_effect_counter_shift(il[463]) + , kernel_sload_write_offset_shift(il[464]) + , kernel_sstore_write_offset_shift(il[465]) + , main_da_gas_remaining_shift(il[466]) + , main_internal_return_ptr_shift(il[467]) + , main_l2_gas_remaining_shift(il[468]) + , main_pc_shift(il[469]) + , mem_glob_addr_shift(il[470]) + , mem_rw_shift(il[471]) + , mem_sel_mem_shift(il[472]) + , mem_tag_shift(il[473]) + , mem_tsp_shift(il[474]) + , mem_val_shift(il[475]) + , slice_addr_shift(il[476]) + , slice_clk_shift(il[477]) + , slice_cnt_shift(il[478]) + , slice_col_offset_shift(il[479]) + , slice_sel_cd_cpy_shift(il[480]) + , slice_sel_mem_active_shift(il[481]) + , slice_sel_return_shift(il[482]) + , slice_sel_start_shift(il[483]) + , slice_space_id_shift(il[484]) + {} + }; + + /** + * @brief A container for the prover polynomials handles. + */ + class ProverPolynomials : public AllEntities { + public: + // Define all operations as default, except copy construction/assignment + ProverPolynomials() = default; + ProverPolynomials& operator=(const ProverPolynomials&) = delete; + ProverPolynomials(const ProverPolynomials& o) = delete; + ProverPolynomials(ProverPolynomials&& o) noexcept = default; + ProverPolynomials& operator=(ProverPolynomials&& o) noexcept = default; + ~ProverPolynomials() = default; + + ProverPolynomials(ProvingKey& proving_key) + { + for (auto [prover_poly, key_poly] : zip_view(this->get_unshifted(), proving_key.get_all())) { + ASSERT(flavor_get_label(*this, prover_poly) == flavor_get_label(proving_key, key_poly)); + prover_poly = key_poly.share(); + } + for (auto [prover_poly, key_poly] : zip_view(this->get_shifted(), proving_key.get_to_be_shifted())) { + ASSERT(flavor_get_label(*this, prover_poly) == (flavor_get_label(proving_key, key_poly) + "_shift")); + prover_poly = key_poly.shifted(); + } + } + + [[nodiscard]] size_t get_polynomial_size() const { return kernel_kernel_inputs.size(); } + /** + * @brief Returns the evaluations of all prover polynomials at one point on the boolean hypercube, which + * represents one row in the execution trace. + */ + [[nodiscard]] AllConstRefValues get_row(size_t row_idx) const + { + return AllConstRefValues(RefArray{ main_clk[row_idx], + main_sel_first[row_idx], + kernel_kernel_inputs[row_idx], + kernel_kernel_value_out[row_idx], + kernel_kernel_side_effect_out[row_idx], + kernel_kernel_metadata_out[row_idx], + main_calldata[row_idx], + main_returndata[row_idx], + alu_a_hi[row_idx], + alu_a_lo[row_idx], + alu_b_hi[row_idx], + alu_b_lo[row_idx], + alu_borrow[row_idx], + alu_cf[row_idx], + alu_clk[row_idx], + alu_cmp_rng_ctr[row_idx], + alu_div_u16_r0[row_idx], + alu_div_u16_r1[row_idx], + alu_div_u16_r2[row_idx], + alu_div_u16_r3[row_idx], + alu_div_u16_r4[row_idx], + alu_div_u16_r5[row_idx], + alu_div_u16_r6[row_idx], + alu_div_u16_r7[row_idx], + alu_divisor_hi[row_idx], + alu_divisor_lo[row_idx], + alu_ff_tag[row_idx], + alu_ia[row_idx], + alu_ib[row_idx], + alu_ic[row_idx], + alu_in_tag[row_idx], + alu_op_add[row_idx], + alu_op_cast[row_idx], + alu_op_cast_prev[row_idx], + alu_op_div[row_idx], + alu_op_div_a_lt_b[row_idx], + alu_op_div_std[row_idx], + alu_op_eq[row_idx], + alu_op_eq_diff_inv[row_idx], + alu_op_lt[row_idx], + alu_op_lte[row_idx], + alu_op_mul[row_idx], + alu_op_not[row_idx], + alu_op_shl[row_idx], + alu_op_shr[row_idx], + alu_op_sub[row_idx], + alu_p_a_borrow[row_idx], + alu_p_b_borrow[row_idx], + alu_p_sub_a_hi[row_idx], + alu_p_sub_a_lo[row_idx], + alu_p_sub_b_hi[row_idx], + alu_p_sub_b_lo[row_idx], + alu_partial_prod_hi[row_idx], + alu_partial_prod_lo[row_idx], + alu_quotient_hi[row_idx], + alu_quotient_lo[row_idx], + alu_remainder[row_idx], + alu_res_hi[row_idx], + alu_res_lo[row_idx], + alu_sel_alu[row_idx], + alu_sel_cmp[row_idx], + alu_sel_div_rng_chk[row_idx], + alu_sel_rng_chk[row_idx], + alu_sel_rng_chk_lookup[row_idx], + alu_sel_shift_which[row_idx], + alu_shift_lt_bit_len[row_idx], + alu_t_sub_s_bits[row_idx], + alu_two_pow_s[row_idx], + alu_two_pow_t_sub_s[row_idx], + alu_u128_tag[row_idx], + alu_u16_r0[row_idx], + alu_u16_r1[row_idx], + alu_u16_r10[row_idx], + alu_u16_r11[row_idx], + alu_u16_r12[row_idx], + alu_u16_r13[row_idx], + alu_u16_r14[row_idx], + alu_u16_r2[row_idx], + alu_u16_r3[row_idx], + alu_u16_r4[row_idx], + alu_u16_r5[row_idx], + alu_u16_r6[row_idx], + alu_u16_r7[row_idx], + alu_u16_r8[row_idx], + alu_u16_r9[row_idx], + alu_u16_tag[row_idx], + alu_u32_tag[row_idx], + alu_u64_tag[row_idx], + alu_u8_r0[row_idx], + alu_u8_r1[row_idx], + alu_u8_tag[row_idx], + binary_acc_ia[row_idx], + binary_acc_ib[row_idx], + binary_acc_ic[row_idx], + binary_clk[row_idx], + binary_ia_bytes[row_idx], + binary_ib_bytes[row_idx], + binary_ic_bytes[row_idx], + binary_in_tag[row_idx], + binary_mem_tag_ctr[row_idx], + binary_mem_tag_ctr_inv[row_idx], + binary_op_id[row_idx], + binary_sel_bin[row_idx], + binary_start[row_idx], + byte_lookup_sel_bin[row_idx], + byte_lookup_table_byte_lengths[row_idx], + byte_lookup_table_in_tags[row_idx], + byte_lookup_table_input_a[row_idx], + byte_lookup_table_input_b[row_idx], + byte_lookup_table_op_id[row_idx], + byte_lookup_table_output[row_idx], + conversion_clk[row_idx], + conversion_input[row_idx], + conversion_num_limbs[row_idx], + conversion_radix[row_idx], + conversion_sel_to_radix_le[row_idx], + gas_da_gas_fixed_table[row_idx], + gas_l2_gas_fixed_table[row_idx], + gas_sel_gas_cost[row_idx], + keccakf1600_clk[row_idx], + keccakf1600_input[row_idx], + keccakf1600_output[row_idx], + keccakf1600_sel_keccakf1600[row_idx], + kernel_emit_l2_to_l1_msg_write_offset[row_idx], + kernel_emit_note_hash_write_offset[row_idx], + kernel_emit_nullifier_write_offset[row_idx], + kernel_emit_unencrypted_log_write_offset[row_idx], + kernel_kernel_in_offset[row_idx], + kernel_kernel_out_offset[row_idx], + kernel_l1_to_l2_msg_exists_write_offset[row_idx], + kernel_note_hash_exist_write_offset[row_idx], + kernel_nullifier_exists_write_offset[row_idx], + kernel_nullifier_non_exists_write_offset[row_idx], + kernel_q_public_input_kernel_add_to_table[row_idx], + kernel_q_public_input_kernel_out_add_to_table[row_idx], + kernel_side_effect_counter[row_idx], + kernel_sload_write_offset[row_idx], + kernel_sstore_write_offset[row_idx], + main_abs_da_rem_gas_hi[row_idx], + main_abs_da_rem_gas_lo[row_idx], + main_abs_l2_rem_gas_hi[row_idx], + main_abs_l2_rem_gas_lo[row_idx], + main_alu_in_tag[row_idx], + main_bin_op_id[row_idx], + main_call_ptr[row_idx], + main_da_gas_op_cost[row_idx], + main_da_gas_remaining[row_idx], + main_da_out_of_gas[row_idx], + main_ia[row_idx], + main_ib[row_idx], + main_ic[row_idx], + main_id[row_idx], + main_id_zero[row_idx], + main_ind_addr_a[row_idx], + main_ind_addr_b[row_idx], + main_ind_addr_c[row_idx], + main_ind_addr_d[row_idx], + main_internal_return_ptr[row_idx], + main_inv[row_idx], + main_l2_gas_op_cost[row_idx], + main_l2_gas_remaining[row_idx], + main_l2_out_of_gas[row_idx], + main_mem_addr_a[row_idx], + main_mem_addr_b[row_idx], + main_mem_addr_c[row_idx], + main_mem_addr_d[row_idx], + main_op_err[row_idx], + main_opcode_val[row_idx], + main_pc[row_idx], + main_r_in_tag[row_idx], + main_rwa[row_idx], + main_rwb[row_idx], + main_rwc[row_idx], + main_rwd[row_idx], + main_sel_alu[row_idx], + main_sel_bin[row_idx], + main_sel_calldata[row_idx], + main_sel_gas_accounting_active[row_idx], + main_sel_last[row_idx], + main_sel_mem_op_a[row_idx], + main_sel_mem_op_activate_gas[row_idx], + main_sel_mem_op_b[row_idx], + main_sel_mem_op_c[row_idx], + main_sel_mem_op_d[row_idx], + main_sel_mov_ia_to_ic[row_idx], + main_sel_mov_ib_to_ic[row_idx], + main_sel_op_add[row_idx], + main_sel_op_address[row_idx], + main_sel_op_and[row_idx], + main_sel_op_block_number[row_idx], + main_sel_op_calldata_copy[row_idx], + main_sel_op_cast[row_idx], + main_sel_op_chain_id[row_idx], + main_sel_op_cmov[row_idx], + main_sel_op_coinbase[row_idx], + main_sel_op_dagasleft[row_idx], + main_sel_op_div[row_idx], + main_sel_op_emit_l2_to_l1_msg[row_idx], + main_sel_op_emit_note_hash[row_idx], + main_sel_op_emit_nullifier[row_idx], + main_sel_op_emit_unencrypted_log[row_idx], + main_sel_op_eq[row_idx], + main_sel_op_external_call[row_idx], + main_sel_op_external_return[row_idx], + main_sel_op_fdiv[row_idx], + main_sel_op_fee_per_da_gas[row_idx], + main_sel_op_fee_per_l2_gas[row_idx], + main_sel_op_function_selector[row_idx], + main_sel_op_get_contract_instance[row_idx], + main_sel_op_halt[row_idx], + main_sel_op_internal_call[row_idx], + main_sel_op_internal_return[row_idx], + main_sel_op_jump[row_idx], + main_sel_op_jumpi[row_idx], + main_sel_op_keccak[row_idx], + main_sel_op_l1_to_l2_msg_exists[row_idx], + main_sel_op_l2gasleft[row_idx], + main_sel_op_lt[row_idx], + main_sel_op_lte[row_idx], + main_sel_op_mov[row_idx], + main_sel_op_mul[row_idx], + main_sel_op_not[row_idx], + main_sel_op_note_hash_exists[row_idx], + main_sel_op_nullifier_exists[row_idx], + main_sel_op_or[row_idx], + main_sel_op_pedersen[row_idx], + main_sel_op_poseidon2[row_idx], + main_sel_op_radix_le[row_idx], + main_sel_op_sender[row_idx], + main_sel_op_sha256[row_idx], + main_sel_op_shl[row_idx], + main_sel_op_shr[row_idx], + main_sel_op_sload[row_idx], + main_sel_op_sstore[row_idx], + main_sel_op_storage_address[row_idx], + main_sel_op_sub[row_idx], + main_sel_op_timestamp[row_idx], + main_sel_op_transaction_fee[row_idx], + main_sel_op_version[row_idx], + main_sel_op_xor[row_idx], + main_sel_q_kernel_lookup[row_idx], + main_sel_q_kernel_output_lookup[row_idx], + main_sel_resolve_ind_addr_a[row_idx], + main_sel_resolve_ind_addr_b[row_idx], + main_sel_resolve_ind_addr_c[row_idx], + main_sel_resolve_ind_addr_d[row_idx], + main_sel_returndata[row_idx], + main_sel_rng_16[row_idx], + main_sel_rng_8[row_idx], + main_sel_slice_gadget[row_idx], + main_space_id[row_idx], + main_tag_err[row_idx], + main_w_in_tag[row_idx], + mem_addr[row_idx], + mem_clk[row_idx], + mem_diff_hi[row_idx], + mem_diff_lo[row_idx], + mem_diff_mid[row_idx], + mem_glob_addr[row_idx], + mem_last[row_idx], + mem_lastAccess[row_idx], + mem_one_min_inv[row_idx], + mem_r_in_tag[row_idx], + mem_rw[row_idx], + mem_sel_mem[row_idx], + mem_sel_mov_ia_to_ic[row_idx], + mem_sel_mov_ib_to_ic[row_idx], + mem_sel_op_a[row_idx], + mem_sel_op_b[row_idx], + mem_sel_op_c[row_idx], + mem_sel_op_cmov[row_idx], + mem_sel_op_d[row_idx], + mem_sel_op_slice[row_idx], + mem_sel_resolve_ind_addr_a[row_idx], + mem_sel_resolve_ind_addr_b[row_idx], + mem_sel_resolve_ind_addr_c[row_idx], + mem_sel_resolve_ind_addr_d[row_idx], + mem_sel_rng_chk[row_idx], + mem_skip_check_tag[row_idx], + mem_space_id[row_idx], + mem_tag[row_idx], + mem_tag_err[row_idx], + mem_tsp[row_idx], + mem_val[row_idx], + mem_w_in_tag[row_idx], + pedersen_clk[row_idx], + pedersen_input[row_idx], + pedersen_output[row_idx], + pedersen_sel_pedersen[row_idx], + poseidon2_clk[row_idx], + poseidon2_input[row_idx], + poseidon2_output[row_idx], + poseidon2_sel_poseidon_perm[row_idx], + powers_power_of_2[row_idx], + sha256_clk[row_idx], + sha256_input[row_idx], + sha256_output[row_idx], + sha256_sel_sha256_compression[row_idx], + sha256_state[row_idx], + slice_addr[row_idx], + slice_clk[row_idx], + slice_cnt[row_idx], + slice_col_offset[row_idx], + slice_one_min_inv[row_idx], + slice_sel_cd_cpy[row_idx], + slice_sel_mem_active[row_idx], + slice_sel_return[row_idx], + slice_sel_start[row_idx], + slice_space_id[row_idx], + slice_val[row_idx], + lookup_byte_lengths_counts[row_idx], + lookup_byte_operations_counts[row_idx], + lookup_cd_value_counts[row_idx], + lookup_ret_value_counts[row_idx], + lookup_opcode_gas_counts[row_idx], + range_check_l2_gas_hi_counts[row_idx], + range_check_l2_gas_lo_counts[row_idx], + range_check_da_gas_hi_counts[row_idx], + range_check_da_gas_lo_counts[row_idx], + kernel_output_lookup_counts[row_idx], + lookup_into_kernel_counts[row_idx], + incl_main_tag_err_counts[row_idx], + incl_mem_tag_err_counts[row_idx], + lookup_mem_rng_chk_lo_counts[row_idx], + lookup_mem_rng_chk_mid_counts[row_idx], + lookup_mem_rng_chk_hi_counts[row_idx], + lookup_pow_2_0_counts[row_idx], + lookup_pow_2_1_counts[row_idx], + lookup_u8_0_counts[row_idx], + lookup_u8_1_counts[row_idx], + lookup_u16_0_counts[row_idx], + lookup_u16_1_counts[row_idx], + lookup_u16_2_counts[row_idx], + lookup_u16_3_counts[row_idx], + lookup_u16_4_counts[row_idx], + lookup_u16_5_counts[row_idx], + lookup_u16_6_counts[row_idx], + lookup_u16_7_counts[row_idx], + lookup_u16_8_counts[row_idx], + lookup_u16_9_counts[row_idx], + lookup_u16_10_counts[row_idx], + lookup_u16_11_counts[row_idx], + lookup_u16_12_counts[row_idx], + lookup_u16_13_counts[row_idx], + lookup_u16_14_counts[row_idx], + lookup_div_u16_0_counts[row_idx], + lookup_div_u16_1_counts[row_idx], + lookup_div_u16_2_counts[row_idx], + lookup_div_u16_3_counts[row_idx], + lookup_div_u16_4_counts[row_idx], + lookup_div_u16_5_counts[row_idx], + lookup_div_u16_6_counts[row_idx], + lookup_div_u16_7_counts[row_idx], + perm_slice_mem[row_idx], + perm_main_alu[row_idx], + perm_main_bin[row_idx], + perm_main_conv[row_idx], + perm_main_pos2_perm[row_idx], + perm_main_pedersen[row_idx], + perm_main_slice[row_idx], + perm_main_mem_a[row_idx], + perm_main_mem_b[row_idx], + perm_main_mem_c[row_idx], + perm_main_mem_d[row_idx], + perm_main_mem_ind_addr_a[row_idx], + perm_main_mem_ind_addr_b[row_idx], + perm_main_mem_ind_addr_c[row_idx], + perm_main_mem_ind_addr_d[row_idx], + lookup_byte_lengths[row_idx], + lookup_byte_operations[row_idx], + lookup_cd_value[row_idx], + lookup_ret_value[row_idx], + lookup_opcode_gas[row_idx], + range_check_l2_gas_hi[row_idx], + range_check_l2_gas_lo[row_idx], + range_check_da_gas_hi[row_idx], + range_check_da_gas_lo[row_idx], + kernel_output_lookup[row_idx], + lookup_into_kernel[row_idx], + incl_main_tag_err[row_idx], + incl_mem_tag_err[row_idx], + lookup_mem_rng_chk_lo[row_idx], + lookup_mem_rng_chk_mid[row_idx], + lookup_mem_rng_chk_hi[row_idx], + lookup_pow_2_0[row_idx], + lookup_pow_2_1[row_idx], + lookup_u8_0[row_idx], + lookup_u8_1[row_idx], + lookup_u16_0[row_idx], + lookup_u16_1[row_idx], + lookup_u16_2[row_idx], + lookup_u16_3[row_idx], + lookup_u16_4[row_idx], + lookup_u16_5[row_idx], + lookup_u16_6[row_idx], + lookup_u16_7[row_idx], + lookup_u16_8[row_idx], + lookup_u16_9[row_idx], + lookup_u16_10[row_idx], + lookup_u16_11[row_idx], + lookup_u16_12[row_idx], + lookup_u16_13[row_idx], + lookup_u16_14[row_idx], + lookup_div_u16_0[row_idx], + lookup_div_u16_1[row_idx], + lookup_div_u16_2[row_idx], + lookup_div_u16_3[row_idx], + lookup_div_u16_4[row_idx], + lookup_div_u16_5[row_idx], + lookup_div_u16_6[row_idx], + lookup_div_u16_7[row_idx], + alu_a_hi_shift[row_idx], + alu_a_lo_shift[row_idx], + alu_b_hi_shift[row_idx], + alu_b_lo_shift[row_idx], + alu_cmp_rng_ctr_shift[row_idx], + alu_div_u16_r0_shift[row_idx], + alu_div_u16_r1_shift[row_idx], + alu_div_u16_r2_shift[row_idx], + alu_div_u16_r3_shift[row_idx], + alu_div_u16_r4_shift[row_idx], + alu_div_u16_r5_shift[row_idx], + alu_div_u16_r6_shift[row_idx], + alu_div_u16_r7_shift[row_idx], + alu_op_add_shift[row_idx], + alu_op_cast_prev_shift[row_idx], + alu_op_cast_shift[row_idx], + alu_op_div_shift[row_idx], + alu_op_mul_shift[row_idx], + alu_op_shl_shift[row_idx], + alu_op_shr_shift[row_idx], + alu_op_sub_shift[row_idx], + alu_p_sub_a_hi_shift[row_idx], + alu_p_sub_a_lo_shift[row_idx], + alu_p_sub_b_hi_shift[row_idx], + alu_p_sub_b_lo_shift[row_idx], + alu_sel_alu_shift[row_idx], + alu_sel_cmp_shift[row_idx], + alu_sel_div_rng_chk_shift[row_idx], + alu_sel_rng_chk_lookup_shift[row_idx], + alu_sel_rng_chk_shift[row_idx], + alu_u16_r0_shift[row_idx], + alu_u16_r1_shift[row_idx], + alu_u16_r2_shift[row_idx], + alu_u16_r3_shift[row_idx], + alu_u16_r4_shift[row_idx], + alu_u16_r5_shift[row_idx], + alu_u16_r6_shift[row_idx], + alu_u8_r0_shift[row_idx], + alu_u8_r1_shift[row_idx], + binary_acc_ia_shift[row_idx], + binary_acc_ib_shift[row_idx], + binary_acc_ic_shift[row_idx], + binary_mem_tag_ctr_shift[row_idx], + binary_op_id_shift[row_idx], + kernel_emit_l2_to_l1_msg_write_offset_shift[row_idx], + kernel_emit_note_hash_write_offset_shift[row_idx], + kernel_emit_nullifier_write_offset_shift[row_idx], + kernel_emit_unencrypted_log_write_offset_shift[row_idx], + kernel_l1_to_l2_msg_exists_write_offset_shift[row_idx], + kernel_note_hash_exist_write_offset_shift[row_idx], + kernel_nullifier_exists_write_offset_shift[row_idx], + kernel_nullifier_non_exists_write_offset_shift[row_idx], + kernel_side_effect_counter_shift[row_idx], + kernel_sload_write_offset_shift[row_idx], + kernel_sstore_write_offset_shift[row_idx], + main_da_gas_remaining_shift[row_idx], + main_internal_return_ptr_shift[row_idx], + main_l2_gas_remaining_shift[row_idx], + main_pc_shift[row_idx], + mem_glob_addr_shift[row_idx], + mem_rw_shift[row_idx], + mem_sel_mem_shift[row_idx], + mem_tag_shift[row_idx], + mem_tsp_shift[row_idx], + mem_val_shift[row_idx], + slice_addr_shift[row_idx], + slice_clk_shift[row_idx], + slice_cnt_shift[row_idx], + slice_col_offset_shift[row_idx], + slice_sel_cd_cpy_shift[row_idx], + slice_sel_mem_active_shift[row_idx], + slice_sel_return_shift[row_idx], + slice_sel_start_shift[row_idx], + slice_space_id_shift[row_idx] }); + } + }; + + class PartiallyEvaluatedMultivariates : public AllEntities { + public: + PartiallyEvaluatedMultivariates() = default; + PartiallyEvaluatedMultivariates(const size_t circuit_size) + { + // Storage is only needed after the first partial evaluation, hence polynomials of size (n / 2) + for (auto& poly : get_all()) { + poly = Polynomial(circuit_size / 2); + } + } + }; + + /** + * @brief A container for univariates used during Protogalaxy folding and sumcheck. + * @details During folding and sumcheck, the prover evaluates the relations on these univariates. + */ + template using ProverUnivariates = AllEntities>; + + /** + * @brief A container for univariates used during Protogalaxy folding and sumcheck with some of the computation + * optimistically ignored + * @details During folding and sumcheck, the prover evaluates the relations on these univariates. + */ + template + using OptimisedProverUnivariates = AllEntities>; + + /** + * @brief A container for univariates produced during the hot loop in sumcheck. + */ + using ExtendedEdges = ProverUnivariates; + + /** + * @brief A container for the witness commitments. + * + */ + using WitnessCommitments = WitnessEntities; + + class CommitmentLabels : public AllEntities { + private: + using Base = AllEntities; + + public: + CommitmentLabels() + { + Base::main_clk = "MAIN_CLK"; + Base::main_sel_first = "MAIN_SEL_FIRST"; + Base::kernel_kernel_inputs = "KERNEL_KERNEL_INPUTS"; + Base::kernel_kernel_value_out = "KERNEL_KERNEL_VALUE_OUT"; + Base::kernel_kernel_side_effect_out = "KERNEL_KERNEL_SIDE_EFFECT_OUT"; + Base::kernel_kernel_metadata_out = "KERNEL_KERNEL_METADATA_OUT"; + Base::main_calldata = "MAIN_CALLDATA"; + Base::main_returndata = "MAIN_RETURNDATA"; + Base::alu_a_hi = "ALU_A_HI"; + Base::alu_a_lo = "ALU_A_LO"; + Base::alu_b_hi = "ALU_B_HI"; + Base::alu_b_lo = "ALU_B_LO"; + Base::alu_borrow = "ALU_BORROW"; + Base::alu_cf = "ALU_CF"; + Base::alu_clk = "ALU_CLK"; + Base::alu_cmp_rng_ctr = "ALU_CMP_RNG_CTR"; + Base::alu_div_u16_r0 = "ALU_DIV_U16_R0"; + Base::alu_div_u16_r1 = "ALU_DIV_U16_R1"; + Base::alu_div_u16_r2 = "ALU_DIV_U16_R2"; + Base::alu_div_u16_r3 = "ALU_DIV_U16_R3"; + Base::alu_div_u16_r4 = "ALU_DIV_U16_R4"; + Base::alu_div_u16_r5 = "ALU_DIV_U16_R5"; + Base::alu_div_u16_r6 = "ALU_DIV_U16_R6"; + Base::alu_div_u16_r7 = "ALU_DIV_U16_R7"; + Base::alu_divisor_hi = "ALU_DIVISOR_HI"; + Base::alu_divisor_lo = "ALU_DIVISOR_LO"; + Base::alu_ff_tag = "ALU_FF_TAG"; + Base::alu_ia = "ALU_IA"; + Base::alu_ib = "ALU_IB"; + Base::alu_ic = "ALU_IC"; + Base::alu_in_tag = "ALU_IN_TAG"; + Base::alu_op_add = "ALU_OP_ADD"; + Base::alu_op_cast = "ALU_OP_CAST"; + Base::alu_op_cast_prev = "ALU_OP_CAST_PREV"; + Base::alu_op_div = "ALU_OP_DIV"; + Base::alu_op_div_a_lt_b = "ALU_OP_DIV_A_LT_B"; + Base::alu_op_div_std = "ALU_OP_DIV_STD"; + Base::alu_op_eq = "ALU_OP_EQ"; + Base::alu_op_eq_diff_inv = "ALU_OP_EQ_DIFF_INV"; + Base::alu_op_lt = "ALU_OP_LT"; + Base::alu_op_lte = "ALU_OP_LTE"; + Base::alu_op_mul = "ALU_OP_MUL"; + Base::alu_op_not = "ALU_OP_NOT"; + Base::alu_op_shl = "ALU_OP_SHL"; + Base::alu_op_shr = "ALU_OP_SHR"; + Base::alu_op_sub = "ALU_OP_SUB"; + Base::alu_p_a_borrow = "ALU_P_A_BORROW"; + Base::alu_p_b_borrow = "ALU_P_B_BORROW"; + Base::alu_p_sub_a_hi = "ALU_P_SUB_A_HI"; + Base::alu_p_sub_a_lo = "ALU_P_SUB_A_LO"; + Base::alu_p_sub_b_hi = "ALU_P_SUB_B_HI"; + Base::alu_p_sub_b_lo = "ALU_P_SUB_B_LO"; + Base::alu_partial_prod_hi = "ALU_PARTIAL_PROD_HI"; + Base::alu_partial_prod_lo = "ALU_PARTIAL_PROD_LO"; + Base::alu_quotient_hi = "ALU_QUOTIENT_HI"; + Base::alu_quotient_lo = "ALU_QUOTIENT_LO"; + Base::alu_remainder = "ALU_REMAINDER"; + Base::alu_res_hi = "ALU_RES_HI"; + Base::alu_res_lo = "ALU_RES_LO"; + Base::alu_sel_alu = "ALU_SEL_ALU"; + Base::alu_sel_cmp = "ALU_SEL_CMP"; + Base::alu_sel_div_rng_chk = "ALU_SEL_DIV_RNG_CHK"; + Base::alu_sel_rng_chk = "ALU_SEL_RNG_CHK"; + Base::alu_sel_rng_chk_lookup = "ALU_SEL_RNG_CHK_LOOKUP"; + Base::alu_sel_shift_which = "ALU_SEL_SHIFT_WHICH"; + Base::alu_shift_lt_bit_len = "ALU_SHIFT_LT_BIT_LEN"; + Base::alu_t_sub_s_bits = "ALU_T_SUB_S_BITS"; + Base::alu_two_pow_s = "ALU_TWO_POW_S"; + Base::alu_two_pow_t_sub_s = "ALU_TWO_POW_T_SUB_S"; + Base::alu_u128_tag = "ALU_U128_TAG"; + Base::alu_u16_r0 = "ALU_U16_R0"; + Base::alu_u16_r1 = "ALU_U16_R1"; + Base::alu_u16_r10 = "ALU_U16_R10"; + Base::alu_u16_r11 = "ALU_U16_R11"; + Base::alu_u16_r12 = "ALU_U16_R12"; + Base::alu_u16_r13 = "ALU_U16_R13"; + Base::alu_u16_r14 = "ALU_U16_R14"; + Base::alu_u16_r2 = "ALU_U16_R2"; + Base::alu_u16_r3 = "ALU_U16_R3"; + Base::alu_u16_r4 = "ALU_U16_R4"; + Base::alu_u16_r5 = "ALU_U16_R5"; + Base::alu_u16_r6 = "ALU_U16_R6"; + Base::alu_u16_r7 = "ALU_U16_R7"; + Base::alu_u16_r8 = "ALU_U16_R8"; + Base::alu_u16_r9 = "ALU_U16_R9"; + Base::alu_u16_tag = "ALU_U16_TAG"; + Base::alu_u32_tag = "ALU_U32_TAG"; + Base::alu_u64_tag = "ALU_U64_TAG"; + Base::alu_u8_r0 = "ALU_U8_R0"; + Base::alu_u8_r1 = "ALU_U8_R1"; + Base::alu_u8_tag = "ALU_U8_TAG"; + Base::binary_acc_ia = "BINARY_ACC_IA"; + Base::binary_acc_ib = "BINARY_ACC_IB"; + Base::binary_acc_ic = "BINARY_ACC_IC"; + Base::binary_clk = "BINARY_CLK"; + Base::binary_ia_bytes = "BINARY_IA_BYTES"; + Base::binary_ib_bytes = "BINARY_IB_BYTES"; + Base::binary_ic_bytes = "BINARY_IC_BYTES"; + Base::binary_in_tag = "BINARY_IN_TAG"; + Base::binary_mem_tag_ctr = "BINARY_MEM_TAG_CTR"; + Base::binary_mem_tag_ctr_inv = "BINARY_MEM_TAG_CTR_INV"; + Base::binary_op_id = "BINARY_OP_ID"; + Base::binary_sel_bin = "BINARY_SEL_BIN"; + Base::binary_start = "BINARY_START"; + Base::byte_lookup_sel_bin = "BYTE_LOOKUP_SEL_BIN"; + Base::byte_lookup_table_byte_lengths = "BYTE_LOOKUP_TABLE_BYTE_LENGTHS"; + Base::byte_lookup_table_in_tags = "BYTE_LOOKUP_TABLE_IN_TAGS"; + Base::byte_lookup_table_input_a = "BYTE_LOOKUP_TABLE_INPUT_A"; + Base::byte_lookup_table_input_b = "BYTE_LOOKUP_TABLE_INPUT_B"; + Base::byte_lookup_table_op_id = "BYTE_LOOKUP_TABLE_OP_ID"; + Base::byte_lookup_table_output = "BYTE_LOOKUP_TABLE_OUTPUT"; + Base::conversion_clk = "CONVERSION_CLK"; + Base::conversion_input = "CONVERSION_INPUT"; + Base::conversion_num_limbs = "CONVERSION_NUM_LIMBS"; + Base::conversion_radix = "CONVERSION_RADIX"; + Base::conversion_sel_to_radix_le = "CONVERSION_SEL_TO_RADIX_LE"; + Base::gas_da_gas_fixed_table = "GAS_DA_GAS_FIXED_TABLE"; + Base::gas_l2_gas_fixed_table = "GAS_L2_GAS_FIXED_TABLE"; + Base::gas_sel_gas_cost = "GAS_SEL_GAS_COST"; + Base::keccakf1600_clk = "KECCAKF1600_CLK"; + Base::keccakf1600_input = "KECCAKF1600_INPUT"; + Base::keccakf1600_output = "KECCAKF1600_OUTPUT"; + Base::keccakf1600_sel_keccakf1600 = "KECCAKF1600_SEL_KECCAKF1600"; + Base::kernel_emit_l2_to_l1_msg_write_offset = "KERNEL_EMIT_L2_TO_L1_MSG_WRITE_OFFSET"; + Base::kernel_emit_note_hash_write_offset = "KERNEL_EMIT_NOTE_HASH_WRITE_OFFSET"; + Base::kernel_emit_nullifier_write_offset = "KERNEL_EMIT_NULLIFIER_WRITE_OFFSET"; + Base::kernel_emit_unencrypted_log_write_offset = "KERNEL_EMIT_UNENCRYPTED_LOG_WRITE_OFFSET"; + Base::kernel_kernel_in_offset = "KERNEL_KERNEL_IN_OFFSET"; + Base::kernel_kernel_out_offset = "KERNEL_KERNEL_OUT_OFFSET"; + Base::kernel_l1_to_l2_msg_exists_write_offset = "KERNEL_L1_TO_L2_MSG_EXISTS_WRITE_OFFSET"; + Base::kernel_note_hash_exist_write_offset = "KERNEL_NOTE_HASH_EXIST_WRITE_OFFSET"; + Base::kernel_nullifier_exists_write_offset = "KERNEL_NULLIFIER_EXISTS_WRITE_OFFSET"; + Base::kernel_nullifier_non_exists_write_offset = "KERNEL_NULLIFIER_NON_EXISTS_WRITE_OFFSET"; + Base::kernel_q_public_input_kernel_add_to_table = "KERNEL_Q_PUBLIC_INPUT_KERNEL_ADD_TO_TABLE"; + Base::kernel_q_public_input_kernel_out_add_to_table = "KERNEL_Q_PUBLIC_INPUT_KERNEL_OUT_ADD_TO_TABLE"; + Base::kernel_side_effect_counter = "KERNEL_SIDE_EFFECT_COUNTER"; + Base::kernel_sload_write_offset = "KERNEL_SLOAD_WRITE_OFFSET"; + Base::kernel_sstore_write_offset = "KERNEL_SSTORE_WRITE_OFFSET"; + Base::main_abs_da_rem_gas_hi = "MAIN_ABS_DA_REM_GAS_HI"; + Base::main_abs_da_rem_gas_lo = "MAIN_ABS_DA_REM_GAS_LO"; + Base::main_abs_l2_rem_gas_hi = "MAIN_ABS_L2_REM_GAS_HI"; + Base::main_abs_l2_rem_gas_lo = "MAIN_ABS_L2_REM_GAS_LO"; + Base::main_alu_in_tag = "MAIN_ALU_IN_TAG"; + Base::main_bin_op_id = "MAIN_BIN_OP_ID"; + Base::main_call_ptr = "MAIN_CALL_PTR"; + Base::main_da_gas_op_cost = "MAIN_DA_GAS_OP_COST"; + Base::main_da_gas_remaining = "MAIN_DA_GAS_REMAINING"; + Base::main_da_out_of_gas = "MAIN_DA_OUT_OF_GAS"; + Base::main_ia = "MAIN_IA"; + Base::main_ib = "MAIN_IB"; + Base::main_ic = "MAIN_IC"; + Base::main_id = "MAIN_ID"; + Base::main_id_zero = "MAIN_ID_ZERO"; + Base::main_ind_addr_a = "MAIN_IND_ADDR_A"; + Base::main_ind_addr_b = "MAIN_IND_ADDR_B"; + Base::main_ind_addr_c = "MAIN_IND_ADDR_C"; + Base::main_ind_addr_d = "MAIN_IND_ADDR_D"; + Base::main_internal_return_ptr = "MAIN_INTERNAL_RETURN_PTR"; + Base::main_inv = "MAIN_INV"; + Base::main_l2_gas_op_cost = "MAIN_L2_GAS_OP_COST"; + Base::main_l2_gas_remaining = "MAIN_L2_GAS_REMAINING"; + Base::main_l2_out_of_gas = "MAIN_L2_OUT_OF_GAS"; + Base::main_mem_addr_a = "MAIN_MEM_ADDR_A"; + Base::main_mem_addr_b = "MAIN_MEM_ADDR_B"; + Base::main_mem_addr_c = "MAIN_MEM_ADDR_C"; + Base::main_mem_addr_d = "MAIN_MEM_ADDR_D"; + Base::main_op_err = "MAIN_OP_ERR"; + Base::main_opcode_val = "MAIN_OPCODE_VAL"; + Base::main_pc = "MAIN_PC"; + Base::main_r_in_tag = "MAIN_R_IN_TAG"; + Base::main_rwa = "MAIN_RWA"; + Base::main_rwb = "MAIN_RWB"; + Base::main_rwc = "MAIN_RWC"; + Base::main_rwd = "MAIN_RWD"; + Base::main_sel_alu = "MAIN_SEL_ALU"; + Base::main_sel_bin = "MAIN_SEL_BIN"; + Base::main_sel_calldata = "MAIN_SEL_CALLDATA"; + Base::main_sel_gas_accounting_active = "MAIN_SEL_GAS_ACCOUNTING_ACTIVE"; + Base::main_sel_last = "MAIN_SEL_LAST"; + Base::main_sel_mem_op_a = "MAIN_SEL_MEM_OP_A"; + Base::main_sel_mem_op_activate_gas = "MAIN_SEL_MEM_OP_ACTIVATE_GAS"; + Base::main_sel_mem_op_b = "MAIN_SEL_MEM_OP_B"; + Base::main_sel_mem_op_c = "MAIN_SEL_MEM_OP_C"; + Base::main_sel_mem_op_d = "MAIN_SEL_MEM_OP_D"; + Base::main_sel_mov_ia_to_ic = "MAIN_SEL_MOV_IA_TO_IC"; + Base::main_sel_mov_ib_to_ic = "MAIN_SEL_MOV_IB_TO_IC"; + Base::main_sel_op_add = "MAIN_SEL_OP_ADD"; + Base::main_sel_op_address = "MAIN_SEL_OP_ADDRESS"; + Base::main_sel_op_and = "MAIN_SEL_OP_AND"; + Base::main_sel_op_block_number = "MAIN_SEL_OP_BLOCK_NUMBER"; + Base::main_sel_op_calldata_copy = "MAIN_SEL_OP_CALLDATA_COPY"; + Base::main_sel_op_cast = "MAIN_SEL_OP_CAST"; + Base::main_sel_op_chain_id = "MAIN_SEL_OP_CHAIN_ID"; + Base::main_sel_op_cmov = "MAIN_SEL_OP_CMOV"; + Base::main_sel_op_coinbase = "MAIN_SEL_OP_COINBASE"; + Base::main_sel_op_dagasleft = "MAIN_SEL_OP_DAGASLEFT"; + Base::main_sel_op_div = "MAIN_SEL_OP_DIV"; + Base::main_sel_op_emit_l2_to_l1_msg = "MAIN_SEL_OP_EMIT_L2_TO_L1_MSG"; + Base::main_sel_op_emit_note_hash = "MAIN_SEL_OP_EMIT_NOTE_HASH"; + Base::main_sel_op_emit_nullifier = "MAIN_SEL_OP_EMIT_NULLIFIER"; + Base::main_sel_op_emit_unencrypted_log = "MAIN_SEL_OP_EMIT_UNENCRYPTED_LOG"; + Base::main_sel_op_eq = "MAIN_SEL_OP_EQ"; + Base::main_sel_op_external_call = "MAIN_SEL_OP_EXTERNAL_CALL"; + Base::main_sel_op_external_return = "MAIN_SEL_OP_EXTERNAL_RETURN"; + Base::main_sel_op_fdiv = "MAIN_SEL_OP_FDIV"; + Base::main_sel_op_fee_per_da_gas = "MAIN_SEL_OP_FEE_PER_DA_GAS"; + Base::main_sel_op_fee_per_l2_gas = "MAIN_SEL_OP_FEE_PER_L2_GAS"; + Base::main_sel_op_function_selector = "MAIN_SEL_OP_FUNCTION_SELECTOR"; + Base::main_sel_op_get_contract_instance = "MAIN_SEL_OP_GET_CONTRACT_INSTANCE"; + Base::main_sel_op_halt = "MAIN_SEL_OP_HALT"; + Base::main_sel_op_internal_call = "MAIN_SEL_OP_INTERNAL_CALL"; + Base::main_sel_op_internal_return = "MAIN_SEL_OP_INTERNAL_RETURN"; + Base::main_sel_op_jump = "MAIN_SEL_OP_JUMP"; + Base::main_sel_op_jumpi = "MAIN_SEL_OP_JUMPI"; + Base::main_sel_op_keccak = "MAIN_SEL_OP_KECCAK"; + Base::main_sel_op_l1_to_l2_msg_exists = "MAIN_SEL_OP_L1_TO_L2_MSG_EXISTS"; + Base::main_sel_op_l2gasleft = "MAIN_SEL_OP_L2GASLEFT"; + Base::main_sel_op_lt = "MAIN_SEL_OP_LT"; + Base::main_sel_op_lte = "MAIN_SEL_OP_LTE"; + Base::main_sel_op_mov = "MAIN_SEL_OP_MOV"; + Base::main_sel_op_mul = "MAIN_SEL_OP_MUL"; + Base::main_sel_op_not = "MAIN_SEL_OP_NOT"; + Base::main_sel_op_note_hash_exists = "MAIN_SEL_OP_NOTE_HASH_EXISTS"; + Base::main_sel_op_nullifier_exists = "MAIN_SEL_OP_NULLIFIER_EXISTS"; + Base::main_sel_op_or = "MAIN_SEL_OP_OR"; + Base::main_sel_op_pedersen = "MAIN_SEL_OP_PEDERSEN"; + Base::main_sel_op_poseidon2 = "MAIN_SEL_OP_POSEIDON2"; + Base::main_sel_op_radix_le = "MAIN_SEL_OP_RADIX_LE"; + Base::main_sel_op_sender = "MAIN_SEL_OP_SENDER"; + Base::main_sel_op_sha256 = "MAIN_SEL_OP_SHA256"; + Base::main_sel_op_shl = "MAIN_SEL_OP_SHL"; + Base::main_sel_op_shr = "MAIN_SEL_OP_SHR"; + Base::main_sel_op_sload = "MAIN_SEL_OP_SLOAD"; + Base::main_sel_op_sstore = "MAIN_SEL_OP_SSTORE"; + Base::main_sel_op_storage_address = "MAIN_SEL_OP_STORAGE_ADDRESS"; + Base::main_sel_op_sub = "MAIN_SEL_OP_SUB"; + Base::main_sel_op_timestamp = "MAIN_SEL_OP_TIMESTAMP"; + Base::main_sel_op_transaction_fee = "MAIN_SEL_OP_TRANSACTION_FEE"; + Base::main_sel_op_version = "MAIN_SEL_OP_VERSION"; + Base::main_sel_op_xor = "MAIN_SEL_OP_XOR"; + Base::main_sel_q_kernel_lookup = "MAIN_SEL_Q_KERNEL_LOOKUP"; + Base::main_sel_q_kernel_output_lookup = "MAIN_SEL_Q_KERNEL_OUTPUT_LOOKUP"; + Base::main_sel_resolve_ind_addr_a = "MAIN_SEL_RESOLVE_IND_ADDR_A"; + Base::main_sel_resolve_ind_addr_b = "MAIN_SEL_RESOLVE_IND_ADDR_B"; + Base::main_sel_resolve_ind_addr_c = "MAIN_SEL_RESOLVE_IND_ADDR_C"; + Base::main_sel_resolve_ind_addr_d = "MAIN_SEL_RESOLVE_IND_ADDR_D"; + Base::main_sel_returndata = "MAIN_SEL_RETURNDATA"; + Base::main_sel_rng_16 = "MAIN_SEL_RNG_16"; + Base::main_sel_rng_8 = "MAIN_SEL_RNG_8"; + Base::main_sel_slice_gadget = "MAIN_SEL_SLICE_GADGET"; + Base::main_space_id = "MAIN_SPACE_ID"; + Base::main_tag_err = "MAIN_TAG_ERR"; + Base::main_w_in_tag = "MAIN_W_IN_TAG"; + Base::mem_addr = "MEM_ADDR"; + Base::mem_clk = "MEM_CLK"; + Base::mem_diff_hi = "MEM_DIFF_HI"; + Base::mem_diff_lo = "MEM_DIFF_LO"; + Base::mem_diff_mid = "MEM_DIFF_MID"; + Base::mem_glob_addr = "MEM_GLOB_ADDR"; + Base::mem_last = "MEM_LAST"; + Base::mem_lastAccess = "MEM_LAST_ACCESS"; + Base::mem_one_min_inv = "MEM_ONE_MIN_INV"; + Base::mem_r_in_tag = "MEM_R_IN_TAG"; + Base::mem_rw = "MEM_RW"; + Base::mem_sel_mem = "MEM_SEL_MEM"; + Base::mem_sel_mov_ia_to_ic = "MEM_SEL_MOV_IA_TO_IC"; + Base::mem_sel_mov_ib_to_ic = "MEM_SEL_MOV_IB_TO_IC"; + Base::mem_sel_op_a = "MEM_SEL_OP_A"; + Base::mem_sel_op_b = "MEM_SEL_OP_B"; + Base::mem_sel_op_c = "MEM_SEL_OP_C"; + Base::mem_sel_op_cmov = "MEM_SEL_OP_CMOV"; + Base::mem_sel_op_d = "MEM_SEL_OP_D"; + Base::mem_sel_op_slice = "MEM_SEL_OP_SLICE"; + Base::mem_sel_resolve_ind_addr_a = "MEM_SEL_RESOLVE_IND_ADDR_A"; + Base::mem_sel_resolve_ind_addr_b = "MEM_SEL_RESOLVE_IND_ADDR_B"; + Base::mem_sel_resolve_ind_addr_c = "MEM_SEL_RESOLVE_IND_ADDR_C"; + Base::mem_sel_resolve_ind_addr_d = "MEM_SEL_RESOLVE_IND_ADDR_D"; + Base::mem_sel_rng_chk = "MEM_SEL_RNG_CHK"; + Base::mem_skip_check_tag = "MEM_SKIP_CHECK_TAG"; + Base::mem_space_id = "MEM_SPACE_ID"; + Base::mem_tag = "MEM_TAG"; + Base::mem_tag_err = "MEM_TAG_ERR"; + Base::mem_tsp = "MEM_TSP"; + Base::mem_val = "MEM_VAL"; + Base::mem_w_in_tag = "MEM_W_IN_TAG"; + Base::pedersen_clk = "PEDERSEN_CLK"; + Base::pedersen_input = "PEDERSEN_INPUT"; + Base::pedersen_output = "PEDERSEN_OUTPUT"; + Base::pedersen_sel_pedersen = "PEDERSEN_SEL_PEDERSEN"; + Base::poseidon2_a_0 = "POSEIDON2_A_0"; + Base::poseidon2_a_1 = "POSEIDON2_A_1"; + Base::poseidon2_a_2 = "POSEIDON2_A_2"; + Base::poseidon2_a_3 = "POSEIDON2_A_3"; + Base::poseidon2_b_0 = "POSEIDON2_B_0"; + Base::poseidon2_b_1 = "POSEIDON2_B_1"; + Base::poseidon2_b_2 = "POSEIDON2_B_2"; + Base::poseidon2_b_3 = "POSEIDON2_B_3"; + Base::poseidon2_clk = "POSEIDON2_CLK"; + Base::poseidon2_input = "POSEIDON2_INPUT"; + Base::poseidon2_output = "POSEIDON2_OUTPUT"; + Base::poseidon2_sel_poseidon_perm = "POSEIDON2_SEL_POSEIDON_PERM"; + Base::powers_power_of_2 = "POWERS_POWER_OF_2"; + Base::sha256_clk = "SHA256_CLK"; + Base::sha256_input = "SHA256_INPUT"; + Base::sha256_output = "SHA256_OUTPUT"; + Base::sha256_sel_sha256_compression = "SHA256_SEL_SHA256_COMPRESSION"; + Base::sha256_state = "SHA256_STATE"; + Base::slice_addr = "SLICE_ADDR"; + Base::slice_clk = "SLICE_CLK"; + Base::slice_cnt = "SLICE_CNT"; + Base::slice_col_offset = "SLICE_COL_OFFSET"; + Base::slice_one_min_inv = "SLICE_ONE_MIN_INV"; + Base::slice_sel_cd_cpy = "SLICE_SEL_CD_CPY"; + Base::slice_sel_mem_active = "SLICE_SEL_MEM_ACTIVE"; + Base::slice_sel_return = "SLICE_SEL_RETURN"; + Base::slice_sel_start = "SLICE_SEL_START"; + Base::slice_space_id = "SLICE_SPACE_ID"; + Base::slice_val = "SLICE_VAL"; + Base::perm_slice_mem = "PERM_SLICE_MEM"; + Base::perm_main_alu = "PERM_MAIN_ALU"; + Base::perm_main_bin = "PERM_MAIN_BIN"; + Base::perm_main_conv = "PERM_MAIN_CONV"; + Base::perm_main_pos2_perm = "PERM_MAIN_POS2_PERM"; + Base::perm_main_pedersen = "PERM_MAIN_PEDERSEN"; + Base::perm_main_slice = "PERM_MAIN_SLICE"; + Base::perm_main_mem_a = "PERM_MAIN_MEM_A"; + Base::perm_main_mem_b = "PERM_MAIN_MEM_B"; + Base::perm_main_mem_c = "PERM_MAIN_MEM_C"; + Base::perm_main_mem_d = "PERM_MAIN_MEM_D"; + Base::perm_main_mem_ind_addr_a = "PERM_MAIN_MEM_IND_ADDR_A"; + Base::perm_main_mem_ind_addr_b = "PERM_MAIN_MEM_IND_ADDR_B"; + Base::perm_main_mem_ind_addr_c = "PERM_MAIN_MEM_IND_ADDR_C"; + Base::perm_main_mem_ind_addr_d = "PERM_MAIN_MEM_IND_ADDR_D"; + Base::lookup_byte_lengths = "LOOKUP_BYTE_LENGTHS"; + Base::lookup_byte_operations = "LOOKUP_BYTE_OPERATIONS"; + Base::lookup_cd_value = "LOOKUP_CD_VALUE"; + Base::lookup_ret_value = "LOOKUP_RET_VALUE"; + Base::lookup_opcode_gas = "LOOKUP_OPCODE_GAS"; + Base::range_check_l2_gas_hi = "RANGE_CHECK_L2_GAS_HI"; + Base::range_check_l2_gas_lo = "RANGE_CHECK_L2_GAS_LO"; + Base::range_check_da_gas_hi = "RANGE_CHECK_DA_GAS_HI"; + Base::range_check_da_gas_lo = "RANGE_CHECK_DA_GAS_LO"; + Base::kernel_output_lookup = "KERNEL_OUTPUT_LOOKUP"; + Base::lookup_into_kernel = "LOOKUP_INTO_KERNEL"; + Base::incl_main_tag_err = "INCL_MAIN_TAG_ERR"; + Base::incl_mem_tag_err = "INCL_MEM_TAG_ERR"; + Base::lookup_mem_rng_chk_lo = "LOOKUP_MEM_RNG_CHK_LO"; + Base::lookup_mem_rng_chk_mid = "LOOKUP_MEM_RNG_CHK_MID"; + Base::lookup_mem_rng_chk_hi = "LOOKUP_MEM_RNG_CHK_HI"; + Base::lookup_pow_2_0 = "LOOKUP_POW_2_0"; + Base::lookup_pow_2_1 = "LOOKUP_POW_2_1"; + Base::lookup_u8_0 = "LOOKUP_U8_0"; + Base::lookup_u8_1 = "LOOKUP_U8_1"; + Base::lookup_u16_0 = "LOOKUP_U16_0"; + Base::lookup_u16_1 = "LOOKUP_U16_1"; + Base::lookup_u16_2 = "LOOKUP_U16_2"; + Base::lookup_u16_3 = "LOOKUP_U16_3"; + Base::lookup_u16_4 = "LOOKUP_U16_4"; + Base::lookup_u16_5 = "LOOKUP_U16_5"; + Base::lookup_u16_6 = "LOOKUP_U16_6"; + Base::lookup_u16_7 = "LOOKUP_U16_7"; + Base::lookup_u16_8 = "LOOKUP_U16_8"; + Base::lookup_u16_9 = "LOOKUP_U16_9"; + Base::lookup_u16_10 = "LOOKUP_U16_10"; + Base::lookup_u16_11 = "LOOKUP_U16_11"; + Base::lookup_u16_12 = "LOOKUP_U16_12"; + Base::lookup_u16_13 = "LOOKUP_U16_13"; + Base::lookup_u16_14 = "LOOKUP_U16_14"; + Base::lookup_div_u16_0 = "LOOKUP_DIV_U16_0"; + Base::lookup_div_u16_1 = "LOOKUP_DIV_U16_1"; + Base::lookup_div_u16_2 = "LOOKUP_DIV_U16_2"; + Base::lookup_div_u16_3 = "LOOKUP_DIV_U16_3"; + Base::lookup_div_u16_4 = "LOOKUP_DIV_U16_4"; + Base::lookup_div_u16_5 = "LOOKUP_DIV_U16_5"; + Base::lookup_div_u16_6 = "LOOKUP_DIV_U16_6"; + Base::lookup_div_u16_7 = "LOOKUP_DIV_U16_7"; + Base::lookup_byte_lengths_counts = "LOOKUP_BYTE_LENGTHS_COUNTS"; + Base::lookup_byte_operations_counts = "LOOKUP_BYTE_OPERATIONS_COUNTS"; + Base::lookup_cd_value_counts = "LOOKUP_CD_VALUE_COUNTS"; + Base::lookup_ret_value_counts = "LOOKUP_RET_VALUE_COUNTS"; + Base::lookup_opcode_gas_counts = "LOOKUP_OPCODE_GAS_COUNTS"; + Base::range_check_l2_gas_hi_counts = "RANGE_CHECK_L2_GAS_HI_COUNTS"; + Base::range_check_l2_gas_lo_counts = "RANGE_CHECK_L2_GAS_LO_COUNTS"; + Base::range_check_da_gas_hi_counts = "RANGE_CHECK_DA_GAS_HI_COUNTS"; + Base::range_check_da_gas_lo_counts = "RANGE_CHECK_DA_GAS_LO_COUNTS"; + Base::kernel_output_lookup_counts = "KERNEL_OUTPUT_LOOKUP_COUNTS"; + Base::lookup_into_kernel_counts = "LOOKUP_INTO_KERNEL_COUNTS"; + Base::incl_main_tag_err_counts = "INCL_MAIN_TAG_ERR_COUNTS"; + Base::incl_mem_tag_err_counts = "INCL_MEM_TAG_ERR_COUNTS"; + Base::lookup_mem_rng_chk_lo_counts = "LOOKUP_MEM_RNG_CHK_LO_COUNTS"; + Base::lookup_mem_rng_chk_mid_counts = "LOOKUP_MEM_RNG_CHK_MID_COUNTS"; + Base::lookup_mem_rng_chk_hi_counts = "LOOKUP_MEM_RNG_CHK_HI_COUNTS"; + Base::lookup_pow_2_0_counts = "LOOKUP_POW_2_0_COUNTS"; + Base::lookup_pow_2_1_counts = "LOOKUP_POW_2_1_COUNTS"; + Base::lookup_u8_0_counts = "LOOKUP_U8_0_COUNTS"; + Base::lookup_u8_1_counts = "LOOKUP_U8_1_COUNTS"; + Base::lookup_u16_0_counts = "LOOKUP_U16_0_COUNTS"; + Base::lookup_u16_1_counts = "LOOKUP_U16_1_COUNTS"; + Base::lookup_u16_2_counts = "LOOKUP_U16_2_COUNTS"; + Base::lookup_u16_3_counts = "LOOKUP_U16_3_COUNTS"; + Base::lookup_u16_4_counts = "LOOKUP_U16_4_COUNTS"; + Base::lookup_u16_5_counts = "LOOKUP_U16_5_COUNTS"; + Base::lookup_u16_6_counts = "LOOKUP_U16_6_COUNTS"; + Base::lookup_u16_7_counts = "LOOKUP_U16_7_COUNTS"; + Base::lookup_u16_8_counts = "LOOKUP_U16_8_COUNTS"; + Base::lookup_u16_9_counts = "LOOKUP_U16_9_COUNTS"; + Base::lookup_u16_10_counts = "LOOKUP_U16_10_COUNTS"; + Base::lookup_u16_11_counts = "LOOKUP_U16_11_COUNTS"; + Base::lookup_u16_12_counts = "LOOKUP_U16_12_COUNTS"; + Base::lookup_u16_13_counts = "LOOKUP_U16_13_COUNTS"; + Base::lookup_u16_14_counts = "LOOKUP_U16_14_COUNTS"; + Base::lookup_div_u16_0_counts = "LOOKUP_DIV_U16_0_COUNTS"; + Base::lookup_div_u16_1_counts = "LOOKUP_DIV_U16_1_COUNTS"; + Base::lookup_div_u16_2_counts = "LOOKUP_DIV_U16_2_COUNTS"; + Base::lookup_div_u16_3_counts = "LOOKUP_DIV_U16_3_COUNTS"; + Base::lookup_div_u16_4_counts = "LOOKUP_DIV_U16_4_COUNTS"; + Base::lookup_div_u16_5_counts = "LOOKUP_DIV_U16_5_COUNTS"; + Base::lookup_div_u16_6_counts = "LOOKUP_DIV_U16_6_COUNTS"; + Base::lookup_div_u16_7_counts = "LOOKUP_DIV_U16_7_COUNTS"; + }; + }; + + class VerifierCommitments : public AllEntities { + private: + using Base = AllEntities; + + public: + VerifierCommitments(const std::shared_ptr& verification_key) + { + main_clk = verification_key->main_clk; + main_sel_first = verification_key->main_sel_first; + } + }; + + class Transcript : public NativeTranscript { + public: + uint32_t circuit_size; + +<<<<<<< HEAD + std::array commitments; +======= + Commitment kernel_kernel_inputs; + Commitment kernel_kernel_value_out; + Commitment kernel_kernel_side_effect_out; + Commitment kernel_kernel_metadata_out; + Commitment main_calldata; + Commitment alu_a_hi; + Commitment alu_a_lo; + Commitment alu_b_hi; + Commitment alu_b_lo; + Commitment alu_borrow; + Commitment alu_cf; + Commitment alu_clk; + Commitment alu_cmp_rng_ctr; + Commitment alu_div_u16_r0; + Commitment alu_div_u16_r1; + Commitment alu_div_u16_r2; + Commitment alu_div_u16_r3; + Commitment alu_div_u16_r4; + Commitment alu_div_u16_r5; + Commitment alu_div_u16_r6; + Commitment alu_div_u16_r7; + Commitment alu_divisor_hi; + Commitment alu_divisor_lo; + Commitment alu_ff_tag; + Commitment alu_ia; + Commitment alu_ib; + Commitment alu_ic; + Commitment alu_in_tag; + Commitment alu_op_add; + Commitment alu_op_cast; + Commitment alu_op_cast_prev; + Commitment alu_op_div; + Commitment alu_op_div_a_lt_b; + Commitment alu_op_div_std; + Commitment alu_op_eq; + Commitment alu_op_eq_diff_inv; + Commitment alu_op_lt; + Commitment alu_op_lte; + Commitment alu_op_mul; + Commitment alu_op_not; + Commitment alu_op_shl; + Commitment alu_op_shr; + Commitment alu_op_sub; + Commitment alu_p_a_borrow; + Commitment alu_p_b_borrow; + Commitment alu_p_sub_a_hi; + Commitment alu_p_sub_a_lo; + Commitment alu_p_sub_b_hi; + Commitment alu_p_sub_b_lo; + Commitment alu_partial_prod_hi; + Commitment alu_partial_prod_lo; + Commitment alu_quotient_hi; + Commitment alu_quotient_lo; + Commitment alu_remainder; + Commitment alu_res_hi; + Commitment alu_res_lo; + Commitment alu_sel_alu; + Commitment alu_sel_cmp; + Commitment alu_sel_div_rng_chk; + Commitment alu_sel_rng_chk; + Commitment alu_sel_rng_chk_lookup; + Commitment alu_sel_shift_which; + Commitment alu_shift_lt_bit_len; + Commitment alu_t_sub_s_bits; + Commitment alu_two_pow_s; + Commitment alu_two_pow_t_sub_s; + Commitment alu_u128_tag; + Commitment alu_u16_r0; + Commitment alu_u16_r1; + Commitment alu_u16_r10; + Commitment alu_u16_r11; + Commitment alu_u16_r12; + Commitment alu_u16_r13; + Commitment alu_u16_r14; + Commitment alu_u16_r2; + Commitment alu_u16_r3; + Commitment alu_u16_r4; + Commitment alu_u16_r5; + Commitment alu_u16_r6; + Commitment alu_u16_r7; + Commitment alu_u16_r8; + Commitment alu_u16_r9; + Commitment alu_u16_tag; + Commitment alu_u32_tag; + Commitment alu_u64_tag; + Commitment alu_u8_r0; + Commitment alu_u8_r1; + Commitment alu_u8_tag; + Commitment binary_acc_ia; + Commitment binary_acc_ib; + Commitment binary_acc_ic; + Commitment binary_clk; + Commitment binary_ia_bytes; + Commitment binary_ib_bytes; + Commitment binary_ic_bytes; + Commitment binary_in_tag; + Commitment binary_mem_tag_ctr; + Commitment binary_mem_tag_ctr_inv; + Commitment binary_op_id; + Commitment binary_sel_bin; + Commitment binary_start; + Commitment byte_lookup_sel_bin; + Commitment byte_lookup_table_byte_lengths; + Commitment byte_lookup_table_in_tags; + Commitment byte_lookup_table_input_a; + Commitment byte_lookup_table_input_b; + Commitment byte_lookup_table_op_id; + Commitment byte_lookup_table_output; + Commitment conversion_clk; + Commitment conversion_input; + Commitment conversion_num_limbs; + Commitment conversion_radix; + Commitment conversion_sel_to_radix_le; + Commitment gas_da_gas_fixed_table; + Commitment gas_l2_gas_fixed_table; + Commitment gas_sel_gas_cost; + Commitment keccakf1600_clk; + Commitment keccakf1600_input; + Commitment keccakf1600_output; + Commitment keccakf1600_sel_keccakf1600; + Commitment kernel_emit_l2_to_l1_msg_write_offset; + Commitment kernel_emit_note_hash_write_offset; + Commitment kernel_emit_nullifier_write_offset; + Commitment kernel_emit_unencrypted_log_write_offset; + Commitment kernel_kernel_in_offset; + Commitment kernel_kernel_out_offset; + Commitment kernel_l1_to_l2_msg_exists_write_offset; + Commitment kernel_note_hash_exist_write_offset; + Commitment kernel_nullifier_exists_write_offset; + Commitment kernel_nullifier_non_exists_write_offset; + Commitment kernel_q_public_input_kernel_add_to_table; + Commitment kernel_q_public_input_kernel_out_add_to_table; + Commitment kernel_side_effect_counter; + Commitment kernel_sload_write_offset; + Commitment kernel_sstore_write_offset; + Commitment main_abs_da_rem_gas_hi; + Commitment main_abs_da_rem_gas_lo; + Commitment main_abs_l2_rem_gas_hi; + Commitment main_abs_l2_rem_gas_lo; + Commitment main_alu_in_tag; + Commitment main_bin_op_id; + Commitment main_call_ptr; + Commitment main_da_gas_op_cost; + Commitment main_da_gas_remaining; + Commitment main_da_out_of_gas; + Commitment main_ia; + Commitment main_ib; + Commitment main_ic; + Commitment main_id; + Commitment main_id_zero; + Commitment main_ind_addr_a; + Commitment main_ind_addr_b; + Commitment main_ind_addr_c; + Commitment main_ind_addr_d; + Commitment main_internal_return_ptr; + Commitment main_inv; + Commitment main_l2_gas_op_cost; + Commitment main_l2_gas_remaining; + Commitment main_l2_out_of_gas; + Commitment main_mem_addr_a; + Commitment main_mem_addr_b; + Commitment main_mem_addr_c; + Commitment main_mem_addr_d; + Commitment main_op_err; + Commitment main_opcode_val; + Commitment main_pc; + Commitment main_r_in_tag; + Commitment main_rwa; + Commitment main_rwb; + Commitment main_rwc; + Commitment main_rwd; + Commitment main_sel_alu; + Commitment main_sel_bin; + Commitment main_sel_gas_accounting_active; + Commitment main_sel_last; + Commitment main_sel_mem_op_a; + Commitment main_sel_mem_op_activate_gas; + Commitment main_sel_mem_op_b; + Commitment main_sel_mem_op_c; + Commitment main_sel_mem_op_d; + Commitment main_sel_mov_ia_to_ic; + Commitment main_sel_mov_ib_to_ic; + Commitment main_sel_op_add; + Commitment main_sel_op_address; + Commitment main_sel_op_and; + Commitment main_sel_op_block_number; + Commitment main_sel_op_cast; + Commitment main_sel_op_chain_id; + Commitment main_sel_op_cmov; + Commitment main_sel_op_coinbase; + Commitment main_sel_op_dagasleft; + Commitment main_sel_op_div; + Commitment main_sel_op_emit_l2_to_l1_msg; + Commitment main_sel_op_emit_note_hash; + Commitment main_sel_op_emit_nullifier; + Commitment main_sel_op_emit_unencrypted_log; + Commitment main_sel_op_eq; + Commitment main_sel_op_external_call; + Commitment main_sel_op_fdiv; + Commitment main_sel_op_fee_per_da_gas; + Commitment main_sel_op_fee_per_l2_gas; + Commitment main_sel_op_function_selector; + Commitment main_sel_op_get_contract_instance; + Commitment main_sel_op_halt; + Commitment main_sel_op_internal_call; + Commitment main_sel_op_internal_return; + Commitment main_sel_op_jump; + Commitment main_sel_op_jumpi; + Commitment main_sel_op_keccak; + Commitment main_sel_op_l1_to_l2_msg_exists; + Commitment main_sel_op_l2gasleft; + Commitment main_sel_op_lt; + Commitment main_sel_op_lte; + Commitment main_sel_op_mov; + Commitment main_sel_op_mul; + Commitment main_sel_op_not; + Commitment main_sel_op_note_hash_exists; + Commitment main_sel_op_nullifier_exists; + Commitment main_sel_op_or; + Commitment main_sel_op_pedersen; + Commitment main_sel_op_poseidon2; + Commitment main_sel_op_radix_le; + Commitment main_sel_op_sender; + Commitment main_sel_op_sha256; + Commitment main_sel_op_shl; + Commitment main_sel_op_shr; + Commitment main_sel_op_sload; + Commitment main_sel_op_sstore; + Commitment main_sel_op_storage_address; + Commitment main_sel_op_sub; + Commitment main_sel_op_timestamp; + Commitment main_sel_op_transaction_fee; + Commitment main_sel_op_version; + Commitment main_sel_op_xor; + Commitment main_sel_q_kernel_lookup; + Commitment main_sel_q_kernel_output_lookup; + Commitment main_sel_resolve_ind_addr_a; + Commitment main_sel_resolve_ind_addr_b; + Commitment main_sel_resolve_ind_addr_c; + Commitment main_sel_resolve_ind_addr_d; + Commitment main_sel_rng_16; + Commitment main_sel_rng_8; + Commitment main_space_id; + Commitment main_tag_err; + Commitment main_w_in_tag; + Commitment mem_addr; + Commitment mem_clk; + Commitment mem_diff_hi; + Commitment mem_diff_lo; + Commitment mem_diff_mid; + Commitment mem_glob_addr; + Commitment mem_last; + Commitment mem_lastAccess; + Commitment mem_one_min_inv; + Commitment mem_r_in_tag; + Commitment mem_rw; + Commitment mem_sel_mem; + Commitment mem_sel_mov_ia_to_ic; + Commitment mem_sel_mov_ib_to_ic; + Commitment mem_sel_op_a; + Commitment mem_sel_op_b; + Commitment mem_sel_op_c; + Commitment mem_sel_op_cmov; + Commitment mem_sel_op_d; + Commitment mem_sel_resolve_ind_addr_a; + Commitment mem_sel_resolve_ind_addr_b; + Commitment mem_sel_resolve_ind_addr_c; + Commitment mem_sel_resolve_ind_addr_d; + Commitment mem_sel_rng_chk; + Commitment mem_skip_check_tag; + Commitment mem_space_id; + Commitment mem_tag; + Commitment mem_tag_err; + Commitment mem_tsp; + Commitment mem_val; + Commitment mem_w_in_tag; + Commitment pedersen_clk; + Commitment pedersen_input; + Commitment pedersen_output; + Commitment pedersen_sel_pedersen; + Commitment poseidon2_a_0; + Commitment poseidon2_a_1; + Commitment poseidon2_a_2; + Commitment poseidon2_a_3; + Commitment poseidon2_b_0; + Commitment poseidon2_b_1; + Commitment poseidon2_b_2; + Commitment poseidon2_b_3; + Commitment poseidon2_clk; + Commitment poseidon2_input; + Commitment poseidon2_output; + Commitment poseidon2_sel_poseidon_perm; + Commitment powers_power_of_2; + Commitment sha256_clk; + Commitment sha256_input; + Commitment sha256_output; + Commitment sha256_sel_sha256_compression; + Commitment sha256_state; + Commitment perm_main_alu; + Commitment perm_main_bin; + Commitment perm_main_conv; + Commitment perm_main_pos2_perm; + Commitment perm_main_pedersen; + Commitment perm_main_mem_a; + Commitment perm_main_mem_b; + Commitment perm_main_mem_c; + Commitment perm_main_mem_d; + Commitment perm_main_mem_ind_addr_a; + Commitment perm_main_mem_ind_addr_b; + Commitment perm_main_mem_ind_addr_c; + Commitment perm_main_mem_ind_addr_d; + Commitment lookup_byte_lengths; + Commitment lookup_byte_operations; + Commitment lookup_opcode_gas; + Commitment range_check_l2_gas_hi; + Commitment range_check_l2_gas_lo; + Commitment range_check_da_gas_hi; + Commitment range_check_da_gas_lo; + Commitment kernel_output_lookup; + Commitment lookup_into_kernel; + Commitment incl_main_tag_err; + Commitment incl_mem_tag_err; + Commitment lookup_mem_rng_chk_lo; + Commitment lookup_mem_rng_chk_mid; + Commitment lookup_mem_rng_chk_hi; + Commitment lookup_pow_2_0; + Commitment lookup_pow_2_1; + Commitment lookup_u8_0; + Commitment lookup_u8_1; + Commitment lookup_u16_0; + Commitment lookup_u16_1; + Commitment lookup_u16_2; + Commitment lookup_u16_3; + Commitment lookup_u16_4; + Commitment lookup_u16_5; + Commitment lookup_u16_6; + Commitment lookup_u16_7; + Commitment lookup_u16_8; + Commitment lookup_u16_9; + Commitment lookup_u16_10; + Commitment lookup_u16_11; + Commitment lookup_u16_12; + Commitment lookup_u16_13; + Commitment lookup_u16_14; + Commitment lookup_div_u16_0; + Commitment lookup_div_u16_1; + Commitment lookup_div_u16_2; + Commitment lookup_div_u16_3; + Commitment lookup_div_u16_4; + Commitment lookup_div_u16_5; + Commitment lookup_div_u16_6; + Commitment lookup_div_u16_7; + Commitment lookup_byte_lengths_counts; + Commitment lookup_byte_operations_counts; + Commitment lookup_opcode_gas_counts; + Commitment range_check_l2_gas_hi_counts; + Commitment range_check_l2_gas_lo_counts; + Commitment range_check_da_gas_hi_counts; + Commitment range_check_da_gas_lo_counts; + Commitment kernel_output_lookup_counts; + Commitment lookup_into_kernel_counts; + Commitment incl_main_tag_err_counts; + Commitment incl_mem_tag_err_counts; + Commitment lookup_mem_rng_chk_lo_counts; + Commitment lookup_mem_rng_chk_mid_counts; + Commitment lookup_mem_rng_chk_hi_counts; + Commitment lookup_pow_2_0_counts; + Commitment lookup_pow_2_1_counts; + Commitment lookup_u8_0_counts; + Commitment lookup_u8_1_counts; + Commitment lookup_u16_0_counts; + Commitment lookup_u16_1_counts; + Commitment lookup_u16_2_counts; + Commitment lookup_u16_3_counts; + Commitment lookup_u16_4_counts; + Commitment lookup_u16_5_counts; + Commitment lookup_u16_6_counts; + Commitment lookup_u16_7_counts; + Commitment lookup_u16_8_counts; + Commitment lookup_u16_9_counts; + Commitment lookup_u16_10_counts; + Commitment lookup_u16_11_counts; + Commitment lookup_u16_12_counts; + Commitment lookup_u16_13_counts; + Commitment lookup_u16_14_counts; + Commitment lookup_div_u16_0_counts; + Commitment lookup_div_u16_1_counts; + Commitment lookup_div_u16_2_counts; + Commitment lookup_div_u16_3_counts; + Commitment lookup_div_u16_4_counts; + Commitment lookup_div_u16_5_counts; + Commitment lookup_div_u16_6_counts; + Commitment lookup_div_u16_7_counts; +>>>>>>> 520b7216c (feat(avm): poseidon2 constraints) + + std::vector> sumcheck_univariates; + std::array sumcheck_evaluations; + std::vector zm_cq_comms; + Commitment zm_cq_comm; + Commitment zm_pi_comm; + + Transcript() = default; + + Transcript(const std::vector& proof) + : NativeTranscript(proof) + {} + + void deserialize_full_transcript() + { + size_t num_frs_read = 0; + circuit_size = deserialize_from_buffer(proof_data, num_frs_read); + size_t log_n = numeric::get_msb(circuit_size); + +<<<<<<< HEAD + for (auto& commitment : commitments) { + commitment = deserialize_from_buffer(proof_data, num_frs_read); + } +======= + kernel_kernel_inputs = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_kernel_value_out = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_kernel_side_effect_out = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_kernel_metadata_out = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_calldata = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_a_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_a_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_b_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_b_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_borrow = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_cf = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_cmp_rng_ctr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_div_u16_r0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_div_u16_r1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_div_u16_r2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_div_u16_r3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_div_u16_r4 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_div_u16_r5 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_div_u16_r6 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_div_u16_r7 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_divisor_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_divisor_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_ff_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_ia = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_ib = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_add = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_cast = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_cast_prev = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_div = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_div_a_lt_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_div_std = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_eq = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_eq_diff_inv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_lt = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_lte = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_mul = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_not = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_shl = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_shr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_op_sub = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_p_a_borrow = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_p_b_borrow = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_p_sub_a_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_p_sub_a_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_p_sub_b_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_p_sub_b_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_partial_prod_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_partial_prod_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_quotient_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_quotient_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_remainder = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_res_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_res_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_sel_alu = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_sel_cmp = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_sel_div_rng_chk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_sel_rng_chk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_sel_rng_chk_lookup = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_sel_shift_which = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_shift_lt_bit_len = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_t_sub_s_bits = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_two_pow_s = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_two_pow_t_sub_s = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u128_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r10 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r11 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r12 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r13 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r14 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r4 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r5 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r6 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r7 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r8 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_r9 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u16_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u32_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u64_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u8_r0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u8_r1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + alu_u8_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_acc_ia = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_acc_ib = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_acc_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_ia_bytes = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_ib_bytes = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_ic_bytes = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_mem_tag_ctr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_mem_tag_ctr_inv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_op_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_sel_bin = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + binary_start = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + byte_lookup_sel_bin = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + byte_lookup_table_byte_lengths = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + byte_lookup_table_in_tags = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + byte_lookup_table_input_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + byte_lookup_table_input_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + byte_lookup_table_op_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + byte_lookup_table_output = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + conversion_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + conversion_input = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + conversion_num_limbs = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + conversion_radix = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + conversion_sel_to_radix_le = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + gas_da_gas_fixed_table = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + gas_l2_gas_fixed_table = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + gas_sel_gas_cost = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + keccakf1600_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + keccakf1600_input = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + keccakf1600_output = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + keccakf1600_sel_keccakf1600 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_emit_l2_to_l1_msg_write_offset = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_emit_note_hash_write_offset = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_emit_nullifier_write_offset = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_emit_unencrypted_log_write_offset = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_kernel_in_offset = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_kernel_out_offset = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_l1_to_l2_msg_exists_write_offset = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_note_hash_exist_write_offset = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_nullifier_exists_write_offset = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_nullifier_non_exists_write_offset = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_q_public_input_kernel_add_to_table = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_q_public_input_kernel_out_add_to_table = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_side_effect_counter = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_sload_write_offset = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_sstore_write_offset = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_abs_da_rem_gas_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_abs_da_rem_gas_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_abs_l2_rem_gas_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_abs_l2_rem_gas_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_alu_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_bin_op_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_call_ptr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_da_gas_op_cost = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_da_gas_remaining = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_da_out_of_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_ia = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_ib = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_id_zero = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_ind_addr_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_ind_addr_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_ind_addr_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_ind_addr_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_internal_return_ptr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_inv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_l2_gas_op_cost = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_l2_gas_remaining = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_l2_out_of_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_mem_addr_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_mem_addr_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_mem_addr_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_mem_addr_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_op_err = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_opcode_val = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_pc = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_r_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_rwa = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_rwb = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_rwc = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_rwd = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_alu = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_bin = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_gas_accounting_active = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_last = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_mem_op_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_mem_op_activate_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_mem_op_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_mem_op_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_mem_op_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_mov_ia_to_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_mov_ib_to_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_add = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_address = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_and = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_block_number = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_cast = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_chain_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_cmov = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_coinbase = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_dagasleft = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_div = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_emit_l2_to_l1_msg = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_emit_note_hash = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_emit_nullifier = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_emit_unencrypted_log = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_eq = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_external_call = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_fdiv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_fee_per_da_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_fee_per_l2_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_function_selector = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_get_contract_instance = + deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_halt = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_internal_call = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_internal_return = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_jump = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_jumpi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_keccak = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_l1_to_l2_msg_exists = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_l2gasleft = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_lt = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_lte = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_mov = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_mul = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_not = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_note_hash_exists = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_nullifier_exists = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_or = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_pedersen = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_poseidon2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_radix_le = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_sender = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_sha256 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_shl = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_shr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_sload = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_sstore = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_storage_address = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_sub = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_timestamp = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_transaction_fee = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_version = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_op_xor = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_q_kernel_lookup = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_q_kernel_output_lookup = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_resolve_ind_addr_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_resolve_ind_addr_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_resolve_ind_addr_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_resolve_ind_addr_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_rng_16 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_sel_rng_8 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_space_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_tag_err = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + main_w_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_addr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_diff_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_diff_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_diff_mid = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_glob_addr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_last = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_lastAccess = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_one_min_inv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_r_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_rw = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_mem = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_mov_ia_to_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_mov_ib_to_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_op_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_op_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_op_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_op_cmov = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_op_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_resolve_ind_addr_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_resolve_ind_addr_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_resolve_ind_addr_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_resolve_ind_addr_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_sel_rng_chk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_skip_check_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_space_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_tag_err = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_tsp = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_val = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + mem_w_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + pedersen_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + pedersen_input = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + pedersen_output = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + pedersen_sel_pedersen = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_a_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_a_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_a_2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_a_3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_b_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_b_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_b_2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_b_3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_input = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_output = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + poseidon2_sel_poseidon_perm = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + powers_power_of_2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + sha256_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + sha256_input = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + sha256_output = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + sha256_sel_sha256_compression = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + sha256_state = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_alu = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_bin = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_conv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_pos2_perm = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_pedersen = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_mem_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_mem_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_mem_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_mem_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_mem_ind_addr_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_mem_ind_addr_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_mem_ind_addr_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + perm_main_mem_ind_addr_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_byte_lengths = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_byte_operations = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_opcode_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + range_check_l2_gas_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + range_check_l2_gas_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + range_check_da_gas_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + range_check_da_gas_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_output_lookup = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_into_kernel = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + incl_main_tag_err = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + incl_mem_tag_err = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_mem_rng_chk_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_mem_rng_chk_mid = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_mem_rng_chk_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_pow_2_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_pow_2_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u8_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u8_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_4 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_5 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_6 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_7 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_8 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_9 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_10 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_11 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_12 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_13 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_14 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_4 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_5 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_6 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_7 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_byte_lengths_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_byte_operations_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_opcode_gas_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + range_check_l2_gas_hi_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + range_check_l2_gas_lo_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + range_check_da_gas_hi_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + range_check_da_gas_lo_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + kernel_output_lookup_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_into_kernel_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + incl_main_tag_err_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + incl_mem_tag_err_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_mem_rng_chk_lo_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_mem_rng_chk_mid_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_mem_rng_chk_hi_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_pow_2_0_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_pow_2_1_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u8_0_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u8_1_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_0_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_1_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_2_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_3_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_4_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_5_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_6_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_7_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_8_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_9_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_10_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_11_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_12_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_13_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_u16_14_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_0_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_1_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_2_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_3_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_4_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_5_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_6_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + lookup_div_u16_7_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); + +>>>>>>> 520b7216c (feat(avm): poseidon2 constraints) + for (size_t i = 0; i < log_n; ++i) { + sumcheck_univariates.emplace_back( + deserialize_from_buffer>(Transcript::proof_data, + num_frs_read)); + } + sumcheck_evaluations = + deserialize_from_buffer>(Transcript::proof_data, num_frs_read); + for (size_t i = 0; i < log_n; ++i) { + zm_cq_comms.push_back(deserialize_from_buffer(proof_data, num_frs_read)); + } + zm_cq_comm = deserialize_from_buffer(proof_data, num_frs_read); + zm_pi_comm = deserialize_from_buffer(proof_data, num_frs_read); + } + + void serialize_full_transcript() + { + size_t old_proof_length = proof_data.size(); + Transcript::proof_data.clear(); + size_t log_n = numeric::get_msb(circuit_size); + + serialize_to_buffer(circuit_size, Transcript::proof_data); + +<<<<<<< HEAD + for (const auto& commitment : commitments) { + serialize_to_buffer(commitment, Transcript::proof_data); + } +======= + serialize_to_buffer(kernel_kernel_inputs, Transcript::proof_data); + serialize_to_buffer(kernel_kernel_value_out, Transcript::proof_data); + serialize_to_buffer(kernel_kernel_side_effect_out, Transcript::proof_data); + serialize_to_buffer(kernel_kernel_metadata_out, Transcript::proof_data); + serialize_to_buffer(main_calldata, Transcript::proof_data); + serialize_to_buffer(alu_a_hi, Transcript::proof_data); + serialize_to_buffer(alu_a_lo, Transcript::proof_data); + serialize_to_buffer(alu_b_hi, Transcript::proof_data); + serialize_to_buffer(alu_b_lo, Transcript::proof_data); + serialize_to_buffer(alu_borrow, Transcript::proof_data); + serialize_to_buffer(alu_cf, Transcript::proof_data); + serialize_to_buffer(alu_clk, Transcript::proof_data); + serialize_to_buffer(alu_cmp_rng_ctr, Transcript::proof_data); + serialize_to_buffer(alu_div_u16_r0, Transcript::proof_data); + serialize_to_buffer(alu_div_u16_r1, Transcript::proof_data); + serialize_to_buffer(alu_div_u16_r2, Transcript::proof_data); + serialize_to_buffer(alu_div_u16_r3, Transcript::proof_data); + serialize_to_buffer(alu_div_u16_r4, Transcript::proof_data); + serialize_to_buffer(alu_div_u16_r5, Transcript::proof_data); + serialize_to_buffer(alu_div_u16_r6, Transcript::proof_data); + serialize_to_buffer(alu_div_u16_r7, Transcript::proof_data); + serialize_to_buffer(alu_divisor_hi, Transcript::proof_data); + serialize_to_buffer(alu_divisor_lo, Transcript::proof_data); + serialize_to_buffer(alu_ff_tag, Transcript::proof_data); + serialize_to_buffer(alu_ia, Transcript::proof_data); + serialize_to_buffer(alu_ib, Transcript::proof_data); + serialize_to_buffer(alu_ic, Transcript::proof_data); + serialize_to_buffer(alu_in_tag, Transcript::proof_data); + serialize_to_buffer(alu_op_add, Transcript::proof_data); + serialize_to_buffer(alu_op_cast, Transcript::proof_data); + serialize_to_buffer(alu_op_cast_prev, Transcript::proof_data); + serialize_to_buffer(alu_op_div, Transcript::proof_data); + serialize_to_buffer(alu_op_div_a_lt_b, Transcript::proof_data); + serialize_to_buffer(alu_op_div_std, Transcript::proof_data); + serialize_to_buffer(alu_op_eq, Transcript::proof_data); + serialize_to_buffer(alu_op_eq_diff_inv, Transcript::proof_data); + serialize_to_buffer(alu_op_lt, Transcript::proof_data); + serialize_to_buffer(alu_op_lte, Transcript::proof_data); + serialize_to_buffer(alu_op_mul, Transcript::proof_data); + serialize_to_buffer(alu_op_not, Transcript::proof_data); + serialize_to_buffer(alu_op_shl, Transcript::proof_data); + serialize_to_buffer(alu_op_shr, Transcript::proof_data); + serialize_to_buffer(alu_op_sub, Transcript::proof_data); + serialize_to_buffer(alu_p_a_borrow, Transcript::proof_data); + serialize_to_buffer(alu_p_b_borrow, Transcript::proof_data); + serialize_to_buffer(alu_p_sub_a_hi, Transcript::proof_data); + serialize_to_buffer(alu_p_sub_a_lo, Transcript::proof_data); + serialize_to_buffer(alu_p_sub_b_hi, Transcript::proof_data); + serialize_to_buffer(alu_p_sub_b_lo, Transcript::proof_data); + serialize_to_buffer(alu_partial_prod_hi, Transcript::proof_data); + serialize_to_buffer(alu_partial_prod_lo, Transcript::proof_data); + serialize_to_buffer(alu_quotient_hi, Transcript::proof_data); + serialize_to_buffer(alu_quotient_lo, Transcript::proof_data); + serialize_to_buffer(alu_remainder, Transcript::proof_data); + serialize_to_buffer(alu_res_hi, Transcript::proof_data); + serialize_to_buffer(alu_res_lo, Transcript::proof_data); + serialize_to_buffer(alu_sel_alu, Transcript::proof_data); + serialize_to_buffer(alu_sel_cmp, Transcript::proof_data); + serialize_to_buffer(alu_sel_div_rng_chk, Transcript::proof_data); + serialize_to_buffer(alu_sel_rng_chk, Transcript::proof_data); + serialize_to_buffer(alu_sel_rng_chk_lookup, Transcript::proof_data); + serialize_to_buffer(alu_sel_shift_which, Transcript::proof_data); + serialize_to_buffer(alu_shift_lt_bit_len, Transcript::proof_data); + serialize_to_buffer(alu_t_sub_s_bits, Transcript::proof_data); + serialize_to_buffer(alu_two_pow_s, Transcript::proof_data); + serialize_to_buffer(alu_two_pow_t_sub_s, Transcript::proof_data); + serialize_to_buffer(alu_u128_tag, Transcript::proof_data); + serialize_to_buffer(alu_u16_r0, Transcript::proof_data); + serialize_to_buffer(alu_u16_r1, Transcript::proof_data); + serialize_to_buffer(alu_u16_r10, Transcript::proof_data); + serialize_to_buffer(alu_u16_r11, Transcript::proof_data); + serialize_to_buffer(alu_u16_r12, Transcript::proof_data); + serialize_to_buffer(alu_u16_r13, Transcript::proof_data); + serialize_to_buffer(alu_u16_r14, Transcript::proof_data); + serialize_to_buffer(alu_u16_r2, Transcript::proof_data); + serialize_to_buffer(alu_u16_r3, Transcript::proof_data); + serialize_to_buffer(alu_u16_r4, Transcript::proof_data); + serialize_to_buffer(alu_u16_r5, Transcript::proof_data); + serialize_to_buffer(alu_u16_r6, Transcript::proof_data); + serialize_to_buffer(alu_u16_r7, Transcript::proof_data); + serialize_to_buffer(alu_u16_r8, Transcript::proof_data); + serialize_to_buffer(alu_u16_r9, Transcript::proof_data); + serialize_to_buffer(alu_u16_tag, Transcript::proof_data); + serialize_to_buffer(alu_u32_tag, Transcript::proof_data); + serialize_to_buffer(alu_u64_tag, Transcript::proof_data); + serialize_to_buffer(alu_u8_r0, Transcript::proof_data); + serialize_to_buffer(alu_u8_r1, Transcript::proof_data); + serialize_to_buffer(alu_u8_tag, Transcript::proof_data); + serialize_to_buffer(binary_acc_ia, Transcript::proof_data); + serialize_to_buffer(binary_acc_ib, Transcript::proof_data); + serialize_to_buffer(binary_acc_ic, Transcript::proof_data); + serialize_to_buffer(binary_clk, Transcript::proof_data); + serialize_to_buffer(binary_ia_bytes, Transcript::proof_data); + serialize_to_buffer(binary_ib_bytes, Transcript::proof_data); + serialize_to_buffer(binary_ic_bytes, Transcript::proof_data); + serialize_to_buffer(binary_in_tag, Transcript::proof_data); + serialize_to_buffer(binary_mem_tag_ctr, Transcript::proof_data); + serialize_to_buffer(binary_mem_tag_ctr_inv, Transcript::proof_data); + serialize_to_buffer(binary_op_id, Transcript::proof_data); + serialize_to_buffer(binary_sel_bin, Transcript::proof_data); + serialize_to_buffer(binary_start, Transcript::proof_data); + serialize_to_buffer(byte_lookup_sel_bin, Transcript::proof_data); + serialize_to_buffer(byte_lookup_table_byte_lengths, Transcript::proof_data); + serialize_to_buffer(byte_lookup_table_in_tags, Transcript::proof_data); + serialize_to_buffer(byte_lookup_table_input_a, Transcript::proof_data); + serialize_to_buffer(byte_lookup_table_input_b, Transcript::proof_data); + serialize_to_buffer(byte_lookup_table_op_id, Transcript::proof_data); + serialize_to_buffer(byte_lookup_table_output, Transcript::proof_data); + serialize_to_buffer(conversion_clk, Transcript::proof_data); + serialize_to_buffer(conversion_input, Transcript::proof_data); + serialize_to_buffer(conversion_num_limbs, Transcript::proof_data); + serialize_to_buffer(conversion_radix, Transcript::proof_data); + serialize_to_buffer(conversion_sel_to_radix_le, Transcript::proof_data); + serialize_to_buffer(gas_da_gas_fixed_table, Transcript::proof_data); + serialize_to_buffer(gas_l2_gas_fixed_table, Transcript::proof_data); + serialize_to_buffer(gas_sel_gas_cost, Transcript::proof_data); + serialize_to_buffer(keccakf1600_clk, Transcript::proof_data); + serialize_to_buffer(keccakf1600_input, Transcript::proof_data); + serialize_to_buffer(keccakf1600_output, Transcript::proof_data); + serialize_to_buffer(keccakf1600_sel_keccakf1600, Transcript::proof_data); + serialize_to_buffer(kernel_emit_l2_to_l1_msg_write_offset, Transcript::proof_data); + serialize_to_buffer(kernel_emit_note_hash_write_offset, Transcript::proof_data); + serialize_to_buffer(kernel_emit_nullifier_write_offset, Transcript::proof_data); + serialize_to_buffer(kernel_emit_unencrypted_log_write_offset, Transcript::proof_data); + serialize_to_buffer(kernel_kernel_in_offset, Transcript::proof_data); + serialize_to_buffer(kernel_kernel_out_offset, Transcript::proof_data); + serialize_to_buffer(kernel_l1_to_l2_msg_exists_write_offset, Transcript::proof_data); + serialize_to_buffer(kernel_note_hash_exist_write_offset, Transcript::proof_data); + serialize_to_buffer(kernel_nullifier_exists_write_offset, Transcript::proof_data); + serialize_to_buffer(kernel_nullifier_non_exists_write_offset, Transcript::proof_data); + serialize_to_buffer(kernel_q_public_input_kernel_add_to_table, Transcript::proof_data); + serialize_to_buffer(kernel_q_public_input_kernel_out_add_to_table, Transcript::proof_data); + serialize_to_buffer(kernel_side_effect_counter, Transcript::proof_data); + serialize_to_buffer(kernel_sload_write_offset, Transcript::proof_data); + serialize_to_buffer(kernel_sstore_write_offset, Transcript::proof_data); + serialize_to_buffer(main_abs_da_rem_gas_hi, Transcript::proof_data); + serialize_to_buffer(main_abs_da_rem_gas_lo, Transcript::proof_data); + serialize_to_buffer(main_abs_l2_rem_gas_hi, Transcript::proof_data); + serialize_to_buffer(main_abs_l2_rem_gas_lo, Transcript::proof_data); + serialize_to_buffer(main_alu_in_tag, Transcript::proof_data); + serialize_to_buffer(main_bin_op_id, Transcript::proof_data); + serialize_to_buffer(main_call_ptr, Transcript::proof_data); + serialize_to_buffer(main_da_gas_op_cost, Transcript::proof_data); + serialize_to_buffer(main_da_gas_remaining, Transcript::proof_data); + serialize_to_buffer(main_da_out_of_gas, Transcript::proof_data); + serialize_to_buffer(main_ia, Transcript::proof_data); + serialize_to_buffer(main_ib, Transcript::proof_data); + serialize_to_buffer(main_ic, Transcript::proof_data); + serialize_to_buffer(main_id, Transcript::proof_data); + serialize_to_buffer(main_id_zero, Transcript::proof_data); + serialize_to_buffer(main_ind_addr_a, Transcript::proof_data); + serialize_to_buffer(main_ind_addr_b, Transcript::proof_data); + serialize_to_buffer(main_ind_addr_c, Transcript::proof_data); + serialize_to_buffer(main_ind_addr_d, Transcript::proof_data); + serialize_to_buffer(main_internal_return_ptr, Transcript::proof_data); + serialize_to_buffer(main_inv, Transcript::proof_data); + serialize_to_buffer(main_l2_gas_op_cost, Transcript::proof_data); + serialize_to_buffer(main_l2_gas_remaining, Transcript::proof_data); + serialize_to_buffer(main_l2_out_of_gas, Transcript::proof_data); + serialize_to_buffer(main_mem_addr_a, Transcript::proof_data); + serialize_to_buffer(main_mem_addr_b, Transcript::proof_data); + serialize_to_buffer(main_mem_addr_c, Transcript::proof_data); + serialize_to_buffer(main_mem_addr_d, Transcript::proof_data); + serialize_to_buffer(main_op_err, Transcript::proof_data); + serialize_to_buffer(main_opcode_val, Transcript::proof_data); + serialize_to_buffer(main_pc, Transcript::proof_data); + serialize_to_buffer(main_r_in_tag, Transcript::proof_data); + serialize_to_buffer(main_rwa, Transcript::proof_data); + serialize_to_buffer(main_rwb, Transcript::proof_data); + serialize_to_buffer(main_rwc, Transcript::proof_data); + serialize_to_buffer(main_rwd, Transcript::proof_data); + serialize_to_buffer(main_sel_alu, Transcript::proof_data); + serialize_to_buffer(main_sel_bin, Transcript::proof_data); + serialize_to_buffer(main_sel_gas_accounting_active, Transcript::proof_data); + serialize_to_buffer(main_sel_last, Transcript::proof_data); + serialize_to_buffer(main_sel_mem_op_a, Transcript::proof_data); + serialize_to_buffer(main_sel_mem_op_activate_gas, Transcript::proof_data); + serialize_to_buffer(main_sel_mem_op_b, Transcript::proof_data); + serialize_to_buffer(main_sel_mem_op_c, Transcript::proof_data); + serialize_to_buffer(main_sel_mem_op_d, Transcript::proof_data); + serialize_to_buffer(main_sel_mov_ia_to_ic, Transcript::proof_data); + serialize_to_buffer(main_sel_mov_ib_to_ic, Transcript::proof_data); + serialize_to_buffer(main_sel_op_add, Transcript::proof_data); + serialize_to_buffer(main_sel_op_address, Transcript::proof_data); + serialize_to_buffer(main_sel_op_and, Transcript::proof_data); + serialize_to_buffer(main_sel_op_block_number, Transcript::proof_data); + serialize_to_buffer(main_sel_op_cast, Transcript::proof_data); + serialize_to_buffer(main_sel_op_chain_id, Transcript::proof_data); + serialize_to_buffer(main_sel_op_cmov, Transcript::proof_data); + serialize_to_buffer(main_sel_op_coinbase, Transcript::proof_data); + serialize_to_buffer(main_sel_op_dagasleft, Transcript::proof_data); + serialize_to_buffer(main_sel_op_div, Transcript::proof_data); + serialize_to_buffer(main_sel_op_emit_l2_to_l1_msg, Transcript::proof_data); + serialize_to_buffer(main_sel_op_emit_note_hash, Transcript::proof_data); + serialize_to_buffer(main_sel_op_emit_nullifier, Transcript::proof_data); + serialize_to_buffer(main_sel_op_emit_unencrypted_log, Transcript::proof_data); + serialize_to_buffer(main_sel_op_eq, Transcript::proof_data); + serialize_to_buffer(main_sel_op_external_call, Transcript::proof_data); + serialize_to_buffer(main_sel_op_fdiv, Transcript::proof_data); + serialize_to_buffer(main_sel_op_fee_per_da_gas, Transcript::proof_data); + serialize_to_buffer(main_sel_op_fee_per_l2_gas, Transcript::proof_data); + serialize_to_buffer(main_sel_op_function_selector, Transcript::proof_data); + serialize_to_buffer(main_sel_op_get_contract_instance, Transcript::proof_data); + serialize_to_buffer(main_sel_op_halt, Transcript::proof_data); + serialize_to_buffer(main_sel_op_internal_call, Transcript::proof_data); + serialize_to_buffer(main_sel_op_internal_return, Transcript::proof_data); + serialize_to_buffer(main_sel_op_jump, Transcript::proof_data); + serialize_to_buffer(main_sel_op_jumpi, Transcript::proof_data); + serialize_to_buffer(main_sel_op_keccak, Transcript::proof_data); + serialize_to_buffer(main_sel_op_l1_to_l2_msg_exists, Transcript::proof_data); + serialize_to_buffer(main_sel_op_l2gasleft, Transcript::proof_data); + serialize_to_buffer(main_sel_op_lt, Transcript::proof_data); + serialize_to_buffer(main_sel_op_lte, Transcript::proof_data); + serialize_to_buffer(main_sel_op_mov, Transcript::proof_data); + serialize_to_buffer(main_sel_op_mul, Transcript::proof_data); + serialize_to_buffer(main_sel_op_not, Transcript::proof_data); + serialize_to_buffer(main_sel_op_note_hash_exists, Transcript::proof_data); + serialize_to_buffer(main_sel_op_nullifier_exists, Transcript::proof_data); + serialize_to_buffer(main_sel_op_or, Transcript::proof_data); + serialize_to_buffer(main_sel_op_pedersen, Transcript::proof_data); + serialize_to_buffer(main_sel_op_poseidon2, Transcript::proof_data); + serialize_to_buffer(main_sel_op_radix_le, Transcript::proof_data); + serialize_to_buffer(main_sel_op_sender, Transcript::proof_data); + serialize_to_buffer(main_sel_op_sha256, Transcript::proof_data); + serialize_to_buffer(main_sel_op_shl, Transcript::proof_data); + serialize_to_buffer(main_sel_op_shr, Transcript::proof_data); + serialize_to_buffer(main_sel_op_sload, Transcript::proof_data); + serialize_to_buffer(main_sel_op_sstore, Transcript::proof_data); + serialize_to_buffer(main_sel_op_storage_address, Transcript::proof_data); + serialize_to_buffer(main_sel_op_sub, Transcript::proof_data); + serialize_to_buffer(main_sel_op_timestamp, Transcript::proof_data); + serialize_to_buffer(main_sel_op_transaction_fee, Transcript::proof_data); + serialize_to_buffer(main_sel_op_version, Transcript::proof_data); + serialize_to_buffer(main_sel_op_xor, Transcript::proof_data); + serialize_to_buffer(main_sel_q_kernel_lookup, Transcript::proof_data); + serialize_to_buffer(main_sel_q_kernel_output_lookup, Transcript::proof_data); + serialize_to_buffer(main_sel_resolve_ind_addr_a, Transcript::proof_data); + serialize_to_buffer(main_sel_resolve_ind_addr_b, Transcript::proof_data); + serialize_to_buffer(main_sel_resolve_ind_addr_c, Transcript::proof_data); + serialize_to_buffer(main_sel_resolve_ind_addr_d, Transcript::proof_data); + serialize_to_buffer(main_sel_rng_16, Transcript::proof_data); + serialize_to_buffer(main_sel_rng_8, Transcript::proof_data); + serialize_to_buffer(main_space_id, Transcript::proof_data); + serialize_to_buffer(main_tag_err, Transcript::proof_data); + serialize_to_buffer(main_w_in_tag, Transcript::proof_data); + serialize_to_buffer(mem_addr, Transcript::proof_data); + serialize_to_buffer(mem_clk, Transcript::proof_data); + serialize_to_buffer(mem_diff_hi, Transcript::proof_data); + serialize_to_buffer(mem_diff_lo, Transcript::proof_data); + serialize_to_buffer(mem_diff_mid, Transcript::proof_data); + serialize_to_buffer(mem_glob_addr, Transcript::proof_data); + serialize_to_buffer(mem_last, Transcript::proof_data); + serialize_to_buffer(mem_lastAccess, Transcript::proof_data); + serialize_to_buffer(mem_one_min_inv, Transcript::proof_data); + serialize_to_buffer(mem_r_in_tag, Transcript::proof_data); + serialize_to_buffer(mem_rw, Transcript::proof_data); + serialize_to_buffer(mem_sel_mem, Transcript::proof_data); + serialize_to_buffer(mem_sel_mov_ia_to_ic, Transcript::proof_data); + serialize_to_buffer(mem_sel_mov_ib_to_ic, Transcript::proof_data); + serialize_to_buffer(mem_sel_op_a, Transcript::proof_data); + serialize_to_buffer(mem_sel_op_b, Transcript::proof_data); + serialize_to_buffer(mem_sel_op_c, Transcript::proof_data); + serialize_to_buffer(mem_sel_op_cmov, Transcript::proof_data); + serialize_to_buffer(mem_sel_op_d, Transcript::proof_data); + serialize_to_buffer(mem_sel_resolve_ind_addr_a, Transcript::proof_data); + serialize_to_buffer(mem_sel_resolve_ind_addr_b, Transcript::proof_data); + serialize_to_buffer(mem_sel_resolve_ind_addr_c, Transcript::proof_data); + serialize_to_buffer(mem_sel_resolve_ind_addr_d, Transcript::proof_data); + serialize_to_buffer(mem_sel_rng_chk, Transcript::proof_data); + serialize_to_buffer(mem_skip_check_tag, Transcript::proof_data); + serialize_to_buffer(mem_space_id, Transcript::proof_data); + serialize_to_buffer(mem_tag, Transcript::proof_data); + serialize_to_buffer(mem_tag_err, Transcript::proof_data); + serialize_to_buffer(mem_tsp, Transcript::proof_data); + serialize_to_buffer(mem_val, Transcript::proof_data); + serialize_to_buffer(mem_w_in_tag, Transcript::proof_data); + serialize_to_buffer(pedersen_clk, Transcript::proof_data); + serialize_to_buffer(pedersen_input, Transcript::proof_data); + serialize_to_buffer(pedersen_output, Transcript::proof_data); + serialize_to_buffer(pedersen_sel_pedersen, Transcript::proof_data); + serialize_to_buffer(poseidon2_a_0, Transcript::proof_data); + serialize_to_buffer(poseidon2_a_1, Transcript::proof_data); + serialize_to_buffer(poseidon2_a_2, Transcript::proof_data); + serialize_to_buffer(poseidon2_a_3, Transcript::proof_data); + serialize_to_buffer(poseidon2_b_0, Transcript::proof_data); + serialize_to_buffer(poseidon2_b_1, Transcript::proof_data); + serialize_to_buffer(poseidon2_b_2, Transcript::proof_data); + serialize_to_buffer(poseidon2_b_3, Transcript::proof_data); + serialize_to_buffer(poseidon2_clk, Transcript::proof_data); + serialize_to_buffer(poseidon2_input, Transcript::proof_data); + serialize_to_buffer(poseidon2_output, Transcript::proof_data); + serialize_to_buffer(poseidon2_sel_poseidon_perm, Transcript::proof_data); + serialize_to_buffer(powers_power_of_2, Transcript::proof_data); + serialize_to_buffer(sha256_clk, Transcript::proof_data); + serialize_to_buffer(sha256_input, Transcript::proof_data); + serialize_to_buffer(sha256_output, Transcript::proof_data); + serialize_to_buffer(sha256_sel_sha256_compression, Transcript::proof_data); + serialize_to_buffer(sha256_state, Transcript::proof_data); + serialize_to_buffer(perm_main_alu, Transcript::proof_data); + serialize_to_buffer(perm_main_bin, Transcript::proof_data); + serialize_to_buffer(perm_main_conv, Transcript::proof_data); + serialize_to_buffer(perm_main_pos2_perm, Transcript::proof_data); + serialize_to_buffer(perm_main_pedersen, Transcript::proof_data); + serialize_to_buffer(perm_main_mem_a, Transcript::proof_data); + serialize_to_buffer(perm_main_mem_b, Transcript::proof_data); + serialize_to_buffer(perm_main_mem_c, Transcript::proof_data); + serialize_to_buffer(perm_main_mem_d, Transcript::proof_data); + serialize_to_buffer(perm_main_mem_ind_addr_a, Transcript::proof_data); + serialize_to_buffer(perm_main_mem_ind_addr_b, Transcript::proof_data); + serialize_to_buffer(perm_main_mem_ind_addr_c, Transcript::proof_data); + serialize_to_buffer(perm_main_mem_ind_addr_d, Transcript::proof_data); + serialize_to_buffer(lookup_byte_lengths, Transcript::proof_data); + serialize_to_buffer(lookup_byte_operations, Transcript::proof_data); + serialize_to_buffer(lookup_opcode_gas, Transcript::proof_data); + serialize_to_buffer(range_check_l2_gas_hi, Transcript::proof_data); + serialize_to_buffer(range_check_l2_gas_lo, Transcript::proof_data); + serialize_to_buffer(range_check_da_gas_hi, Transcript::proof_data); + serialize_to_buffer(range_check_da_gas_lo, Transcript::proof_data); + serialize_to_buffer(kernel_output_lookup, Transcript::proof_data); + serialize_to_buffer(lookup_into_kernel, Transcript::proof_data); + serialize_to_buffer(incl_main_tag_err, Transcript::proof_data); + serialize_to_buffer(incl_mem_tag_err, Transcript::proof_data); + serialize_to_buffer(lookup_mem_rng_chk_lo, Transcript::proof_data); + serialize_to_buffer(lookup_mem_rng_chk_mid, Transcript::proof_data); + serialize_to_buffer(lookup_mem_rng_chk_hi, Transcript::proof_data); + serialize_to_buffer(lookup_pow_2_0, Transcript::proof_data); + serialize_to_buffer(lookup_pow_2_1, Transcript::proof_data); + serialize_to_buffer(lookup_u8_0, Transcript::proof_data); + serialize_to_buffer(lookup_u8_1, Transcript::proof_data); + serialize_to_buffer(lookup_u16_0, Transcript::proof_data); + serialize_to_buffer(lookup_u16_1, Transcript::proof_data); + serialize_to_buffer(lookup_u16_2, Transcript::proof_data); + serialize_to_buffer(lookup_u16_3, Transcript::proof_data); + serialize_to_buffer(lookup_u16_4, Transcript::proof_data); + serialize_to_buffer(lookup_u16_5, Transcript::proof_data); + serialize_to_buffer(lookup_u16_6, Transcript::proof_data); + serialize_to_buffer(lookup_u16_7, Transcript::proof_data); + serialize_to_buffer(lookup_u16_8, Transcript::proof_data); + serialize_to_buffer(lookup_u16_9, Transcript::proof_data); + serialize_to_buffer(lookup_u16_10, Transcript::proof_data); + serialize_to_buffer(lookup_u16_11, Transcript::proof_data); + serialize_to_buffer(lookup_u16_12, Transcript::proof_data); + serialize_to_buffer(lookup_u16_13, Transcript::proof_data); + serialize_to_buffer(lookup_u16_14, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_0, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_1, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_2, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_3, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_4, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_5, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_6, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_7, Transcript::proof_data); + serialize_to_buffer(lookup_byte_lengths_counts, Transcript::proof_data); + serialize_to_buffer(lookup_byte_operations_counts, Transcript::proof_data); + serialize_to_buffer(lookup_opcode_gas_counts, Transcript::proof_data); + serialize_to_buffer(range_check_l2_gas_hi_counts, Transcript::proof_data); + serialize_to_buffer(range_check_l2_gas_lo_counts, Transcript::proof_data); + serialize_to_buffer(range_check_da_gas_hi_counts, Transcript::proof_data); + serialize_to_buffer(range_check_da_gas_lo_counts, Transcript::proof_data); + serialize_to_buffer(kernel_output_lookup_counts, Transcript::proof_data); + serialize_to_buffer(lookup_into_kernel_counts, Transcript::proof_data); + serialize_to_buffer(incl_main_tag_err_counts, Transcript::proof_data); + serialize_to_buffer(incl_mem_tag_err_counts, Transcript::proof_data); + serialize_to_buffer(lookup_mem_rng_chk_lo_counts, Transcript::proof_data); + serialize_to_buffer(lookup_mem_rng_chk_mid_counts, Transcript::proof_data); + serialize_to_buffer(lookup_mem_rng_chk_hi_counts, Transcript::proof_data); + serialize_to_buffer(lookup_pow_2_0_counts, Transcript::proof_data); + serialize_to_buffer(lookup_pow_2_1_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u8_0_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u8_1_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_0_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_1_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_2_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_3_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_4_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_5_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_6_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_7_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_8_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_9_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_10_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_11_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_12_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_13_counts, Transcript::proof_data); + serialize_to_buffer(lookup_u16_14_counts, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_0_counts, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_1_counts, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_2_counts, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_3_counts, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_4_counts, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_5_counts, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_6_counts, Transcript::proof_data); + serialize_to_buffer(lookup_div_u16_7_counts, Transcript::proof_data); + +>>>>>>> 520b7216c (feat(avm): poseidon2 constraints) + for (size_t i = 0; i < log_n; ++i) { + serialize_to_buffer(sumcheck_univariates[i], Transcript::proof_data); + } + serialize_to_buffer(sumcheck_evaluations, Transcript::proof_data); + for (size_t i = 0; i < log_n; ++i) { + serialize_to_buffer(zm_cq_comms[i], proof_data); + } + serialize_to_buffer(zm_cq_comm, proof_data); + serialize_to_buffer(zm_pi_comm, proof_data); + + // sanity check to make sure we generate the same length of proof as before. + ASSERT(proof_data.size() == old_proof_length); + } + }; +}; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp b/barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp new file mode 100644 index 000000000000..6060b0407140 --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp @@ -0,0 +1,786 @@ +#include "barretenberg/vm/generated/avm_verifier.hpp" + +#include "barretenberg/commitment_schemes/zeromorph/zeromorph.hpp" +#include "barretenberg/numeric/bitop/get_msb.hpp" +#include "barretenberg/polynomials/polynomial.hpp" +#include "barretenberg/transcript/transcript.hpp" + +namespace bb { + +AvmVerifier::AvmVerifier(std::shared_ptr verifier_key) + : key(verifier_key) +{} + +AvmVerifier::AvmVerifier(AvmVerifier&& other) noexcept + : key(std::move(other.key)) + , pcs_verification_key(std::move(other.pcs_verification_key)) +{} + +AvmVerifier& AvmVerifier::operator=(AvmVerifier&& other) noexcept +{ + key = other.key; + pcs_verification_key = (std::move(other.pcs_verification_key)); + commitments.clear(); + return *this; +} + +using FF = AvmFlavor::FF; + +// Evaluate the given public input column over the multivariate challenge points +[[maybe_unused]] inline FF evaluate_public_input_column(const std::vector& points, + const size_t circuit_size, + std::vector challenges) +{ + + // TODO(https://github.com/AztecProtocol/aztec-packages/issues/6361): we pad the points to the circuit size in order + // to get the correct evaluation. This is not efficient, and will not be valid in production. + std::vector new_points(circuit_size, 0); + std::copy(points.begin(), points.end(), new_points.data()); + + Polynomial polynomial(new_points); + return polynomial.evaluate_mle(challenges); +} + +/** + * @brief This function verifies an Avm Honk proof for given program settings. + * + */ +bool AvmVerifier::verify_proof(const HonkProof& proof, const std::vector>& public_inputs) +{ + using Flavor = AvmFlavor; + using FF = Flavor::FF; + using Commitment = Flavor::Commitment; + // using PCS = Flavor::PCS; + // using Curve = Flavor::Curve; + // using ZeroMorph = ZeroMorphVerifier_; + using VerifierCommitments = Flavor::VerifierCommitments; + using CommitmentLabels = Flavor::CommitmentLabels; + + RelationParameters relation_parameters; + + transcript = std::make_shared(proof); + + VerifierCommitments commitments{ key }; + CommitmentLabels commitment_labels; + + const auto circuit_size = transcript->template receive_from_prover("circuit_size"); + + if (circuit_size != key->circuit_size) { + return false; + } + + // Get commitments to VM wires +<<<<<<< HEAD + for (auto [comm, label] : zip_view(commitments.get_wires(), commitment_labels.get_wires())) { + comm = transcript->template receive_from_prover(label); + } +======= + commitments.kernel_kernel_inputs = + transcript->template receive_from_prover(commitment_labels.kernel_kernel_inputs); + commitments.kernel_kernel_value_out = + transcript->template receive_from_prover(commitment_labels.kernel_kernel_value_out); + commitments.kernel_kernel_side_effect_out = + transcript->template receive_from_prover(commitment_labels.kernel_kernel_side_effect_out); + commitments.kernel_kernel_metadata_out = + transcript->template receive_from_prover(commitment_labels.kernel_kernel_metadata_out); + commitments.main_calldata = transcript->template receive_from_prover(commitment_labels.main_calldata); + commitments.alu_a_hi = transcript->template receive_from_prover(commitment_labels.alu_a_hi); + commitments.alu_a_lo = transcript->template receive_from_prover(commitment_labels.alu_a_lo); + commitments.alu_b_hi = transcript->template receive_from_prover(commitment_labels.alu_b_hi); + commitments.alu_b_lo = transcript->template receive_from_prover(commitment_labels.alu_b_lo); + commitments.alu_borrow = transcript->template receive_from_prover(commitment_labels.alu_borrow); + commitments.alu_cf = transcript->template receive_from_prover(commitment_labels.alu_cf); + commitments.alu_clk = transcript->template receive_from_prover(commitment_labels.alu_clk); + commitments.alu_cmp_rng_ctr = + transcript->template receive_from_prover(commitment_labels.alu_cmp_rng_ctr); + commitments.alu_div_u16_r0 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r0); + commitments.alu_div_u16_r1 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r1); + commitments.alu_div_u16_r2 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r2); + commitments.alu_div_u16_r3 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r3); + commitments.alu_div_u16_r4 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r4); + commitments.alu_div_u16_r5 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r5); + commitments.alu_div_u16_r6 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r6); + commitments.alu_div_u16_r7 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r7); + commitments.alu_divisor_hi = transcript->template receive_from_prover(commitment_labels.alu_divisor_hi); + commitments.alu_divisor_lo = transcript->template receive_from_prover(commitment_labels.alu_divisor_lo); + commitments.alu_ff_tag = transcript->template receive_from_prover(commitment_labels.alu_ff_tag); + commitments.alu_ia = transcript->template receive_from_prover(commitment_labels.alu_ia); + commitments.alu_ib = transcript->template receive_from_prover(commitment_labels.alu_ib); + commitments.alu_ic = transcript->template receive_from_prover(commitment_labels.alu_ic); + commitments.alu_in_tag = transcript->template receive_from_prover(commitment_labels.alu_in_tag); + commitments.alu_op_add = transcript->template receive_from_prover(commitment_labels.alu_op_add); + commitments.alu_op_cast = transcript->template receive_from_prover(commitment_labels.alu_op_cast); + commitments.alu_op_cast_prev = + transcript->template receive_from_prover(commitment_labels.alu_op_cast_prev); + commitments.alu_op_div = transcript->template receive_from_prover(commitment_labels.alu_op_div); + commitments.alu_op_div_a_lt_b = + transcript->template receive_from_prover(commitment_labels.alu_op_div_a_lt_b); + commitments.alu_op_div_std = transcript->template receive_from_prover(commitment_labels.alu_op_div_std); + commitments.alu_op_eq = transcript->template receive_from_prover(commitment_labels.alu_op_eq); + commitments.alu_op_eq_diff_inv = + transcript->template receive_from_prover(commitment_labels.alu_op_eq_diff_inv); + commitments.alu_op_lt = transcript->template receive_from_prover(commitment_labels.alu_op_lt); + commitments.alu_op_lte = transcript->template receive_from_prover(commitment_labels.alu_op_lte); + commitments.alu_op_mul = transcript->template receive_from_prover(commitment_labels.alu_op_mul); + commitments.alu_op_not = transcript->template receive_from_prover(commitment_labels.alu_op_not); + commitments.alu_op_shl = transcript->template receive_from_prover(commitment_labels.alu_op_shl); + commitments.alu_op_shr = transcript->template receive_from_prover(commitment_labels.alu_op_shr); + commitments.alu_op_sub = transcript->template receive_from_prover(commitment_labels.alu_op_sub); + commitments.alu_p_a_borrow = transcript->template receive_from_prover(commitment_labels.alu_p_a_borrow); + commitments.alu_p_b_borrow = transcript->template receive_from_prover(commitment_labels.alu_p_b_borrow); + commitments.alu_p_sub_a_hi = transcript->template receive_from_prover(commitment_labels.alu_p_sub_a_hi); + commitments.alu_p_sub_a_lo = transcript->template receive_from_prover(commitment_labels.alu_p_sub_a_lo); + commitments.alu_p_sub_b_hi = transcript->template receive_from_prover(commitment_labels.alu_p_sub_b_hi); + commitments.alu_p_sub_b_lo = transcript->template receive_from_prover(commitment_labels.alu_p_sub_b_lo); + commitments.alu_partial_prod_hi = + transcript->template receive_from_prover(commitment_labels.alu_partial_prod_hi); + commitments.alu_partial_prod_lo = + transcript->template receive_from_prover(commitment_labels.alu_partial_prod_lo); + commitments.alu_quotient_hi = + transcript->template receive_from_prover(commitment_labels.alu_quotient_hi); + commitments.alu_quotient_lo = + transcript->template receive_from_prover(commitment_labels.alu_quotient_lo); + commitments.alu_remainder = transcript->template receive_from_prover(commitment_labels.alu_remainder); + commitments.alu_res_hi = transcript->template receive_from_prover(commitment_labels.alu_res_hi); + commitments.alu_res_lo = transcript->template receive_from_prover(commitment_labels.alu_res_lo); + commitments.alu_sel_alu = transcript->template receive_from_prover(commitment_labels.alu_sel_alu); + commitments.alu_sel_cmp = transcript->template receive_from_prover(commitment_labels.alu_sel_cmp); + commitments.alu_sel_div_rng_chk = + transcript->template receive_from_prover(commitment_labels.alu_sel_div_rng_chk); + commitments.alu_sel_rng_chk = + transcript->template receive_from_prover(commitment_labels.alu_sel_rng_chk); + commitments.alu_sel_rng_chk_lookup = + transcript->template receive_from_prover(commitment_labels.alu_sel_rng_chk_lookup); + commitments.alu_sel_shift_which = + transcript->template receive_from_prover(commitment_labels.alu_sel_shift_which); + commitments.alu_shift_lt_bit_len = + transcript->template receive_from_prover(commitment_labels.alu_shift_lt_bit_len); + commitments.alu_t_sub_s_bits = + transcript->template receive_from_prover(commitment_labels.alu_t_sub_s_bits); + commitments.alu_two_pow_s = transcript->template receive_from_prover(commitment_labels.alu_two_pow_s); + commitments.alu_two_pow_t_sub_s = + transcript->template receive_from_prover(commitment_labels.alu_two_pow_t_sub_s); + commitments.alu_u128_tag = transcript->template receive_from_prover(commitment_labels.alu_u128_tag); + commitments.alu_u16_r0 = transcript->template receive_from_prover(commitment_labels.alu_u16_r0); + commitments.alu_u16_r1 = transcript->template receive_from_prover(commitment_labels.alu_u16_r1); + commitments.alu_u16_r10 = transcript->template receive_from_prover(commitment_labels.alu_u16_r10); + commitments.alu_u16_r11 = transcript->template receive_from_prover(commitment_labels.alu_u16_r11); + commitments.alu_u16_r12 = transcript->template receive_from_prover(commitment_labels.alu_u16_r12); + commitments.alu_u16_r13 = transcript->template receive_from_prover(commitment_labels.alu_u16_r13); + commitments.alu_u16_r14 = transcript->template receive_from_prover(commitment_labels.alu_u16_r14); + commitments.alu_u16_r2 = transcript->template receive_from_prover(commitment_labels.alu_u16_r2); + commitments.alu_u16_r3 = transcript->template receive_from_prover(commitment_labels.alu_u16_r3); + commitments.alu_u16_r4 = transcript->template receive_from_prover(commitment_labels.alu_u16_r4); + commitments.alu_u16_r5 = transcript->template receive_from_prover(commitment_labels.alu_u16_r5); + commitments.alu_u16_r6 = transcript->template receive_from_prover(commitment_labels.alu_u16_r6); + commitments.alu_u16_r7 = transcript->template receive_from_prover(commitment_labels.alu_u16_r7); + commitments.alu_u16_r8 = transcript->template receive_from_prover(commitment_labels.alu_u16_r8); + commitments.alu_u16_r9 = transcript->template receive_from_prover(commitment_labels.alu_u16_r9); + commitments.alu_u16_tag = transcript->template receive_from_prover(commitment_labels.alu_u16_tag); + commitments.alu_u32_tag = transcript->template receive_from_prover(commitment_labels.alu_u32_tag); + commitments.alu_u64_tag = transcript->template receive_from_prover(commitment_labels.alu_u64_tag); + commitments.alu_u8_r0 = transcript->template receive_from_prover(commitment_labels.alu_u8_r0); + commitments.alu_u8_r1 = transcript->template receive_from_prover(commitment_labels.alu_u8_r1); + commitments.alu_u8_tag = transcript->template receive_from_prover(commitment_labels.alu_u8_tag); + commitments.binary_acc_ia = transcript->template receive_from_prover(commitment_labels.binary_acc_ia); + commitments.binary_acc_ib = transcript->template receive_from_prover(commitment_labels.binary_acc_ib); + commitments.binary_acc_ic = transcript->template receive_from_prover(commitment_labels.binary_acc_ic); + commitments.binary_clk = transcript->template receive_from_prover(commitment_labels.binary_clk); + commitments.binary_ia_bytes = + transcript->template receive_from_prover(commitment_labels.binary_ia_bytes); + commitments.binary_ib_bytes = + transcript->template receive_from_prover(commitment_labels.binary_ib_bytes); + commitments.binary_ic_bytes = + transcript->template receive_from_prover(commitment_labels.binary_ic_bytes); + commitments.binary_in_tag = transcript->template receive_from_prover(commitment_labels.binary_in_tag); + commitments.binary_mem_tag_ctr = + transcript->template receive_from_prover(commitment_labels.binary_mem_tag_ctr); + commitments.binary_mem_tag_ctr_inv = + transcript->template receive_from_prover(commitment_labels.binary_mem_tag_ctr_inv); + commitments.binary_op_id = transcript->template receive_from_prover(commitment_labels.binary_op_id); + commitments.binary_sel_bin = transcript->template receive_from_prover(commitment_labels.binary_sel_bin); + commitments.binary_start = transcript->template receive_from_prover(commitment_labels.binary_start); + commitments.byte_lookup_sel_bin = + transcript->template receive_from_prover(commitment_labels.byte_lookup_sel_bin); + commitments.byte_lookup_table_byte_lengths = + transcript->template receive_from_prover(commitment_labels.byte_lookup_table_byte_lengths); + commitments.byte_lookup_table_in_tags = + transcript->template receive_from_prover(commitment_labels.byte_lookup_table_in_tags); + commitments.byte_lookup_table_input_a = + transcript->template receive_from_prover(commitment_labels.byte_lookup_table_input_a); + commitments.byte_lookup_table_input_b = + transcript->template receive_from_prover(commitment_labels.byte_lookup_table_input_b); + commitments.byte_lookup_table_op_id = + transcript->template receive_from_prover(commitment_labels.byte_lookup_table_op_id); + commitments.byte_lookup_table_output = + transcript->template receive_from_prover(commitment_labels.byte_lookup_table_output); + commitments.conversion_clk = transcript->template receive_from_prover(commitment_labels.conversion_clk); + commitments.conversion_input = + transcript->template receive_from_prover(commitment_labels.conversion_input); + commitments.conversion_num_limbs = + transcript->template receive_from_prover(commitment_labels.conversion_num_limbs); + commitments.conversion_radix = + transcript->template receive_from_prover(commitment_labels.conversion_radix); + commitments.conversion_sel_to_radix_le = + transcript->template receive_from_prover(commitment_labels.conversion_sel_to_radix_le); + commitments.gas_da_gas_fixed_table = + transcript->template receive_from_prover(commitment_labels.gas_da_gas_fixed_table); + commitments.gas_l2_gas_fixed_table = + transcript->template receive_from_prover(commitment_labels.gas_l2_gas_fixed_table); + commitments.gas_sel_gas_cost = + transcript->template receive_from_prover(commitment_labels.gas_sel_gas_cost); + commitments.keccakf1600_clk = + transcript->template receive_from_prover(commitment_labels.keccakf1600_clk); + commitments.keccakf1600_input = + transcript->template receive_from_prover(commitment_labels.keccakf1600_input); + commitments.keccakf1600_output = + transcript->template receive_from_prover(commitment_labels.keccakf1600_output); + commitments.keccakf1600_sel_keccakf1600 = + transcript->template receive_from_prover(commitment_labels.keccakf1600_sel_keccakf1600); + commitments.kernel_emit_l2_to_l1_msg_write_offset = + transcript->template receive_from_prover(commitment_labels.kernel_emit_l2_to_l1_msg_write_offset); + commitments.kernel_emit_note_hash_write_offset = + transcript->template receive_from_prover(commitment_labels.kernel_emit_note_hash_write_offset); + commitments.kernel_emit_nullifier_write_offset = + transcript->template receive_from_prover(commitment_labels.kernel_emit_nullifier_write_offset); + commitments.kernel_emit_unencrypted_log_write_offset = transcript->template receive_from_prover( + commitment_labels.kernel_emit_unencrypted_log_write_offset); + commitments.kernel_kernel_in_offset = + transcript->template receive_from_prover(commitment_labels.kernel_kernel_in_offset); + commitments.kernel_kernel_out_offset = + transcript->template receive_from_prover(commitment_labels.kernel_kernel_out_offset); + commitments.kernel_l1_to_l2_msg_exists_write_offset = + transcript->template receive_from_prover(commitment_labels.kernel_l1_to_l2_msg_exists_write_offset); + commitments.kernel_note_hash_exist_write_offset = + transcript->template receive_from_prover(commitment_labels.kernel_note_hash_exist_write_offset); + commitments.kernel_nullifier_exists_write_offset = + transcript->template receive_from_prover(commitment_labels.kernel_nullifier_exists_write_offset); + commitments.kernel_nullifier_non_exists_write_offset = transcript->template receive_from_prover( + commitment_labels.kernel_nullifier_non_exists_write_offset); + commitments.kernel_q_public_input_kernel_add_to_table = transcript->template receive_from_prover( + commitment_labels.kernel_q_public_input_kernel_add_to_table); + commitments.kernel_q_public_input_kernel_out_add_to_table = transcript->template receive_from_prover( + commitment_labels.kernel_q_public_input_kernel_out_add_to_table); + commitments.kernel_side_effect_counter = + transcript->template receive_from_prover(commitment_labels.kernel_side_effect_counter); + commitments.kernel_sload_write_offset = + transcript->template receive_from_prover(commitment_labels.kernel_sload_write_offset); + commitments.kernel_sstore_write_offset = + transcript->template receive_from_prover(commitment_labels.kernel_sstore_write_offset); + commitments.main_abs_da_rem_gas_hi = + transcript->template receive_from_prover(commitment_labels.main_abs_da_rem_gas_hi); + commitments.main_abs_da_rem_gas_lo = + transcript->template receive_from_prover(commitment_labels.main_abs_da_rem_gas_lo); + commitments.main_abs_l2_rem_gas_hi = + transcript->template receive_from_prover(commitment_labels.main_abs_l2_rem_gas_hi); + commitments.main_abs_l2_rem_gas_lo = + transcript->template receive_from_prover(commitment_labels.main_abs_l2_rem_gas_lo); + commitments.main_alu_in_tag = + transcript->template receive_from_prover(commitment_labels.main_alu_in_tag); + commitments.main_bin_op_id = transcript->template receive_from_prover(commitment_labels.main_bin_op_id); + commitments.main_call_ptr = transcript->template receive_from_prover(commitment_labels.main_call_ptr); + commitments.main_da_gas_op_cost = + transcript->template receive_from_prover(commitment_labels.main_da_gas_op_cost); + commitments.main_da_gas_remaining = + transcript->template receive_from_prover(commitment_labels.main_da_gas_remaining); + commitments.main_da_out_of_gas = + transcript->template receive_from_prover(commitment_labels.main_da_out_of_gas); + commitments.main_ia = transcript->template receive_from_prover(commitment_labels.main_ia); + commitments.main_ib = transcript->template receive_from_prover(commitment_labels.main_ib); + commitments.main_ic = transcript->template receive_from_prover(commitment_labels.main_ic); + commitments.main_id = transcript->template receive_from_prover(commitment_labels.main_id); + commitments.main_id_zero = transcript->template receive_from_prover(commitment_labels.main_id_zero); + commitments.main_ind_addr_a = + transcript->template receive_from_prover(commitment_labels.main_ind_addr_a); + commitments.main_ind_addr_b = + transcript->template receive_from_prover(commitment_labels.main_ind_addr_b); + commitments.main_ind_addr_c = + transcript->template receive_from_prover(commitment_labels.main_ind_addr_c); + commitments.main_ind_addr_d = + transcript->template receive_from_prover(commitment_labels.main_ind_addr_d); + commitments.main_internal_return_ptr = + transcript->template receive_from_prover(commitment_labels.main_internal_return_ptr); + commitments.main_inv = transcript->template receive_from_prover(commitment_labels.main_inv); + commitments.main_l2_gas_op_cost = + transcript->template receive_from_prover(commitment_labels.main_l2_gas_op_cost); + commitments.main_l2_gas_remaining = + transcript->template receive_from_prover(commitment_labels.main_l2_gas_remaining); + commitments.main_l2_out_of_gas = + transcript->template receive_from_prover(commitment_labels.main_l2_out_of_gas); + commitments.main_mem_addr_a = + transcript->template receive_from_prover(commitment_labels.main_mem_addr_a); + commitments.main_mem_addr_b = + transcript->template receive_from_prover(commitment_labels.main_mem_addr_b); + commitments.main_mem_addr_c = + transcript->template receive_from_prover(commitment_labels.main_mem_addr_c); + commitments.main_mem_addr_d = + transcript->template receive_from_prover(commitment_labels.main_mem_addr_d); + commitments.main_op_err = transcript->template receive_from_prover(commitment_labels.main_op_err); + commitments.main_opcode_val = + transcript->template receive_from_prover(commitment_labels.main_opcode_val); + commitments.main_pc = transcript->template receive_from_prover(commitment_labels.main_pc); + commitments.main_r_in_tag = transcript->template receive_from_prover(commitment_labels.main_r_in_tag); + commitments.main_rwa = transcript->template receive_from_prover(commitment_labels.main_rwa); + commitments.main_rwb = transcript->template receive_from_prover(commitment_labels.main_rwb); + commitments.main_rwc = transcript->template receive_from_prover(commitment_labels.main_rwc); + commitments.main_rwd = transcript->template receive_from_prover(commitment_labels.main_rwd); + commitments.main_sel_alu = transcript->template receive_from_prover(commitment_labels.main_sel_alu); + commitments.main_sel_bin = transcript->template receive_from_prover(commitment_labels.main_sel_bin); + commitments.main_sel_gas_accounting_active = + transcript->template receive_from_prover(commitment_labels.main_sel_gas_accounting_active); + commitments.main_sel_last = transcript->template receive_from_prover(commitment_labels.main_sel_last); + commitments.main_sel_mem_op_a = + transcript->template receive_from_prover(commitment_labels.main_sel_mem_op_a); + commitments.main_sel_mem_op_activate_gas = + transcript->template receive_from_prover(commitment_labels.main_sel_mem_op_activate_gas); + commitments.main_sel_mem_op_b = + transcript->template receive_from_prover(commitment_labels.main_sel_mem_op_b); + commitments.main_sel_mem_op_c = + transcript->template receive_from_prover(commitment_labels.main_sel_mem_op_c); + commitments.main_sel_mem_op_d = + transcript->template receive_from_prover(commitment_labels.main_sel_mem_op_d); + commitments.main_sel_mov_ia_to_ic = + transcript->template receive_from_prover(commitment_labels.main_sel_mov_ia_to_ic); + commitments.main_sel_mov_ib_to_ic = + transcript->template receive_from_prover(commitment_labels.main_sel_mov_ib_to_ic); + commitments.main_sel_op_add = + transcript->template receive_from_prover(commitment_labels.main_sel_op_add); + commitments.main_sel_op_address = + transcript->template receive_from_prover(commitment_labels.main_sel_op_address); + commitments.main_sel_op_and = + transcript->template receive_from_prover(commitment_labels.main_sel_op_and); + commitments.main_sel_op_block_number = + transcript->template receive_from_prover(commitment_labels.main_sel_op_block_number); + commitments.main_sel_op_cast = + transcript->template receive_from_prover(commitment_labels.main_sel_op_cast); + commitments.main_sel_op_chain_id = + transcript->template receive_from_prover(commitment_labels.main_sel_op_chain_id); + commitments.main_sel_op_cmov = + transcript->template receive_from_prover(commitment_labels.main_sel_op_cmov); + commitments.main_sel_op_coinbase = + transcript->template receive_from_prover(commitment_labels.main_sel_op_coinbase); + commitments.main_sel_op_dagasleft = + transcript->template receive_from_prover(commitment_labels.main_sel_op_dagasleft); + commitments.main_sel_op_div = + transcript->template receive_from_prover(commitment_labels.main_sel_op_div); + commitments.main_sel_op_emit_l2_to_l1_msg = + transcript->template receive_from_prover(commitment_labels.main_sel_op_emit_l2_to_l1_msg); + commitments.main_sel_op_emit_note_hash = + transcript->template receive_from_prover(commitment_labels.main_sel_op_emit_note_hash); + commitments.main_sel_op_emit_nullifier = + transcript->template receive_from_prover(commitment_labels.main_sel_op_emit_nullifier); + commitments.main_sel_op_emit_unencrypted_log = + transcript->template receive_from_prover(commitment_labels.main_sel_op_emit_unencrypted_log); + commitments.main_sel_op_eq = transcript->template receive_from_prover(commitment_labels.main_sel_op_eq); + commitments.main_sel_op_external_call = + transcript->template receive_from_prover(commitment_labels.main_sel_op_external_call); + commitments.main_sel_op_fdiv = + transcript->template receive_from_prover(commitment_labels.main_sel_op_fdiv); + commitments.main_sel_op_fee_per_da_gas = + transcript->template receive_from_prover(commitment_labels.main_sel_op_fee_per_da_gas); + commitments.main_sel_op_fee_per_l2_gas = + transcript->template receive_from_prover(commitment_labels.main_sel_op_fee_per_l2_gas); + commitments.main_sel_op_function_selector = + transcript->template receive_from_prover(commitment_labels.main_sel_op_function_selector); + commitments.main_sel_op_get_contract_instance = + transcript->template receive_from_prover(commitment_labels.main_sel_op_get_contract_instance); + commitments.main_sel_op_halt = + transcript->template receive_from_prover(commitment_labels.main_sel_op_halt); + commitments.main_sel_op_internal_call = + transcript->template receive_from_prover(commitment_labels.main_sel_op_internal_call); + commitments.main_sel_op_internal_return = + transcript->template receive_from_prover(commitment_labels.main_sel_op_internal_return); + commitments.main_sel_op_jump = + transcript->template receive_from_prover(commitment_labels.main_sel_op_jump); + commitments.main_sel_op_jumpi = + transcript->template receive_from_prover(commitment_labels.main_sel_op_jumpi); + commitments.main_sel_op_keccak = + transcript->template receive_from_prover(commitment_labels.main_sel_op_keccak); + commitments.main_sel_op_l1_to_l2_msg_exists = + transcript->template receive_from_prover(commitment_labels.main_sel_op_l1_to_l2_msg_exists); + commitments.main_sel_op_l2gasleft = + transcript->template receive_from_prover(commitment_labels.main_sel_op_l2gasleft); + commitments.main_sel_op_lt = transcript->template receive_from_prover(commitment_labels.main_sel_op_lt); + commitments.main_sel_op_lte = + transcript->template receive_from_prover(commitment_labels.main_sel_op_lte); + commitments.main_sel_op_mov = + transcript->template receive_from_prover(commitment_labels.main_sel_op_mov); + commitments.main_sel_op_mul = + transcript->template receive_from_prover(commitment_labels.main_sel_op_mul); + commitments.main_sel_op_not = + transcript->template receive_from_prover(commitment_labels.main_sel_op_not); + commitments.main_sel_op_note_hash_exists = + transcript->template receive_from_prover(commitment_labels.main_sel_op_note_hash_exists); + commitments.main_sel_op_nullifier_exists = + transcript->template receive_from_prover(commitment_labels.main_sel_op_nullifier_exists); + commitments.main_sel_op_or = transcript->template receive_from_prover(commitment_labels.main_sel_op_or); + commitments.main_sel_op_pedersen = + transcript->template receive_from_prover(commitment_labels.main_sel_op_pedersen); + commitments.main_sel_op_poseidon2 = + transcript->template receive_from_prover(commitment_labels.main_sel_op_poseidon2); + commitments.main_sel_op_radix_le = + transcript->template receive_from_prover(commitment_labels.main_sel_op_radix_le); + commitments.main_sel_op_sender = + transcript->template receive_from_prover(commitment_labels.main_sel_op_sender); + commitments.main_sel_op_sha256 = + transcript->template receive_from_prover(commitment_labels.main_sel_op_sha256); + commitments.main_sel_op_shl = + transcript->template receive_from_prover(commitment_labels.main_sel_op_shl); + commitments.main_sel_op_shr = + transcript->template receive_from_prover(commitment_labels.main_sel_op_shr); + commitments.main_sel_op_sload = + transcript->template receive_from_prover(commitment_labels.main_sel_op_sload); + commitments.main_sel_op_sstore = + transcript->template receive_from_prover(commitment_labels.main_sel_op_sstore); + commitments.main_sel_op_storage_address = + transcript->template receive_from_prover(commitment_labels.main_sel_op_storage_address); + commitments.main_sel_op_sub = + transcript->template receive_from_prover(commitment_labels.main_sel_op_sub); + commitments.main_sel_op_timestamp = + transcript->template receive_from_prover(commitment_labels.main_sel_op_timestamp); + commitments.main_sel_op_transaction_fee = + transcript->template receive_from_prover(commitment_labels.main_sel_op_transaction_fee); + commitments.main_sel_op_version = + transcript->template receive_from_prover(commitment_labels.main_sel_op_version); + commitments.main_sel_op_xor = + transcript->template receive_from_prover(commitment_labels.main_sel_op_xor); + commitments.main_sel_q_kernel_lookup = + transcript->template receive_from_prover(commitment_labels.main_sel_q_kernel_lookup); + commitments.main_sel_q_kernel_output_lookup = + transcript->template receive_from_prover(commitment_labels.main_sel_q_kernel_output_lookup); + commitments.main_sel_resolve_ind_addr_a = + transcript->template receive_from_prover(commitment_labels.main_sel_resolve_ind_addr_a); + commitments.main_sel_resolve_ind_addr_b = + transcript->template receive_from_prover(commitment_labels.main_sel_resolve_ind_addr_b); + commitments.main_sel_resolve_ind_addr_c = + transcript->template receive_from_prover(commitment_labels.main_sel_resolve_ind_addr_c); + commitments.main_sel_resolve_ind_addr_d = + transcript->template receive_from_prover(commitment_labels.main_sel_resolve_ind_addr_d); + commitments.main_sel_rng_16 = + transcript->template receive_from_prover(commitment_labels.main_sel_rng_16); + commitments.main_sel_rng_8 = transcript->template receive_from_prover(commitment_labels.main_sel_rng_8); + commitments.main_space_id = transcript->template receive_from_prover(commitment_labels.main_space_id); + commitments.main_tag_err = transcript->template receive_from_prover(commitment_labels.main_tag_err); + commitments.main_w_in_tag = transcript->template receive_from_prover(commitment_labels.main_w_in_tag); + commitments.mem_addr = transcript->template receive_from_prover(commitment_labels.mem_addr); + commitments.mem_clk = transcript->template receive_from_prover(commitment_labels.mem_clk); + commitments.mem_diff_hi = transcript->template receive_from_prover(commitment_labels.mem_diff_hi); + commitments.mem_diff_lo = transcript->template receive_from_prover(commitment_labels.mem_diff_lo); + commitments.mem_diff_mid = transcript->template receive_from_prover(commitment_labels.mem_diff_mid); + commitments.mem_glob_addr = transcript->template receive_from_prover(commitment_labels.mem_glob_addr); + commitments.mem_last = transcript->template receive_from_prover(commitment_labels.mem_last); + commitments.mem_lastAccess = transcript->template receive_from_prover(commitment_labels.mem_lastAccess); + commitments.mem_one_min_inv = + transcript->template receive_from_prover(commitment_labels.mem_one_min_inv); + commitments.mem_r_in_tag = transcript->template receive_from_prover(commitment_labels.mem_r_in_tag); + commitments.mem_rw = transcript->template receive_from_prover(commitment_labels.mem_rw); + commitments.mem_sel_mem = transcript->template receive_from_prover(commitment_labels.mem_sel_mem); + commitments.mem_sel_mov_ia_to_ic = + transcript->template receive_from_prover(commitment_labels.mem_sel_mov_ia_to_ic); + commitments.mem_sel_mov_ib_to_ic = + transcript->template receive_from_prover(commitment_labels.mem_sel_mov_ib_to_ic); + commitments.mem_sel_op_a = transcript->template receive_from_prover(commitment_labels.mem_sel_op_a); + commitments.mem_sel_op_b = transcript->template receive_from_prover(commitment_labels.mem_sel_op_b); + commitments.mem_sel_op_c = transcript->template receive_from_prover(commitment_labels.mem_sel_op_c); + commitments.mem_sel_op_cmov = + transcript->template receive_from_prover(commitment_labels.mem_sel_op_cmov); + commitments.mem_sel_op_d = transcript->template receive_from_prover(commitment_labels.mem_sel_op_d); + commitments.mem_sel_resolve_ind_addr_a = + transcript->template receive_from_prover(commitment_labels.mem_sel_resolve_ind_addr_a); + commitments.mem_sel_resolve_ind_addr_b = + transcript->template receive_from_prover(commitment_labels.mem_sel_resolve_ind_addr_b); + commitments.mem_sel_resolve_ind_addr_c = + transcript->template receive_from_prover(commitment_labels.mem_sel_resolve_ind_addr_c); + commitments.mem_sel_resolve_ind_addr_d = + transcript->template receive_from_prover(commitment_labels.mem_sel_resolve_ind_addr_d); + commitments.mem_sel_rng_chk = + transcript->template receive_from_prover(commitment_labels.mem_sel_rng_chk); + commitments.mem_skip_check_tag = + transcript->template receive_from_prover(commitment_labels.mem_skip_check_tag); + commitments.mem_space_id = transcript->template receive_from_prover(commitment_labels.mem_space_id); + commitments.mem_tag = transcript->template receive_from_prover(commitment_labels.mem_tag); + commitments.mem_tag_err = transcript->template receive_from_prover(commitment_labels.mem_tag_err); + commitments.mem_tsp = transcript->template receive_from_prover(commitment_labels.mem_tsp); + commitments.mem_val = transcript->template receive_from_prover(commitment_labels.mem_val); + commitments.mem_w_in_tag = transcript->template receive_from_prover(commitment_labels.mem_w_in_tag); + commitments.pedersen_clk = transcript->template receive_from_prover(commitment_labels.pedersen_clk); + commitments.pedersen_input = transcript->template receive_from_prover(commitment_labels.pedersen_input); + commitments.pedersen_output = + transcript->template receive_from_prover(commitment_labels.pedersen_output); + commitments.pedersen_sel_pedersen = + transcript->template receive_from_prover(commitment_labels.pedersen_sel_pedersen); + commitments.poseidon2_a_0 = transcript->template receive_from_prover(commitment_labels.poseidon2_a_0); + commitments.poseidon2_a_1 = transcript->template receive_from_prover(commitment_labels.poseidon2_a_1); + commitments.poseidon2_a_2 = transcript->template receive_from_prover(commitment_labels.poseidon2_a_2); + commitments.poseidon2_a_3 = transcript->template receive_from_prover(commitment_labels.poseidon2_a_3); + commitments.poseidon2_b_0 = transcript->template receive_from_prover(commitment_labels.poseidon2_b_0); + commitments.poseidon2_b_1 = transcript->template receive_from_prover(commitment_labels.poseidon2_b_1); + commitments.poseidon2_b_2 = transcript->template receive_from_prover(commitment_labels.poseidon2_b_2); + commitments.poseidon2_b_3 = transcript->template receive_from_prover(commitment_labels.poseidon2_b_3); + commitments.poseidon2_clk = transcript->template receive_from_prover(commitment_labels.poseidon2_clk); + commitments.poseidon2_input = + transcript->template receive_from_prover(commitment_labels.poseidon2_input); + commitments.poseidon2_output = + transcript->template receive_from_prover(commitment_labels.poseidon2_output); + commitments.poseidon2_sel_poseidon_perm = + transcript->template receive_from_prover(commitment_labels.poseidon2_sel_poseidon_perm); + commitments.powers_power_of_2 = + transcript->template receive_from_prover(commitment_labels.powers_power_of_2); + commitments.sha256_clk = transcript->template receive_from_prover(commitment_labels.sha256_clk); + commitments.sha256_input = transcript->template receive_from_prover(commitment_labels.sha256_input); + commitments.sha256_output = transcript->template receive_from_prover(commitment_labels.sha256_output); + commitments.sha256_sel_sha256_compression = + transcript->template receive_from_prover(commitment_labels.sha256_sel_sha256_compression); + commitments.sha256_state = transcript->template receive_from_prover(commitment_labels.sha256_state); + commitments.lookup_byte_lengths_counts = + transcript->template receive_from_prover(commitment_labels.lookup_byte_lengths_counts); + commitments.lookup_byte_operations_counts = + transcript->template receive_from_prover(commitment_labels.lookup_byte_operations_counts); + commitments.lookup_opcode_gas_counts = + transcript->template receive_from_prover(commitment_labels.lookup_opcode_gas_counts); + commitments.range_check_l2_gas_hi_counts = + transcript->template receive_from_prover(commitment_labels.range_check_l2_gas_hi_counts); + commitments.range_check_l2_gas_lo_counts = + transcript->template receive_from_prover(commitment_labels.range_check_l2_gas_lo_counts); + commitments.range_check_da_gas_hi_counts = + transcript->template receive_from_prover(commitment_labels.range_check_da_gas_hi_counts); + commitments.range_check_da_gas_lo_counts = + transcript->template receive_from_prover(commitment_labels.range_check_da_gas_lo_counts); + commitments.kernel_output_lookup_counts = + transcript->template receive_from_prover(commitment_labels.kernel_output_lookup_counts); + commitments.lookup_into_kernel_counts = + transcript->template receive_from_prover(commitment_labels.lookup_into_kernel_counts); + commitments.incl_main_tag_err_counts = + transcript->template receive_from_prover(commitment_labels.incl_main_tag_err_counts); + commitments.incl_mem_tag_err_counts = + transcript->template receive_from_prover(commitment_labels.incl_mem_tag_err_counts); + commitments.lookup_mem_rng_chk_lo_counts = + transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_lo_counts); + commitments.lookup_mem_rng_chk_mid_counts = + transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_mid_counts); + commitments.lookup_mem_rng_chk_hi_counts = + transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_hi_counts); + commitments.lookup_pow_2_0_counts = + transcript->template receive_from_prover(commitment_labels.lookup_pow_2_0_counts); + commitments.lookup_pow_2_1_counts = + transcript->template receive_from_prover(commitment_labels.lookup_pow_2_1_counts); + commitments.lookup_u8_0_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u8_0_counts); + commitments.lookup_u8_1_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u8_1_counts); + commitments.lookup_u16_0_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_0_counts); + commitments.lookup_u16_1_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_1_counts); + commitments.lookup_u16_2_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_2_counts); + commitments.lookup_u16_3_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_3_counts); + commitments.lookup_u16_4_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_4_counts); + commitments.lookup_u16_5_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_5_counts); + commitments.lookup_u16_6_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_6_counts); + commitments.lookup_u16_7_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_7_counts); + commitments.lookup_u16_8_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_8_counts); + commitments.lookup_u16_9_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_9_counts); + commitments.lookup_u16_10_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_10_counts); + commitments.lookup_u16_11_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_11_counts); + commitments.lookup_u16_12_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_12_counts); + commitments.lookup_u16_13_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_13_counts); + commitments.lookup_u16_14_counts = + transcript->template receive_from_prover(commitment_labels.lookup_u16_14_counts); + commitments.lookup_div_u16_0_counts = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_0_counts); + commitments.lookup_div_u16_1_counts = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_1_counts); + commitments.lookup_div_u16_2_counts = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_2_counts); + commitments.lookup_div_u16_3_counts = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_3_counts); + commitments.lookup_div_u16_4_counts = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_4_counts); + commitments.lookup_div_u16_5_counts = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_5_counts); + commitments.lookup_div_u16_6_counts = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_6_counts); + commitments.lookup_div_u16_7_counts = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_7_counts); +>>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) + + auto [beta, gamm] = transcript->template get_challenges("beta", "gamma"); + relation_parameters.beta = beta; + relation_parameters.gamma = gamm; + + // Get commitments to inverses + commitments.perm_slice_mem = transcript->template receive_from_prover(commitment_labels.perm_slice_mem); + commitments.perm_main_alu = transcript->template receive_from_prover(commitment_labels.perm_main_alu); + commitments.perm_main_bin = transcript->template receive_from_prover(commitment_labels.perm_main_bin); + commitments.perm_main_conv = transcript->template receive_from_prover(commitment_labels.perm_main_conv); + commitments.perm_main_pos2_perm = + transcript->template receive_from_prover(commitment_labels.perm_main_pos2_perm); + commitments.perm_main_pedersen = + transcript->template receive_from_prover(commitment_labels.perm_main_pedersen); + commitments.perm_main_slice = + transcript->template receive_from_prover(commitment_labels.perm_main_slice); + commitments.perm_main_mem_a = + transcript->template receive_from_prover(commitment_labels.perm_main_mem_a); + commitments.perm_main_mem_b = + transcript->template receive_from_prover(commitment_labels.perm_main_mem_b); + commitments.perm_main_mem_c = + transcript->template receive_from_prover(commitment_labels.perm_main_mem_c); + commitments.perm_main_mem_d = + transcript->template receive_from_prover(commitment_labels.perm_main_mem_d); + commitments.perm_main_mem_ind_addr_a = + transcript->template receive_from_prover(commitment_labels.perm_main_mem_ind_addr_a); + commitments.perm_main_mem_ind_addr_b = + transcript->template receive_from_prover(commitment_labels.perm_main_mem_ind_addr_b); + commitments.perm_main_mem_ind_addr_c = + transcript->template receive_from_prover(commitment_labels.perm_main_mem_ind_addr_c); + commitments.perm_main_mem_ind_addr_d = + transcript->template receive_from_prover(commitment_labels.perm_main_mem_ind_addr_d); + commitments.lookup_byte_lengths = + transcript->template receive_from_prover(commitment_labels.lookup_byte_lengths); + commitments.lookup_byte_operations = + transcript->template receive_from_prover(commitment_labels.lookup_byte_operations); + commitments.lookup_cd_value = + transcript->template receive_from_prover(commitment_labels.lookup_cd_value); + commitments.lookup_ret_value = + transcript->template receive_from_prover(commitment_labels.lookup_ret_value); + commitments.lookup_opcode_gas = + transcript->template receive_from_prover(commitment_labels.lookup_opcode_gas); + commitments.range_check_l2_gas_hi = + transcript->template receive_from_prover(commitment_labels.range_check_l2_gas_hi); + commitments.range_check_l2_gas_lo = + transcript->template receive_from_prover(commitment_labels.range_check_l2_gas_lo); + commitments.range_check_da_gas_hi = + transcript->template receive_from_prover(commitment_labels.range_check_da_gas_hi); + commitments.range_check_da_gas_lo = + transcript->template receive_from_prover(commitment_labels.range_check_da_gas_lo); + commitments.kernel_output_lookup = + transcript->template receive_from_prover(commitment_labels.kernel_output_lookup); + commitments.lookup_into_kernel = + transcript->template receive_from_prover(commitment_labels.lookup_into_kernel); + commitments.incl_main_tag_err = + transcript->template receive_from_prover(commitment_labels.incl_main_tag_err); + commitments.incl_mem_tag_err = + transcript->template receive_from_prover(commitment_labels.incl_mem_tag_err); + commitments.lookup_mem_rng_chk_lo = + transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_lo); + commitments.lookup_mem_rng_chk_mid = + transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_mid); + commitments.lookup_mem_rng_chk_hi = + transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_hi); + commitments.lookup_pow_2_0 = transcript->template receive_from_prover(commitment_labels.lookup_pow_2_0); + commitments.lookup_pow_2_1 = transcript->template receive_from_prover(commitment_labels.lookup_pow_2_1); + commitments.lookup_u8_0 = transcript->template receive_from_prover(commitment_labels.lookup_u8_0); + commitments.lookup_u8_1 = transcript->template receive_from_prover(commitment_labels.lookup_u8_1); + commitments.lookup_u16_0 = transcript->template receive_from_prover(commitment_labels.lookup_u16_0); + commitments.lookup_u16_1 = transcript->template receive_from_prover(commitment_labels.lookup_u16_1); + commitments.lookup_u16_2 = transcript->template receive_from_prover(commitment_labels.lookup_u16_2); + commitments.lookup_u16_3 = transcript->template receive_from_prover(commitment_labels.lookup_u16_3); + commitments.lookup_u16_4 = transcript->template receive_from_prover(commitment_labels.lookup_u16_4); + commitments.lookup_u16_5 = transcript->template receive_from_prover(commitment_labels.lookup_u16_5); + commitments.lookup_u16_6 = transcript->template receive_from_prover(commitment_labels.lookup_u16_6); + commitments.lookup_u16_7 = transcript->template receive_from_prover(commitment_labels.lookup_u16_7); + commitments.lookup_u16_8 = transcript->template receive_from_prover(commitment_labels.lookup_u16_8); + commitments.lookup_u16_9 = transcript->template receive_from_prover(commitment_labels.lookup_u16_9); + commitments.lookup_u16_10 = transcript->template receive_from_prover(commitment_labels.lookup_u16_10); + commitments.lookup_u16_11 = transcript->template receive_from_prover(commitment_labels.lookup_u16_11); + commitments.lookup_u16_12 = transcript->template receive_from_prover(commitment_labels.lookup_u16_12); + commitments.lookup_u16_13 = transcript->template receive_from_prover(commitment_labels.lookup_u16_13); + commitments.lookup_u16_14 = transcript->template receive_from_prover(commitment_labels.lookup_u16_14); + commitments.lookup_div_u16_0 = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_0); + commitments.lookup_div_u16_1 = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_1); + commitments.lookup_div_u16_2 = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_2); + commitments.lookup_div_u16_3 = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_3); + commitments.lookup_div_u16_4 = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_4); + commitments.lookup_div_u16_5 = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_5); + commitments.lookup_div_u16_6 = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_6); + commitments.lookup_div_u16_7 = + transcript->template receive_from_prover(commitment_labels.lookup_div_u16_7); + + // Execute Sumcheck Verifier + const size_t log_circuit_size = numeric::get_msb(circuit_size); + auto sumcheck = SumcheckVerifier(log_circuit_size, transcript); + + FF alpha = transcript->template get_challenge("Sumcheck:alpha"); + + auto gate_challenges = std::vector(log_circuit_size); + for (size_t idx = 0; idx < log_circuit_size; idx++) { + gate_challenges[idx] = transcript->template get_challenge("Sumcheck:gate_challenge_" + std::to_string(idx)); + } + + auto [multivariate_challenge, claimed_evaluations, sumcheck_verified] = + sumcheck.verify(relation_parameters, alpha, gate_challenges); + + // If Sumcheck did not verify, return false + if (sumcheck_verified.has_value() && !sumcheck_verified.value()) { + return false; + } + + // Public columns evaluation checks + std::vector mle_challenge(multivariate_challenge.begin(), + multivariate_challenge.begin() + static_cast(log_circuit_size)); + + FF kernel_kernel_inputs_evaluation = evaluate_public_input_column(public_inputs[0], circuit_size, mle_challenge); + if (kernel_kernel_inputs_evaluation != claimed_evaluations.kernel_kernel_inputs) { + return false; + } + FF kernel_kernel_value_out_evaluation = evaluate_public_input_column(public_inputs[1], circuit_size, mle_challenge); + if (kernel_kernel_value_out_evaluation != claimed_evaluations.kernel_kernel_value_out) { + return false; + } + FF kernel_kernel_side_effect_out_evaluation = + evaluate_public_input_column(public_inputs[2], circuit_size, mle_challenge); + if (kernel_kernel_side_effect_out_evaluation != claimed_evaluations.kernel_kernel_side_effect_out) { + return false; + } + FF kernel_kernel_metadata_out_evaluation = + evaluate_public_input_column(public_inputs[3], circuit_size, mle_challenge); + if (kernel_kernel_metadata_out_evaluation != claimed_evaluations.kernel_kernel_metadata_out) { + return false; + } + FF main_calldata_evaluation = evaluate_public_input_column(public_inputs[4], circuit_size, mle_challenge); + if (main_calldata_evaluation != claimed_evaluations.main_calldata) { + return false; + } + FF main_returndata_evaluation = evaluate_public_input_column(public_inputs[5], circuit_size, mle_challenge); + if (main_returndata_evaluation != claimed_evaluations.main_returndata) { + return false; + } + + // Execute ZeroMorph rounds. See https://hackmd.io/dlf9xEwhTQyE3hiGbq4FsA?view for a complete description of the + // unrolled protocol. + // NOTE: temporarily disabled - facing integration issues + // auto opening_claim = ZeroMorph::verify(circuit_size, + // commitments.get_unshifted(), + // commitments.get_to_be_shifted(), + // claimed_evaluations.get_unshifted(), + // claimed_evaluations.get_shifted(), + // multivariate_challenge, + // pcs_verification_key->get_g1_identity(), + // transcript); + + // auto pairing_points = PCS::reduce_verify(opening_claim, transcript); + // auto verified = pcs_verification_key->pairing_check(pairing_points[0], pairing_points[1]); + // return sumcheck_verified.value() && verified; + return sumcheck_verified.value(); +} + +} // namespace bb diff --git a/barretenberg/srs_db/grumpkin/monomial/transcript00.dat b/barretenberg/srs_db/grumpkin/monomial/transcript00.dat new file mode 100644 index 0000000000000000000000000000000000000000..7971743c1a87df13d27a4ee78cfcb09db0ad763f GIT binary patch literal 92 zcmZQz00TxK3Bn)%qZ#I%|2xk` Date: Wed, 26 Jun 2024 16:20:34 +0000 Subject: [PATCH 2/4] fix: adjust poseidon --- .../cpp/pil/avm/gadgets/poseidon2.pil | 444 +++++++++--------- 1 file changed, 222 insertions(+), 222 deletions(-) diff --git a/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil b/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil index 3f8283674fa8..ca2c5d2f8cf6 100644 --- a/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil +++ b/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil @@ -157,10 +157,10 @@ namespace poseidon2(256); // Round 6 (Partial Round) // ARK (Add Round Constant) - pol ARK_5_0 = B_5_0 + poseidon2_params.C_5_0; - pol ARK_5_1 = B_5_0 + poseidon2_params.C_5_1; - pol ARK_5_2 = B_5_0 + poseidon2_params.C_5_2; - pol ARK_5_3 = B_5_0 + poseidon2_params.C_5_3; + pol ARK_5_0 = B_4_0 + poseidon2_params.C_5_0; + pol ARK_5_1 = B_4_1 + poseidon2_params.C_5_1; + pol ARK_5_2 = B_4_2 + poseidon2_params.C_5_2; + pol ARK_5_3 = B_4_3 + poseidon2_params.C_5_3; // S-BOX (In partial round only first input is exponentiated) pol A_5_0 = ARK_5_0 * ARK_5_0 * ARK_5_0 * ARK_5_0 * ARK_5_0; @@ -176,10 +176,10 @@ namespace poseidon2(256); // Round 7 (Partial Round) // ARK (Add Round Constant) - pol ARK_6_0 = B_6_0 + poseidon2_params.C_6_0; - pol ARK_6_1 = B_6_0 + poseidon2_params.C_6_1; - pol ARK_6_2 = B_6_0 + poseidon2_params.C_6_2; - pol ARK_6_3 = B_6_0 + poseidon2_params.C_6_3; + pol ARK_6_0 = B_5_0 + poseidon2_params.C_6_0; + pol ARK_6_1 = B_5_1 + poseidon2_params.C_6_1; + pol ARK_6_2 = B_5_2 + poseidon2_params.C_6_2; + pol ARK_6_3 = B_5_3 + poseidon2_params.C_6_3; // S-BOX (In partial round only first input is exponentiated) pol A_6_0 = ARK_6_0 * ARK_6_0 * ARK_6_0 * ARK_6_0 * ARK_6_0; @@ -195,10 +195,10 @@ namespace poseidon2(256); // Round 8 (Partial Round) // ARK (Add Round Constant) - pol ARK_7_0 = B_7_0 + poseidon2_params.C_7_0; - pol ARK_7_1 = B_7_0 + poseidon2_params.C_7_1; - pol ARK_7_2 = B_7_0 + poseidon2_params.C_7_2; - pol ARK_7_3 = B_7_0 + poseidon2_params.C_7_3; + pol ARK_7_0 = B_6_0 + poseidon2_params.C_7_0; + pol ARK_7_1 = B_6_1 + poseidon2_params.C_7_1; + pol ARK_7_2 = B_6_2 + poseidon2_params.C_7_2; + pol ARK_7_3 = B_6_3 + poseidon2_params.C_7_3; // S-BOX (In partial round only first input is exponentiated) pol A_7_0 = ARK_7_0 * ARK_7_0 * ARK_7_0 * ARK_7_0 * ARK_7_0; @@ -214,10 +214,10 @@ namespace poseidon2(256); // Round 9 (Partial Round) // ARK (Add Round Constant) - pol ARK_8_0 = B_8_0 + poseidon2_params.C_8_0; - pol ARK_8_1 = B_8_0 + poseidon2_params.C_8_1; - pol ARK_8_2 = B_8_0 + poseidon2_params.C_8_2; - pol ARK_8_3 = B_8_0 + poseidon2_params.C_8_3; + pol ARK_8_0 = B_7_0 + poseidon2_params.C_8_0; + pol ARK_8_1 = B_7_1 + poseidon2_params.C_8_1; + pol ARK_8_2 = B_7_2 + poseidon2_params.C_8_2; + pol ARK_8_3 = B_7_3 + poseidon2_params.C_8_3; // S-BOX (In partial round only first input is exponentiated) pol A_8_0 = ARK_8_0 * ARK_8_0 * ARK_8_0 * ARK_8_0 * ARK_8_0; @@ -233,10 +233,10 @@ namespace poseidon2(256); // Round 10 (Partial Round) // ARK (Add Round Constant) - pol ARK_9_0 = B_9_0 + poseidon2_params.C_9_0; - pol ARK_9_1 = B_9_0 + poseidon2_params.C_9_1; - pol ARK_9_2 = B_9_0 + poseidon2_params.C_9_2; - pol ARK_9_3 = B_9_0 + poseidon2_params.C_9_3; + pol ARK_9_0 = B_8_0 + poseidon2_params.C_9_0; + pol ARK_9_1 = B_8_1 + poseidon2_params.C_9_1; + pol ARK_9_2 = B_8_2 + poseidon2_params.C_9_2; + pol ARK_9_3 = B_8_3 + poseidon2_params.C_9_3; // S-BOX (In partial round only first input is exponentiated) pol A_9_0 = ARK_9_0 * ARK_9_0 * ARK_9_0 * ARK_9_0 * ARK_9_0; @@ -252,10 +252,10 @@ namespace poseidon2(256); // Round 11 (Partial Round) // ARK (Add Round Constant) - pol ARK_10_0 = B_10_0 + poseidon2_params.C_10_0; - pol ARK_10_1 = B_10_0 + poseidon2_params.C_10_1; - pol ARK_10_2 = B_10_0 + poseidon2_params.C_10_2; - pol ARK_10_3 = B_10_0 + poseidon2_params.C_10_3; + pol ARK_10_0 = B_9_0 + poseidon2_params.C_10_0; + pol ARK_10_1 = B_9_1 + poseidon2_params.C_10_1; + pol ARK_10_2 = B_9_2 + poseidon2_params.C_10_2; + pol ARK_10_3 = B_9_3 + poseidon2_params.C_10_3; // S-BOX (In partial round only first input is exponentiated) pol A_10_0 = ARK_10_0 * ARK_10_0 * ARK_10_0 * ARK_10_0 * ARK_10_0; @@ -271,10 +271,10 @@ namespace poseidon2(256); // Round 12 (Partial Round) // ARK (Add Round Constant) - pol ARK_11_0 = B_11_0 + poseidon2_params.C_11_0; - pol ARK_11_1 = B_11_0 + poseidon2_params.C_11_1; - pol ARK_11_2 = B_11_0 + poseidon2_params.C_11_2; - pol ARK_11_3 = B_11_0 + poseidon2_params.C_11_3; + pol ARK_11_0 = B_10_0 + poseidon2_params.C_11_0; + pol ARK_11_1 = B_10_1 + poseidon2_params.C_11_1; + pol ARK_11_2 = B_10_2 + poseidon2_params.C_11_2; + pol ARK_11_3 = B_10_3 + poseidon2_params.C_11_3; // S-BOX (In partial round only first input is exponentiated) pol A_11_0 = ARK_11_0 * ARK_11_0 * ARK_11_0 * ARK_11_0 * ARK_11_0; @@ -290,10 +290,10 @@ namespace poseidon2(256); // Round 13 (Partial Round) // ARK (Add Round Constant) - pol ARK_12_0 = B_12_0 + poseidon2_params.C_12_0; - pol ARK_12_1 = B_12_0 + poseidon2_params.C_12_1; - pol ARK_12_2 = B_12_0 + poseidon2_params.C_12_2; - pol ARK_12_3 = B_12_0 + poseidon2_params.C_12_3; + pol ARK_12_0 = B_11_0 + poseidon2_params.C_12_0; + pol ARK_12_1 = B_11_1 + poseidon2_params.C_12_1; + pol ARK_12_2 = B_11_2 + poseidon2_params.C_12_2; + pol ARK_12_3 = B_11_3 + poseidon2_params.C_12_3; // S-BOX (In partial round only first input is exponentiated) pol A_12_0 = ARK_12_0 * ARK_12_0 * ARK_12_0 * ARK_12_0 * ARK_12_0; @@ -309,10 +309,10 @@ namespace poseidon2(256); // Round 14 (Partial Round) // ARK (Add Round Constant) - pol ARK_13_0 = B_13_0 + poseidon2_params.C_13_0; - pol ARK_13_1 = B_13_0 + poseidon2_params.C_13_1; - pol ARK_13_2 = B_13_0 + poseidon2_params.C_13_2; - pol ARK_13_3 = B_13_0 + poseidon2_params.C_13_3; + pol ARK_13_0 = B_12_0 + poseidon2_params.C_13_0; + pol ARK_13_1 = B_12_1 + poseidon2_params.C_13_1; + pol ARK_13_2 = B_12_2 + poseidon2_params.C_13_2; + pol ARK_13_3 = B_12_3 + poseidon2_params.C_13_3; // S-BOX (In partial round only first input is exponentiated) pol A_13_0 = ARK_13_0 * ARK_13_0 * ARK_13_0 * ARK_13_0 * ARK_13_0; @@ -328,10 +328,10 @@ namespace poseidon2(256); // Round 15 (Partial Round) // ARK (Add Round Constant) - pol ARK_14_0 = B_14_0 + poseidon2_params.C_14_0; - pol ARK_14_1 = B_14_0 + poseidon2_params.C_14_1; - pol ARK_14_2 = B_14_0 + poseidon2_params.C_14_2; - pol ARK_14_3 = B_14_0 + poseidon2_params.C_14_3; + pol ARK_14_0 = B_13_0 + poseidon2_params.C_14_0; + pol ARK_14_1 = B_13_1 + poseidon2_params.C_14_1; + pol ARK_14_2 = B_13_2 + poseidon2_params.C_14_2; + pol ARK_14_3 = B_13_3 + poseidon2_params.C_14_3; // S-BOX (In partial round only first input is exponentiated) pol A_14_0 = ARK_14_0 * ARK_14_0 * ARK_14_0 * ARK_14_0 * ARK_14_0; @@ -347,10 +347,10 @@ namespace poseidon2(256); // Round 16 (Partial Round) // ARK (Add Round Constant) - pol ARK_15_0 = B_15_0 + poseidon2_params.C_15_0; - pol ARK_15_1 = B_15_0 + poseidon2_params.C_15_1; - pol ARK_15_2 = B_15_0 + poseidon2_params.C_15_2; - pol ARK_15_3 = B_15_0 + poseidon2_params.C_15_3; + pol ARK_15_0 = B_14_0 + poseidon2_params.C_15_0; + pol ARK_15_1 = B_14_1 + poseidon2_params.C_15_1; + pol ARK_15_2 = B_14_2 + poseidon2_params.C_15_2; + pol ARK_15_3 = B_14_3 + poseidon2_params.C_15_3; // S-BOX (In partial round only first input is exponentiated) pol A_15_0 = ARK_15_0 * ARK_15_0 * ARK_15_0 * ARK_15_0 * ARK_15_0; @@ -366,10 +366,10 @@ namespace poseidon2(256); // Round 17 (Partial Round) // ARK (Add Round Constant) - pol ARK_16_0 = B_16_0 + poseidon2_params.C_16_0; - pol ARK_16_1 = B_16_0 + poseidon2_params.C_16_1; - pol ARK_16_2 = B_16_0 + poseidon2_params.C_16_2; - pol ARK_16_3 = B_16_0 + poseidon2_params.C_16_3; + pol ARK_16_0 = B_15_0 + poseidon2_params.C_16_0; + pol ARK_16_1 = B_15_1 + poseidon2_params.C_16_1; + pol ARK_16_2 = B_15_2 + poseidon2_params.C_16_2; + pol ARK_16_3 = B_15_3 + poseidon2_params.C_16_3; // S-BOX (In partial round only first input is exponentiated) pol A_16_0 = ARK_16_0 * ARK_16_0 * ARK_16_0 * ARK_16_0 * ARK_16_0; @@ -385,10 +385,10 @@ namespace poseidon2(256); // Round 18 (Partial Round) // ARK (Add Round Constant) - pol ARK_17_0 = B_17_0 + poseidon2_params.C_17_0; - pol ARK_17_1 = B_17_0 + poseidon2_params.C_17_1; - pol ARK_17_2 = B_17_0 + poseidon2_params.C_17_2; - pol ARK_17_3 = B_17_0 + poseidon2_params.C_17_3; + pol ARK_17_0 = B_16_0 + poseidon2_params.C_17_0; + pol ARK_17_1 = B_16_1 + poseidon2_params.C_17_1; + pol ARK_17_2 = B_16_2 + poseidon2_params.C_17_2; + pol ARK_17_3 = B_16_3 + poseidon2_params.C_17_3; // S-BOX (In partial round only first input is exponentiated) pol A_17_0 = ARK_17_0 * ARK_17_0 * ARK_17_0 * ARK_17_0 * ARK_17_0; @@ -404,10 +404,10 @@ namespace poseidon2(256); // Round 19 (Partial Round) // ARK (Add Round Constant) - pol ARK_18_0 = B_18_0 + poseidon2_params.C_18_0; - pol ARK_18_1 = B_18_0 + poseidon2_params.C_18_1; - pol ARK_18_2 = B_18_0 + poseidon2_params.C_18_2; - pol ARK_18_3 = B_18_0 + poseidon2_params.C_18_3; + pol ARK_18_0 = B_17_0 + poseidon2_params.C_18_0; + pol ARK_18_1 = B_17_1 + poseidon2_params.C_18_1; + pol ARK_18_2 = B_17_2 + poseidon2_params.C_18_2; + pol ARK_18_3 = B_17_3 + poseidon2_params.C_18_3; // S-BOX (In partial round only first input is exponentiated) pol A_18_0 = ARK_18_0 * ARK_18_0 * ARK_18_0 * ARK_18_0 * ARK_18_0; @@ -423,10 +423,10 @@ namespace poseidon2(256); // Round 20 (Partial Round) // ARK (Add Round Constant) - pol ARK_19_0 = B_19_0 + poseidon2_params.C_19_0; - pol ARK_19_1 = B_19_0 + poseidon2_params.C_19_1; - pol ARK_19_2 = B_19_0 + poseidon2_params.C_19_2; - pol ARK_19_3 = B_19_0 + poseidon2_params.C_19_3; + pol ARK_19_0 = B_18_0 + poseidon2_params.C_19_0; + pol ARK_19_1 = B_18_1 + poseidon2_params.C_19_1; + pol ARK_19_2 = B_18_2 + poseidon2_params.C_19_2; + pol ARK_19_3 = B_18_3 + poseidon2_params.C_19_3; // S-BOX (In partial round only first input is exponentiated) pol A_19_0 = ARK_19_0 * ARK_19_0 * ARK_19_0 * ARK_19_0 * ARK_19_0; @@ -442,10 +442,10 @@ namespace poseidon2(256); // Round 21 (Partial Round) // ARK (Add Round Constant) - pol ARK_20_0 = B_20_0 + poseidon2_params.C_20_0; - pol ARK_20_1 = B_20_0 + poseidon2_params.C_20_1; - pol ARK_20_2 = B_20_0 + poseidon2_params.C_20_2; - pol ARK_20_3 = B_20_0 + poseidon2_params.C_20_3; + pol ARK_20_0 = B_19_0 + poseidon2_params.C_20_0; + pol ARK_20_1 = B_19_1 + poseidon2_params.C_20_1; + pol ARK_20_2 = B_19_2 + poseidon2_params.C_20_2; + pol ARK_20_3 = B_19_3 + poseidon2_params.C_20_3; // S-BOX (In partial round only first input is exponentiated) pol A_20_0 = ARK_20_0 * ARK_20_0 * ARK_20_0 * ARK_20_0 * ARK_20_0; @@ -461,10 +461,10 @@ namespace poseidon2(256); // Round 22 (Partial Round) // ARK (Add Round Constant) - pol ARK_21_0 = B_21_0 + poseidon2_params.C_21_0; - pol ARK_21_1 = B_21_0 + poseidon2_params.C_21_1; - pol ARK_21_2 = B_21_0 + poseidon2_params.C_21_2; - pol ARK_21_3 = B_21_0 + poseidon2_params.C_21_3; + pol ARK_21_0 = B_20_0 + poseidon2_params.C_21_0; + pol ARK_21_1 = B_20_1 + poseidon2_params.C_21_1; + pol ARK_21_2 = B_20_2 + poseidon2_params.C_21_2; + pol ARK_21_3 = B_20_3 + poseidon2_params.C_21_3; // S-BOX (In partial round only first input is exponentiated) pol A_21_0 = ARK_21_0 * ARK_21_0 * ARK_21_0 * ARK_21_0 * ARK_21_0; @@ -480,10 +480,10 @@ namespace poseidon2(256); // Round 23 (Partial Round) // ARK (Add Round Constant) - pol ARK_22_0 = B_22_0 + poseidon2_params.C_22_0; - pol ARK_22_1 = B_22_0 + poseidon2_params.C_22_1; - pol ARK_22_2 = B_22_0 + poseidon2_params.C_22_2; - pol ARK_22_3 = B_22_0 + poseidon2_params.C_22_3; + pol ARK_22_0 = B_21_0 + poseidon2_params.C_22_0; + pol ARK_22_1 = B_21_1 + poseidon2_params.C_22_1; + pol ARK_22_2 = B_21_2 + poseidon2_params.C_22_2; + pol ARK_22_3 = B_21_3 + poseidon2_params.C_22_3; // S-BOX (In partial round only first input is exponentiated) pol A_22_0 = ARK_22_0 * ARK_22_0 * ARK_22_0 * ARK_22_0 * ARK_22_0; @@ -499,10 +499,10 @@ namespace poseidon2(256); // Round 24 (Partial Round) // ARK (Add Round Constant) - pol ARK_23_0 = B_23_0 + poseidon2_params.C_23_0; - pol ARK_23_1 = B_23_0 + poseidon2_params.C_23_1; - pol ARK_23_2 = B_23_0 + poseidon2_params.C_23_2; - pol ARK_23_3 = B_23_0 + poseidon2_params.C_23_3; + pol ARK_23_0 = B_22_0 + poseidon2_params.C_23_0; + pol ARK_23_1 = B_22_1 + poseidon2_params.C_23_1; + pol ARK_23_2 = B_22_2 + poseidon2_params.C_23_2; + pol ARK_23_3 = B_22_3 + poseidon2_params.C_23_3; // S-BOX (In partial round only first input is exponentiated) pol A_23_0 = ARK_23_0 * ARK_23_0 * ARK_23_0 * ARK_23_0 * ARK_23_0; @@ -518,10 +518,10 @@ namespace poseidon2(256); // Round 25 (Partial Round) // ARK (Add Round Constant) - pol ARK_24_0 = B_24_0 + poseidon2_params.C_24_0; - pol ARK_24_1 = B_24_0 + poseidon2_params.C_24_1; - pol ARK_24_2 = B_24_0 + poseidon2_params.C_24_2; - pol ARK_24_3 = B_24_0 + poseidon2_params.C_24_3; + pol ARK_24_0 = B_23_0 + poseidon2_params.C_24_0; + pol ARK_24_1 = B_23_1 + poseidon2_params.C_24_1; + pol ARK_24_2 = B_23_2 + poseidon2_params.C_24_2; + pol ARK_24_3 = B_23_3 + poseidon2_params.C_24_3; // S-BOX (In partial round only first input is exponentiated) pol A_24_0 = ARK_24_0 * ARK_24_0 * ARK_24_0 * ARK_24_0 * ARK_24_0; @@ -537,10 +537,10 @@ namespace poseidon2(256); // Round 26 (Partial Round) // ARK (Add Round Constant) - pol ARK_25_0 = B_25_0 + poseidon2_params.C_25_0; - pol ARK_25_1 = B_25_0 + poseidon2_params.C_25_1; - pol ARK_25_2 = B_25_0 + poseidon2_params.C_25_2; - pol ARK_25_3 = B_25_0 + poseidon2_params.C_25_3; + pol ARK_25_0 = B_24_0 + poseidon2_params.C_25_0; + pol ARK_25_1 = B_24_1 + poseidon2_params.C_25_1; + pol ARK_25_2 = B_24_2 + poseidon2_params.C_25_2; + pol ARK_25_3 = B_24_3 + poseidon2_params.C_25_3; // S-BOX (In partial round only first input is exponentiated) pol A_25_0 = ARK_25_0 * ARK_25_0 * ARK_25_0 * ARK_25_0 * ARK_25_0; @@ -556,10 +556,10 @@ namespace poseidon2(256); // Round 27 (Partial Round) // ARK (Add Round Constant) - pol ARK_26_0 = B_26_0 + poseidon2_params.C_26_0; - pol ARK_26_1 = B_26_0 + poseidon2_params.C_26_1; - pol ARK_26_2 = B_26_0 + poseidon2_params.C_26_2; - pol ARK_26_3 = B_26_0 + poseidon2_params.C_26_3; + pol ARK_26_0 = B_25_0 + poseidon2_params.C_26_0; + pol ARK_26_1 = B_25_1 + poseidon2_params.C_26_1; + pol ARK_26_2 = B_25_2 + poseidon2_params.C_26_2; + pol ARK_26_3 = B_25_3 + poseidon2_params.C_26_3; // S-BOX (In partial round only first input is exponentiated) pol A_26_0 = ARK_26_0 * ARK_26_0 * ARK_26_0 * ARK_26_0 * ARK_26_0; @@ -575,10 +575,10 @@ namespace poseidon2(256); // Round 28 (Partial Round) // ARK (Add Round Constant) - pol ARK_27_0 = B_27_0 + poseidon2_params.C_27_0; - pol ARK_27_1 = B_27_0 + poseidon2_params.C_27_1; - pol ARK_27_2 = B_27_0 + poseidon2_params.C_27_2; - pol ARK_27_3 = B_27_0 + poseidon2_params.C_27_3; + pol ARK_27_0 = B_26_0 + poseidon2_params.C_27_0; + pol ARK_27_1 = B_26_1 + poseidon2_params.C_27_1; + pol ARK_27_2 = B_26_2 + poseidon2_params.C_27_2; + pol ARK_27_3 = B_26_3 + poseidon2_params.C_27_3; // S-BOX (In partial round only first input is exponentiated) pol A_27_0 = ARK_27_0 * ARK_27_0 * ARK_27_0 * ARK_27_0 * ARK_27_0; @@ -594,10 +594,10 @@ namespace poseidon2(256); // Round 29 (Partial Round) // ARK (Add Round Constant) - pol ARK_28_0 = B_28_0 + poseidon2_params.C_28_0; - pol ARK_28_1 = B_28_0 + poseidon2_params.C_28_1; - pol ARK_28_2 = B_28_0 + poseidon2_params.C_28_2; - pol ARK_28_3 = B_28_0 + poseidon2_params.C_28_3; + pol ARK_28_0 = B_27_0 + poseidon2_params.C_28_0; + pol ARK_28_1 = B_27_1 + poseidon2_params.C_28_1; + pol ARK_28_2 = B_27_2 + poseidon2_params.C_28_2; + pol ARK_28_3 = B_27_3 + poseidon2_params.C_28_3; // S-BOX (In partial round only first input is exponentiated) pol A_28_0 = ARK_28_0 * ARK_28_0 * ARK_28_0 * ARK_28_0 * ARK_28_0; @@ -613,10 +613,10 @@ namespace poseidon2(256); // Round 30 (Partial Round) // ARK (Add Round Constant) - pol ARK_29_0 = B_29_0 + poseidon2_params.C_29_0; - pol ARK_29_1 = B_29_0 + poseidon2_params.C_29_1; - pol ARK_29_2 = B_29_0 + poseidon2_params.C_29_2; - pol ARK_29_3 = B_29_0 + poseidon2_params.C_29_3; + pol ARK_29_0 = B_28_0 + poseidon2_params.C_29_0; + pol ARK_29_1 = B_28_1 + poseidon2_params.C_29_1; + pol ARK_29_2 = B_28_2 + poseidon2_params.C_29_2; + pol ARK_29_3 = B_28_3 + poseidon2_params.C_29_3; // S-BOX (In partial round only first input is exponentiated) pol A_29_0 = ARK_29_0 * ARK_29_0 * ARK_29_0 * ARK_29_0 * ARK_29_0; @@ -632,10 +632,10 @@ namespace poseidon2(256); // Round 31 (Partial Round) // ARK (Add Round Constant) - pol ARK_30_0 = B_30_0 + poseidon2_params.C_30_0; - pol ARK_30_1 = B_30_0 + poseidon2_params.C_30_1; - pol ARK_30_2 = B_30_0 + poseidon2_params.C_30_2; - pol ARK_30_3 = B_30_0 + poseidon2_params.C_30_3; + pol ARK_30_0 = B_29_0 + poseidon2_params.C_30_0; + pol ARK_30_1 = B_29_1 + poseidon2_params.C_30_1; + pol ARK_30_2 = B_29_2 + poseidon2_params.C_30_2; + pol ARK_30_3 = B_29_3 + poseidon2_params.C_30_3; // S-BOX (In partial round only first input is exponentiated) pol A_30_0 = ARK_30_0 * ARK_30_0 * ARK_30_0 * ARK_30_0 * ARK_30_0; @@ -651,10 +651,10 @@ namespace poseidon2(256); // Round 32 (Partial Round) // ARK (Add Round Constant) - pol ARK_31_0 = B_31_0 + poseidon2_params.C_31_0; - pol ARK_31_1 = B_31_0 + poseidon2_params.C_31_1; - pol ARK_31_2 = B_31_0 + poseidon2_params.C_31_2; - pol ARK_31_3 = B_31_0 + poseidon2_params.C_31_3; + pol ARK_31_0 = B_30_0 + poseidon2_params.C_31_0; + pol ARK_31_1 = B_30_1 + poseidon2_params.C_31_1; + pol ARK_31_2 = B_30_2 + poseidon2_params.C_31_2; + pol ARK_31_3 = B_30_3 + poseidon2_params.C_31_3; // S-BOX (In partial round only first input is exponentiated) pol A_31_0 = ARK_31_0 * ARK_31_0 * ARK_31_0 * ARK_31_0 * ARK_31_0; @@ -670,10 +670,10 @@ namespace poseidon2(256); // Round 33 (Partial Round) // ARK (Add Round Constant) - pol ARK_32_0 = B_32_0 + poseidon2_params.C_32_0; - pol ARK_32_1 = B_32_0 + poseidon2_params.C_32_1; - pol ARK_32_2 = B_32_0 + poseidon2_params.C_32_2; - pol ARK_32_3 = B_32_0 + poseidon2_params.C_32_3; + pol ARK_32_0 = B_31_0 + poseidon2_params.C_32_0; + pol ARK_32_1 = B_31_1 + poseidon2_params.C_32_1; + pol ARK_32_2 = B_31_2 + poseidon2_params.C_32_2; + pol ARK_32_3 = B_31_3 + poseidon2_params.C_32_3; // S-BOX (In partial round only first input is exponentiated) pol A_32_0 = ARK_32_0 * ARK_32_0 * ARK_32_0 * ARK_32_0 * ARK_32_0; @@ -689,10 +689,10 @@ namespace poseidon2(256); // Round 34 (Partial Round) // ARK (Add Round Constant) - pol ARK_33_0 = B_33_0 + poseidon2_params.C_33_0; - pol ARK_33_1 = B_33_0 + poseidon2_params.C_33_1; - pol ARK_33_2 = B_33_0 + poseidon2_params.C_33_2; - pol ARK_33_3 = B_33_0 + poseidon2_params.C_33_3; + pol ARK_33_0 = B_32_0 + poseidon2_params.C_33_0; + pol ARK_33_1 = B_32_1 + poseidon2_params.C_33_1; + pol ARK_33_2 = B_32_2 + poseidon2_params.C_33_2; + pol ARK_33_3 = B_32_3 + poseidon2_params.C_33_3; // S-BOX (In partial round only first input is exponentiated) pol A_33_0 = ARK_33_0 * ARK_33_0 * ARK_33_0 * ARK_33_0 * ARK_33_0; @@ -708,10 +708,10 @@ namespace poseidon2(256); // Round 35 (Partial Round) // ARK (Add Round Constant) - pol ARK_34_0 = B_34_0 + poseidon2_params.C_34_0; - pol ARK_34_1 = B_34_0 + poseidon2_params.C_34_1; - pol ARK_34_2 = B_34_0 + poseidon2_params.C_34_2; - pol ARK_34_3 = B_34_0 + poseidon2_params.C_34_3; + pol ARK_34_0 = B_33_0 + poseidon2_params.C_34_0; + pol ARK_34_1 = B_33_1 + poseidon2_params.C_34_1; + pol ARK_34_2 = B_33_2 + poseidon2_params.C_34_2; + pol ARK_34_3 = B_33_3 + poseidon2_params.C_34_3; // S-BOX (In partial round only first input is exponentiated) pol A_34_0 = ARK_34_0 * ARK_34_0 * ARK_34_0 * ARK_34_0 * ARK_34_0; @@ -727,10 +727,10 @@ namespace poseidon2(256); // Round 36 (Partial Round) // ARK (Add Round Constant) - pol ARK_35_0 = B_35_0 + poseidon2_params.C_35_0; - pol ARK_35_1 = B_35_0 + poseidon2_params.C_35_1; - pol ARK_35_2 = B_35_0 + poseidon2_params.C_35_2; - pol ARK_35_3 = B_35_0 + poseidon2_params.C_35_3; + pol ARK_35_0 = B_34_0 + poseidon2_params.C_35_0; + pol ARK_35_1 = B_34_1 + poseidon2_params.C_35_1; + pol ARK_35_2 = B_34_2 + poseidon2_params.C_35_2; + pol ARK_35_3 = B_34_3 + poseidon2_params.C_35_3; // S-BOX (In partial round only first input is exponentiated) pol A_35_0 = ARK_35_0 * ARK_35_0 * ARK_35_0 * ARK_35_0 * ARK_35_0; @@ -746,10 +746,10 @@ namespace poseidon2(256); // Round 37 (Partial Round) // ARK (Add Round Constant) - pol ARK_36_0 = B_36_0 + poseidon2_params.C_36_0; - pol ARK_36_1 = B_36_0 + poseidon2_params.C_36_1; - pol ARK_36_2 = B_36_0 + poseidon2_params.C_36_2; - pol ARK_36_3 = B_36_0 + poseidon2_params.C_36_3; + pol ARK_36_0 = B_35_0 + poseidon2_params.C_36_0; + pol ARK_36_1 = B_35_1 + poseidon2_params.C_36_1; + pol ARK_36_2 = B_35_2 + poseidon2_params.C_36_2; + pol ARK_36_3 = B_35_3 + poseidon2_params.C_36_3; // S-BOX (In partial round only first input is exponentiated) pol A_36_0 = ARK_36_0 * ARK_36_0 * ARK_36_0 * ARK_36_0 * ARK_36_0; @@ -765,10 +765,10 @@ namespace poseidon2(256); // Round 38 (Partial Round) // ARK (Add Round Constant) - pol ARK_37_0 = B_37_0 + poseidon2_params.C_37_0; - pol ARK_37_1 = B_37_0 + poseidon2_params.C_37_1; - pol ARK_37_2 = B_37_0 + poseidon2_params.C_37_2; - pol ARK_37_3 = B_37_0 + poseidon2_params.C_37_3; + pol ARK_37_0 = B_36_0 + poseidon2_params.C_37_0; + pol ARK_37_1 = B_36_1 + poseidon2_params.C_37_1; + pol ARK_37_2 = B_36_2 + poseidon2_params.C_37_2; + pol ARK_37_3 = B_36_3 + poseidon2_params.C_37_3; // S-BOX (In partial round only first input is exponentiated) pol A_37_0 = ARK_37_0 * ARK_37_0 * ARK_37_0 * ARK_37_0 * ARK_37_0; @@ -784,10 +784,10 @@ namespace poseidon2(256); // Round 39 (Partial Round) // ARK (Add Round Constant) - pol ARK_38_0 = B_38_0 + poseidon2_params.C_38_0; - pol ARK_38_1 = B_38_0 + poseidon2_params.C_38_1; - pol ARK_38_2 = B_38_0 + poseidon2_params.C_38_2; - pol ARK_38_3 = B_38_0 + poseidon2_params.C_38_3; + pol ARK_38_0 = B_37_0 + poseidon2_params.C_38_0; + pol ARK_38_1 = B_37_1 + poseidon2_params.C_38_1; + pol ARK_38_2 = B_37_2 + poseidon2_params.C_38_2; + pol ARK_38_3 = B_37_3 + poseidon2_params.C_38_3; // S-BOX (In partial round only first input is exponentiated) pol A_38_0 = ARK_38_0 * ARK_38_0 * ARK_38_0 * ARK_38_0 * ARK_38_0; @@ -803,10 +803,10 @@ namespace poseidon2(256); // Round 40 (Partial Round) // ARK (Add Round Constant) - pol ARK_39_0 = B_39_0 + poseidon2_params.C_39_0; - pol ARK_39_1 = B_39_0 + poseidon2_params.C_39_1; - pol ARK_39_2 = B_39_0 + poseidon2_params.C_39_2; - pol ARK_39_3 = B_39_0 + poseidon2_params.C_39_3; + pol ARK_39_0 = B_38_0 + poseidon2_params.C_39_0; + pol ARK_39_1 = B_38_1 + poseidon2_params.C_39_1; + pol ARK_39_2 = B_38_2 + poseidon2_params.C_39_2; + pol ARK_39_3 = B_38_3 + poseidon2_params.C_39_3; // S-BOX (In partial round only first input is exponentiated) pol A_39_0 = ARK_39_0 * ARK_39_0 * ARK_39_0 * ARK_39_0 * ARK_39_0; @@ -822,10 +822,10 @@ namespace poseidon2(256); // Round 41 (Partial Round) // ARK (Add Round Constant) - pol ARK_40_0 = B_40_0 + poseidon2_params.C_40_0; - pol ARK_40_1 = B_40_0 + poseidon2_params.C_40_1; - pol ARK_40_2 = B_40_0 + poseidon2_params.C_40_2; - pol ARK_40_3 = B_40_0 + poseidon2_params.C_40_3; + pol ARK_40_0 = B_39_0 + poseidon2_params.C_40_0; + pol ARK_40_1 = B_39_1 + poseidon2_params.C_40_1; + pol ARK_40_2 = B_39_2 + poseidon2_params.C_40_2; + pol ARK_40_3 = B_39_3 + poseidon2_params.C_40_3; // S-BOX (In partial round only first input is exponentiated) pol A_40_0 = ARK_40_0 * ARK_40_0 * ARK_40_0 * ARK_40_0 * ARK_40_0; @@ -841,10 +841,10 @@ namespace poseidon2(256); // Round 42 (Partial Round) // ARK (Add Round Constant) - pol ARK_41_0 = B_41_0 + poseidon2_params.C_41_0; - pol ARK_41_1 = B_41_0 + poseidon2_params.C_41_1; - pol ARK_41_2 = B_41_0 + poseidon2_params.C_41_2; - pol ARK_41_3 = B_41_0 + poseidon2_params.C_41_3; + pol ARK_41_0 = B_40_0 + poseidon2_params.C_41_0; + pol ARK_41_1 = B_40_1 + poseidon2_params.C_41_1; + pol ARK_41_2 = B_40_2 + poseidon2_params.C_41_2; + pol ARK_41_3 = B_40_3 + poseidon2_params.C_41_3; // S-BOX (In partial round only first input is exponentiated) pol A_41_0 = ARK_41_0 * ARK_41_0 * ARK_41_0 * ARK_41_0 * ARK_41_0; @@ -860,10 +860,10 @@ namespace poseidon2(256); // Round 43 (Partial Round) // ARK (Add Round Constant) - pol ARK_42_0 = B_42_0 + poseidon2_params.C_42_0; - pol ARK_42_1 = B_42_0 + poseidon2_params.C_42_1; - pol ARK_42_2 = B_42_0 + poseidon2_params.C_42_2; - pol ARK_42_3 = B_42_0 + poseidon2_params.C_42_3; + pol ARK_42_0 = B_41_0 + poseidon2_params.C_42_0; + pol ARK_42_1 = B_41_1 + poseidon2_params.C_42_1; + pol ARK_42_2 = B_41_2 + poseidon2_params.C_42_2; + pol ARK_42_3 = B_41_3 + poseidon2_params.C_42_3; // S-BOX (In partial round only first input is exponentiated) pol A_42_0 = ARK_42_0 * ARK_42_0 * ARK_42_0 * ARK_42_0 * ARK_42_0; @@ -879,10 +879,10 @@ namespace poseidon2(256); // Round 44 (Partial Round) // ARK (Add Round Constant) - pol ARK_43_0 = B_43_0 + poseidon2_params.C_43_0; - pol ARK_43_1 = B_43_0 + poseidon2_params.C_43_1; - pol ARK_43_2 = B_43_0 + poseidon2_params.C_43_2; - pol ARK_43_3 = B_43_0 + poseidon2_params.C_43_3; + pol ARK_43_0 = B_42_0 + poseidon2_params.C_43_0; + pol ARK_43_1 = B_42_1 + poseidon2_params.C_43_1; + pol ARK_43_2 = B_42_2 + poseidon2_params.C_43_2; + pol ARK_43_3 = B_42_3 + poseidon2_params.C_43_3; // S-BOX (In partial round only first input is exponentiated) pol A_43_0 = ARK_43_0 * ARK_43_0 * ARK_43_0 * ARK_43_0 * ARK_43_0; @@ -898,10 +898,10 @@ namespace poseidon2(256); // Round 45 (Partial Round) // ARK (Add Round Constant) - pol ARK_44_0 = B_44_0 + poseidon2_params.C_44_0; - pol ARK_44_1 = B_44_0 + poseidon2_params.C_44_1; - pol ARK_44_2 = B_44_0 + poseidon2_params.C_44_2; - pol ARK_44_3 = B_44_0 + poseidon2_params.C_44_3; + pol ARK_44_0 = B_43_0 + poseidon2_params.C_44_0; + pol ARK_44_1 = B_43_1 + poseidon2_params.C_44_1; + pol ARK_44_2 = B_43_2 + poseidon2_params.C_44_2; + pol ARK_44_3 = B_43_3 + poseidon2_params.C_44_3; // S-BOX (In partial round only first input is exponentiated) pol A_44_0 = ARK_44_0 * ARK_44_0 * ARK_44_0 * ARK_44_0 * ARK_44_0; @@ -917,10 +917,10 @@ namespace poseidon2(256); // Round 46 (Partial Round) // ARK (Add Round Constant) - pol ARK_45_0 = B_45_0 + poseidon2_params.C_45_0; - pol ARK_45_1 = B_45_0 + poseidon2_params.C_45_1; - pol ARK_45_2 = B_45_0 + poseidon2_params.C_45_2; - pol ARK_45_3 = B_45_0 + poseidon2_params.C_45_3; + pol ARK_45_0 = B_44_0 + poseidon2_params.C_45_0; + pol ARK_45_1 = B_44_1 + poseidon2_params.C_45_1; + pol ARK_45_2 = B_44_2 + poseidon2_params.C_45_2; + pol ARK_45_3 = B_44_3 + poseidon2_params.C_45_3; // S-BOX (In partial round only first input is exponentiated) pol A_45_0 = ARK_45_0 * ARK_45_0 * ARK_45_0 * ARK_45_0 * ARK_45_0; @@ -936,10 +936,10 @@ namespace poseidon2(256); // Round 47 (Partial Round) // ARK (Add Round Constant) - pol ARK_46_0 = B_46_0 + poseidon2_params.C_46_0; - pol ARK_46_1 = B_46_0 + poseidon2_params.C_46_1; - pol ARK_46_2 = B_46_0 + poseidon2_params.C_46_2; - pol ARK_46_3 = B_46_0 + poseidon2_params.C_46_3; + pol ARK_46_0 = B_45_0 + poseidon2_params.C_46_0; + pol ARK_46_1 = B_45_1 + poseidon2_params.C_46_1; + pol ARK_46_2 = B_45_2 + poseidon2_params.C_46_2; + pol ARK_46_3 = B_45_3 + poseidon2_params.C_46_3; // S-BOX (In partial round only first input is exponentiated) pol A_46_0 = ARK_46_0 * ARK_46_0 * ARK_46_0 * ARK_46_0 * ARK_46_0; @@ -955,10 +955,10 @@ namespace poseidon2(256); // Round 48 (Partial Round) // ARK (Add Round Constant) - pol ARK_47_0 = B_47_0 + poseidon2_params.C_47_0; - pol ARK_47_1 = B_47_0 + poseidon2_params.C_47_1; - pol ARK_47_2 = B_47_0 + poseidon2_params.C_47_2; - pol ARK_47_3 = B_47_0 + poseidon2_params.C_47_3; + pol ARK_47_0 = B_46_0 + poseidon2_params.C_47_0; + pol ARK_47_1 = B_46_1 + poseidon2_params.C_47_1; + pol ARK_47_2 = B_46_2 + poseidon2_params.C_47_2; + pol ARK_47_3 = B_46_3 + poseidon2_params.C_47_3; // S-BOX (In partial round only first input is exponentiated) pol A_47_0 = ARK_47_0 * ARK_47_0 * ARK_47_0 * ARK_47_0 * ARK_47_0; @@ -974,10 +974,10 @@ namespace poseidon2(256); // Round 49 (Partial Round) // ARK (Add Round Constant) - pol ARK_48_0 = B_48_0 + poseidon2_params.C_48_0; - pol ARK_48_1 = B_48_0 + poseidon2_params.C_48_1; - pol ARK_48_2 = B_48_0 + poseidon2_params.C_48_2; - pol ARK_48_3 = B_48_0 + poseidon2_params.C_48_3; + pol ARK_48_0 = B_47_0 + poseidon2_params.C_48_0; + pol ARK_48_1 = B_47_1 + poseidon2_params.C_48_1; + pol ARK_48_2 = B_47_2 + poseidon2_params.C_48_2; + pol ARK_48_3 = B_47_3 + poseidon2_params.C_48_3; // S-BOX (In partial round only first input is exponentiated) pol A_48_0 = ARK_48_0 * ARK_48_0 * ARK_48_0 * ARK_48_0 * ARK_48_0; @@ -993,10 +993,10 @@ namespace poseidon2(256); // Round 50 (Partial Round) // ARK (Add Round Constant) - pol ARK_49_0 = B_49_0 + poseidon2_params.C_49_0; - pol ARK_49_1 = B_49_0 + poseidon2_params.C_49_1; - pol ARK_49_2 = B_49_0 + poseidon2_params.C_49_2; - pol ARK_49_3 = B_49_0 + poseidon2_params.C_49_3; + pol ARK_49_0 = B_48_0 + poseidon2_params.C_49_0; + pol ARK_49_1 = B_48_1 + poseidon2_params.C_49_1; + pol ARK_49_2 = B_48_2 + poseidon2_params.C_49_2; + pol ARK_49_3 = B_48_3 + poseidon2_params.C_49_3; // S-BOX (In partial round only first input is exponentiated) pol A_49_0 = ARK_49_0 * ARK_49_0 * ARK_49_0 * ARK_49_0 * ARK_49_0; @@ -1012,10 +1012,10 @@ namespace poseidon2(256); // Round 51 (Partial Round) // ARK (Add Round Constant) - pol ARK_50_0 = B_50_0 + poseidon2_params.C_50_0; - pol ARK_50_1 = B_50_0 + poseidon2_params.C_50_1; - pol ARK_50_2 = B_50_0 + poseidon2_params.C_50_2; - pol ARK_50_3 = B_50_0 + poseidon2_params.C_50_3; + pol ARK_50_0 = B_49_0 + poseidon2_params.C_50_0; + pol ARK_50_1 = B_49_1 + poseidon2_params.C_50_1; + pol ARK_50_2 = B_49_2 + poseidon2_params.C_50_2; + pol ARK_50_3 = B_49_3 + poseidon2_params.C_50_3; // S-BOX (In partial round only first input is exponentiated) pol A_50_0 = ARK_50_0 * ARK_50_0 * ARK_50_0 * ARK_50_0 * ARK_50_0; @@ -1031,10 +1031,10 @@ namespace poseidon2(256); // Round 52 (Partial Round) // ARK (Add Round Constant) - pol ARK_51_0 = B_51_0 + poseidon2_params.C_51_0; - pol ARK_51_1 = B_51_0 + poseidon2_params.C_51_1; - pol ARK_51_2 = B_51_0 + poseidon2_params.C_51_2; - pol ARK_51_3 = B_51_0 + poseidon2_params.C_51_3; + pol ARK_51_0 = B_50_0 + poseidon2_params.C_51_0; + pol ARK_51_1 = B_50_1 + poseidon2_params.C_51_1; + pol ARK_51_2 = B_50_2 + poseidon2_params.C_51_2; + pol ARK_51_3 = B_50_3 + poseidon2_params.C_51_3; // S-BOX (In partial round only first input is exponentiated) pol A_51_0 = ARK_51_0 * ARK_51_0 * ARK_51_0 * ARK_51_0 * ARK_51_0; @@ -1050,10 +1050,10 @@ namespace poseidon2(256); // Round 53 (Partial Round) // ARK (Add Round Constant) - pol ARK_52_0 = B_52_0 + poseidon2_params.C_52_0; - pol ARK_52_1 = B_52_0 + poseidon2_params.C_52_1; - pol ARK_52_2 = B_52_0 + poseidon2_params.C_52_2; - pol ARK_52_3 = B_52_0 + poseidon2_params.C_52_3; + pol ARK_52_0 = B_51_0 + poseidon2_params.C_52_0; + pol ARK_52_1 = B_51_1 + poseidon2_params.C_52_1; + pol ARK_52_2 = B_51_2 + poseidon2_params.C_52_2; + pol ARK_52_3 = B_51_3 + poseidon2_params.C_52_3; // S-BOX (In partial round only first input is exponentiated) pol A_52_0 = ARK_52_0 * ARK_52_0 * ARK_52_0 * ARK_52_0 * ARK_52_0; @@ -1069,10 +1069,10 @@ namespace poseidon2(256); // Round 54 (Partial Round) // ARK (Add Round Constant) - pol ARK_53_0 = B_53_0 + poseidon2_params.C_53_0; - pol ARK_53_1 = B_53_0 + poseidon2_params.C_53_1; - pol ARK_53_2 = B_53_0 + poseidon2_params.C_53_2; - pol ARK_53_3 = B_53_0 + poseidon2_params.C_53_3; + pol ARK_53_0 = B_52_0 + poseidon2_params.C_53_0; + pol ARK_53_1 = B_52_1 + poseidon2_params.C_53_1; + pol ARK_53_2 = B_52_2 + poseidon2_params.C_53_2; + pol ARK_53_3 = B_52_3 + poseidon2_params.C_53_3; // S-BOX (In partial round only first input is exponentiated) pol A_53_0 = ARK_53_0 * ARK_53_0 * ARK_53_0 * ARK_53_0 * ARK_53_0; @@ -1088,10 +1088,10 @@ namespace poseidon2(256); // Round 55 (Partial Round) // ARK (Add Round Constant) - pol ARK_54_0 = B_54_0 + poseidon2_params.C_54_0; - pol ARK_54_1 = B_54_0 + poseidon2_params.C_54_1; - pol ARK_54_2 = B_54_0 + poseidon2_params.C_54_2; - pol ARK_54_3 = B_54_0 + poseidon2_params.C_54_3; + pol ARK_54_0 = B_53_0 + poseidon2_params.C_54_0; + pol ARK_54_1 = B_53_1 + poseidon2_params.C_54_1; + pol ARK_54_2 = B_53_2 + poseidon2_params.C_54_2; + pol ARK_54_3 = B_53_3 + poseidon2_params.C_54_3; // S-BOX (In partial round only first input is exponentiated) pol A_54_0 = ARK_54_0 * ARK_54_0 * ARK_54_0 * ARK_54_0 * ARK_54_0; @@ -1107,10 +1107,10 @@ namespace poseidon2(256); // Round 56 (Partial Round) // ARK (Add Round Constant) - pol ARK_55_0 = B_55_0 + poseidon2_params.C_55_0; - pol ARK_55_1 = B_55_0 + poseidon2_params.C_55_1; - pol ARK_55_2 = B_55_0 + poseidon2_params.C_55_2; - pol ARK_55_3 = B_55_0 + poseidon2_params.C_55_3; + pol ARK_55_0 = B_54_0 + poseidon2_params.C_55_0; + pol ARK_55_1 = B_54_1 + poseidon2_params.C_55_1; + pol ARK_55_2 = B_54_2 + poseidon2_params.C_55_2; + pol ARK_55_3 = B_54_3 + poseidon2_params.C_55_3; // S-BOX (In partial round only first input is exponentiated) pol A_55_0 = ARK_55_0 * ARK_55_0 * ARK_55_0 * ARK_55_0 * ARK_55_0; @@ -1126,10 +1126,10 @@ namespace poseidon2(256); // Round 57 (Partial Round) // ARK (Add Round Constant) - pol ARK_56_0 = B_56_0 + poseidon2_params.C_56_0; - pol ARK_56_1 = B_56_0 + poseidon2_params.C_56_1; - pol ARK_56_2 = B_56_0 + poseidon2_params.C_56_2; - pol ARK_56_3 = B_56_0 + poseidon2_params.C_56_3; + pol ARK_56_0 = B_55_0 + poseidon2_params.C_56_0; + pol ARK_56_1 = B_55_1 + poseidon2_params.C_56_1; + pol ARK_56_2 = B_55_2 + poseidon2_params.C_56_2; + pol ARK_56_3 = B_55_3 + poseidon2_params.C_56_3; // S-BOX (In partial round only first input is exponentiated) pol A_56_0 = ARK_56_0 * ARK_56_0 * ARK_56_0 * ARK_56_0 * ARK_56_0; @@ -1145,10 +1145,10 @@ namespace poseidon2(256); // Round 58 (Partial Round) // ARK (Add Round Constant) - pol ARK_57_0 = B_57_0 + poseidon2_params.C_57_0; - pol ARK_57_1 = B_57_0 + poseidon2_params.C_57_1; - pol ARK_57_2 = B_57_0 + poseidon2_params.C_57_2; - pol ARK_57_3 = B_57_0 + poseidon2_params.C_57_3; + pol ARK_57_0 = B_56_0 + poseidon2_params.C_57_0; + pol ARK_57_1 = B_56_1 + poseidon2_params.C_57_1; + pol ARK_57_2 = B_56_2 + poseidon2_params.C_57_2; + pol ARK_57_3 = B_56_3 + poseidon2_params.C_57_3; // S-BOX (In partial round only first input is exponentiated) pol A_57_0 = ARK_57_0 * ARK_57_0 * ARK_57_0 * ARK_57_0 * ARK_57_0; @@ -1164,10 +1164,10 @@ namespace poseidon2(256); // Round 59 (Partial Round) // ARK (Add Round Constant) - pol ARK_58_0 = B_58_0 + poseidon2_params.C_58_0; - pol ARK_58_1 = B_58_0 + poseidon2_params.C_58_1; - pol ARK_58_2 = B_58_0 + poseidon2_params.C_58_2; - pol ARK_58_3 = B_58_0 + poseidon2_params.C_58_3; + pol ARK_58_0 = B_57_0 + poseidon2_params.C_58_0; + pol ARK_58_1 = B_57_1 + poseidon2_params.C_58_1; + pol ARK_58_2 = B_57_2 + poseidon2_params.C_58_2; + pol ARK_58_3 = B_57_3 + poseidon2_params.C_58_3; // S-BOX (In partial round only first input is exponentiated) pol A_58_0 = ARK_58_0 * ARK_58_0 * ARK_58_0 * ARK_58_0 * ARK_58_0; @@ -1183,10 +1183,10 @@ namespace poseidon2(256); // Round 60 (Partial Round) // ARK (Add Round Constant) - pol ARK_59_0 = B_59_0 + poseidon2_params.C_59_0; - pol ARK_59_1 = B_59_0 + poseidon2_params.C_59_1; - pol ARK_59_2 = B_59_0 + poseidon2_params.C_59_2; - pol ARK_59_3 = B_59_0 + poseidon2_params.C_59_3; + pol ARK_59_0 = B_58_0 + poseidon2_params.C_59_0; + pol ARK_59_1 = B_58_1 + poseidon2_params.C_59_1; + pol ARK_59_2 = B_58_2 + poseidon2_params.C_59_2; + pol ARK_59_3 = B_58_3 + poseidon2_params.C_59_3; // S-BOX (In partial round only first input is exponentiated) pol A_59_0 = ARK_59_0 * ARK_59_0 * ARK_59_0 * ARK_59_0 * ARK_59_0; @@ -1299,7 +1299,7 @@ namespace poseidon2(256); // PERMUTATION END ///////////////////////////////////////////////////// // Check output against claimed output - // b_0 - T_63_6 = 0; + b_0 - T_63_6 = 0; // b_1 - T_63_5 = 0; // b_2 - T_63_7 = 0; - // b_2 - T_63_4 = 0; + // b_3 - T_63_4 = 0; From 99048974e3112798da17c8a010cf47548df9e8f6 Mon Sep 17 00:00:00 2001 From: IlyasRidhuan Date: Thu, 27 Jun 2024 16:47:24 +0000 Subject: [PATCH 3/4] feat: try intermediate committed cols --- barretenberg/cpp/CMakeLists.txt | 2 +- .../cpp/pil/avm/gadgets/poseidon2.pil | 1060 +- barretenberg/cpp/pil/avm/main.pil | 6 +- barretenberg/cpp/pil/avm/mem.pil | 24 +- .../poseidon2/poseidon2_permutation.hpp | 2 +- .../relations/generated/avm/declare_views.hpp | 286 +- .../generated/avm/perm_pos_mem_a.hpp | 72 + .../generated/avm/perm_pos_mem_b.hpp | 72 + .../generated/avm/perm_pos_mem_c.hpp | 72 + .../generated/avm/perm_pos_mem_d.hpp | 72 + .../vm/avm/generated/full_row.cpp | 1202 +- .../vm/avm/generated/full_row.hpp | 290 +- .../barretenberg/vm/avm/generated/prover.cpp | 775 - .../vm/avm/generated/relations/mem.hpp | 48 +- .../relations/perm_main_pos2_perm.hpp | 16 +- .../vm/avm/generated/relations/poseidon2.hpp | 11969 +++++++++++++++- .../vm/avm/tests/execution.test.cpp | 43 +- .../vm/avm/trace/gadgets/poseidon2.cpp | 52 +- .../vm/avm/trace/gadgets/poseidon2.hpp | 597 +- .../barretenberg/vm/avm/trace/mem_trace.cpp | 42 +- .../barretenberg/vm/avm/trace/mem_trace.hpp | 23 +- .../src/barretenberg/vm/avm/trace/trace.cpp | 177 +- .../src/barretenberg/vm/avm/trace/trace.hpp | 9 +- .../vm/generated/avm_circuit_builder.hpp | 705 +- .../barretenberg/vm/generated/avm_flavor.hpp | 4640 ++---- .../vm/generated/avm_verifier.cpp | 546 +- 26 files changed, 16445 insertions(+), 6357 deletions(-) create mode 100644 barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_a.hpp create mode 100644 barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_b.hpp create mode 100644 barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_c.hpp create mode 100644 barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_d.hpp diff --git a/barretenberg/cpp/CMakeLists.txt b/barretenberg/cpp/CMakeLists.txt index aeb9cc0928a4..a595b225dff5 100644 --- a/barretenberg/cpp/CMakeLists.txt +++ b/barretenberg/cpp/CMakeLists.txt @@ -95,7 +95,7 @@ set(CMAKE_CXX_STANDARD_REQUIRED TRUE) set(CMAKE_CXX_EXTENSIONS ON) if(CMAKE_CXX_COMPILER_ID MATCHES "Clang") - add_compile_options(-fbracket-depth=512) + add_compile_options(-fbracket-depth=1024) if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS "14") message(WARNING "Clang <14 is not supported") endif() diff --git a/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil b/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil index ca2c5d2f8cf6..96052ff38211 100644 --- a/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil +++ b/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil @@ -8,16 +8,73 @@ namespace poseidon2(256); pol commit sel_poseidon_perm; // Selector is boolean sel_poseidon_perm * (1 - sel_poseidon_perm) = 0; + // If poseidon_sel is set, it cannot be set on the next row + sel_poseidon_perm * sel_poseidon_perm' = 0; + + // Each poseidon2 invocation involves two rows, + // (1) A read line where 4 input values are loaded from memory + // (2) A write line where 4 output values are written to memory + pol commit read_line; + pol commit write_line; + // Line selectors are boolean values + read_line * (1 - read_line) = 0; + write_line * (1 - write_line) = 0; + // If poseidon_perm is selected, the current line is a read line and the next one is a write line + sel_poseidon_perm - read_line = 0; + sel_poseidon_perm - write_line' = 0; + + // Trivially on for all lines + pol commit mem_op; + mem_op = read_line + write_line; + // Read + Write must be mutual exclusive (todo: This should be enforceable by instruction decomposition) + mem_op * (1 - mem_op) = 0; + + // Constrain read and write tag to be FF + pol commit in_tag; + mem_op * (in_tag - 6) = 0; + + // The initial mem address for inputs or output + pol commit input_addr; + pol commit output_addr; + + // Address that is loaded by the gadget memory operations + pol commit mem_addr_a; + pol commit mem_addr_b; + pol commit mem_addr_c; + pol commit mem_addr_d; + // Accessed read / write addresses are contiguous blocks + mem_op * (mem_addr_a - (read_line * input_addr + write_line * output_addr)) = 0; + mem_op * (mem_addr_b - (read_line * input_addr + write_line * output_addr + 1)) = 0; + mem_op * (mem_addr_c - (read_line * input_addr + write_line * output_addr + 2)) = 0; + mem_op * (mem_addr_d - (read_line * input_addr + write_line * output_addr + 3)) = 0; - pol commit input; - pol commit output; - // These will all be arrays, but we just store the first element for permutation to the main trace for now // The input values are represented by a_0, a_1, a_2, a_3 pol commit a_0; pol commit a_1; pol commit a_2; pol commit a_3; + + #[PERM_POS_MEM_A] + mem_op {clk, main.space_id, mem_addr_a, a_0, write_line, in_tag, in_tag} + is + mem.sel_op_gadget_a {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw, mem.r_in_tag, mem.w_in_tag}; + + #[PERM_POS_MEM_B] + mem_op {clk, main.space_id, mem_addr_b, a_1, write_line, in_tag, in_tag} + is + mem.sel_op_gadget_b {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw, mem.r_in_tag, mem.w_in_tag}; + + #[PERM_POS_MEM_C] + mem_op {clk, main.space_id, mem_addr_c, a_2, write_line, in_tag, in_tag} + is + mem.sel_op_gadget_c {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw, mem.r_in_tag, mem.w_in_tag}; + + #[PERM_POS_MEM_D] + mem_op {clk, main.space_id, mem_addr_d, a_3, write_line, in_tag, in_tag} + is + mem.sel_op_gadget_d {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw, mem.r_in_tag, mem.w_in_tag}; + // Output values represented by b_0, b_1, b_2, b_3 pol commit b_0; pol commit b_1; @@ -33,19 +90,36 @@ namespace poseidon2(256); // T_5 = 4 * T_0 + T_2; // T_6 = T_3 + T_5; // T_7 = T_2 + T_4; - - // We additionally include the round identifier + // We additionally include the round identifier in the naming + // __ + // e.g. ARK_0_2 -> Add Round Constant, round 0, input 2 + + + // FIRST EXTERNAL MATRIX LAYER + pol commit EXT_LAYER_4; + pol commit EXT_LAYER_5; + pol commit EXT_LAYER_6; + pol commit EXT_LAYER_7; + pol EXT_LAYER_0 = a_0 + a_1; + pol EXT_LAYER_1 = a_2 + a_3; + pol EXT_LAYER_2 = 2 * a_1 + EXT_LAYER_1; + pol EXT_LAYER_3 = 2 * a_3 + EXT_LAYER_0; + sel_poseidon_perm * (EXT_LAYER_4 - (4 * EXT_LAYER_1 + EXT_LAYER_3)) = 0; + sel_poseidon_perm * (EXT_LAYER_5 - (4 * EXT_LAYER_0 + EXT_LAYER_2)) = 0; + sel_poseidon_perm * (EXT_LAYER_6 - (EXT_LAYER_3 + EXT_LAYER_5)) = 0; + sel_poseidon_perm * (EXT_LAYER_7 - (EXT_LAYER_2 + EXT_LAYER_4)) = 0; + ///////////////////////////////////////////////////// // START FULL ROUND (4 ROUNDS) ///////////////////////////////////////////////////// // Round 1 (Full Round) // ARK (Add Round Constant) - pol ARK_0_0 = a_0 + poseidon2_params.C_0_0; - pol ARK_0_1 = a_1 + poseidon2_params.C_0_1; - pol ARK_0_2 = a_2 + poseidon2_params.C_0_2; - pol ARK_0_3 = a_3 + poseidon2_params.C_0_3; + pol ARK_0_0 = EXT_LAYER_6 + poseidon2_params.C_0_0; + pol ARK_0_1 = EXT_LAYER_5 + poseidon2_params.C_0_1; + pol ARK_0_2 = EXT_LAYER_7 + poseidon2_params.C_0_2; + pol ARK_0_3 = EXT_LAYER_4 + poseidon2_params.C_0_3; // S-BOX (In full round all inputs are exponentiated) pol A_0_0 = ARK_0_0 * ARK_0_0 * ARK_0_0 * ARK_0_0 * ARK_0_0; @@ -54,14 +128,19 @@ namespace poseidon2(256); pol A_0_3 = ARK_0_3 * ARK_0_3 * ARK_0_3 * ARK_0_3 * ARK_0_3; // MATRIX (Full round uses the external matrix) + pol commit T_0_4; + pol commit T_0_5; + pol commit T_0_6; + pol commit T_0_7; + pol T_0_0 = A_0_0 + A_0_1; pol T_0_1 = A_0_2 + A_0_3; - pol T_0_2 = 2 * A_0_1 + T_0_0; + pol T_0_2 = 2 * A_0_1 + T_0_1; pol T_0_3 = 2 * A_0_3 + T_0_0; - pol T_0_4 = 4 * T_0_1 + T_0_3; - pol T_0_5 = 4 * T_0_0 + T_0_2; - pol T_0_6 = T_0_3 + T_0_5; - pol T_0_7 = T_0_2 + T_0_4; + sel_poseidon_perm * (T_0_4 - (4 * T_0_1 + T_0_3)) = 0; + sel_poseidon_perm * (T_0_5 - (4 * T_0_0 + T_0_2)) = 0; + sel_poseidon_perm * (T_0_6 - (T_0_3 + T_0_5)) = 0; + sel_poseidon_perm * (T_0_7 - (T_0_2 + T_0_4)) = 0; // Round 2 (Full Round) // ARK (Add Round Constant) @@ -77,14 +156,19 @@ namespace poseidon2(256); pol A_1_3 = ARK_1_3 * ARK_1_3 * ARK_1_3 * ARK_1_3 * ARK_1_3; // MATRIX (Full round uses the external matrix) + pol commit T_1_4; + pol commit T_1_5; + pol commit T_1_6; + pol commit T_1_7; + pol T_1_0 = A_1_0 + A_1_1; pol T_1_1 = A_1_2 + A_1_3; - pol T_1_2 = 2 * A_1_1 + T_1_0; + pol T_1_2 = 2 * A_1_1 + T_1_1; pol T_1_3 = 2 * A_1_3 + T_1_0; - pol T_1_4 = 4 * T_1_1 + T_1_3; - pol T_1_5 = 4 * T_1_0 + T_1_2; - pol T_1_6 = T_1_3 + T_1_5; - pol T_1_7 = T_1_2 + T_1_4; + sel_poseidon_perm * (T_1_4 - (4 * T_1_1 + T_1_3)) = 0; + sel_poseidon_perm * (T_1_5 - (4 * T_1_0 + T_1_2)) = 0; + sel_poseidon_perm * (T_1_6 - (T_1_3 + T_1_5)) = 0; + sel_poseidon_perm * (T_1_7 - (T_1_2 + T_1_4)) = 0; // Round 3 (Full Round) // ARK (Add Round Constant) @@ -100,14 +184,19 @@ namespace poseidon2(256); pol A_2_3 = ARK_2_3 * ARK_2_3 * ARK_2_3 * ARK_2_3 * ARK_2_3; // MATRIX (Full round uses the external matrix) + pol commit T_2_4; + pol commit T_2_5; + pol commit T_2_6; + pol commit T_2_7; + pol T_2_0 = A_2_0 + A_2_1; pol T_2_1 = A_2_2 + A_2_3; - pol T_2_2 = 2 * A_2_1 + T_2_0; + pol T_2_2 = 2 * A_2_1 + T_2_1; pol T_2_3 = 2 * A_2_3 + T_2_0; - pol T_2_4 = 4 * T_2_1 + T_2_3; - pol T_2_5 = 4 * T_2_0 + T_2_2; - pol T_2_6 = T_2_3 + T_2_5; - pol T_2_7 = T_2_2 + T_2_4; + sel_poseidon_perm * (T_2_4 - (4 * T_2_1 + T_2_3)) = 0; + sel_poseidon_perm * (T_2_5 - (4 * T_2_0 + T_2_2)) = 0; + sel_poseidon_perm * (T_2_6 - (T_2_3 + T_2_5)) = 0; + sel_poseidon_perm * (T_2_7 - (T_2_2 + T_2_4)) = 0; // Round 4 (Full Round) // ARK (Add Round Constant) @@ -123,14 +212,19 @@ namespace poseidon2(256); pol A_3_3 = ARK_3_3 * ARK_3_3 * ARK_3_3 * ARK_3_3 * ARK_3_3; // MATRIX (Full round uses the external matrix) + pol commit T_3_4; + pol commit T_3_5; + pol commit T_3_6; + pol commit T_3_7; + pol T_3_0 = A_3_0 + A_3_1; pol T_3_1 = A_3_2 + A_3_3; - pol T_3_2 = 2 * A_3_1 + T_3_0; + pol T_3_2 = 2 * A_3_1 + T_3_1; pol T_3_3 = 2 * A_3_3 + T_3_0; - pol T_3_4 = 4 * T_3_1 + T_3_3; - pol T_3_5 = 4 * T_3_0 + T_3_2; - pol T_3_6 = T_3_3 + T_3_5; - pol T_3_7 = T_3_2 + T_3_4; + sel_poseidon_perm * (T_3_4 - (4 * T_3_1 + T_3_3)) = 0; + sel_poseidon_perm * (T_3_5 - (4 * T_3_0 + T_3_2)) = 0; + sel_poseidon_perm * (T_3_6 - (T_3_3 + T_3_5)) = 0; + sel_poseidon_perm * (T_3_7 - (T_3_2 + T_3_4)) = 0; ///////////////////////////////////////////////////// // PARTIAL ROUNDS (56 ROUNDS) @@ -150,10 +244,17 @@ namespace poseidon2(256); pol A_4_3 = ARK_4_3; // MATRIX (Partial round uses the external matrix) - pol B_4_0 = poseidon2_params.MU_0 * A_4_0 + A_4_1 + A_4_2 + A_4_3; - pol B_4_1 = poseidon2_params.MU_1 * A_4_1 + A_4_0 + A_4_2 + A_4_3; - pol B_4_2 = poseidon2_params.MU_2 * A_4_2 + A_4_0 + A_4_1 + A_4_3; - pol B_4_3 = poseidon2_params.MU_3 * A_4_3 + A_4_0 + A_4_1 + A_4_2; + pol commit B_4_0; + pol commit B_4_1; + pol commit B_4_2; + pol commit B_4_3; + + pol SUM_4 = A_4_0 + A_4_1 + A_4_2 + A_4_3; + + sel_poseidon_perm * (B_4_0 - (poseidon2_params.MU_0 * A_4_0 + SUM_4)) = 0; + sel_poseidon_perm * (B_4_1 - (poseidon2_params.MU_1 * A_4_1 + SUM_4)) = 0; + sel_poseidon_perm * (B_4_2 - (poseidon2_params.MU_2 * A_4_2 + SUM_4)) = 0; + sel_poseidon_perm * (B_4_3 - (poseidon2_params.MU_3 * A_4_3 + SUM_4)) = 0; // Round 6 (Partial Round) // ARK (Add Round Constant) @@ -169,10 +270,17 @@ namespace poseidon2(256); pol A_5_3 = ARK_5_3; // MATRIX (Partial round uses the external matrix) - pol B_5_0 = poseidon2_params.MU_0 * A_5_0 + A_5_1 + A_5_2 + A_5_3; - pol B_5_1 = poseidon2_params.MU_1 * A_5_1 + A_5_0 + A_5_2 + A_5_3; - pol B_5_2 = poseidon2_params.MU_2 * A_5_2 + A_5_0 + A_5_1 + A_5_3; - pol B_5_3 = poseidon2_params.MU_3 * A_5_3 + A_5_0 + A_5_1 + A_5_2; + pol commit B_5_0; + pol commit B_5_1; + pol commit B_5_2; + pol commit B_5_3; + + pol SUM_5 = A_5_0 + A_5_1 + A_5_2 + A_5_3; + + sel_poseidon_perm * (B_5_0 - (poseidon2_params.MU_0 * A_5_0 + SUM_5)) = 0; + sel_poseidon_perm * (B_5_1 - (poseidon2_params.MU_1 * A_5_1 + SUM_5)) = 0; + sel_poseidon_perm * (B_5_2 - (poseidon2_params.MU_2 * A_5_2 + SUM_5)) = 0; + sel_poseidon_perm * (B_5_3 - (poseidon2_params.MU_3 * A_5_3 + SUM_5)) = 0; // Round 7 (Partial Round) // ARK (Add Round Constant) @@ -188,10 +296,17 @@ namespace poseidon2(256); pol A_6_3 = ARK_6_3; // MATRIX (Partial round uses the external matrix) - pol B_6_0 = poseidon2_params.MU_0 * A_6_0 + A_6_1 + A_6_2 + A_6_3; - pol B_6_1 = poseidon2_params.MU_1 * A_6_1 + A_6_0 + A_6_2 + A_6_3; - pol B_6_2 = poseidon2_params.MU_2 * A_6_2 + A_6_0 + A_6_1 + A_6_3; - pol B_6_3 = poseidon2_params.MU_3 * A_6_3 + A_6_0 + A_6_1 + A_6_2; + pol commit B_6_0; + pol commit B_6_1; + pol commit B_6_2; + pol commit B_6_3; + + pol SUM_6 = A_6_0 + A_6_1 + A_6_2 + A_6_3; + + sel_poseidon_perm * (B_6_0 - (poseidon2_params.MU_0 * A_6_0 + SUM_6)) = 0; + sel_poseidon_perm * (B_6_1 - (poseidon2_params.MU_1 * A_6_1 + SUM_6)) = 0; + sel_poseidon_perm * (B_6_2 - (poseidon2_params.MU_2 * A_6_2 + SUM_6)) = 0; + sel_poseidon_perm * (B_6_3 - (poseidon2_params.MU_3 * A_6_3 + SUM_6)) = 0; // Round 8 (Partial Round) // ARK (Add Round Constant) @@ -207,10 +322,17 @@ namespace poseidon2(256); pol A_7_3 = ARK_7_3; // MATRIX (Partial round uses the external matrix) - pol B_7_0 = poseidon2_params.MU_0 * A_7_0 + A_7_1 + A_7_2 + A_7_3; - pol B_7_1 = poseidon2_params.MU_1 * A_7_1 + A_7_0 + A_7_2 + A_7_3; - pol B_7_2 = poseidon2_params.MU_2 * A_7_2 + A_7_0 + A_7_1 + A_7_3; - pol B_7_3 = poseidon2_params.MU_3 * A_7_3 + A_7_0 + A_7_1 + A_7_2; + pol commit B_7_0; + pol commit B_7_1; + pol commit B_7_2; + pol commit B_7_3; + + pol SUM_7 = A_7_0 + A_7_1 + A_7_2 + A_7_3; + + sel_poseidon_perm * (B_7_0 - (poseidon2_params.MU_0 * A_7_0 + SUM_7)) = 0; + sel_poseidon_perm * (B_7_1 - (poseidon2_params.MU_1 * A_7_1 + SUM_7)) = 0; + sel_poseidon_perm * (B_7_2 - (poseidon2_params.MU_2 * A_7_2 + SUM_7)) = 0; + sel_poseidon_perm * (B_7_3 - (poseidon2_params.MU_3 * A_7_3 + SUM_7)) = 0; // Round 9 (Partial Round) // ARK (Add Round Constant) @@ -226,10 +348,17 @@ namespace poseidon2(256); pol A_8_3 = ARK_8_3; // MATRIX (Partial round uses the external matrix) - pol B_8_0 = poseidon2_params.MU_0 * A_8_0 + A_8_1 + A_8_2 + A_8_3; - pol B_8_1 = poseidon2_params.MU_1 * A_8_1 + A_8_0 + A_8_2 + A_8_3; - pol B_8_2 = poseidon2_params.MU_2 * A_8_2 + A_8_0 + A_8_1 + A_8_3; - pol B_8_3 = poseidon2_params.MU_3 * A_8_3 + A_8_0 + A_8_1 + A_8_2; + pol commit B_8_0; + pol commit B_8_1; + pol commit B_8_2; + pol commit B_8_3; + + pol SUM_8 = A_8_0 + A_8_1 + A_8_2 + A_8_3; + + sel_poseidon_perm * (B_8_0 - (poseidon2_params.MU_0 * A_8_0 + SUM_8)) = 0; + sel_poseidon_perm * (B_8_1 - (poseidon2_params.MU_1 * A_8_1 + SUM_8)) = 0; + sel_poseidon_perm * (B_8_2 - (poseidon2_params.MU_2 * A_8_2 + SUM_8)) = 0; + sel_poseidon_perm * (B_8_3 - (poseidon2_params.MU_3 * A_8_3 + SUM_8)) = 0; // Round 10 (Partial Round) // ARK (Add Round Constant) @@ -245,10 +374,17 @@ namespace poseidon2(256); pol A_9_3 = ARK_9_3; // MATRIX (Partial round uses the external matrix) - pol B_9_0 = poseidon2_params.MU_0 * A_9_0 + A_9_1 + A_9_2 + A_9_3; - pol B_9_1 = poseidon2_params.MU_1 * A_9_1 + A_9_0 + A_9_2 + A_9_3; - pol B_9_2 = poseidon2_params.MU_2 * A_9_2 + A_9_0 + A_9_1 + A_9_3; - pol B_9_3 = poseidon2_params.MU_3 * A_9_3 + A_9_0 + A_9_1 + A_9_2; + pol commit B_9_0; + pol commit B_9_1; + pol commit B_9_2; + pol commit B_9_3; + + pol SUM_9 = A_9_0 + A_9_1 + A_9_2 + A_9_3; + + sel_poseidon_perm * (B_9_0 - (poseidon2_params.MU_0 * A_9_0 + SUM_9)) = 0; + sel_poseidon_perm * (B_9_1 - (poseidon2_params.MU_1 * A_9_1 + SUM_9)) = 0; + sel_poseidon_perm * (B_9_2 - (poseidon2_params.MU_2 * A_9_2 + SUM_9)) = 0; + sel_poseidon_perm * (B_9_3 - (poseidon2_params.MU_3 * A_9_3 + SUM_9)) = 0; // Round 11 (Partial Round) // ARK (Add Round Constant) @@ -264,10 +400,17 @@ namespace poseidon2(256); pol A_10_3 = ARK_10_3; // MATRIX (Partial round uses the external matrix) - pol B_10_0 = poseidon2_params.MU_0 * A_10_0 + A_10_1 + A_10_2 + A_10_3; - pol B_10_1 = poseidon2_params.MU_1 * A_10_1 + A_10_0 + A_10_2 + A_10_3; - pol B_10_2 = poseidon2_params.MU_2 * A_10_2 + A_10_0 + A_10_1 + A_10_3; - pol B_10_3 = poseidon2_params.MU_3 * A_10_3 + A_10_0 + A_10_1 + A_10_2; + pol commit B_10_0; + pol commit B_10_1; + pol commit B_10_2; + pol commit B_10_3; + + pol SUM_10 = A_10_0 + A_10_1 + A_10_2 + A_10_3; + + sel_poseidon_perm * (B_10_0 - (poseidon2_params.MU_0 * A_10_0 + SUM_10)) = 0; + sel_poseidon_perm * (B_10_1 - (poseidon2_params.MU_1 * A_10_1 + SUM_10)) = 0; + sel_poseidon_perm * (B_10_2 - (poseidon2_params.MU_2 * A_10_2 + SUM_10)) = 0; + sel_poseidon_perm * (B_10_3 - (poseidon2_params.MU_3 * A_10_3 + SUM_10)) = 0; // Round 12 (Partial Round) // ARK (Add Round Constant) @@ -283,10 +426,17 @@ namespace poseidon2(256); pol A_11_3 = ARK_11_3; // MATRIX (Partial round uses the external matrix) - pol B_11_0 = poseidon2_params.MU_0 * A_11_0 + A_11_1 + A_11_2 + A_11_3; - pol B_11_1 = poseidon2_params.MU_1 * A_11_1 + A_11_0 + A_11_2 + A_11_3; - pol B_11_2 = poseidon2_params.MU_2 * A_11_2 + A_11_0 + A_11_1 + A_11_3; - pol B_11_3 = poseidon2_params.MU_3 * A_11_3 + A_11_0 + A_11_1 + A_11_2; + pol commit B_11_0; + pol commit B_11_1; + pol commit B_11_2; + pol commit B_11_3; + + pol SUM_11 = A_11_0 + A_11_1 + A_11_2 + A_11_3; + + sel_poseidon_perm * (B_11_0 - (poseidon2_params.MU_0 * A_11_0 + SUM_11)) = 0; + sel_poseidon_perm * (B_11_1 - (poseidon2_params.MU_1 * A_11_1 + SUM_11)) = 0; + sel_poseidon_perm * (B_11_2 - (poseidon2_params.MU_2 * A_11_2 + SUM_11)) = 0; + sel_poseidon_perm * (B_11_3 - (poseidon2_params.MU_3 * A_11_3 + SUM_11)) = 0; // Round 13 (Partial Round) // ARK (Add Round Constant) @@ -302,10 +452,17 @@ namespace poseidon2(256); pol A_12_3 = ARK_12_3; // MATRIX (Partial round uses the external matrix) - pol B_12_0 = poseidon2_params.MU_0 * A_12_0 + A_12_1 + A_12_2 + A_12_3; - pol B_12_1 = poseidon2_params.MU_1 * A_12_1 + A_12_0 + A_12_2 + A_12_3; - pol B_12_2 = poseidon2_params.MU_2 * A_12_2 + A_12_0 + A_12_1 + A_12_3; - pol B_12_3 = poseidon2_params.MU_3 * A_12_3 + A_12_0 + A_12_1 + A_12_2; + pol commit B_12_0; + pol commit B_12_1; + pol commit B_12_2; + pol commit B_12_3; + + pol SUM_12 = A_12_0 + A_12_1 + A_12_2 + A_12_3; + + sel_poseidon_perm * (B_12_0 - (poseidon2_params.MU_0 * A_12_0 + SUM_12)) = 0; + sel_poseidon_perm * (B_12_1 - (poseidon2_params.MU_1 * A_12_1 + SUM_12)) = 0; + sel_poseidon_perm * (B_12_2 - (poseidon2_params.MU_2 * A_12_2 + SUM_12)) = 0; + sel_poseidon_perm * (B_12_3 - (poseidon2_params.MU_3 * A_12_3 + SUM_12)) = 0; // Round 14 (Partial Round) // ARK (Add Round Constant) @@ -321,10 +478,17 @@ namespace poseidon2(256); pol A_13_3 = ARK_13_3; // MATRIX (Partial round uses the external matrix) - pol B_13_0 = poseidon2_params.MU_0 * A_13_0 + A_13_1 + A_13_2 + A_13_3; - pol B_13_1 = poseidon2_params.MU_1 * A_13_1 + A_13_0 + A_13_2 + A_13_3; - pol B_13_2 = poseidon2_params.MU_2 * A_13_2 + A_13_0 + A_13_1 + A_13_3; - pol B_13_3 = poseidon2_params.MU_3 * A_13_3 + A_13_0 + A_13_1 + A_13_2; + pol commit B_13_0; + pol commit B_13_1; + pol commit B_13_2; + pol commit B_13_3; + + pol SUM_13 = A_13_0 + A_13_1 + A_13_2 + A_13_3; + + sel_poseidon_perm * (B_13_0 - (poseidon2_params.MU_0 * A_13_0 + SUM_13)) = 0; + sel_poseidon_perm * (B_13_1 - (poseidon2_params.MU_1 * A_13_1 + SUM_13)) = 0; + sel_poseidon_perm * (B_13_2 - (poseidon2_params.MU_2 * A_13_2 + SUM_13)) = 0; + sel_poseidon_perm * (B_13_3 - (poseidon2_params.MU_3 * A_13_3 + SUM_13)) = 0; // Round 15 (Partial Round) // ARK (Add Round Constant) @@ -340,10 +504,17 @@ namespace poseidon2(256); pol A_14_3 = ARK_14_3; // MATRIX (Partial round uses the external matrix) - pol B_14_0 = poseidon2_params.MU_0 * A_14_0 + A_14_1 + A_14_2 + A_14_3; - pol B_14_1 = poseidon2_params.MU_1 * A_14_1 + A_14_0 + A_14_2 + A_14_3; - pol B_14_2 = poseidon2_params.MU_2 * A_14_2 + A_14_0 + A_14_1 + A_14_3; - pol B_14_3 = poseidon2_params.MU_3 * A_14_3 + A_14_0 + A_14_1 + A_14_2; + pol commit B_14_0; + pol commit B_14_1; + pol commit B_14_2; + pol commit B_14_3; + + pol SUM_14 = A_14_0 + A_14_1 + A_14_2 + A_14_3; + + sel_poseidon_perm * (B_14_0 - (poseidon2_params.MU_0 * A_14_0 + SUM_14)) = 0; + sel_poseidon_perm * (B_14_1 - (poseidon2_params.MU_1 * A_14_1 + SUM_14)) = 0; + sel_poseidon_perm * (B_14_2 - (poseidon2_params.MU_2 * A_14_2 + SUM_14)) = 0; + sel_poseidon_perm * (B_14_3 - (poseidon2_params.MU_3 * A_14_3 + SUM_14)) = 0; // Round 16 (Partial Round) // ARK (Add Round Constant) @@ -359,10 +530,17 @@ namespace poseidon2(256); pol A_15_3 = ARK_15_3; // MATRIX (Partial round uses the external matrix) - pol B_15_0 = poseidon2_params.MU_0 * A_15_0 + A_15_1 + A_15_2 + A_15_3; - pol B_15_1 = poseidon2_params.MU_1 * A_15_1 + A_15_0 + A_15_2 + A_15_3; - pol B_15_2 = poseidon2_params.MU_2 * A_15_2 + A_15_0 + A_15_1 + A_15_3; - pol B_15_3 = poseidon2_params.MU_3 * A_15_3 + A_15_0 + A_15_1 + A_15_2; + pol commit B_15_0; + pol commit B_15_1; + pol commit B_15_2; + pol commit B_15_3; + + pol SUM_15 = A_15_0 + A_15_1 + A_15_2 + A_15_3; + + sel_poseidon_perm * (B_15_0 - (poseidon2_params.MU_0 * A_15_0 + SUM_15)) = 0; + sel_poseidon_perm * (B_15_1 - (poseidon2_params.MU_1 * A_15_1 + SUM_15)) = 0; + sel_poseidon_perm * (B_15_2 - (poseidon2_params.MU_2 * A_15_2 + SUM_15)) = 0; + sel_poseidon_perm * (B_15_3 - (poseidon2_params.MU_3 * A_15_3 + SUM_15)) = 0; // Round 17 (Partial Round) // ARK (Add Round Constant) @@ -378,10 +556,17 @@ namespace poseidon2(256); pol A_16_3 = ARK_16_3; // MATRIX (Partial round uses the external matrix) - pol B_16_0 = poseidon2_params.MU_0 * A_16_0 + A_16_1 + A_16_2 + A_16_3; - pol B_16_1 = poseidon2_params.MU_1 * A_16_1 + A_16_0 + A_16_2 + A_16_3; - pol B_16_2 = poseidon2_params.MU_2 * A_16_2 + A_16_0 + A_16_1 + A_16_3; - pol B_16_3 = poseidon2_params.MU_3 * A_16_3 + A_16_0 + A_16_1 + A_16_2; + pol commit B_16_0; + pol commit B_16_1; + pol commit B_16_2; + pol commit B_16_3; + + pol SUM_16 = A_16_0 + A_16_1 + A_16_2 + A_16_3; + + sel_poseidon_perm * (B_16_0 - (poseidon2_params.MU_0 * A_16_0 + SUM_16)) = 0; + sel_poseidon_perm * (B_16_1 - (poseidon2_params.MU_1 * A_16_1 + SUM_16)) = 0; + sel_poseidon_perm * (B_16_2 - (poseidon2_params.MU_2 * A_16_2 + SUM_16)) = 0; + sel_poseidon_perm * (B_16_3 - (poseidon2_params.MU_3 * A_16_3 + SUM_16)) = 0; // Round 18 (Partial Round) // ARK (Add Round Constant) @@ -397,10 +582,17 @@ namespace poseidon2(256); pol A_17_3 = ARK_17_3; // MATRIX (Partial round uses the external matrix) - pol B_17_0 = poseidon2_params.MU_0 * A_17_0 + A_17_1 + A_17_2 + A_17_3; - pol B_17_1 = poseidon2_params.MU_1 * A_17_1 + A_17_0 + A_17_2 + A_17_3; - pol B_17_2 = poseidon2_params.MU_2 * A_17_2 + A_17_0 + A_17_1 + A_17_3; - pol B_17_3 = poseidon2_params.MU_3 * A_17_3 + A_17_0 + A_17_1 + A_17_2; + pol commit B_17_0; + pol commit B_17_1; + pol commit B_17_2; + pol commit B_17_3; + + pol SUM_17 = A_17_0 + A_17_1 + A_17_2 + A_17_3; + + sel_poseidon_perm * (B_17_0 - (poseidon2_params.MU_0 * A_17_0 + SUM_17)) = 0; + sel_poseidon_perm * (B_17_1 - (poseidon2_params.MU_1 * A_17_1 + SUM_17)) = 0; + sel_poseidon_perm * (B_17_2 - (poseidon2_params.MU_2 * A_17_2 + SUM_17)) = 0; + sel_poseidon_perm * (B_17_3 - (poseidon2_params.MU_3 * A_17_3 + SUM_17)) = 0; // Round 19 (Partial Round) // ARK (Add Round Constant) @@ -416,10 +608,17 @@ namespace poseidon2(256); pol A_18_3 = ARK_18_3; // MATRIX (Partial round uses the external matrix) - pol B_18_0 = poseidon2_params.MU_0 * A_18_0 + A_18_1 + A_18_2 + A_18_3; - pol B_18_1 = poseidon2_params.MU_1 * A_18_1 + A_18_0 + A_18_2 + A_18_3; - pol B_18_2 = poseidon2_params.MU_2 * A_18_2 + A_18_0 + A_18_1 + A_18_3; - pol B_18_3 = poseidon2_params.MU_3 * A_18_3 + A_18_0 + A_18_1 + A_18_2; + pol commit B_18_0; + pol commit B_18_1; + pol commit B_18_2; + pol commit B_18_3; + + pol SUM_18 = A_18_0 + A_18_1 + A_18_2 + A_18_3; + + sel_poseidon_perm * (B_18_0 - (poseidon2_params.MU_0 * A_18_0 + SUM_18)) = 0; + sel_poseidon_perm * (B_18_1 - (poseidon2_params.MU_1 * A_18_1 + SUM_18)) = 0; + sel_poseidon_perm * (B_18_2 - (poseidon2_params.MU_2 * A_18_2 + SUM_18)) = 0; + sel_poseidon_perm * (B_18_3 - (poseidon2_params.MU_3 * A_18_3 + SUM_18)) = 0; // Round 20 (Partial Round) // ARK (Add Round Constant) @@ -435,10 +634,17 @@ namespace poseidon2(256); pol A_19_3 = ARK_19_3; // MATRIX (Partial round uses the external matrix) - pol B_19_0 = poseidon2_params.MU_0 * A_19_0 + A_19_1 + A_19_2 + A_19_3; - pol B_19_1 = poseidon2_params.MU_1 * A_19_1 + A_19_0 + A_19_2 + A_19_3; - pol B_19_2 = poseidon2_params.MU_2 * A_19_2 + A_19_0 + A_19_1 + A_19_3; - pol B_19_3 = poseidon2_params.MU_3 * A_19_3 + A_19_0 + A_19_1 + A_19_2; + pol commit B_19_0; + pol commit B_19_1; + pol commit B_19_2; + pol commit B_19_3; + + pol SUM_19 = A_19_0 + A_19_1 + A_19_2 + A_19_3; + + sel_poseidon_perm * (B_19_0 - (poseidon2_params.MU_0 * A_19_0 + SUM_19)) = 0; + sel_poseidon_perm * (B_19_1 - (poseidon2_params.MU_1 * A_19_1 + SUM_19)) = 0; + sel_poseidon_perm * (B_19_2 - (poseidon2_params.MU_2 * A_19_2 + SUM_19)) = 0; + sel_poseidon_perm * (B_19_3 - (poseidon2_params.MU_3 * A_19_3 + SUM_19)) = 0; // Round 21 (Partial Round) // ARK (Add Round Constant) @@ -454,10 +660,17 @@ namespace poseidon2(256); pol A_20_3 = ARK_20_3; // MATRIX (Partial round uses the external matrix) - pol B_20_0 = poseidon2_params.MU_0 * A_20_0 + A_20_1 + A_20_2 + A_20_3; - pol B_20_1 = poseidon2_params.MU_1 * A_20_1 + A_20_0 + A_20_2 + A_20_3; - pol B_20_2 = poseidon2_params.MU_2 * A_20_2 + A_20_0 + A_20_1 + A_20_3; - pol B_20_3 = poseidon2_params.MU_3 * A_20_3 + A_20_0 + A_20_1 + A_20_2; + pol commit B_20_0; + pol commit B_20_1; + pol commit B_20_2; + pol commit B_20_3; + + pol SUM_20 = A_20_0 + A_20_1 + A_20_2 + A_20_3; + + sel_poseidon_perm * (B_20_0 - (poseidon2_params.MU_0 * A_20_0 + SUM_20)) = 0; + sel_poseidon_perm * (B_20_1 - (poseidon2_params.MU_1 * A_20_1 + SUM_20)) = 0; + sel_poseidon_perm * (B_20_2 - (poseidon2_params.MU_2 * A_20_2 + SUM_20)) = 0; + sel_poseidon_perm * (B_20_3 - (poseidon2_params.MU_3 * A_20_3 + SUM_20)) = 0; // Round 22 (Partial Round) // ARK (Add Round Constant) @@ -473,10 +686,17 @@ namespace poseidon2(256); pol A_21_3 = ARK_21_3; // MATRIX (Partial round uses the external matrix) - pol B_21_0 = poseidon2_params.MU_0 * A_21_0 + A_21_1 + A_21_2 + A_21_3; - pol B_21_1 = poseidon2_params.MU_1 * A_21_1 + A_21_0 + A_21_2 + A_21_3; - pol B_21_2 = poseidon2_params.MU_2 * A_21_2 + A_21_0 + A_21_1 + A_21_3; - pol B_21_3 = poseidon2_params.MU_3 * A_21_3 + A_21_0 + A_21_1 + A_21_2; + pol commit B_21_0; + pol commit B_21_1; + pol commit B_21_2; + pol commit B_21_3; + + pol SUM_21 = A_21_0 + A_21_1 + A_21_2 + A_21_3; + + sel_poseidon_perm * (B_21_0 - (poseidon2_params.MU_0 * A_21_0 + SUM_21)) = 0; + sel_poseidon_perm * (B_21_1 - (poseidon2_params.MU_1 * A_21_1 + SUM_21)) = 0; + sel_poseidon_perm * (B_21_2 - (poseidon2_params.MU_2 * A_21_2 + SUM_21)) = 0; + sel_poseidon_perm * (B_21_3 - (poseidon2_params.MU_3 * A_21_3 + SUM_21)) = 0; // Round 23 (Partial Round) // ARK (Add Round Constant) @@ -492,10 +712,17 @@ namespace poseidon2(256); pol A_22_3 = ARK_22_3; // MATRIX (Partial round uses the external matrix) - pol B_22_0 = poseidon2_params.MU_0 * A_22_0 + A_22_1 + A_22_2 + A_22_3; - pol B_22_1 = poseidon2_params.MU_1 * A_22_1 + A_22_0 + A_22_2 + A_22_3; - pol B_22_2 = poseidon2_params.MU_2 * A_22_2 + A_22_0 + A_22_1 + A_22_3; - pol B_22_3 = poseidon2_params.MU_3 * A_22_3 + A_22_0 + A_22_1 + A_22_2; + pol commit B_22_0; + pol commit B_22_1; + pol commit B_22_2; + pol commit B_22_3; + + pol SUM_22 = A_22_0 + A_22_1 + A_22_2 + A_22_3; + + sel_poseidon_perm * (B_22_0 - (poseidon2_params.MU_0 * A_22_0 + SUM_22)) = 0; + sel_poseidon_perm * (B_22_1 - (poseidon2_params.MU_1 * A_22_1 + SUM_22)) = 0; + sel_poseidon_perm * (B_22_2 - (poseidon2_params.MU_2 * A_22_2 + SUM_22)) = 0; + sel_poseidon_perm * (B_22_3 - (poseidon2_params.MU_3 * A_22_3 + SUM_22)) = 0; // Round 24 (Partial Round) // ARK (Add Round Constant) @@ -511,10 +738,17 @@ namespace poseidon2(256); pol A_23_3 = ARK_23_3; // MATRIX (Partial round uses the external matrix) - pol B_23_0 = poseidon2_params.MU_0 * A_23_0 + A_23_1 + A_23_2 + A_23_3; - pol B_23_1 = poseidon2_params.MU_1 * A_23_1 + A_23_0 + A_23_2 + A_23_3; - pol B_23_2 = poseidon2_params.MU_2 * A_23_2 + A_23_0 + A_23_1 + A_23_3; - pol B_23_3 = poseidon2_params.MU_3 * A_23_3 + A_23_0 + A_23_1 + A_23_2; + pol commit B_23_0; + pol commit B_23_1; + pol commit B_23_2; + pol commit B_23_3; + + pol SUM_23 = A_23_0 + A_23_1 + A_23_2 + A_23_3; + + sel_poseidon_perm * (B_23_0 - (poseidon2_params.MU_0 * A_23_0 + SUM_23)) = 0; + sel_poseidon_perm * (B_23_1 - (poseidon2_params.MU_1 * A_23_1 + SUM_23)) = 0; + sel_poseidon_perm * (B_23_2 - (poseidon2_params.MU_2 * A_23_2 + SUM_23)) = 0; + sel_poseidon_perm * (B_23_3 - (poseidon2_params.MU_3 * A_23_3 + SUM_23)) = 0; // Round 25 (Partial Round) // ARK (Add Round Constant) @@ -530,10 +764,17 @@ namespace poseidon2(256); pol A_24_3 = ARK_24_3; // MATRIX (Partial round uses the external matrix) - pol B_24_0 = poseidon2_params.MU_0 * A_24_0 + A_24_1 + A_24_2 + A_24_3; - pol B_24_1 = poseidon2_params.MU_1 * A_24_1 + A_24_0 + A_24_2 + A_24_3; - pol B_24_2 = poseidon2_params.MU_2 * A_24_2 + A_24_0 + A_24_1 + A_24_3; - pol B_24_3 = poseidon2_params.MU_3 * A_24_3 + A_24_0 + A_24_1 + A_24_2; + pol commit B_24_0; + pol commit B_24_1; + pol commit B_24_2; + pol commit B_24_3; + + pol SUM_24 = A_24_0 + A_24_1 + A_24_2 + A_24_3; + + sel_poseidon_perm * (B_24_0 - (poseidon2_params.MU_0 * A_24_0 + SUM_24)) = 0; + sel_poseidon_perm * (B_24_1 - (poseidon2_params.MU_1 * A_24_1 + SUM_24)) = 0; + sel_poseidon_perm * (B_24_2 - (poseidon2_params.MU_2 * A_24_2 + SUM_24)) = 0; + sel_poseidon_perm * (B_24_3 - (poseidon2_params.MU_3 * A_24_3 + SUM_24)) = 0; // Round 26 (Partial Round) // ARK (Add Round Constant) @@ -549,10 +790,17 @@ namespace poseidon2(256); pol A_25_3 = ARK_25_3; // MATRIX (Partial round uses the external matrix) - pol B_25_0 = poseidon2_params.MU_0 * A_25_0 + A_25_1 + A_25_2 + A_25_3; - pol B_25_1 = poseidon2_params.MU_1 * A_25_1 + A_25_0 + A_25_2 + A_25_3; - pol B_25_2 = poseidon2_params.MU_2 * A_25_2 + A_25_0 + A_25_1 + A_25_3; - pol B_25_3 = poseidon2_params.MU_3 * A_25_3 + A_25_0 + A_25_1 + A_25_2; + pol commit B_25_0; + pol commit B_25_1; + pol commit B_25_2; + pol commit B_25_3; + + pol SUM_25 = A_25_0 + A_25_1 + A_25_2 + A_25_3; + + sel_poseidon_perm * (B_25_0 - (poseidon2_params.MU_0 * A_25_0 + SUM_25)) = 0; + sel_poseidon_perm * (B_25_1 - (poseidon2_params.MU_1 * A_25_1 + SUM_25)) = 0; + sel_poseidon_perm * (B_25_2 - (poseidon2_params.MU_2 * A_25_2 + SUM_25)) = 0; + sel_poseidon_perm * (B_25_3 - (poseidon2_params.MU_3 * A_25_3 + SUM_25)) = 0; // Round 27 (Partial Round) // ARK (Add Round Constant) @@ -568,10 +816,17 @@ namespace poseidon2(256); pol A_26_3 = ARK_26_3; // MATRIX (Partial round uses the external matrix) - pol B_26_0 = poseidon2_params.MU_0 * A_26_0 + A_26_1 + A_26_2 + A_26_3; - pol B_26_1 = poseidon2_params.MU_1 * A_26_1 + A_26_0 + A_26_2 + A_26_3; - pol B_26_2 = poseidon2_params.MU_2 * A_26_2 + A_26_0 + A_26_1 + A_26_3; - pol B_26_3 = poseidon2_params.MU_3 * A_26_3 + A_26_0 + A_26_1 + A_26_2; + pol commit B_26_0; + pol commit B_26_1; + pol commit B_26_2; + pol commit B_26_3; + + pol SUM_26 = A_26_0 + A_26_1 + A_26_2 + A_26_3; + + sel_poseidon_perm * (B_26_0 - (poseidon2_params.MU_0 * A_26_0 + SUM_26)) = 0; + sel_poseidon_perm * (B_26_1 - (poseidon2_params.MU_1 * A_26_1 + SUM_26)) = 0; + sel_poseidon_perm * (B_26_2 - (poseidon2_params.MU_2 * A_26_2 + SUM_26)) = 0; + sel_poseidon_perm * (B_26_3 - (poseidon2_params.MU_3 * A_26_3 + SUM_26)) = 0; // Round 28 (Partial Round) // ARK (Add Round Constant) @@ -587,10 +842,17 @@ namespace poseidon2(256); pol A_27_3 = ARK_27_3; // MATRIX (Partial round uses the external matrix) - pol B_27_0 = poseidon2_params.MU_0 * A_27_0 + A_27_1 + A_27_2 + A_27_3; - pol B_27_1 = poseidon2_params.MU_1 * A_27_1 + A_27_0 + A_27_2 + A_27_3; - pol B_27_2 = poseidon2_params.MU_2 * A_27_2 + A_27_0 + A_27_1 + A_27_3; - pol B_27_3 = poseidon2_params.MU_3 * A_27_3 + A_27_0 + A_27_1 + A_27_2; + pol commit B_27_0; + pol commit B_27_1; + pol commit B_27_2; + pol commit B_27_3; + + pol SUM_27 = A_27_0 + A_27_1 + A_27_2 + A_27_3; + + sel_poseidon_perm * (B_27_0 - (poseidon2_params.MU_0 * A_27_0 + SUM_27)) = 0; + sel_poseidon_perm * (B_27_1 - (poseidon2_params.MU_1 * A_27_1 + SUM_27)) = 0; + sel_poseidon_perm * (B_27_2 - (poseidon2_params.MU_2 * A_27_2 + SUM_27)) = 0; + sel_poseidon_perm * (B_27_3 - (poseidon2_params.MU_3 * A_27_3 + SUM_27)) = 0; // Round 29 (Partial Round) // ARK (Add Round Constant) @@ -606,10 +868,17 @@ namespace poseidon2(256); pol A_28_3 = ARK_28_3; // MATRIX (Partial round uses the external matrix) - pol B_28_0 = poseidon2_params.MU_0 * A_28_0 + A_28_1 + A_28_2 + A_28_3; - pol B_28_1 = poseidon2_params.MU_1 * A_28_1 + A_28_0 + A_28_2 + A_28_3; - pol B_28_2 = poseidon2_params.MU_2 * A_28_2 + A_28_0 + A_28_1 + A_28_3; - pol B_28_3 = poseidon2_params.MU_3 * A_28_3 + A_28_0 + A_28_1 + A_28_2; + pol commit B_28_0; + pol commit B_28_1; + pol commit B_28_2; + pol commit B_28_3; + + pol SUM_28 = A_28_0 + A_28_1 + A_28_2 + A_28_3; + + sel_poseidon_perm * (B_28_0 - (poseidon2_params.MU_0 * A_28_0 + SUM_28)) = 0; + sel_poseidon_perm * (B_28_1 - (poseidon2_params.MU_1 * A_28_1 + SUM_28)) = 0; + sel_poseidon_perm * (B_28_2 - (poseidon2_params.MU_2 * A_28_2 + SUM_28)) = 0; + sel_poseidon_perm * (B_28_3 - (poseidon2_params.MU_3 * A_28_3 + SUM_28)) = 0; // Round 30 (Partial Round) // ARK (Add Round Constant) @@ -625,10 +894,17 @@ namespace poseidon2(256); pol A_29_3 = ARK_29_3; // MATRIX (Partial round uses the external matrix) - pol B_29_0 = poseidon2_params.MU_0 * A_29_0 + A_29_1 + A_29_2 + A_29_3; - pol B_29_1 = poseidon2_params.MU_1 * A_29_1 + A_29_0 + A_29_2 + A_29_3; - pol B_29_2 = poseidon2_params.MU_2 * A_29_2 + A_29_0 + A_29_1 + A_29_3; - pol B_29_3 = poseidon2_params.MU_3 * A_29_3 + A_29_0 + A_29_1 + A_29_2; + pol commit B_29_0; + pol commit B_29_1; + pol commit B_29_2; + pol commit B_29_3; + + pol SUM_29 = A_29_0 + A_29_1 + A_29_2 + A_29_3; + + sel_poseidon_perm * (B_29_0 - (poseidon2_params.MU_0 * A_29_0 + SUM_29)) = 0; + sel_poseidon_perm * (B_29_1 - (poseidon2_params.MU_1 * A_29_1 + SUM_29)) = 0; + sel_poseidon_perm * (B_29_2 - (poseidon2_params.MU_2 * A_29_2 + SUM_29)) = 0; + sel_poseidon_perm * (B_29_3 - (poseidon2_params.MU_3 * A_29_3 + SUM_29)) = 0; // Round 31 (Partial Round) // ARK (Add Round Constant) @@ -644,10 +920,17 @@ namespace poseidon2(256); pol A_30_3 = ARK_30_3; // MATRIX (Partial round uses the external matrix) - pol B_30_0 = poseidon2_params.MU_0 * A_30_0 + A_30_1 + A_30_2 + A_30_3; - pol B_30_1 = poseidon2_params.MU_1 * A_30_1 + A_30_0 + A_30_2 + A_30_3; - pol B_30_2 = poseidon2_params.MU_2 * A_30_2 + A_30_0 + A_30_1 + A_30_3; - pol B_30_3 = poseidon2_params.MU_3 * A_30_3 + A_30_0 + A_30_1 + A_30_2; + pol commit B_30_0; + pol commit B_30_1; + pol commit B_30_2; + pol commit B_30_3; + + pol SUM_30 = A_30_0 + A_30_1 + A_30_2 + A_30_3; + + sel_poseidon_perm * (B_30_0 - (poseidon2_params.MU_0 * A_30_0 + SUM_30)) = 0; + sel_poseidon_perm * (B_30_1 - (poseidon2_params.MU_1 * A_30_1 + SUM_30)) = 0; + sel_poseidon_perm * (B_30_2 - (poseidon2_params.MU_2 * A_30_2 + SUM_30)) = 0; + sel_poseidon_perm * (B_30_3 - (poseidon2_params.MU_3 * A_30_3 + SUM_30)) = 0; // Round 32 (Partial Round) // ARK (Add Round Constant) @@ -663,10 +946,17 @@ namespace poseidon2(256); pol A_31_3 = ARK_31_3; // MATRIX (Partial round uses the external matrix) - pol B_31_0 = poseidon2_params.MU_0 * A_31_0 + A_31_1 + A_31_2 + A_31_3; - pol B_31_1 = poseidon2_params.MU_1 * A_31_1 + A_31_0 + A_31_2 + A_31_3; - pol B_31_2 = poseidon2_params.MU_2 * A_31_2 + A_31_0 + A_31_1 + A_31_3; - pol B_31_3 = poseidon2_params.MU_3 * A_31_3 + A_31_0 + A_31_1 + A_31_2; + pol commit B_31_0; + pol commit B_31_1; + pol commit B_31_2; + pol commit B_31_3; + + pol SUM_31 = A_31_0 + A_31_1 + A_31_2 + A_31_3; + + sel_poseidon_perm * (B_31_0 - (poseidon2_params.MU_0 * A_31_0 + SUM_31)) = 0; + sel_poseidon_perm * (B_31_1 - (poseidon2_params.MU_1 * A_31_1 + SUM_31)) = 0; + sel_poseidon_perm * (B_31_2 - (poseidon2_params.MU_2 * A_31_2 + SUM_31)) = 0; + sel_poseidon_perm * (B_31_3 - (poseidon2_params.MU_3 * A_31_3 + SUM_31)) = 0; // Round 33 (Partial Round) // ARK (Add Round Constant) @@ -682,10 +972,17 @@ namespace poseidon2(256); pol A_32_3 = ARK_32_3; // MATRIX (Partial round uses the external matrix) - pol B_32_0 = poseidon2_params.MU_0 * A_32_0 + A_32_1 + A_32_2 + A_32_3; - pol B_32_1 = poseidon2_params.MU_1 * A_32_1 + A_32_0 + A_32_2 + A_32_3; - pol B_32_2 = poseidon2_params.MU_2 * A_32_2 + A_32_0 + A_32_1 + A_32_3; - pol B_32_3 = poseidon2_params.MU_3 * A_32_3 + A_32_0 + A_32_1 + A_32_2; + pol commit B_32_0; + pol commit B_32_1; + pol commit B_32_2; + pol commit B_32_3; + + pol SUM_32 = A_32_0 + A_32_1 + A_32_2 + A_32_3; + + sel_poseidon_perm * (B_32_0 - (poseidon2_params.MU_0 * A_32_0 + SUM_32)) = 0; + sel_poseidon_perm * (B_32_1 - (poseidon2_params.MU_1 * A_32_1 + SUM_32)) = 0; + sel_poseidon_perm * (B_32_2 - (poseidon2_params.MU_2 * A_32_2 + SUM_32)) = 0; + sel_poseidon_perm * (B_32_3 - (poseidon2_params.MU_3 * A_32_3 + SUM_32)) = 0; // Round 34 (Partial Round) // ARK (Add Round Constant) @@ -701,10 +998,17 @@ namespace poseidon2(256); pol A_33_3 = ARK_33_3; // MATRIX (Partial round uses the external matrix) - pol B_33_0 = poseidon2_params.MU_0 * A_33_0 + A_33_1 + A_33_2 + A_33_3; - pol B_33_1 = poseidon2_params.MU_1 * A_33_1 + A_33_0 + A_33_2 + A_33_3; - pol B_33_2 = poseidon2_params.MU_2 * A_33_2 + A_33_0 + A_33_1 + A_33_3; - pol B_33_3 = poseidon2_params.MU_3 * A_33_3 + A_33_0 + A_33_1 + A_33_2; + pol commit B_33_0; + pol commit B_33_1; + pol commit B_33_2; + pol commit B_33_3; + + pol SUM_33 = A_33_0 + A_33_1 + A_33_2 + A_33_3; + + sel_poseidon_perm * (B_33_0 - (poseidon2_params.MU_0 * A_33_0 + SUM_33)) = 0; + sel_poseidon_perm * (B_33_1 - (poseidon2_params.MU_1 * A_33_1 + SUM_33)) = 0; + sel_poseidon_perm * (B_33_2 - (poseidon2_params.MU_2 * A_33_2 + SUM_33)) = 0; + sel_poseidon_perm * (B_33_3 - (poseidon2_params.MU_3 * A_33_3 + SUM_33)) = 0; // Round 35 (Partial Round) // ARK (Add Round Constant) @@ -720,10 +1024,17 @@ namespace poseidon2(256); pol A_34_3 = ARK_34_3; // MATRIX (Partial round uses the external matrix) - pol B_34_0 = poseidon2_params.MU_0 * A_34_0 + A_34_1 + A_34_2 + A_34_3; - pol B_34_1 = poseidon2_params.MU_1 * A_34_1 + A_34_0 + A_34_2 + A_34_3; - pol B_34_2 = poseidon2_params.MU_2 * A_34_2 + A_34_0 + A_34_1 + A_34_3; - pol B_34_3 = poseidon2_params.MU_3 * A_34_3 + A_34_0 + A_34_1 + A_34_2; + pol commit B_34_0; + pol commit B_34_1; + pol commit B_34_2; + pol commit B_34_3; + + pol SUM_34 = A_34_0 + A_34_1 + A_34_2 + A_34_3; + + sel_poseidon_perm * (B_34_0 - (poseidon2_params.MU_0 * A_34_0 + SUM_34)) = 0; + sel_poseidon_perm * (B_34_1 - (poseidon2_params.MU_1 * A_34_1 + SUM_34)) = 0; + sel_poseidon_perm * (B_34_2 - (poseidon2_params.MU_2 * A_34_2 + SUM_34)) = 0; + sel_poseidon_perm * (B_34_3 - (poseidon2_params.MU_3 * A_34_3 + SUM_34)) = 0; // Round 36 (Partial Round) // ARK (Add Round Constant) @@ -739,10 +1050,17 @@ namespace poseidon2(256); pol A_35_3 = ARK_35_3; // MATRIX (Partial round uses the external matrix) - pol B_35_0 = poseidon2_params.MU_0 * A_35_0 + A_35_1 + A_35_2 + A_35_3; - pol B_35_1 = poseidon2_params.MU_1 * A_35_1 + A_35_0 + A_35_2 + A_35_3; - pol B_35_2 = poseidon2_params.MU_2 * A_35_2 + A_35_0 + A_35_1 + A_35_3; - pol B_35_3 = poseidon2_params.MU_3 * A_35_3 + A_35_0 + A_35_1 + A_35_2; + pol commit B_35_0; + pol commit B_35_1; + pol commit B_35_2; + pol commit B_35_3; + + pol SUM_35 = A_35_0 + A_35_1 + A_35_2 + A_35_3; + + sel_poseidon_perm * (B_35_0 - (poseidon2_params.MU_0 * A_35_0 + SUM_35)) = 0; + sel_poseidon_perm * (B_35_1 - (poseidon2_params.MU_1 * A_35_1 + SUM_35)) = 0; + sel_poseidon_perm * (B_35_2 - (poseidon2_params.MU_2 * A_35_2 + SUM_35)) = 0; + sel_poseidon_perm * (B_35_3 - (poseidon2_params.MU_3 * A_35_3 + SUM_35)) = 0; // Round 37 (Partial Round) // ARK (Add Round Constant) @@ -758,10 +1076,17 @@ namespace poseidon2(256); pol A_36_3 = ARK_36_3; // MATRIX (Partial round uses the external matrix) - pol B_36_0 = poseidon2_params.MU_0 * A_36_0 + A_36_1 + A_36_2 + A_36_3; - pol B_36_1 = poseidon2_params.MU_1 * A_36_1 + A_36_0 + A_36_2 + A_36_3; - pol B_36_2 = poseidon2_params.MU_2 * A_36_2 + A_36_0 + A_36_1 + A_36_3; - pol B_36_3 = poseidon2_params.MU_3 * A_36_3 + A_36_0 + A_36_1 + A_36_2; + pol commit B_36_0; + pol commit B_36_1; + pol commit B_36_2; + pol commit B_36_3; + + pol SUM_36 = A_36_0 + A_36_1 + A_36_2 + A_36_3; + + sel_poseidon_perm * (B_36_0 - (poseidon2_params.MU_0 * A_36_0 + SUM_36)) = 0; + sel_poseidon_perm * (B_36_1 - (poseidon2_params.MU_1 * A_36_1 + SUM_36)) = 0; + sel_poseidon_perm * (B_36_2 - (poseidon2_params.MU_2 * A_36_2 + SUM_36)) = 0; + sel_poseidon_perm * (B_36_3 - (poseidon2_params.MU_3 * A_36_3 + SUM_36)) = 0; // Round 38 (Partial Round) // ARK (Add Round Constant) @@ -777,10 +1102,17 @@ namespace poseidon2(256); pol A_37_3 = ARK_37_3; // MATRIX (Partial round uses the external matrix) - pol B_37_0 = poseidon2_params.MU_0 * A_37_0 + A_37_1 + A_37_2 + A_37_3; - pol B_37_1 = poseidon2_params.MU_1 * A_37_1 + A_37_0 + A_37_2 + A_37_3; - pol B_37_2 = poseidon2_params.MU_2 * A_37_2 + A_37_0 + A_37_1 + A_37_3; - pol B_37_3 = poseidon2_params.MU_3 * A_37_3 + A_37_0 + A_37_1 + A_37_2; + pol commit B_37_0; + pol commit B_37_1; + pol commit B_37_2; + pol commit B_37_3; + + pol SUM_37 = A_37_0 + A_37_1 + A_37_2 + A_37_3; + + sel_poseidon_perm * (B_37_0 - (poseidon2_params.MU_0 * A_37_0 + SUM_37)) = 0; + sel_poseidon_perm * (B_37_1 - (poseidon2_params.MU_1 * A_37_1 + SUM_37)) = 0; + sel_poseidon_perm * (B_37_2 - (poseidon2_params.MU_2 * A_37_2 + SUM_37)) = 0; + sel_poseidon_perm * (B_37_3 - (poseidon2_params.MU_3 * A_37_3 + SUM_37)) = 0; // Round 39 (Partial Round) // ARK (Add Round Constant) @@ -796,10 +1128,17 @@ namespace poseidon2(256); pol A_38_3 = ARK_38_3; // MATRIX (Partial round uses the external matrix) - pol B_38_0 = poseidon2_params.MU_0 * A_38_0 + A_38_1 + A_38_2 + A_38_3; - pol B_38_1 = poseidon2_params.MU_1 * A_38_1 + A_38_0 + A_38_2 + A_38_3; - pol B_38_2 = poseidon2_params.MU_2 * A_38_2 + A_38_0 + A_38_1 + A_38_3; - pol B_38_3 = poseidon2_params.MU_3 * A_38_3 + A_38_0 + A_38_1 + A_38_2; + pol commit B_38_0; + pol commit B_38_1; + pol commit B_38_2; + pol commit B_38_3; + + pol SUM_38 = A_38_0 + A_38_1 + A_38_2 + A_38_3; + + sel_poseidon_perm * (B_38_0 - (poseidon2_params.MU_0 * A_38_0 + SUM_38)) = 0; + sel_poseidon_perm * (B_38_1 - (poseidon2_params.MU_1 * A_38_1 + SUM_38)) = 0; + sel_poseidon_perm * (B_38_2 - (poseidon2_params.MU_2 * A_38_2 + SUM_38)) = 0; + sel_poseidon_perm * (B_38_3 - (poseidon2_params.MU_3 * A_38_3 + SUM_38)) = 0; // Round 40 (Partial Round) // ARK (Add Round Constant) @@ -815,10 +1154,17 @@ namespace poseidon2(256); pol A_39_3 = ARK_39_3; // MATRIX (Partial round uses the external matrix) - pol B_39_0 = poseidon2_params.MU_0 * A_39_0 + A_39_1 + A_39_2 + A_39_3; - pol B_39_1 = poseidon2_params.MU_1 * A_39_1 + A_39_0 + A_39_2 + A_39_3; - pol B_39_2 = poseidon2_params.MU_2 * A_39_2 + A_39_0 + A_39_1 + A_39_3; - pol B_39_3 = poseidon2_params.MU_3 * A_39_3 + A_39_0 + A_39_1 + A_39_2; + pol commit B_39_0; + pol commit B_39_1; + pol commit B_39_2; + pol commit B_39_3; + + pol SUM_39 = A_39_0 + A_39_1 + A_39_2 + A_39_3; + + sel_poseidon_perm * (B_39_0 - (poseidon2_params.MU_0 * A_39_0 + SUM_39)) = 0; + sel_poseidon_perm * (B_39_1 - (poseidon2_params.MU_1 * A_39_1 + SUM_39)) = 0; + sel_poseidon_perm * (B_39_2 - (poseidon2_params.MU_2 * A_39_2 + SUM_39)) = 0; + sel_poseidon_perm * (B_39_3 - (poseidon2_params.MU_3 * A_39_3 + SUM_39)) = 0; // Round 41 (Partial Round) // ARK (Add Round Constant) @@ -834,10 +1180,17 @@ namespace poseidon2(256); pol A_40_3 = ARK_40_3; // MATRIX (Partial round uses the external matrix) - pol B_40_0 = poseidon2_params.MU_0 * A_40_0 + A_40_1 + A_40_2 + A_40_3; - pol B_40_1 = poseidon2_params.MU_1 * A_40_1 + A_40_0 + A_40_2 + A_40_3; - pol B_40_2 = poseidon2_params.MU_2 * A_40_2 + A_40_0 + A_40_1 + A_40_3; - pol B_40_3 = poseidon2_params.MU_3 * A_40_3 + A_40_0 + A_40_1 + A_40_2; + pol commit B_40_0; + pol commit B_40_1; + pol commit B_40_2; + pol commit B_40_3; + + pol SUM_40 = A_40_0 + A_40_1 + A_40_2 + A_40_3; + + sel_poseidon_perm * (B_40_0 - (poseidon2_params.MU_0 * A_40_0 + SUM_40)) = 0; + sel_poseidon_perm * (B_40_1 - (poseidon2_params.MU_1 * A_40_1 + SUM_40)) = 0; + sel_poseidon_perm * (B_40_2 - (poseidon2_params.MU_2 * A_40_2 + SUM_40)) = 0; + sel_poseidon_perm * (B_40_3 - (poseidon2_params.MU_3 * A_40_3 + SUM_40)) = 0; // Round 42 (Partial Round) // ARK (Add Round Constant) @@ -853,10 +1206,17 @@ namespace poseidon2(256); pol A_41_3 = ARK_41_3; // MATRIX (Partial round uses the external matrix) - pol B_41_0 = poseidon2_params.MU_0 * A_41_0 + A_41_1 + A_41_2 + A_41_3; - pol B_41_1 = poseidon2_params.MU_1 * A_41_1 + A_41_0 + A_41_2 + A_41_3; - pol B_41_2 = poseidon2_params.MU_2 * A_41_2 + A_41_0 + A_41_1 + A_41_3; - pol B_41_3 = poseidon2_params.MU_3 * A_41_3 + A_41_0 + A_41_1 + A_41_2; + pol commit B_41_0; + pol commit B_41_1; + pol commit B_41_2; + pol commit B_41_3; + + pol SUM_41 = A_41_0 + A_41_1 + A_41_2 + A_41_3; + + sel_poseidon_perm * (B_41_0 - (poseidon2_params.MU_0 * A_41_0 + SUM_41)) = 0; + sel_poseidon_perm * (B_41_1 - (poseidon2_params.MU_1 * A_41_1 + SUM_41)) = 0; + sel_poseidon_perm * (B_41_2 - (poseidon2_params.MU_2 * A_41_2 + SUM_41)) = 0; + sel_poseidon_perm * (B_41_3 - (poseidon2_params.MU_3 * A_41_3 + SUM_41)) = 0; // Round 43 (Partial Round) // ARK (Add Round Constant) @@ -872,10 +1232,17 @@ namespace poseidon2(256); pol A_42_3 = ARK_42_3; // MATRIX (Partial round uses the external matrix) - pol B_42_0 = poseidon2_params.MU_0 * A_42_0 + A_42_1 + A_42_2 + A_42_3; - pol B_42_1 = poseidon2_params.MU_1 * A_42_1 + A_42_0 + A_42_2 + A_42_3; - pol B_42_2 = poseidon2_params.MU_2 * A_42_2 + A_42_0 + A_42_1 + A_42_3; - pol B_42_3 = poseidon2_params.MU_3 * A_42_3 + A_42_0 + A_42_1 + A_42_2; + pol commit B_42_0; + pol commit B_42_1; + pol commit B_42_2; + pol commit B_42_3; + + pol SUM_42 = A_42_0 + A_42_1 + A_42_2 + A_42_3; + + sel_poseidon_perm * (B_42_0 - (poseidon2_params.MU_0 * A_42_0 + SUM_42)) = 0; + sel_poseidon_perm * (B_42_1 - (poseidon2_params.MU_1 * A_42_1 + SUM_42)) = 0; + sel_poseidon_perm * (B_42_2 - (poseidon2_params.MU_2 * A_42_2 + SUM_42)) = 0; + sel_poseidon_perm * (B_42_3 - (poseidon2_params.MU_3 * A_42_3 + SUM_42)) = 0; // Round 44 (Partial Round) // ARK (Add Round Constant) @@ -891,10 +1258,17 @@ namespace poseidon2(256); pol A_43_3 = ARK_43_3; // MATRIX (Partial round uses the external matrix) - pol B_43_0 = poseidon2_params.MU_0 * A_43_0 + A_43_1 + A_43_2 + A_43_3; - pol B_43_1 = poseidon2_params.MU_1 * A_43_1 + A_43_0 + A_43_2 + A_43_3; - pol B_43_2 = poseidon2_params.MU_2 * A_43_2 + A_43_0 + A_43_1 + A_43_3; - pol B_43_3 = poseidon2_params.MU_3 * A_43_3 + A_43_0 + A_43_1 + A_43_2; + pol commit B_43_0; + pol commit B_43_1; + pol commit B_43_2; + pol commit B_43_3; + + pol SUM_43 = A_43_0 + A_43_1 + A_43_2 + A_43_3; + + sel_poseidon_perm * (B_43_0 - (poseidon2_params.MU_0 * A_43_0 + SUM_43)) = 0; + sel_poseidon_perm * (B_43_1 - (poseidon2_params.MU_1 * A_43_1 + SUM_43)) = 0; + sel_poseidon_perm * (B_43_2 - (poseidon2_params.MU_2 * A_43_2 + SUM_43)) = 0; + sel_poseidon_perm * (B_43_3 - (poseidon2_params.MU_3 * A_43_3 + SUM_43)) = 0; // Round 45 (Partial Round) // ARK (Add Round Constant) @@ -910,10 +1284,17 @@ namespace poseidon2(256); pol A_44_3 = ARK_44_3; // MATRIX (Partial round uses the external matrix) - pol B_44_0 = poseidon2_params.MU_0 * A_44_0 + A_44_1 + A_44_2 + A_44_3; - pol B_44_1 = poseidon2_params.MU_1 * A_44_1 + A_44_0 + A_44_2 + A_44_3; - pol B_44_2 = poseidon2_params.MU_2 * A_44_2 + A_44_0 + A_44_1 + A_44_3; - pol B_44_3 = poseidon2_params.MU_3 * A_44_3 + A_44_0 + A_44_1 + A_44_2; + pol commit B_44_0; + pol commit B_44_1; + pol commit B_44_2; + pol commit B_44_3; + + pol SUM_44 = A_44_0 + A_44_1 + A_44_2 + A_44_3; + + sel_poseidon_perm * (B_44_0 - (poseidon2_params.MU_0 * A_44_0 + SUM_44)) = 0; + sel_poseidon_perm * (B_44_1 - (poseidon2_params.MU_1 * A_44_1 + SUM_44)) = 0; + sel_poseidon_perm * (B_44_2 - (poseidon2_params.MU_2 * A_44_2 + SUM_44)) = 0; + sel_poseidon_perm * (B_44_3 - (poseidon2_params.MU_3 * A_44_3 + SUM_44)) = 0; // Round 46 (Partial Round) // ARK (Add Round Constant) @@ -929,10 +1310,17 @@ namespace poseidon2(256); pol A_45_3 = ARK_45_3; // MATRIX (Partial round uses the external matrix) - pol B_45_0 = poseidon2_params.MU_0 * A_45_0 + A_45_1 + A_45_2 + A_45_3; - pol B_45_1 = poseidon2_params.MU_1 * A_45_1 + A_45_0 + A_45_2 + A_45_3; - pol B_45_2 = poseidon2_params.MU_2 * A_45_2 + A_45_0 + A_45_1 + A_45_3; - pol B_45_3 = poseidon2_params.MU_3 * A_45_3 + A_45_0 + A_45_1 + A_45_2; + pol commit B_45_0; + pol commit B_45_1; + pol commit B_45_2; + pol commit B_45_3; + + pol SUM_45 = A_45_0 + A_45_1 + A_45_2 + A_45_3; + + sel_poseidon_perm * (B_45_0 - (poseidon2_params.MU_0 * A_45_0 + SUM_45)) = 0; + sel_poseidon_perm * (B_45_1 - (poseidon2_params.MU_1 * A_45_1 + SUM_45)) = 0; + sel_poseidon_perm * (B_45_2 - (poseidon2_params.MU_2 * A_45_2 + SUM_45)) = 0; + sel_poseidon_perm * (B_45_3 - (poseidon2_params.MU_3 * A_45_3 + SUM_45)) = 0; // Round 47 (Partial Round) // ARK (Add Round Constant) @@ -948,10 +1336,17 @@ namespace poseidon2(256); pol A_46_3 = ARK_46_3; // MATRIX (Partial round uses the external matrix) - pol B_46_0 = poseidon2_params.MU_0 * A_46_0 + A_46_1 + A_46_2 + A_46_3; - pol B_46_1 = poseidon2_params.MU_1 * A_46_1 + A_46_0 + A_46_2 + A_46_3; - pol B_46_2 = poseidon2_params.MU_2 * A_46_2 + A_46_0 + A_46_1 + A_46_3; - pol B_46_3 = poseidon2_params.MU_3 * A_46_3 + A_46_0 + A_46_1 + A_46_2; + pol commit B_46_0; + pol commit B_46_1; + pol commit B_46_2; + pol commit B_46_3; + + pol SUM_46 = A_46_0 + A_46_1 + A_46_2 + A_46_3; + + sel_poseidon_perm * (B_46_0 - (poseidon2_params.MU_0 * A_46_0 + SUM_46)) = 0; + sel_poseidon_perm * (B_46_1 - (poseidon2_params.MU_1 * A_46_1 + SUM_46)) = 0; + sel_poseidon_perm * (B_46_2 - (poseidon2_params.MU_2 * A_46_2 + SUM_46)) = 0; + sel_poseidon_perm * (B_46_3 - (poseidon2_params.MU_3 * A_46_3 + SUM_46)) = 0; // Round 48 (Partial Round) // ARK (Add Round Constant) @@ -967,10 +1362,17 @@ namespace poseidon2(256); pol A_47_3 = ARK_47_3; // MATRIX (Partial round uses the external matrix) - pol B_47_0 = poseidon2_params.MU_0 * A_47_0 + A_47_1 + A_47_2 + A_47_3; - pol B_47_1 = poseidon2_params.MU_1 * A_47_1 + A_47_0 + A_47_2 + A_47_3; - pol B_47_2 = poseidon2_params.MU_2 * A_47_2 + A_47_0 + A_47_1 + A_47_3; - pol B_47_3 = poseidon2_params.MU_3 * A_47_3 + A_47_0 + A_47_1 + A_47_2; + pol commit B_47_0; + pol commit B_47_1; + pol commit B_47_2; + pol commit B_47_3; + + pol SUM_47 = A_47_0 + A_47_1 + A_47_2 + A_47_3; + + sel_poseidon_perm * (B_47_0 - (poseidon2_params.MU_0 * A_47_0 + SUM_47)) = 0; + sel_poseidon_perm * (B_47_1 - (poseidon2_params.MU_1 * A_47_1 + SUM_47)) = 0; + sel_poseidon_perm * (B_47_2 - (poseidon2_params.MU_2 * A_47_2 + SUM_47)) = 0; + sel_poseidon_perm * (B_47_3 - (poseidon2_params.MU_3 * A_47_3 + SUM_47)) = 0; // Round 49 (Partial Round) // ARK (Add Round Constant) @@ -986,10 +1388,17 @@ namespace poseidon2(256); pol A_48_3 = ARK_48_3; // MATRIX (Partial round uses the external matrix) - pol B_48_0 = poseidon2_params.MU_0 * A_48_0 + A_48_1 + A_48_2 + A_48_3; - pol B_48_1 = poseidon2_params.MU_1 * A_48_1 + A_48_0 + A_48_2 + A_48_3; - pol B_48_2 = poseidon2_params.MU_2 * A_48_2 + A_48_0 + A_48_1 + A_48_3; - pol B_48_3 = poseidon2_params.MU_3 * A_48_3 + A_48_0 + A_48_1 + A_48_2; + pol commit B_48_0; + pol commit B_48_1; + pol commit B_48_2; + pol commit B_48_3; + + pol SUM_48 = A_48_0 + A_48_1 + A_48_2 + A_48_3; + + sel_poseidon_perm * (B_48_0 - (poseidon2_params.MU_0 * A_48_0 + SUM_48)) = 0; + sel_poseidon_perm * (B_48_1 - (poseidon2_params.MU_1 * A_48_1 + SUM_48)) = 0; + sel_poseidon_perm * (B_48_2 - (poseidon2_params.MU_2 * A_48_2 + SUM_48)) = 0; + sel_poseidon_perm * (B_48_3 - (poseidon2_params.MU_3 * A_48_3 + SUM_48)) = 0; // Round 50 (Partial Round) // ARK (Add Round Constant) @@ -1005,10 +1414,17 @@ namespace poseidon2(256); pol A_49_3 = ARK_49_3; // MATRIX (Partial round uses the external matrix) - pol B_49_0 = poseidon2_params.MU_0 * A_49_0 + A_49_1 + A_49_2 + A_49_3; - pol B_49_1 = poseidon2_params.MU_1 * A_49_1 + A_49_0 + A_49_2 + A_49_3; - pol B_49_2 = poseidon2_params.MU_2 * A_49_2 + A_49_0 + A_49_1 + A_49_3; - pol B_49_3 = poseidon2_params.MU_3 * A_49_3 + A_49_0 + A_49_1 + A_49_2; + pol commit B_49_0; + pol commit B_49_1; + pol commit B_49_2; + pol commit B_49_3; + + pol SUM_49 = A_49_0 + A_49_1 + A_49_2 + A_49_3; + + sel_poseidon_perm * (B_49_0 - (poseidon2_params.MU_0 * A_49_0 + SUM_49)) = 0; + sel_poseidon_perm * (B_49_1 - (poseidon2_params.MU_1 * A_49_1 + SUM_49)) = 0; + sel_poseidon_perm * (B_49_2 - (poseidon2_params.MU_2 * A_49_2 + SUM_49)) = 0; + sel_poseidon_perm * (B_49_3 - (poseidon2_params.MU_3 * A_49_3 + SUM_49)) = 0; // Round 51 (Partial Round) // ARK (Add Round Constant) @@ -1024,10 +1440,17 @@ namespace poseidon2(256); pol A_50_3 = ARK_50_3; // MATRIX (Partial round uses the external matrix) - pol B_50_0 = poseidon2_params.MU_0 * A_50_0 + A_50_1 + A_50_2 + A_50_3; - pol B_50_1 = poseidon2_params.MU_1 * A_50_1 + A_50_0 + A_50_2 + A_50_3; - pol B_50_2 = poseidon2_params.MU_2 * A_50_2 + A_50_0 + A_50_1 + A_50_3; - pol B_50_3 = poseidon2_params.MU_3 * A_50_3 + A_50_0 + A_50_1 + A_50_2; + pol commit B_50_0; + pol commit B_50_1; + pol commit B_50_2; + pol commit B_50_3; + + pol SUM_50 = A_50_0 + A_50_1 + A_50_2 + A_50_3; + + sel_poseidon_perm * (B_50_0 - (poseidon2_params.MU_0 * A_50_0 + SUM_50)) = 0; + sel_poseidon_perm * (B_50_1 - (poseidon2_params.MU_1 * A_50_1 + SUM_50)) = 0; + sel_poseidon_perm * (B_50_2 - (poseidon2_params.MU_2 * A_50_2 + SUM_50)) = 0; + sel_poseidon_perm * (B_50_3 - (poseidon2_params.MU_3 * A_50_3 + SUM_50)) = 0; // Round 52 (Partial Round) // ARK (Add Round Constant) @@ -1043,10 +1466,17 @@ namespace poseidon2(256); pol A_51_3 = ARK_51_3; // MATRIX (Partial round uses the external matrix) - pol B_51_0 = poseidon2_params.MU_0 * A_51_0 + A_51_1 + A_51_2 + A_51_3; - pol B_51_1 = poseidon2_params.MU_1 * A_51_1 + A_51_0 + A_51_2 + A_51_3; - pol B_51_2 = poseidon2_params.MU_2 * A_51_2 + A_51_0 + A_51_1 + A_51_3; - pol B_51_3 = poseidon2_params.MU_3 * A_51_3 + A_51_0 + A_51_1 + A_51_2; + pol commit B_51_0; + pol commit B_51_1; + pol commit B_51_2; + pol commit B_51_3; + + pol SUM_51 = A_51_0 + A_51_1 + A_51_2 + A_51_3; + + sel_poseidon_perm * (B_51_0 - (poseidon2_params.MU_0 * A_51_0 + SUM_51)) = 0; + sel_poseidon_perm * (B_51_1 - (poseidon2_params.MU_1 * A_51_1 + SUM_51)) = 0; + sel_poseidon_perm * (B_51_2 - (poseidon2_params.MU_2 * A_51_2 + SUM_51)) = 0; + sel_poseidon_perm * (B_51_3 - (poseidon2_params.MU_3 * A_51_3 + SUM_51)) = 0; // Round 53 (Partial Round) // ARK (Add Round Constant) @@ -1062,10 +1492,17 @@ namespace poseidon2(256); pol A_52_3 = ARK_52_3; // MATRIX (Partial round uses the external matrix) - pol B_52_0 = poseidon2_params.MU_0 * A_52_0 + A_52_1 + A_52_2 + A_52_3; - pol B_52_1 = poseidon2_params.MU_1 * A_52_1 + A_52_0 + A_52_2 + A_52_3; - pol B_52_2 = poseidon2_params.MU_2 * A_52_2 + A_52_0 + A_52_1 + A_52_3; - pol B_52_3 = poseidon2_params.MU_3 * A_52_3 + A_52_0 + A_52_1 + A_52_2; + pol commit B_52_0; + pol commit B_52_1; + pol commit B_52_2; + pol commit B_52_3; + + pol SUM_52 = A_52_0 + A_52_1 + A_52_2 + A_52_3; + + sel_poseidon_perm * (B_52_0 - (poseidon2_params.MU_0 * A_52_0 + SUM_52)) = 0; + sel_poseidon_perm * (B_52_1 - (poseidon2_params.MU_1 * A_52_1 + SUM_52)) = 0; + sel_poseidon_perm * (B_52_2 - (poseidon2_params.MU_2 * A_52_2 + SUM_52)) = 0; + sel_poseidon_perm * (B_52_3 - (poseidon2_params.MU_3 * A_52_3 + SUM_52)) = 0; // Round 54 (Partial Round) // ARK (Add Round Constant) @@ -1081,10 +1518,17 @@ namespace poseidon2(256); pol A_53_3 = ARK_53_3; // MATRIX (Partial round uses the external matrix) - pol B_53_0 = poseidon2_params.MU_0 * A_53_0 + A_53_1 + A_53_2 + A_53_3; - pol B_53_1 = poseidon2_params.MU_1 * A_53_1 + A_53_0 + A_53_2 + A_53_3; - pol B_53_2 = poseidon2_params.MU_2 * A_53_2 + A_53_0 + A_53_1 + A_53_3; - pol B_53_3 = poseidon2_params.MU_3 * A_53_3 + A_53_0 + A_53_1 + A_53_2; + pol commit B_53_0; + pol commit B_53_1; + pol commit B_53_2; + pol commit B_53_3; + + pol SUM_53 = A_53_0 + A_53_1 + A_53_2 + A_53_3; + + sel_poseidon_perm * (B_53_0 - (poseidon2_params.MU_0 * A_53_0 + SUM_53)) = 0; + sel_poseidon_perm * (B_53_1 - (poseidon2_params.MU_1 * A_53_1 + SUM_53)) = 0; + sel_poseidon_perm * (B_53_2 - (poseidon2_params.MU_2 * A_53_2 + SUM_53)) = 0; + sel_poseidon_perm * (B_53_3 - (poseidon2_params.MU_3 * A_53_3 + SUM_53)) = 0; // Round 55 (Partial Round) // ARK (Add Round Constant) @@ -1100,10 +1544,17 @@ namespace poseidon2(256); pol A_54_3 = ARK_54_3; // MATRIX (Partial round uses the external matrix) - pol B_54_0 = poseidon2_params.MU_0 * A_54_0 + A_54_1 + A_54_2 + A_54_3; - pol B_54_1 = poseidon2_params.MU_1 * A_54_1 + A_54_0 + A_54_2 + A_54_3; - pol B_54_2 = poseidon2_params.MU_2 * A_54_2 + A_54_0 + A_54_1 + A_54_3; - pol B_54_3 = poseidon2_params.MU_3 * A_54_3 + A_54_0 + A_54_1 + A_54_2; + pol commit B_54_0; + pol commit B_54_1; + pol commit B_54_2; + pol commit B_54_3; + + pol SUM_54 = A_54_0 + A_54_1 + A_54_2 + A_54_3; + + sel_poseidon_perm * (B_54_0 - (poseidon2_params.MU_0 * A_54_0 + SUM_54)) = 0; + sel_poseidon_perm * (B_54_1 - (poseidon2_params.MU_1 * A_54_1 + SUM_54)) = 0; + sel_poseidon_perm * (B_54_2 - (poseidon2_params.MU_2 * A_54_2 + SUM_54)) = 0; + sel_poseidon_perm * (B_54_3 - (poseidon2_params.MU_3 * A_54_3 + SUM_54)) = 0; // Round 56 (Partial Round) // ARK (Add Round Constant) @@ -1119,10 +1570,17 @@ namespace poseidon2(256); pol A_55_3 = ARK_55_3; // MATRIX (Partial round uses the external matrix) - pol B_55_0 = poseidon2_params.MU_0 * A_55_0 + A_55_1 + A_55_2 + A_55_3; - pol B_55_1 = poseidon2_params.MU_1 * A_55_1 + A_55_0 + A_55_2 + A_55_3; - pol B_55_2 = poseidon2_params.MU_2 * A_55_2 + A_55_0 + A_55_1 + A_55_3; - pol B_55_3 = poseidon2_params.MU_3 * A_55_3 + A_55_0 + A_55_1 + A_55_2; + pol commit B_55_0; + pol commit B_55_1; + pol commit B_55_2; + pol commit B_55_3; + + pol SUM_55 = A_55_0 + A_55_1 + A_55_2 + A_55_3; + + sel_poseidon_perm * (B_55_0 - (poseidon2_params.MU_0 * A_55_0 + SUM_55)) = 0; + sel_poseidon_perm * (B_55_1 - (poseidon2_params.MU_1 * A_55_1 + SUM_55)) = 0; + sel_poseidon_perm * (B_55_2 - (poseidon2_params.MU_2 * A_55_2 + SUM_55)) = 0; + sel_poseidon_perm * (B_55_3 - (poseidon2_params.MU_3 * A_55_3 + SUM_55)) = 0; // Round 57 (Partial Round) // ARK (Add Round Constant) @@ -1138,10 +1596,17 @@ namespace poseidon2(256); pol A_56_3 = ARK_56_3; // MATRIX (Partial round uses the external matrix) - pol B_56_0 = poseidon2_params.MU_0 * A_56_0 + A_56_1 + A_56_2 + A_56_3; - pol B_56_1 = poseidon2_params.MU_1 * A_56_1 + A_56_0 + A_56_2 + A_56_3; - pol B_56_2 = poseidon2_params.MU_2 * A_56_2 + A_56_0 + A_56_1 + A_56_3; - pol B_56_3 = poseidon2_params.MU_3 * A_56_3 + A_56_0 + A_56_1 + A_56_2; + pol commit B_56_0; + pol commit B_56_1; + pol commit B_56_2; + pol commit B_56_3; + + pol SUM_56 = A_56_0 + A_56_1 + A_56_2 + A_56_3; + + sel_poseidon_perm * (B_56_0 - (poseidon2_params.MU_0 * A_56_0 + SUM_56)) = 0; + sel_poseidon_perm * (B_56_1 - (poseidon2_params.MU_1 * A_56_1 + SUM_56)) = 0; + sel_poseidon_perm * (B_56_2 - (poseidon2_params.MU_2 * A_56_2 + SUM_56)) = 0; + sel_poseidon_perm * (B_56_3 - (poseidon2_params.MU_3 * A_56_3 + SUM_56)) = 0; // Round 58 (Partial Round) // ARK (Add Round Constant) @@ -1157,10 +1622,17 @@ namespace poseidon2(256); pol A_57_3 = ARK_57_3; // MATRIX (Partial round uses the external matrix) - pol B_57_0 = poseidon2_params.MU_0 * A_57_0 + A_57_1 + A_57_2 + A_57_3; - pol B_57_1 = poseidon2_params.MU_1 * A_57_1 + A_57_0 + A_57_2 + A_57_3; - pol B_57_2 = poseidon2_params.MU_2 * A_57_2 + A_57_0 + A_57_1 + A_57_3; - pol B_57_3 = poseidon2_params.MU_3 * A_57_3 + A_57_0 + A_57_1 + A_57_2; + pol commit B_57_0; + pol commit B_57_1; + pol commit B_57_2; + pol commit B_57_3; + + pol SUM_57 = A_57_0 + A_57_1 + A_57_2 + A_57_3; + + sel_poseidon_perm * (B_57_0 - (poseidon2_params.MU_0 * A_57_0 + SUM_57)) = 0; + sel_poseidon_perm * (B_57_1 - (poseidon2_params.MU_1 * A_57_1 + SUM_57)) = 0; + sel_poseidon_perm * (B_57_2 - (poseidon2_params.MU_2 * A_57_2 + SUM_57)) = 0; + sel_poseidon_perm * (B_57_3 - (poseidon2_params.MU_3 * A_57_3 + SUM_57)) = 0; // Round 59 (Partial Round) // ARK (Add Round Constant) @@ -1176,10 +1648,17 @@ namespace poseidon2(256); pol A_58_3 = ARK_58_3; // MATRIX (Partial round uses the external matrix) - pol B_58_0 = poseidon2_params.MU_0 * A_58_0 + A_58_1 + A_58_2 + A_58_3; - pol B_58_1 = poseidon2_params.MU_1 * A_58_1 + A_58_0 + A_58_2 + A_58_3; - pol B_58_2 = poseidon2_params.MU_2 * A_58_2 + A_58_0 + A_58_1 + A_58_3; - pol B_58_3 = poseidon2_params.MU_3 * A_58_3 + A_58_0 + A_58_1 + A_58_2; + pol commit B_58_0; + pol commit B_58_1; + pol commit B_58_2; + pol commit B_58_3; + + pol SUM_58 = A_58_0 + A_58_1 + A_58_2 + A_58_3; + + sel_poseidon_perm * (B_58_0 - (poseidon2_params.MU_0 * A_58_0 + SUM_58)) = 0; + sel_poseidon_perm * (B_58_1 - (poseidon2_params.MU_1 * A_58_1 + SUM_58)) = 0; + sel_poseidon_perm * (B_58_2 - (poseidon2_params.MU_2 * A_58_2 + SUM_58)) = 0; + sel_poseidon_perm * (B_58_3 - (poseidon2_params.MU_3 * A_58_3 + SUM_58)) = 0; // Round 60 (Partial Round) // ARK (Add Round Constant) @@ -1195,10 +1674,17 @@ namespace poseidon2(256); pol A_59_3 = ARK_59_3; // MATRIX (Partial round uses the external matrix) - pol B_59_0 = poseidon2_params.MU_0 * A_59_0 + A_59_1 + A_59_2 + A_59_3; - pol B_59_1 = poseidon2_params.MU_1 * A_59_1 + A_59_0 + A_59_2 + A_59_3; - pol B_59_2 = poseidon2_params.MU_2 * A_59_2 + A_59_0 + A_59_1 + A_59_3; - pol B_59_3 = poseidon2_params.MU_3 * A_59_3 + A_59_0 + A_59_1 + A_59_2; + pol commit B_59_0; + pol commit B_59_1; + pol commit B_59_2; + pol commit B_59_3; + + pol SUM_59 = A_59_0 + A_59_1 + A_59_2 + A_59_3; + + sel_poseidon_perm * (B_59_0 - (poseidon2_params.MU_0 * A_59_0 + SUM_59)) = 0; + sel_poseidon_perm * (B_59_1 - (poseidon2_params.MU_1 * A_59_1 + SUM_59)) = 0; + sel_poseidon_perm * (B_59_2 - (poseidon2_params.MU_2 * A_59_2 + SUM_59)) = 0; + sel_poseidon_perm * (B_59_3 - (poseidon2_params.MU_3 * A_59_3 + SUM_59)) = 0; ///////////////////////////////////////////////////// // FINAL FULL ROUND (4 ROUNDS) @@ -1217,14 +1703,19 @@ namespace poseidon2(256); pol A_60_3 = ARK_60_3 * ARK_60_3 * ARK_60_3 * ARK_60_3 * ARK_60_3; // MATRIX (Full round uses the external matrix) + pol commit T_60_4; + pol commit T_60_5; + pol commit T_60_6; + pol commit T_60_7; + pol T_60_0 = A_60_0 + A_60_1; pol T_60_1 = A_60_2 + A_60_3; - pol T_60_2 = 2 * A_60_1 + T_60_0; + pol T_60_2 = 2 * A_60_1 + T_60_1; pol T_60_3 = 2 * A_60_3 + T_60_0; - pol T_60_4 = 4 * T_60_1 + T_60_3; - pol T_60_5 = 4 * T_60_0 + T_60_2; - pol T_60_6 = T_60_3 + T_60_5; - pol T_60_7 = T_60_2 + T_60_4; + sel_poseidon_perm * (T_60_4 - (4 * T_60_1 + T_60_3)) = 0; + sel_poseidon_perm * (T_60_5 - (4 * T_60_0 + T_60_2)) = 0; + sel_poseidon_perm * (T_60_6 - (T_60_3 + T_60_5)) = 0; + sel_poseidon_perm * (T_60_7 - (T_60_2 + T_60_4)) = 0; // Round 62 (Full Round) // ARK (Add Round Constant) @@ -1240,14 +1731,19 @@ namespace poseidon2(256); pol A_61_3 = ARK_61_3 * ARK_61_3 * ARK_61_3 * ARK_61_3 * ARK_61_3; // MATRIX (Full round uses the external matrix) + pol commit T_61_4; + pol commit T_61_5; + pol commit T_61_6; + pol commit T_61_7; + pol T_61_0 = A_61_0 + A_61_1; pol T_61_1 = A_61_2 + A_61_3; - pol T_61_2 = 2 * A_61_1 + T_61_0; + pol T_61_2 = 2 * A_61_1 + T_61_1; pol T_61_3 = 2 * A_61_3 + T_61_0; - pol T_61_4 = 4 * T_61_1 + T_61_3; - pol T_61_5 = 4 * T_61_0 + T_61_2; - pol T_61_6 = T_61_3 + T_61_5; - pol T_61_7 = T_61_2 + T_61_4; + sel_poseidon_perm * (T_61_4 - (4 * T_61_1 + T_61_3)) = 0; + sel_poseidon_perm * (T_61_5 - (4 * T_61_0 + T_61_2)) = 0; + sel_poseidon_perm * (T_61_6 - (T_61_3 + T_61_5)) = 0; + sel_poseidon_perm * (T_61_7 - (T_61_2 + T_61_4)) = 0; // Round 63 (Full Round) // ARK (Add Round Constant) @@ -1263,14 +1759,19 @@ namespace poseidon2(256); pol A_62_3 = ARK_62_3 * ARK_62_3 * ARK_62_3 * ARK_62_3 * ARK_62_3; // MATRIX (Full round uses the external matrix) + pol commit T_62_4; + pol commit T_62_5; + pol commit T_62_6; + pol commit T_62_7; + pol T_62_0 = A_62_0 + A_62_1; pol T_62_1 = A_62_2 + A_62_3; - pol T_62_2 = 2 * A_62_1 + T_62_0; + pol T_62_2 = 2 * A_62_1 + T_62_1; pol T_62_3 = 2 * A_62_3 + T_62_0; - pol T_62_4 = 4 * T_62_1 + T_62_3; - pol T_62_5 = 4 * T_62_0 + T_62_2; - pol T_62_6 = T_62_3 + T_62_5; - pol T_62_7 = T_62_2 + T_62_4; + sel_poseidon_perm * (T_62_4 - (4 * T_62_1 + T_62_3)) = 0; + sel_poseidon_perm * (T_62_5 - (4 * T_62_0 + T_62_2)) = 0; + sel_poseidon_perm * (T_62_6 - (T_62_3 + T_62_5)) = 0; + sel_poseidon_perm * (T_62_7 - (T_62_2 + T_62_4)) = 0; // Round 64 (Full Round) // ARK (Add Round Constant) @@ -1286,20 +1787,25 @@ namespace poseidon2(256); pol A_63_3 = ARK_63_3 * ARK_63_3 * ARK_63_3 * ARK_63_3 * ARK_63_3; // MATRIX (Full round uses the external matrix) + pol commit T_63_4; + pol commit T_63_5; + pol commit T_63_6; + pol commit T_63_7; + pol T_63_0 = A_63_0 + A_63_1; pol T_63_1 = A_63_2 + A_63_3; - pol T_63_2 = 2 * A_63_1 + T_63_0; + pol T_63_2 = 2 * A_63_1 + T_63_1; pol T_63_3 = 2 * A_63_3 + T_63_0; - pol T_63_4 = 4 * T_63_1 + T_63_3; - pol T_63_5 = 4 * T_63_0 + T_63_2; - pol T_63_6 = T_63_3 + T_63_5; - pol T_63_7 = T_63_2 + T_63_4; + sel_poseidon_perm * (T_63_4 - (4 * T_63_1 + T_63_3)) = 0; + sel_poseidon_perm * (T_63_5 - (4 * T_63_0 + T_63_2)) = 0; + sel_poseidon_perm * (T_63_6 - (T_63_3 + T_63_5)) = 0; + sel_poseidon_perm * (T_63_7 - (T_63_2 + T_63_4)) = 0; ///////////////////////////////////////////////////// // PERMUTATION END ///////////////////////////////////////////////////// // Check output against claimed output - b_0 - T_63_6 = 0; - // b_1 - T_63_5 = 0; - // b_2 - T_63_7 = 0; - // b_3 - T_63_4 = 0; + sel_poseidon_perm * (a_0' - T_63_6) = 0; + sel_poseidon_perm * (a_1' - T_63_5) = 0; + sel_poseidon_perm * (a_2' - T_63_7) = 0; + sel_poseidon_perm * (a_3' - T_63_4) = 0; diff --git a/barretenberg/cpp/pil/avm/main.pil b/barretenberg/cpp/pil/avm/main.pil index c498e242b814..c209e491aae3 100644 --- a/barretenberg/cpp/pil/avm/main.pil +++ b/barretenberg/cpp/pil/avm/main.pil @@ -726,10 +726,12 @@ namespace main(256); // is // sha256.sel_sha256_compression {sha256.clk, sha256.state, sha256.input, sha256.output}; + // Mem_addr_a points to the start of the input array of length 4 + // Mem_addr_b points to the start of the output array of length 4 #[PERM_MAIN_POS2_PERM] - sel_op_poseidon2 {clk, ia, ib} + sel_op_poseidon2 {clk, mem_addr_a, mem_addr_b} is - poseidon2.sel_poseidon_perm {poseidon2.clk, poseidon2.input, poseidon2.output}; + poseidon2.sel_poseidon_perm {poseidon2.clk, poseidon2.input_addr, poseidon2.output_addr}; // This will be enabled when we migrate just to keccakf1600, as getting keccak to work with it is tricky. // #[PERM_MAIN_KECCAK] diff --git a/barretenberg/cpp/pil/avm/mem.pil b/barretenberg/cpp/pil/avm/mem.pil index 781d2891add9..262748f92bd8 100644 --- a/barretenberg/cpp/pil/avm/mem.pil +++ b/barretenberg/cpp/pil/avm/mem.pil @@ -26,6 +26,19 @@ namespace mem(256); pol commit sel_op_c; pol commit sel_op_d; + // We add a set of selectors for the gadgets, TODO: boolean check + // TODO: Can we have a single set of sels for each gadget if we instead have a defined, homogenous MEMORY BUS that gadgets connect to + pol commit sel_op_gadget_a; + pol commit sel_op_gadget_b; + pol commit sel_op_gadget_c; + pol commit sel_op_gadget_d; + + // For simplicity we group these as part of the SEL_DIRECT_MEM_OP_X + pol SEL_DIRECT_MEM_OP_A = sel_op_a + sel_op_gadget_a; + pol SEL_DIRECT_MEM_OP_B = sel_op_b + sel_op_gadget_b; + pol SEL_DIRECT_MEM_OP_C = sel_op_c + sel_op_gadget_c; + pol SEL_DIRECT_MEM_OP_D = sel_op_d + sel_op_gadget_d; + // Indicator of the indirect register pertaining to the memory operation (foreign key to main.sel_resolve_ind_addr_XXX) pol commit sel_resolve_ind_addr_a; pol commit sel_resolve_ind_addr_b; @@ -70,9 +83,10 @@ namespace mem(256); // 2) Ensure that tag, r_in_tag, w_in_tag are properly constrained by the main trace and/or bytecode decomposition // Definition of sel_mem - sel_mem = sel_op_a + sel_op_b + sel_op_c + sel_op_d - + sel_resolve_ind_addr_a + sel_resolve_ind_addr_b + sel_resolve_ind_addr_c + sel_resolve_ind_addr_d - + sel_op_slice; + sel_mem = SEL_DIRECT_MEM_OP_A + SEL_DIRECT_MEM_OP_B + SEL_DIRECT_MEM_OP_C + SEL_DIRECT_MEM_OP_D + + sel_resolve_ind_addr_a + sel_resolve_ind_addr_b + sel_resolve_ind_addr_c + sel_resolve_ind_addr_d + + sel_op_slice; + // Maximum one memory operation enabled per row sel_mem * (sel_mem - 1) = 0; // TODO: might be infered by the main trace @@ -101,7 +115,7 @@ namespace mem(256); pol NUM_SUB_CLK = 12; pol IND_OP = sel_resolve_ind_addr_a + sel_resolve_ind_addr_b + sel_resolve_ind_addr_c + sel_resolve_ind_addr_d; - pol SUB_CLK = sel_mem * (sel_resolve_ind_addr_b + sel_op_b + 2 * (sel_resolve_ind_addr_c + sel_op_c) + 3 * (sel_resolve_ind_addr_d + sel_op_d) + 4 * (1 - IND_OP + rw)); + pol SUB_CLK = sel_mem * (sel_resolve_ind_addr_b + SEL_DIRECT_MEM_OP_B + 2 * (sel_resolve_ind_addr_c + SEL_DIRECT_MEM_OP_C) + 3 * (sel_resolve_ind_addr_d + SEL_DIRECT_MEM_OP_D) + 4 * (1 - IND_OP + rw)); // We need the sel_mem factor as the right factor is not zero when all columns are zero. // Calldata_copy memory slice operations will have a sub_clk value of 8 as rw == 1 which is outside of the range of @@ -231,4 +245,4 @@ namespace mem(256); // Constraint #[MOV_MAIN_SAME_TAG] copies r_in_tag to w_in_tag in the main // trace. Then, #[PERM_MAIN_MEM_C] copies w_in_tag for store operation from Ic. #[MOV_SAME_TAG] - (sel_mov_ia_to_ic + sel_mov_ib_to_ic) * tag_err = 0; // Equivalent to (sel_mov_ia_to_ic + sel_mov_ib_to_ic) * (r_in_tag - tag) = 0 \ No newline at end of file + (sel_mov_ia_to_ic + sel_mov_ib_to_ic) * tag_err = 0; // Equivalent to (sel_mov_ia_to_ic + sel_mov_ib_to_ic) * (r_in_tag - tag) = 0 diff --git a/barretenberg/cpp/src/barretenberg/crypto/poseidon2/poseidon2_permutation.hpp b/barretenberg/cpp/src/barretenberg/crypto/poseidon2/poseidon2_permutation.hpp index 12f79c040d98..2b433da29e28 100644 --- a/barretenberg/cpp/src/barretenberg/crypto/poseidon2/poseidon2_permutation.hpp +++ b/barretenberg/cpp/src/barretenberg/crypto/poseidon2/poseidon2_permutation.hpp @@ -161,4 +161,4 @@ template class Poseidon2Permutation { return current_state; } }; -} // namespace bb::crypto \ No newline at end of file +} // namespace bb::crypto diff --git a/barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp b/barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp index 0fe23d36ff60..964a48c6f6c5 100644 --- a/barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp +++ b/barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp @@ -281,6 +281,10 @@ [[maybe_unused]] auto mem_sel_op_c = View(new_term.mem_sel_op_c); \ [[maybe_unused]] auto mem_sel_op_cmov = View(new_term.mem_sel_op_cmov); \ [[maybe_unused]] auto mem_sel_op_d = View(new_term.mem_sel_op_d); \ + [[maybe_unused]] auto mem_sel_op_gadget_a = View(new_term.mem_sel_op_gadget_a); \ + [[maybe_unused]] auto mem_sel_op_gadget_b = View(new_term.mem_sel_op_gadget_b); \ + [[maybe_unused]] auto mem_sel_op_gadget_c = View(new_term.mem_sel_op_gadget_c); \ + [[maybe_unused]] auto mem_sel_op_gadget_d = View(new_term.mem_sel_op_gadget_d); \ [[maybe_unused]] auto mem_sel_op_slice = View(new_term.mem_sel_op_slice); \ [[maybe_unused]] auto mem_sel_resolve_ind_addr_a = View(new_term.mem_sel_resolve_ind_addr_a); \ [[maybe_unused]] auto mem_sel_resolve_ind_addr_b = View(new_term.mem_sel_resolve_ind_addr_b); \ @@ -298,6 +302,266 @@ [[maybe_unused]] auto pedersen_input = View(new_term.pedersen_input); \ [[maybe_unused]] auto pedersen_output = View(new_term.pedersen_output); \ [[maybe_unused]] auto pedersen_sel_pedersen = View(new_term.pedersen_sel_pedersen); \ + [[maybe_unused]] auto poseidon2_B_10_0 = View(new_term.poseidon2_B_10_0); \ + [[maybe_unused]] auto poseidon2_B_10_1 = View(new_term.poseidon2_B_10_1); \ + [[maybe_unused]] auto poseidon2_B_10_2 = View(new_term.poseidon2_B_10_2); \ + [[maybe_unused]] auto poseidon2_B_10_3 = View(new_term.poseidon2_B_10_3); \ + [[maybe_unused]] auto poseidon2_B_11_0 = View(new_term.poseidon2_B_11_0); \ + [[maybe_unused]] auto poseidon2_B_11_1 = View(new_term.poseidon2_B_11_1); \ + [[maybe_unused]] auto poseidon2_B_11_2 = View(new_term.poseidon2_B_11_2); \ + [[maybe_unused]] auto poseidon2_B_11_3 = View(new_term.poseidon2_B_11_3); \ + [[maybe_unused]] auto poseidon2_B_12_0 = View(new_term.poseidon2_B_12_0); \ + [[maybe_unused]] auto poseidon2_B_12_1 = View(new_term.poseidon2_B_12_1); \ + [[maybe_unused]] auto poseidon2_B_12_2 = View(new_term.poseidon2_B_12_2); \ + [[maybe_unused]] auto poseidon2_B_12_3 = View(new_term.poseidon2_B_12_3); \ + [[maybe_unused]] auto poseidon2_B_13_0 = View(new_term.poseidon2_B_13_0); \ + [[maybe_unused]] auto poseidon2_B_13_1 = View(new_term.poseidon2_B_13_1); \ + [[maybe_unused]] auto poseidon2_B_13_2 = View(new_term.poseidon2_B_13_2); \ + [[maybe_unused]] auto poseidon2_B_13_3 = View(new_term.poseidon2_B_13_3); \ + [[maybe_unused]] auto poseidon2_B_14_0 = View(new_term.poseidon2_B_14_0); \ + [[maybe_unused]] auto poseidon2_B_14_1 = View(new_term.poseidon2_B_14_1); \ + [[maybe_unused]] auto poseidon2_B_14_2 = View(new_term.poseidon2_B_14_2); \ + [[maybe_unused]] auto poseidon2_B_14_3 = View(new_term.poseidon2_B_14_3); \ + [[maybe_unused]] auto poseidon2_B_15_0 = View(new_term.poseidon2_B_15_0); \ + [[maybe_unused]] auto poseidon2_B_15_1 = View(new_term.poseidon2_B_15_1); \ + [[maybe_unused]] auto poseidon2_B_15_2 = View(new_term.poseidon2_B_15_2); \ + [[maybe_unused]] auto poseidon2_B_15_3 = View(new_term.poseidon2_B_15_3); \ + [[maybe_unused]] auto poseidon2_B_16_0 = View(new_term.poseidon2_B_16_0); \ + [[maybe_unused]] auto poseidon2_B_16_1 = View(new_term.poseidon2_B_16_1); \ + [[maybe_unused]] auto poseidon2_B_16_2 = View(new_term.poseidon2_B_16_2); \ + [[maybe_unused]] auto poseidon2_B_16_3 = View(new_term.poseidon2_B_16_3); \ + [[maybe_unused]] auto poseidon2_B_17_0 = View(new_term.poseidon2_B_17_0); \ + [[maybe_unused]] auto poseidon2_B_17_1 = View(new_term.poseidon2_B_17_1); \ + [[maybe_unused]] auto poseidon2_B_17_2 = View(new_term.poseidon2_B_17_2); \ + [[maybe_unused]] auto poseidon2_B_17_3 = View(new_term.poseidon2_B_17_3); \ + [[maybe_unused]] auto poseidon2_B_18_0 = View(new_term.poseidon2_B_18_0); \ + [[maybe_unused]] auto poseidon2_B_18_1 = View(new_term.poseidon2_B_18_1); \ + [[maybe_unused]] auto poseidon2_B_18_2 = View(new_term.poseidon2_B_18_2); \ + [[maybe_unused]] auto poseidon2_B_18_3 = View(new_term.poseidon2_B_18_3); \ + [[maybe_unused]] auto poseidon2_B_19_0 = View(new_term.poseidon2_B_19_0); \ + [[maybe_unused]] auto poseidon2_B_19_1 = View(new_term.poseidon2_B_19_1); \ + [[maybe_unused]] auto poseidon2_B_19_2 = View(new_term.poseidon2_B_19_2); \ + [[maybe_unused]] auto poseidon2_B_19_3 = View(new_term.poseidon2_B_19_3); \ + [[maybe_unused]] auto poseidon2_B_20_0 = View(new_term.poseidon2_B_20_0); \ + [[maybe_unused]] auto poseidon2_B_20_1 = View(new_term.poseidon2_B_20_1); \ + [[maybe_unused]] auto poseidon2_B_20_2 = View(new_term.poseidon2_B_20_2); \ + [[maybe_unused]] auto poseidon2_B_20_3 = View(new_term.poseidon2_B_20_3); \ + [[maybe_unused]] auto poseidon2_B_21_0 = View(new_term.poseidon2_B_21_0); \ + [[maybe_unused]] auto poseidon2_B_21_1 = View(new_term.poseidon2_B_21_1); \ + [[maybe_unused]] auto poseidon2_B_21_2 = View(new_term.poseidon2_B_21_2); \ + [[maybe_unused]] auto poseidon2_B_21_3 = View(new_term.poseidon2_B_21_3); \ + [[maybe_unused]] auto poseidon2_B_22_0 = View(new_term.poseidon2_B_22_0); \ + [[maybe_unused]] auto poseidon2_B_22_1 = View(new_term.poseidon2_B_22_1); \ + [[maybe_unused]] auto poseidon2_B_22_2 = View(new_term.poseidon2_B_22_2); \ + [[maybe_unused]] auto poseidon2_B_22_3 = View(new_term.poseidon2_B_22_3); \ + [[maybe_unused]] auto poseidon2_B_23_0 = View(new_term.poseidon2_B_23_0); \ + [[maybe_unused]] auto poseidon2_B_23_1 = View(new_term.poseidon2_B_23_1); \ + [[maybe_unused]] auto poseidon2_B_23_2 = View(new_term.poseidon2_B_23_2); \ + [[maybe_unused]] auto poseidon2_B_23_3 = View(new_term.poseidon2_B_23_3); \ + [[maybe_unused]] auto poseidon2_B_24_0 = View(new_term.poseidon2_B_24_0); \ + [[maybe_unused]] auto poseidon2_B_24_1 = View(new_term.poseidon2_B_24_1); \ + [[maybe_unused]] auto poseidon2_B_24_2 = View(new_term.poseidon2_B_24_2); \ + [[maybe_unused]] auto poseidon2_B_24_3 = View(new_term.poseidon2_B_24_3); \ + [[maybe_unused]] auto poseidon2_B_25_0 = View(new_term.poseidon2_B_25_0); \ + [[maybe_unused]] auto poseidon2_B_25_1 = View(new_term.poseidon2_B_25_1); \ + [[maybe_unused]] auto poseidon2_B_25_2 = View(new_term.poseidon2_B_25_2); \ + [[maybe_unused]] auto poseidon2_B_25_3 = View(new_term.poseidon2_B_25_3); \ + [[maybe_unused]] auto poseidon2_B_26_0 = View(new_term.poseidon2_B_26_0); \ + [[maybe_unused]] auto poseidon2_B_26_1 = View(new_term.poseidon2_B_26_1); \ + [[maybe_unused]] auto poseidon2_B_26_2 = View(new_term.poseidon2_B_26_2); \ + [[maybe_unused]] auto poseidon2_B_26_3 = View(new_term.poseidon2_B_26_3); \ + [[maybe_unused]] auto poseidon2_B_27_0 = View(new_term.poseidon2_B_27_0); \ + [[maybe_unused]] auto poseidon2_B_27_1 = View(new_term.poseidon2_B_27_1); \ + [[maybe_unused]] auto poseidon2_B_27_2 = View(new_term.poseidon2_B_27_2); \ + [[maybe_unused]] auto poseidon2_B_27_3 = View(new_term.poseidon2_B_27_3); \ + [[maybe_unused]] auto poseidon2_B_28_0 = View(new_term.poseidon2_B_28_0); \ + [[maybe_unused]] auto poseidon2_B_28_1 = View(new_term.poseidon2_B_28_1); \ + [[maybe_unused]] auto poseidon2_B_28_2 = View(new_term.poseidon2_B_28_2); \ + [[maybe_unused]] auto poseidon2_B_28_3 = View(new_term.poseidon2_B_28_3); \ + [[maybe_unused]] auto poseidon2_B_29_0 = View(new_term.poseidon2_B_29_0); \ + [[maybe_unused]] auto poseidon2_B_29_1 = View(new_term.poseidon2_B_29_1); \ + [[maybe_unused]] auto poseidon2_B_29_2 = View(new_term.poseidon2_B_29_2); \ + [[maybe_unused]] auto poseidon2_B_29_3 = View(new_term.poseidon2_B_29_3); \ + [[maybe_unused]] auto poseidon2_B_30_0 = View(new_term.poseidon2_B_30_0); \ + [[maybe_unused]] auto poseidon2_B_30_1 = View(new_term.poseidon2_B_30_1); \ + [[maybe_unused]] auto poseidon2_B_30_2 = View(new_term.poseidon2_B_30_2); \ + [[maybe_unused]] auto poseidon2_B_30_3 = View(new_term.poseidon2_B_30_3); \ + [[maybe_unused]] auto poseidon2_B_31_0 = View(new_term.poseidon2_B_31_0); \ + [[maybe_unused]] auto poseidon2_B_31_1 = View(new_term.poseidon2_B_31_1); \ + [[maybe_unused]] auto poseidon2_B_31_2 = View(new_term.poseidon2_B_31_2); \ + [[maybe_unused]] auto poseidon2_B_31_3 = View(new_term.poseidon2_B_31_3); \ + [[maybe_unused]] auto poseidon2_B_32_0 = View(new_term.poseidon2_B_32_0); \ + [[maybe_unused]] auto poseidon2_B_32_1 = View(new_term.poseidon2_B_32_1); \ + [[maybe_unused]] auto poseidon2_B_32_2 = View(new_term.poseidon2_B_32_2); \ + [[maybe_unused]] auto poseidon2_B_32_3 = View(new_term.poseidon2_B_32_3); \ + [[maybe_unused]] auto poseidon2_B_33_0 = View(new_term.poseidon2_B_33_0); \ + [[maybe_unused]] auto poseidon2_B_33_1 = View(new_term.poseidon2_B_33_1); \ + [[maybe_unused]] auto poseidon2_B_33_2 = View(new_term.poseidon2_B_33_2); \ + [[maybe_unused]] auto poseidon2_B_33_3 = View(new_term.poseidon2_B_33_3); \ + [[maybe_unused]] auto poseidon2_B_34_0 = View(new_term.poseidon2_B_34_0); \ + [[maybe_unused]] auto poseidon2_B_34_1 = View(new_term.poseidon2_B_34_1); \ + [[maybe_unused]] auto poseidon2_B_34_2 = View(new_term.poseidon2_B_34_2); \ + [[maybe_unused]] auto poseidon2_B_34_3 = View(new_term.poseidon2_B_34_3); \ + [[maybe_unused]] auto poseidon2_B_35_0 = View(new_term.poseidon2_B_35_0); \ + [[maybe_unused]] auto poseidon2_B_35_1 = View(new_term.poseidon2_B_35_1); \ + [[maybe_unused]] auto poseidon2_B_35_2 = View(new_term.poseidon2_B_35_2); \ + [[maybe_unused]] auto poseidon2_B_35_3 = View(new_term.poseidon2_B_35_3); \ + [[maybe_unused]] auto poseidon2_B_36_0 = View(new_term.poseidon2_B_36_0); \ + [[maybe_unused]] auto poseidon2_B_36_1 = View(new_term.poseidon2_B_36_1); \ + [[maybe_unused]] auto poseidon2_B_36_2 = View(new_term.poseidon2_B_36_2); \ + [[maybe_unused]] auto poseidon2_B_36_3 = View(new_term.poseidon2_B_36_3); \ + [[maybe_unused]] auto poseidon2_B_37_0 = View(new_term.poseidon2_B_37_0); \ + [[maybe_unused]] auto poseidon2_B_37_1 = View(new_term.poseidon2_B_37_1); \ + [[maybe_unused]] auto poseidon2_B_37_2 = View(new_term.poseidon2_B_37_2); \ + [[maybe_unused]] auto poseidon2_B_37_3 = View(new_term.poseidon2_B_37_3); \ + [[maybe_unused]] auto poseidon2_B_38_0 = View(new_term.poseidon2_B_38_0); \ + [[maybe_unused]] auto poseidon2_B_38_1 = View(new_term.poseidon2_B_38_1); \ + [[maybe_unused]] auto poseidon2_B_38_2 = View(new_term.poseidon2_B_38_2); \ + [[maybe_unused]] auto poseidon2_B_38_3 = View(new_term.poseidon2_B_38_3); \ + [[maybe_unused]] auto poseidon2_B_39_0 = View(new_term.poseidon2_B_39_0); \ + [[maybe_unused]] auto poseidon2_B_39_1 = View(new_term.poseidon2_B_39_1); \ + [[maybe_unused]] auto poseidon2_B_39_2 = View(new_term.poseidon2_B_39_2); \ + [[maybe_unused]] auto poseidon2_B_39_3 = View(new_term.poseidon2_B_39_3); \ + [[maybe_unused]] auto poseidon2_B_40_0 = View(new_term.poseidon2_B_40_0); \ + [[maybe_unused]] auto poseidon2_B_40_1 = View(new_term.poseidon2_B_40_1); \ + [[maybe_unused]] auto poseidon2_B_40_2 = View(new_term.poseidon2_B_40_2); \ + [[maybe_unused]] auto poseidon2_B_40_3 = View(new_term.poseidon2_B_40_3); \ + [[maybe_unused]] auto poseidon2_B_41_0 = View(new_term.poseidon2_B_41_0); \ + [[maybe_unused]] auto poseidon2_B_41_1 = View(new_term.poseidon2_B_41_1); \ + [[maybe_unused]] auto poseidon2_B_41_2 = View(new_term.poseidon2_B_41_2); \ + [[maybe_unused]] auto poseidon2_B_41_3 = View(new_term.poseidon2_B_41_3); \ + [[maybe_unused]] auto poseidon2_B_42_0 = View(new_term.poseidon2_B_42_0); \ + [[maybe_unused]] auto poseidon2_B_42_1 = View(new_term.poseidon2_B_42_1); \ + [[maybe_unused]] auto poseidon2_B_42_2 = View(new_term.poseidon2_B_42_2); \ + [[maybe_unused]] auto poseidon2_B_42_3 = View(new_term.poseidon2_B_42_3); \ + [[maybe_unused]] auto poseidon2_B_43_0 = View(new_term.poseidon2_B_43_0); \ + [[maybe_unused]] auto poseidon2_B_43_1 = View(new_term.poseidon2_B_43_1); \ + [[maybe_unused]] auto poseidon2_B_43_2 = View(new_term.poseidon2_B_43_2); \ + [[maybe_unused]] auto poseidon2_B_43_3 = View(new_term.poseidon2_B_43_3); \ + [[maybe_unused]] auto poseidon2_B_44_0 = View(new_term.poseidon2_B_44_0); \ + [[maybe_unused]] auto poseidon2_B_44_1 = View(new_term.poseidon2_B_44_1); \ + [[maybe_unused]] auto poseidon2_B_44_2 = View(new_term.poseidon2_B_44_2); \ + [[maybe_unused]] auto poseidon2_B_44_3 = View(new_term.poseidon2_B_44_3); \ + [[maybe_unused]] auto poseidon2_B_45_0 = View(new_term.poseidon2_B_45_0); \ + [[maybe_unused]] auto poseidon2_B_45_1 = View(new_term.poseidon2_B_45_1); \ + [[maybe_unused]] auto poseidon2_B_45_2 = View(new_term.poseidon2_B_45_2); \ + [[maybe_unused]] auto poseidon2_B_45_3 = View(new_term.poseidon2_B_45_3); \ + [[maybe_unused]] auto poseidon2_B_46_0 = View(new_term.poseidon2_B_46_0); \ + [[maybe_unused]] auto poseidon2_B_46_1 = View(new_term.poseidon2_B_46_1); \ + [[maybe_unused]] auto poseidon2_B_46_2 = View(new_term.poseidon2_B_46_2); \ + [[maybe_unused]] auto poseidon2_B_46_3 = View(new_term.poseidon2_B_46_3); \ + [[maybe_unused]] auto poseidon2_B_47_0 = View(new_term.poseidon2_B_47_0); \ + [[maybe_unused]] auto poseidon2_B_47_1 = View(new_term.poseidon2_B_47_1); \ + [[maybe_unused]] auto poseidon2_B_47_2 = View(new_term.poseidon2_B_47_2); \ + [[maybe_unused]] auto poseidon2_B_47_3 = View(new_term.poseidon2_B_47_3); \ + [[maybe_unused]] auto poseidon2_B_48_0 = View(new_term.poseidon2_B_48_0); \ + [[maybe_unused]] auto poseidon2_B_48_1 = View(new_term.poseidon2_B_48_1); \ + [[maybe_unused]] auto poseidon2_B_48_2 = View(new_term.poseidon2_B_48_2); \ + [[maybe_unused]] auto poseidon2_B_48_3 = View(new_term.poseidon2_B_48_3); \ + [[maybe_unused]] auto poseidon2_B_49_0 = View(new_term.poseidon2_B_49_0); \ + [[maybe_unused]] auto poseidon2_B_49_1 = View(new_term.poseidon2_B_49_1); \ + [[maybe_unused]] auto poseidon2_B_49_2 = View(new_term.poseidon2_B_49_2); \ + [[maybe_unused]] auto poseidon2_B_49_3 = View(new_term.poseidon2_B_49_3); \ + [[maybe_unused]] auto poseidon2_B_4_0 = View(new_term.poseidon2_B_4_0); \ + [[maybe_unused]] auto poseidon2_B_4_1 = View(new_term.poseidon2_B_4_1); \ + [[maybe_unused]] auto poseidon2_B_4_2 = View(new_term.poseidon2_B_4_2); \ + [[maybe_unused]] auto poseidon2_B_4_3 = View(new_term.poseidon2_B_4_3); \ + [[maybe_unused]] auto poseidon2_B_50_0 = View(new_term.poseidon2_B_50_0); \ + [[maybe_unused]] auto poseidon2_B_50_1 = View(new_term.poseidon2_B_50_1); \ + [[maybe_unused]] auto poseidon2_B_50_2 = View(new_term.poseidon2_B_50_2); \ + [[maybe_unused]] auto poseidon2_B_50_3 = View(new_term.poseidon2_B_50_3); \ + [[maybe_unused]] auto poseidon2_B_51_0 = View(new_term.poseidon2_B_51_0); \ + [[maybe_unused]] auto poseidon2_B_51_1 = View(new_term.poseidon2_B_51_1); \ + [[maybe_unused]] auto poseidon2_B_51_2 = View(new_term.poseidon2_B_51_2); \ + [[maybe_unused]] auto poseidon2_B_51_3 = View(new_term.poseidon2_B_51_3); \ + [[maybe_unused]] auto poseidon2_B_52_0 = View(new_term.poseidon2_B_52_0); \ + [[maybe_unused]] auto poseidon2_B_52_1 = View(new_term.poseidon2_B_52_1); \ + [[maybe_unused]] auto poseidon2_B_52_2 = View(new_term.poseidon2_B_52_2); \ + [[maybe_unused]] auto poseidon2_B_52_3 = View(new_term.poseidon2_B_52_3); \ + [[maybe_unused]] auto poseidon2_B_53_0 = View(new_term.poseidon2_B_53_0); \ + [[maybe_unused]] auto poseidon2_B_53_1 = View(new_term.poseidon2_B_53_1); \ + [[maybe_unused]] auto poseidon2_B_53_2 = View(new_term.poseidon2_B_53_2); \ + [[maybe_unused]] auto poseidon2_B_53_3 = View(new_term.poseidon2_B_53_3); \ + [[maybe_unused]] auto poseidon2_B_54_0 = View(new_term.poseidon2_B_54_0); \ + [[maybe_unused]] auto poseidon2_B_54_1 = View(new_term.poseidon2_B_54_1); \ + [[maybe_unused]] auto poseidon2_B_54_2 = View(new_term.poseidon2_B_54_2); \ + [[maybe_unused]] auto poseidon2_B_54_3 = View(new_term.poseidon2_B_54_3); \ + [[maybe_unused]] auto poseidon2_B_55_0 = View(new_term.poseidon2_B_55_0); \ + [[maybe_unused]] auto poseidon2_B_55_1 = View(new_term.poseidon2_B_55_1); \ + [[maybe_unused]] auto poseidon2_B_55_2 = View(new_term.poseidon2_B_55_2); \ + [[maybe_unused]] auto poseidon2_B_55_3 = View(new_term.poseidon2_B_55_3); \ + [[maybe_unused]] auto poseidon2_B_56_0 = View(new_term.poseidon2_B_56_0); \ + [[maybe_unused]] auto poseidon2_B_56_1 = View(new_term.poseidon2_B_56_1); \ + [[maybe_unused]] auto poseidon2_B_56_2 = View(new_term.poseidon2_B_56_2); \ + [[maybe_unused]] auto poseidon2_B_56_3 = View(new_term.poseidon2_B_56_3); \ + [[maybe_unused]] auto poseidon2_B_57_0 = View(new_term.poseidon2_B_57_0); \ + [[maybe_unused]] auto poseidon2_B_57_1 = View(new_term.poseidon2_B_57_1); \ + [[maybe_unused]] auto poseidon2_B_57_2 = View(new_term.poseidon2_B_57_2); \ + [[maybe_unused]] auto poseidon2_B_57_3 = View(new_term.poseidon2_B_57_3); \ + [[maybe_unused]] auto poseidon2_B_58_0 = View(new_term.poseidon2_B_58_0); \ + [[maybe_unused]] auto poseidon2_B_58_1 = View(new_term.poseidon2_B_58_1); \ + [[maybe_unused]] auto poseidon2_B_58_2 = View(new_term.poseidon2_B_58_2); \ + [[maybe_unused]] auto poseidon2_B_58_3 = View(new_term.poseidon2_B_58_3); \ + [[maybe_unused]] auto poseidon2_B_59_0 = View(new_term.poseidon2_B_59_0); \ + [[maybe_unused]] auto poseidon2_B_59_1 = View(new_term.poseidon2_B_59_1); \ + [[maybe_unused]] auto poseidon2_B_59_2 = View(new_term.poseidon2_B_59_2); \ + [[maybe_unused]] auto poseidon2_B_59_3 = View(new_term.poseidon2_B_59_3); \ + [[maybe_unused]] auto poseidon2_B_5_0 = View(new_term.poseidon2_B_5_0); \ + [[maybe_unused]] auto poseidon2_B_5_1 = View(new_term.poseidon2_B_5_1); \ + [[maybe_unused]] auto poseidon2_B_5_2 = View(new_term.poseidon2_B_5_2); \ + [[maybe_unused]] auto poseidon2_B_5_3 = View(new_term.poseidon2_B_5_3); \ + [[maybe_unused]] auto poseidon2_B_6_0 = View(new_term.poseidon2_B_6_0); \ + [[maybe_unused]] auto poseidon2_B_6_1 = View(new_term.poseidon2_B_6_1); \ + [[maybe_unused]] auto poseidon2_B_6_2 = View(new_term.poseidon2_B_6_2); \ + [[maybe_unused]] auto poseidon2_B_6_3 = View(new_term.poseidon2_B_6_3); \ + [[maybe_unused]] auto poseidon2_B_7_0 = View(new_term.poseidon2_B_7_0); \ + [[maybe_unused]] auto poseidon2_B_7_1 = View(new_term.poseidon2_B_7_1); \ + [[maybe_unused]] auto poseidon2_B_7_2 = View(new_term.poseidon2_B_7_2); \ + [[maybe_unused]] auto poseidon2_B_7_3 = View(new_term.poseidon2_B_7_3); \ + [[maybe_unused]] auto poseidon2_B_8_0 = View(new_term.poseidon2_B_8_0); \ + [[maybe_unused]] auto poseidon2_B_8_1 = View(new_term.poseidon2_B_8_1); \ + [[maybe_unused]] auto poseidon2_B_8_2 = View(new_term.poseidon2_B_8_2); \ + [[maybe_unused]] auto poseidon2_B_8_3 = View(new_term.poseidon2_B_8_3); \ + [[maybe_unused]] auto poseidon2_B_9_0 = View(new_term.poseidon2_B_9_0); \ + [[maybe_unused]] auto poseidon2_B_9_1 = View(new_term.poseidon2_B_9_1); \ + [[maybe_unused]] auto poseidon2_B_9_2 = View(new_term.poseidon2_B_9_2); \ + [[maybe_unused]] auto poseidon2_B_9_3 = View(new_term.poseidon2_B_9_3); \ + [[maybe_unused]] auto poseidon2_EXT_LAYER_4 = View(new_term.poseidon2_EXT_LAYER_4); \ + [[maybe_unused]] auto poseidon2_EXT_LAYER_5 = View(new_term.poseidon2_EXT_LAYER_5); \ + [[maybe_unused]] auto poseidon2_EXT_LAYER_6 = View(new_term.poseidon2_EXT_LAYER_6); \ + [[maybe_unused]] auto poseidon2_EXT_LAYER_7 = View(new_term.poseidon2_EXT_LAYER_7); \ + [[maybe_unused]] auto poseidon2_T_0_4 = View(new_term.poseidon2_T_0_4); \ + [[maybe_unused]] auto poseidon2_T_0_5 = View(new_term.poseidon2_T_0_5); \ + [[maybe_unused]] auto poseidon2_T_0_6 = View(new_term.poseidon2_T_0_6); \ + [[maybe_unused]] auto poseidon2_T_0_7 = View(new_term.poseidon2_T_0_7); \ + [[maybe_unused]] auto poseidon2_T_1_4 = View(new_term.poseidon2_T_1_4); \ + [[maybe_unused]] auto poseidon2_T_1_5 = View(new_term.poseidon2_T_1_5); \ + [[maybe_unused]] auto poseidon2_T_1_6 = View(new_term.poseidon2_T_1_6); \ + [[maybe_unused]] auto poseidon2_T_1_7 = View(new_term.poseidon2_T_1_7); \ + [[maybe_unused]] auto poseidon2_T_2_4 = View(new_term.poseidon2_T_2_4); \ + [[maybe_unused]] auto poseidon2_T_2_5 = View(new_term.poseidon2_T_2_5); \ + [[maybe_unused]] auto poseidon2_T_2_6 = View(new_term.poseidon2_T_2_6); \ + [[maybe_unused]] auto poseidon2_T_2_7 = View(new_term.poseidon2_T_2_7); \ + [[maybe_unused]] auto poseidon2_T_3_4 = View(new_term.poseidon2_T_3_4); \ + [[maybe_unused]] auto poseidon2_T_3_5 = View(new_term.poseidon2_T_3_5); \ + [[maybe_unused]] auto poseidon2_T_3_6 = View(new_term.poseidon2_T_3_6); \ + [[maybe_unused]] auto poseidon2_T_3_7 = View(new_term.poseidon2_T_3_7); \ + [[maybe_unused]] auto poseidon2_T_60_4 = View(new_term.poseidon2_T_60_4); \ + [[maybe_unused]] auto poseidon2_T_60_5 = View(new_term.poseidon2_T_60_5); \ + [[maybe_unused]] auto poseidon2_T_60_6 = View(new_term.poseidon2_T_60_6); \ + [[maybe_unused]] auto poseidon2_T_60_7 = View(new_term.poseidon2_T_60_7); \ + [[maybe_unused]] auto poseidon2_T_61_4 = View(new_term.poseidon2_T_61_4); \ + [[maybe_unused]] auto poseidon2_T_61_5 = View(new_term.poseidon2_T_61_5); \ + [[maybe_unused]] auto poseidon2_T_61_6 = View(new_term.poseidon2_T_61_6); \ + [[maybe_unused]] auto poseidon2_T_61_7 = View(new_term.poseidon2_T_61_7); \ + [[maybe_unused]] auto poseidon2_T_62_4 = View(new_term.poseidon2_T_62_4); \ + [[maybe_unused]] auto poseidon2_T_62_5 = View(new_term.poseidon2_T_62_5); \ + [[maybe_unused]] auto poseidon2_T_62_6 = View(new_term.poseidon2_T_62_6); \ + [[maybe_unused]] auto poseidon2_T_62_7 = View(new_term.poseidon2_T_62_7); \ + [[maybe_unused]] auto poseidon2_T_63_4 = View(new_term.poseidon2_T_63_4); \ + [[maybe_unused]] auto poseidon2_T_63_5 = View(new_term.poseidon2_T_63_5); \ + [[maybe_unused]] auto poseidon2_T_63_6 = View(new_term.poseidon2_T_63_6); \ + [[maybe_unused]] auto poseidon2_T_63_7 = View(new_term.poseidon2_T_63_7); \ [[maybe_unused]] auto poseidon2_a_0 = View(new_term.poseidon2_a_0); \ [[maybe_unused]] auto poseidon2_a_1 = View(new_term.poseidon2_a_1); \ [[maybe_unused]] auto poseidon2_a_2 = View(new_term.poseidon2_a_2); \ @@ -307,9 +571,17 @@ [[maybe_unused]] auto poseidon2_b_2 = View(new_term.poseidon2_b_2); \ [[maybe_unused]] auto poseidon2_b_3 = View(new_term.poseidon2_b_3); \ [[maybe_unused]] auto poseidon2_clk = View(new_term.poseidon2_clk); \ - [[maybe_unused]] auto poseidon2_input = View(new_term.poseidon2_input); \ - [[maybe_unused]] auto poseidon2_output = View(new_term.poseidon2_output); \ + [[maybe_unused]] auto poseidon2_in_tag = View(new_term.poseidon2_in_tag); \ + [[maybe_unused]] auto poseidon2_input_addr = View(new_term.poseidon2_input_addr); \ + [[maybe_unused]] auto poseidon2_mem_addr_a = View(new_term.poseidon2_mem_addr_a); \ + [[maybe_unused]] auto poseidon2_mem_addr_b = View(new_term.poseidon2_mem_addr_b); \ + [[maybe_unused]] auto poseidon2_mem_addr_c = View(new_term.poseidon2_mem_addr_c); \ + [[maybe_unused]] auto poseidon2_mem_addr_d = View(new_term.poseidon2_mem_addr_d); \ + [[maybe_unused]] auto poseidon2_mem_op = View(new_term.poseidon2_mem_op); \ + [[maybe_unused]] auto poseidon2_output_addr = View(new_term.poseidon2_output_addr); \ + [[maybe_unused]] auto poseidon2_read_line = View(new_term.poseidon2_read_line); \ [[maybe_unused]] auto poseidon2_sel_poseidon_perm = View(new_term.poseidon2_sel_poseidon_perm); \ + [[maybe_unused]] auto poseidon2_write_line = View(new_term.poseidon2_write_line); \ [[maybe_unused]] auto powers_power_of_2 = View(new_term.powers_power_of_2); \ [[maybe_unused]] auto sha256_clk = View(new_term.sha256_clk); \ [[maybe_unused]] auto sha256_input = View(new_term.sha256_input); \ @@ -327,6 +599,10 @@ [[maybe_unused]] auto slice_sel_start = View(new_term.slice_sel_start); \ [[maybe_unused]] auto slice_space_id = View(new_term.slice_space_id); \ [[maybe_unused]] auto slice_val = View(new_term.slice_val); \ + [[maybe_unused]] auto perm_pos_mem_a = View(new_term.perm_pos_mem_a); \ + [[maybe_unused]] auto perm_pos_mem_b = View(new_term.perm_pos_mem_b); \ + [[maybe_unused]] auto perm_pos_mem_c = View(new_term.perm_pos_mem_c); \ + [[maybe_unused]] auto perm_pos_mem_d = View(new_term.perm_pos_mem_d); \ [[maybe_unused]] auto perm_slice_mem = View(new_term.perm_slice_mem); \ [[maybe_unused]] auto perm_main_alu = View(new_term.perm_main_alu); \ [[maybe_unused]] auto perm_main_bin = View(new_term.perm_main_bin); \ @@ -501,6 +777,12 @@ [[maybe_unused]] auto mem_tag_shift = View(new_term.mem_tag_shift); \ [[maybe_unused]] auto mem_tsp_shift = View(new_term.mem_tsp_shift); \ [[maybe_unused]] auto mem_val_shift = View(new_term.mem_val_shift); \ + [[maybe_unused]] auto poseidon2_a_0_shift = View(new_term.poseidon2_a_0_shift); \ + [[maybe_unused]] auto poseidon2_a_1_shift = View(new_term.poseidon2_a_1_shift); \ + [[maybe_unused]] auto poseidon2_a_2_shift = View(new_term.poseidon2_a_2_shift); \ + [[maybe_unused]] auto poseidon2_a_3_shift = View(new_term.poseidon2_a_3_shift); \ + [[maybe_unused]] auto poseidon2_sel_poseidon_perm_shift = View(new_term.poseidon2_sel_poseidon_perm_shift); \ + [[maybe_unused]] auto poseidon2_write_line_shift = View(new_term.poseidon2_write_line_shift); \ [[maybe_unused]] auto slice_addr_shift = View(new_term.slice_addr_shift); \ [[maybe_unused]] auto slice_clk_shift = View(new_term.slice_clk_shift); \ [[maybe_unused]] auto slice_cnt_shift = View(new_term.slice_cnt_shift); \ diff --git a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_a.hpp b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_a.hpp new file mode 100644 index 000000000000..97f82c801940 --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_a.hpp @@ -0,0 +1,72 @@ +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_a_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 7; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_mem_op == 1 || in.mem_sel_op_gadget_a == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_a, + in.poseidon2_mem_op, + in.poseidon2_mem_op, + in.mem_sel_op_gadget_a, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_a, + in.poseidon2_a_0, + in.poseidon2_write_line, + in.poseidon2_in_tag, + in.poseidon2_in_tag, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw, + in.mem_r_in_tag, + in.mem_w_in_tag); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_a, + in.poseidon2_mem_op, + in.poseidon2_mem_op, + in.mem_sel_op_gadget_a, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_a, + in.poseidon2_a_0, + in.poseidon2_write_line, + in.poseidon2_in_tag, + in.poseidon2_in_tag, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw, + in.mem_r_in_tag, + in.mem_w_in_tag); + } +}; + +template +class perm_pos_mem_a_relation : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_A"; +}; +template using perm_pos_mem_a = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_b.hpp b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_b.hpp new file mode 100644 index 000000000000..ae1f5ee18af1 --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_b.hpp @@ -0,0 +1,72 @@ +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_b_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 7; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_mem_op == 1 || in.mem_sel_op_gadget_b == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_b, + in.poseidon2_mem_op, + in.poseidon2_mem_op, + in.mem_sel_op_gadget_b, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_b, + in.poseidon2_a_1, + in.poseidon2_write_line, + in.poseidon2_in_tag, + in.poseidon2_in_tag, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw, + in.mem_r_in_tag, + in.mem_w_in_tag); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_b, + in.poseidon2_mem_op, + in.poseidon2_mem_op, + in.mem_sel_op_gadget_b, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_b, + in.poseidon2_a_1, + in.poseidon2_write_line, + in.poseidon2_in_tag, + in.poseidon2_in_tag, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw, + in.mem_r_in_tag, + in.mem_w_in_tag); + } +}; + +template +class perm_pos_mem_b_relation : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_B"; +}; +template using perm_pos_mem_b = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_c.hpp b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_c.hpp new file mode 100644 index 000000000000..056b285f7760 --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_c.hpp @@ -0,0 +1,72 @@ +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_c_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 7; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_mem_op == 1 || in.mem_sel_op_gadget_c == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_c, + in.poseidon2_mem_op, + in.poseidon2_mem_op, + in.mem_sel_op_gadget_c, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_c, + in.poseidon2_a_2, + in.poseidon2_write_line, + in.poseidon2_in_tag, + in.poseidon2_in_tag, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw, + in.mem_r_in_tag, + in.mem_w_in_tag); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_c, + in.poseidon2_mem_op, + in.poseidon2_mem_op, + in.mem_sel_op_gadget_c, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_c, + in.poseidon2_a_2, + in.poseidon2_write_line, + in.poseidon2_in_tag, + in.poseidon2_in_tag, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw, + in.mem_r_in_tag, + in.mem_w_in_tag); + } +}; + +template +class perm_pos_mem_c_relation : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_C"; +}; +template using perm_pos_mem_c = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_d.hpp b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_d.hpp new file mode 100644 index 000000000000..e098501b2a69 --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_d.hpp @@ -0,0 +1,72 @@ +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_d_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 7; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_mem_op == 1 || in.mem_sel_op_gadget_d == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_d, + in.poseidon2_mem_op, + in.poseidon2_mem_op, + in.mem_sel_op_gadget_d, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_d, + in.poseidon2_a_3, + in.poseidon2_write_line, + in.poseidon2_in_tag, + in.poseidon2_in_tag, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw, + in.mem_r_in_tag, + in.mem_w_in_tag); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_d, + in.poseidon2_mem_op, + in.poseidon2_mem_op, + in.mem_sel_op_gadget_d, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_d, + in.poseidon2_a_3, + in.poseidon2_write_line, + in.poseidon2_in_tag, + in.poseidon2_in_tag, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw, + in.mem_r_in_tag, + in.mem_w_in_tag); + } +}; + +template +class perm_pos_mem_d_relation : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_D"; +}; +template using perm_pos_mem_d = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp index d5aad15f69a8..deca7a31789d 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp @@ -291,6 +291,10 @@ template std::vector AvmFullRow::names() "mem_sel_op_c", "mem_sel_op_cmov", "mem_sel_op_d", + "mem_sel_op_gadget_a", + "mem_sel_op_gadget_b", + "mem_sel_op_gadget_c", + "mem_sel_op_gadget_d", "mem_sel_op_slice", "mem_sel_resolve_ind_addr_a", "mem_sel_resolve_ind_addr_b", @@ -308,6 +312,266 @@ template std::vector AvmFullRow::names() "pedersen_input", "pedersen_output", "pedersen_sel_pedersen", + "poseidon2_B_10_0", + "poseidon2_B_10_1", + "poseidon2_B_10_2", + "poseidon2_B_10_3", + "poseidon2_B_11_0", + "poseidon2_B_11_1", + "poseidon2_B_11_2", + "poseidon2_B_11_3", + "poseidon2_B_12_0", + "poseidon2_B_12_1", + "poseidon2_B_12_2", + "poseidon2_B_12_3", + "poseidon2_B_13_0", + "poseidon2_B_13_1", + "poseidon2_B_13_2", + "poseidon2_B_13_3", + "poseidon2_B_14_0", + "poseidon2_B_14_1", + "poseidon2_B_14_2", + "poseidon2_B_14_3", + "poseidon2_B_15_0", + "poseidon2_B_15_1", + "poseidon2_B_15_2", + "poseidon2_B_15_3", + "poseidon2_B_16_0", + "poseidon2_B_16_1", + "poseidon2_B_16_2", + "poseidon2_B_16_3", + "poseidon2_B_17_0", + "poseidon2_B_17_1", + "poseidon2_B_17_2", + "poseidon2_B_17_3", + "poseidon2_B_18_0", + "poseidon2_B_18_1", + "poseidon2_B_18_2", + "poseidon2_B_18_3", + "poseidon2_B_19_0", + "poseidon2_B_19_1", + "poseidon2_B_19_2", + "poseidon2_B_19_3", + "poseidon2_B_20_0", + "poseidon2_B_20_1", + "poseidon2_B_20_2", + "poseidon2_B_20_3", + "poseidon2_B_21_0", + "poseidon2_B_21_1", + "poseidon2_B_21_2", + "poseidon2_B_21_3", + "poseidon2_B_22_0", + "poseidon2_B_22_1", + "poseidon2_B_22_2", + "poseidon2_B_22_3", + "poseidon2_B_23_0", + "poseidon2_B_23_1", + "poseidon2_B_23_2", + "poseidon2_B_23_3", + "poseidon2_B_24_0", + "poseidon2_B_24_1", + "poseidon2_B_24_2", + "poseidon2_B_24_3", + "poseidon2_B_25_0", + "poseidon2_B_25_1", + "poseidon2_B_25_2", + "poseidon2_B_25_3", + "poseidon2_B_26_0", + "poseidon2_B_26_1", + "poseidon2_B_26_2", + "poseidon2_B_26_3", + "poseidon2_B_27_0", + "poseidon2_B_27_1", + "poseidon2_B_27_2", + "poseidon2_B_27_3", + "poseidon2_B_28_0", + "poseidon2_B_28_1", + "poseidon2_B_28_2", + "poseidon2_B_28_3", + "poseidon2_B_29_0", + "poseidon2_B_29_1", + "poseidon2_B_29_2", + "poseidon2_B_29_3", + "poseidon2_B_30_0", + "poseidon2_B_30_1", + "poseidon2_B_30_2", + "poseidon2_B_30_3", + "poseidon2_B_31_0", + "poseidon2_B_31_1", + "poseidon2_B_31_2", + "poseidon2_B_31_3", + "poseidon2_B_32_0", + "poseidon2_B_32_1", + "poseidon2_B_32_2", + "poseidon2_B_32_3", + "poseidon2_B_33_0", + "poseidon2_B_33_1", + "poseidon2_B_33_2", + "poseidon2_B_33_3", + "poseidon2_B_34_0", + "poseidon2_B_34_1", + "poseidon2_B_34_2", + "poseidon2_B_34_3", + "poseidon2_B_35_0", + "poseidon2_B_35_1", + "poseidon2_B_35_2", + "poseidon2_B_35_3", + "poseidon2_B_36_0", + "poseidon2_B_36_1", + "poseidon2_B_36_2", + "poseidon2_B_36_3", + "poseidon2_B_37_0", + "poseidon2_B_37_1", + "poseidon2_B_37_2", + "poseidon2_B_37_3", + "poseidon2_B_38_0", + "poseidon2_B_38_1", + "poseidon2_B_38_2", + "poseidon2_B_38_3", + "poseidon2_B_39_0", + "poseidon2_B_39_1", + "poseidon2_B_39_2", + "poseidon2_B_39_3", + "poseidon2_B_40_0", + "poseidon2_B_40_1", + "poseidon2_B_40_2", + "poseidon2_B_40_3", + "poseidon2_B_41_0", + "poseidon2_B_41_1", + "poseidon2_B_41_2", + "poseidon2_B_41_3", + "poseidon2_B_42_0", + "poseidon2_B_42_1", + "poseidon2_B_42_2", + "poseidon2_B_42_3", + "poseidon2_B_43_0", + "poseidon2_B_43_1", + "poseidon2_B_43_2", + "poseidon2_B_43_3", + "poseidon2_B_44_0", + "poseidon2_B_44_1", + "poseidon2_B_44_2", + "poseidon2_B_44_3", + "poseidon2_B_45_0", + "poseidon2_B_45_1", + "poseidon2_B_45_2", + "poseidon2_B_45_3", + "poseidon2_B_46_0", + "poseidon2_B_46_1", + "poseidon2_B_46_2", + "poseidon2_B_46_3", + "poseidon2_B_47_0", + "poseidon2_B_47_1", + "poseidon2_B_47_2", + "poseidon2_B_47_3", + "poseidon2_B_48_0", + "poseidon2_B_48_1", + "poseidon2_B_48_2", + "poseidon2_B_48_3", + "poseidon2_B_49_0", + "poseidon2_B_49_1", + "poseidon2_B_49_2", + "poseidon2_B_49_3", + "poseidon2_B_4_0", + "poseidon2_B_4_1", + "poseidon2_B_4_2", + "poseidon2_B_4_3", + "poseidon2_B_50_0", + "poseidon2_B_50_1", + "poseidon2_B_50_2", + "poseidon2_B_50_3", + "poseidon2_B_51_0", + "poseidon2_B_51_1", + "poseidon2_B_51_2", + "poseidon2_B_51_3", + "poseidon2_B_52_0", + "poseidon2_B_52_1", + "poseidon2_B_52_2", + "poseidon2_B_52_3", + "poseidon2_B_53_0", + "poseidon2_B_53_1", + "poseidon2_B_53_2", + "poseidon2_B_53_3", + "poseidon2_B_54_0", + "poseidon2_B_54_1", + "poseidon2_B_54_2", + "poseidon2_B_54_3", + "poseidon2_B_55_0", + "poseidon2_B_55_1", + "poseidon2_B_55_2", + "poseidon2_B_55_3", + "poseidon2_B_56_0", + "poseidon2_B_56_1", + "poseidon2_B_56_2", + "poseidon2_B_56_3", + "poseidon2_B_57_0", + "poseidon2_B_57_1", + "poseidon2_B_57_2", + "poseidon2_B_57_3", + "poseidon2_B_58_0", + "poseidon2_B_58_1", + "poseidon2_B_58_2", + "poseidon2_B_58_3", + "poseidon2_B_59_0", + "poseidon2_B_59_1", + "poseidon2_B_59_2", + "poseidon2_B_59_3", + "poseidon2_B_5_0", + "poseidon2_B_5_1", + "poseidon2_B_5_2", + "poseidon2_B_5_3", + "poseidon2_B_6_0", + "poseidon2_B_6_1", + "poseidon2_B_6_2", + "poseidon2_B_6_3", + "poseidon2_B_7_0", + "poseidon2_B_7_1", + "poseidon2_B_7_2", + "poseidon2_B_7_3", + "poseidon2_B_8_0", + "poseidon2_B_8_1", + "poseidon2_B_8_2", + "poseidon2_B_8_3", + "poseidon2_B_9_0", + "poseidon2_B_9_1", + "poseidon2_B_9_2", + "poseidon2_B_9_3", + "poseidon2_EXT_LAYER_4", + "poseidon2_EXT_LAYER_5", + "poseidon2_EXT_LAYER_6", + "poseidon2_EXT_LAYER_7", + "poseidon2_T_0_4", + "poseidon2_T_0_5", + "poseidon2_T_0_6", + "poseidon2_T_0_7", + "poseidon2_T_1_4", + "poseidon2_T_1_5", + "poseidon2_T_1_6", + "poseidon2_T_1_7", + "poseidon2_T_2_4", + "poseidon2_T_2_5", + "poseidon2_T_2_6", + "poseidon2_T_2_7", + "poseidon2_T_3_4", + "poseidon2_T_3_5", + "poseidon2_T_3_6", + "poseidon2_T_3_7", + "poseidon2_T_60_4", + "poseidon2_T_60_5", + "poseidon2_T_60_6", + "poseidon2_T_60_7", + "poseidon2_T_61_4", + "poseidon2_T_61_5", + "poseidon2_T_61_6", + "poseidon2_T_61_7", + "poseidon2_T_62_4", + "poseidon2_T_62_5", + "poseidon2_T_62_6", + "poseidon2_T_62_7", + "poseidon2_T_63_4", + "poseidon2_T_63_5", + "poseidon2_T_63_6", + "poseidon2_T_63_7", "poseidon2_a_0", "poseidon2_a_1", "poseidon2_a_2", @@ -317,9 +581,17 @@ template std::vector AvmFullRow::names() "poseidon2_b_2", "poseidon2_b_3", "poseidon2_clk", - "poseidon2_input", - "poseidon2_output", + "poseidon2_in_tag", + "poseidon2_input_addr", + "poseidon2_mem_addr_a", + "poseidon2_mem_addr_b", + "poseidon2_mem_addr_c", + "poseidon2_mem_addr_d", + "poseidon2_mem_op", + "poseidon2_output_addr", + "poseidon2_read_line", "poseidon2_sel_poseidon_perm", + "poseidon2_write_line", "powers_power_of_2", "sha256_clk", "sha256_input", @@ -337,6 +609,10 @@ template std::vector AvmFullRow::names() "slice_sel_start", "slice_space_id", "slice_val", + "perm_pos_mem_a", + "perm_pos_mem_b", + "perm_pos_mem_c", + "perm_pos_mem_d", "perm_slice_mem", "perm_main_alu", "perm_main_bin", @@ -715,6 +991,10 @@ template RefVector AvmFullRow::as_vector() const mem_sel_op_c, mem_sel_op_cmov, mem_sel_op_d, + mem_sel_op_gadget_a, + mem_sel_op_gadget_b, + mem_sel_op_gadget_c, + mem_sel_op_gadget_d, mem_sel_op_slice, mem_sel_resolve_ind_addr_a, mem_sel_resolve_ind_addr_b, @@ -732,10 +1012,286 @@ template RefVector AvmFullRow::as_vector() const pedersen_input, pedersen_output, pedersen_sel_pedersen, + poseidon2_B_10_0, + poseidon2_B_10_1, + poseidon2_B_10_2, + poseidon2_B_10_3, + poseidon2_B_11_0, + poseidon2_B_11_1, + poseidon2_B_11_2, + poseidon2_B_11_3, + poseidon2_B_12_0, + poseidon2_B_12_1, + poseidon2_B_12_2, + poseidon2_B_12_3, + poseidon2_B_13_0, + poseidon2_B_13_1, + poseidon2_B_13_2, + poseidon2_B_13_3, + poseidon2_B_14_0, + poseidon2_B_14_1, + poseidon2_B_14_2, + poseidon2_B_14_3, + poseidon2_B_15_0, + poseidon2_B_15_1, + poseidon2_B_15_2, + poseidon2_B_15_3, + poseidon2_B_16_0, + poseidon2_B_16_1, + poseidon2_B_16_2, + poseidon2_B_16_3, + poseidon2_B_17_0, + poseidon2_B_17_1, + poseidon2_B_17_2, + poseidon2_B_17_3, + poseidon2_B_18_0, + poseidon2_B_18_1, + poseidon2_B_18_2, + poseidon2_B_18_3, + poseidon2_B_19_0, + poseidon2_B_19_1, + poseidon2_B_19_2, + poseidon2_B_19_3, + poseidon2_B_20_0, + poseidon2_B_20_1, + poseidon2_B_20_2, + poseidon2_B_20_3, + poseidon2_B_21_0, + poseidon2_B_21_1, + poseidon2_B_21_2, + poseidon2_B_21_3, + poseidon2_B_22_0, + poseidon2_B_22_1, + poseidon2_B_22_2, + poseidon2_B_22_3, + poseidon2_B_23_0, + poseidon2_B_23_1, + poseidon2_B_23_2, + poseidon2_B_23_3, + poseidon2_B_24_0, + poseidon2_B_24_1, + poseidon2_B_24_2, + poseidon2_B_24_3, + poseidon2_B_25_0, + poseidon2_B_25_1, + poseidon2_B_25_2, + poseidon2_B_25_3, + poseidon2_B_26_0, + poseidon2_B_26_1, + poseidon2_B_26_2, + poseidon2_B_26_3, + poseidon2_B_27_0, + poseidon2_B_27_1, + poseidon2_B_27_2, + poseidon2_B_27_3, + poseidon2_B_28_0, + poseidon2_B_28_1, + poseidon2_B_28_2, + poseidon2_B_28_3, + poseidon2_B_29_0, + poseidon2_B_29_1, + poseidon2_B_29_2, + poseidon2_B_29_3, + poseidon2_B_30_0, + poseidon2_B_30_1, + poseidon2_B_30_2, + poseidon2_B_30_3, + poseidon2_B_31_0, + poseidon2_B_31_1, + poseidon2_B_31_2, + poseidon2_B_31_3, + poseidon2_B_32_0, + poseidon2_B_32_1, + poseidon2_B_32_2, + poseidon2_B_32_3, + poseidon2_B_33_0, + poseidon2_B_33_1, + poseidon2_B_33_2, + poseidon2_B_33_3, + poseidon2_B_34_0, + poseidon2_B_34_1, + poseidon2_B_34_2, + poseidon2_B_34_3, + poseidon2_B_35_0, + poseidon2_B_35_1, + poseidon2_B_35_2, + poseidon2_B_35_3, + poseidon2_B_36_0, + poseidon2_B_36_1, + poseidon2_B_36_2, + poseidon2_B_36_3, + poseidon2_B_37_0, + poseidon2_B_37_1, + poseidon2_B_37_2, + poseidon2_B_37_3, + poseidon2_B_38_0, + poseidon2_B_38_1, + poseidon2_B_38_2, + poseidon2_B_38_3, + poseidon2_B_39_0, + poseidon2_B_39_1, + poseidon2_B_39_2, + poseidon2_B_39_3, + poseidon2_B_40_0, + poseidon2_B_40_1, + poseidon2_B_40_2, + poseidon2_B_40_3, + poseidon2_B_41_0, + poseidon2_B_41_1, + poseidon2_B_41_2, + poseidon2_B_41_3, + poseidon2_B_42_0, + poseidon2_B_42_1, + poseidon2_B_42_2, + poseidon2_B_42_3, + poseidon2_B_43_0, + poseidon2_B_43_1, + poseidon2_B_43_2, + poseidon2_B_43_3, + poseidon2_B_44_0, + poseidon2_B_44_1, + poseidon2_B_44_2, + poseidon2_B_44_3, + poseidon2_B_45_0, + poseidon2_B_45_1, + poseidon2_B_45_2, + poseidon2_B_45_3, + poseidon2_B_46_0, + poseidon2_B_46_1, + poseidon2_B_46_2, + poseidon2_B_46_3, + poseidon2_B_47_0, + poseidon2_B_47_1, + poseidon2_B_47_2, + poseidon2_B_47_3, + poseidon2_B_48_0, + poseidon2_B_48_1, + poseidon2_B_48_2, + poseidon2_B_48_3, + poseidon2_B_49_0, + poseidon2_B_49_1, + poseidon2_B_49_2, + poseidon2_B_49_3, + poseidon2_B_4_0, + poseidon2_B_4_1, + poseidon2_B_4_2, + poseidon2_B_4_3, + poseidon2_B_50_0, + poseidon2_B_50_1, + poseidon2_B_50_2, + poseidon2_B_50_3, + poseidon2_B_51_0, + poseidon2_B_51_1, + poseidon2_B_51_2, + poseidon2_B_51_3, + poseidon2_B_52_0, + poseidon2_B_52_1, + poseidon2_B_52_2, + poseidon2_B_52_3, + poseidon2_B_53_0, + poseidon2_B_53_1, + poseidon2_B_53_2, + poseidon2_B_53_3, + poseidon2_B_54_0, + poseidon2_B_54_1, + poseidon2_B_54_2, + poseidon2_B_54_3, + poseidon2_B_55_0, + poseidon2_B_55_1, + poseidon2_B_55_2, + poseidon2_B_55_3, + poseidon2_B_56_0, + poseidon2_B_56_1, + poseidon2_B_56_2, + poseidon2_B_56_3, + poseidon2_B_57_0, + poseidon2_B_57_1, + poseidon2_B_57_2, + poseidon2_B_57_3, + poseidon2_B_58_0, + poseidon2_B_58_1, + poseidon2_B_58_2, + poseidon2_B_58_3, + poseidon2_B_59_0, + poseidon2_B_59_1, + poseidon2_B_59_2, + poseidon2_B_59_3, + poseidon2_B_5_0, + poseidon2_B_5_1, + poseidon2_B_5_2, + poseidon2_B_5_3, + poseidon2_B_6_0, + poseidon2_B_6_1, + poseidon2_B_6_2, + poseidon2_B_6_3, + poseidon2_B_7_0, + poseidon2_B_7_1, + poseidon2_B_7_2, + poseidon2_B_7_3, + poseidon2_B_8_0, + poseidon2_B_8_1, + poseidon2_B_8_2, + poseidon2_B_8_3, + poseidon2_B_9_0, + poseidon2_B_9_1, + poseidon2_B_9_2, + poseidon2_B_9_3, + poseidon2_EXT_LAYER_4, + poseidon2_EXT_LAYER_5, + poseidon2_EXT_LAYER_6, + poseidon2_EXT_LAYER_7, + poseidon2_T_0_4, + poseidon2_T_0_5, + poseidon2_T_0_6, + poseidon2_T_0_7, + poseidon2_T_1_4, + poseidon2_T_1_5, + poseidon2_T_1_6, + poseidon2_T_1_7, + poseidon2_T_2_4, + poseidon2_T_2_5, + poseidon2_T_2_6, + poseidon2_T_2_7, + poseidon2_T_3_4, + poseidon2_T_3_5, + poseidon2_T_3_6, + poseidon2_T_3_7, + poseidon2_T_60_4, + poseidon2_T_60_5, + poseidon2_T_60_6, + poseidon2_T_60_7, + poseidon2_T_61_4, + poseidon2_T_61_5, + poseidon2_T_61_6, + poseidon2_T_61_7, + poseidon2_T_62_4, + poseidon2_T_62_5, + poseidon2_T_62_6, + poseidon2_T_62_7, + poseidon2_T_63_4, + poseidon2_T_63_5, + poseidon2_T_63_6, + poseidon2_T_63_7, + poseidon2_a_0, + poseidon2_a_1, + poseidon2_a_2, + poseidon2_a_3, + poseidon2_b_0, + poseidon2_b_1, + poseidon2_b_2, + poseidon2_b_3, poseidon2_clk, - poseidon2_input, - poseidon2_output, + poseidon2_in_tag, + poseidon2_input_addr, + poseidon2_mem_addr_a, + poseidon2_mem_addr_b, + poseidon2_mem_addr_c, + poseidon2_mem_addr_d, + poseidon2_mem_op, + poseidon2_output_addr, + poseidon2_read_line, poseidon2_sel_poseidon_perm, + poseidon2_write_line, powers_power_of_2, sha256_clk, sha256_input, @@ -753,6 +1309,10 @@ template RefVector AvmFullRow::as_vector() const slice_sel_start, slice_space_id, slice_val, + perm_pos_mem_a, + perm_pos_mem_b, + perm_pos_mem_c, + perm_pos_mem_d, perm_slice_mem, perm_main_alu, perm_main_bin, @@ -859,644 +1419,10 @@ template RefVector AvmFullRow::as_vector() const template std::ostream& operator<<(std::ostream& os, AvmFullRow const& row) { -<<<<<<< HEAD for (const auto& ff : row.as_vector()) { os << field_to_string(ff) << ", "; } return os; -======= -<<<<<<< HEAD - return os << field_to_string(row.main_clk) // - << "," << field_to_string(row.main_sel_first) // - << "," << field_to_string(row.kernel_kernel_inputs) // - << "," << field_to_string(row.kernel_kernel_value_out) // - << "," << field_to_string(row.kernel_kernel_side_effect_out) // - << "," << field_to_string(row.kernel_kernel_metadata_out) // - << "," << field_to_string(row.main_calldata) // - << "," << field_to_string(row.main_returndata) // - << "," << field_to_string(row.alu_a_hi) // - << "," << field_to_string(row.alu_a_lo) // - << "," << field_to_string(row.alu_b_hi) // - << "," << field_to_string(row.alu_b_lo) // - << "," << field_to_string(row.alu_borrow) // - << "," << field_to_string(row.alu_cf) // - << "," << field_to_string(row.alu_clk) // - << "," << field_to_string(row.alu_cmp_rng_ctr) // - << "," << field_to_string(row.alu_div_u16_r0) // - << "," << field_to_string(row.alu_div_u16_r1) // - << "," << field_to_string(row.alu_div_u16_r2) // - << "," << field_to_string(row.alu_div_u16_r3) // - << "," << field_to_string(row.alu_div_u16_r4) // - << "," << field_to_string(row.alu_div_u16_r5) // - << "," << field_to_string(row.alu_div_u16_r6) // - << "," << field_to_string(row.alu_div_u16_r7) // - << "," << field_to_string(row.alu_divisor_hi) // - << "," << field_to_string(row.alu_divisor_lo) // - << "," << field_to_string(row.alu_ff_tag) // - << "," << field_to_string(row.alu_ia) // - << "," << field_to_string(row.alu_ib) // - << "," << field_to_string(row.alu_ic) // - << "," << field_to_string(row.alu_in_tag) // - << "," << field_to_string(row.alu_op_add) // - << "," << field_to_string(row.alu_op_cast) // - << "," << field_to_string(row.alu_op_cast_prev) // - << "," << field_to_string(row.alu_op_div) // - << "," << field_to_string(row.alu_op_div_a_lt_b) // - << "," << field_to_string(row.alu_op_div_std) // - << "," << field_to_string(row.alu_op_eq) // - << "," << field_to_string(row.alu_op_eq_diff_inv) // - << "," << field_to_string(row.alu_op_lt) // - << "," << field_to_string(row.alu_op_lte) // - << "," << field_to_string(row.alu_op_mul) // - << "," << field_to_string(row.alu_op_not) // - << "," << field_to_string(row.alu_op_shl) // - << "," << field_to_string(row.alu_op_shr) // - << "," << field_to_string(row.alu_op_sub) // - << "," << field_to_string(row.alu_p_a_borrow) // - << "," << field_to_string(row.alu_p_b_borrow) // - << "," << field_to_string(row.alu_p_sub_a_hi) // - << "," << field_to_string(row.alu_p_sub_a_lo) // - << "," << field_to_string(row.alu_p_sub_b_hi) // - << "," << field_to_string(row.alu_p_sub_b_lo) // - << "," << field_to_string(row.alu_partial_prod_hi) // - << "," << field_to_string(row.alu_partial_prod_lo) // - << "," << field_to_string(row.alu_quotient_hi) // - << "," << field_to_string(row.alu_quotient_lo) // - << "," << field_to_string(row.alu_remainder) // - << "," << field_to_string(row.alu_res_hi) // - << "," << field_to_string(row.alu_res_lo) // - << "," << field_to_string(row.alu_sel_alu) // - << "," << field_to_string(row.alu_sel_cmp) // - << "," << field_to_string(row.alu_sel_div_rng_chk) // - << "," << field_to_string(row.alu_sel_rng_chk) // - << "," << field_to_string(row.alu_sel_rng_chk_lookup) // - << "," << field_to_string(row.alu_sel_shift_which) // - << "," << field_to_string(row.alu_shift_lt_bit_len) // - << "," << field_to_string(row.alu_t_sub_s_bits) // - << "," << field_to_string(row.alu_two_pow_s) // - << "," << field_to_string(row.alu_two_pow_t_sub_s) // - << "," << field_to_string(row.alu_u128_tag) // - << "," << field_to_string(row.alu_u16_r0) // - << "," << field_to_string(row.alu_u16_r1) // - << "," << field_to_string(row.alu_u16_r10) // - << "," << field_to_string(row.alu_u16_r11) // - << "," << field_to_string(row.alu_u16_r12) // - << "," << field_to_string(row.alu_u16_r13) // - << "," << field_to_string(row.alu_u16_r14) // - << "," << field_to_string(row.alu_u16_r2) // - << "," << field_to_string(row.alu_u16_r3) // - << "," << field_to_string(row.alu_u16_r4) // - << "," << field_to_string(row.alu_u16_r5) // - << "," << field_to_string(row.alu_u16_r6) // - << "," << field_to_string(row.alu_u16_r7) // - << "," << field_to_string(row.alu_u16_r8) // - << "," << field_to_string(row.alu_u16_r9) // - << "," << field_to_string(row.alu_u16_tag) // - << "," << field_to_string(row.alu_u32_tag) // - << "," << field_to_string(row.alu_u64_tag) // - << "," << field_to_string(row.alu_u8_r0) // - << "," << field_to_string(row.alu_u8_r1) // - << "," << field_to_string(row.alu_u8_tag) // - << "," << field_to_string(row.binary_acc_ia) // - << "," << field_to_string(row.binary_acc_ib) // - << "," << field_to_string(row.binary_acc_ic) // - << "," << field_to_string(row.binary_clk) // - << "," << field_to_string(row.binary_ia_bytes) // - << "," << field_to_string(row.binary_ib_bytes) // - << "," << field_to_string(row.binary_ic_bytes) // - << "," << field_to_string(row.binary_in_tag) // - << "," << field_to_string(row.binary_mem_tag_ctr) // - << "," << field_to_string(row.binary_mem_tag_ctr_inv) // - << "," << field_to_string(row.binary_op_id) // - << "," << field_to_string(row.binary_sel_bin) // - << "," << field_to_string(row.binary_start) // - << "," << field_to_string(row.byte_lookup_sel_bin) // - << "," << field_to_string(row.byte_lookup_table_byte_lengths) // - << "," << field_to_string(row.byte_lookup_table_in_tags) // - << "," << field_to_string(row.byte_lookup_table_input_a) // - << "," << field_to_string(row.byte_lookup_table_input_b) // - << "," << field_to_string(row.byte_lookup_table_op_id) // - << "," << field_to_string(row.byte_lookup_table_output) // - << "," << field_to_string(row.conversion_clk) // - << "," << field_to_string(row.conversion_input) // - << "," << field_to_string(row.conversion_num_limbs) // - << "," << field_to_string(row.conversion_radix) // - << "," << field_to_string(row.conversion_sel_to_radix_le) // - << "," << field_to_string(row.gas_da_gas_fixed_table) // - << "," << field_to_string(row.gas_l2_gas_fixed_table) // - << "," << field_to_string(row.gas_sel_gas_cost) // - << "," << field_to_string(row.keccakf1600_clk) // - << "," << field_to_string(row.keccakf1600_input) // - << "," << field_to_string(row.keccakf1600_output) // - << "," << field_to_string(row.keccakf1600_sel_keccakf1600) // - << "," << field_to_string(row.kernel_emit_l2_to_l1_msg_write_offset) // - << "," << field_to_string(row.kernel_emit_note_hash_write_offset) // - << "," << field_to_string(row.kernel_emit_nullifier_write_offset) // - << "," << field_to_string(row.kernel_emit_unencrypted_log_write_offset) // - << "," << field_to_string(row.kernel_kernel_in_offset) // - << "," << field_to_string(row.kernel_kernel_out_offset) // - << "," << field_to_string(row.kernel_l1_to_l2_msg_exists_write_offset) // - << "," << field_to_string(row.kernel_note_hash_exist_write_offset) // - << "," << field_to_string(row.kernel_nullifier_exists_write_offset) // - << "," << field_to_string(row.kernel_nullifier_non_exists_write_offset) // - << "," << field_to_string(row.kernel_q_public_input_kernel_add_to_table) // - << "," << field_to_string(row.kernel_q_public_input_kernel_out_add_to_table) // - << "," << field_to_string(row.kernel_side_effect_counter) // - << "," << field_to_string(row.kernel_sload_write_offset) // - << "," << field_to_string(row.kernel_sstore_write_offset) // - << "," << field_to_string(row.main_abs_da_rem_gas_hi) // - << "," << field_to_string(row.main_abs_da_rem_gas_lo) // - << "," << field_to_string(row.main_abs_l2_rem_gas_hi) // - << "," << field_to_string(row.main_abs_l2_rem_gas_lo) // - << "," << field_to_string(row.main_alu_in_tag) // - << "," << field_to_string(row.main_bin_op_id) // - << "," << field_to_string(row.main_call_ptr) // - << "," << field_to_string(row.main_da_gas_op_cost) // - << "," << field_to_string(row.main_da_gas_remaining) // - << "," << field_to_string(row.main_da_out_of_gas) // - << "," << field_to_string(row.main_ia) // - << "," << field_to_string(row.main_ib) // - << "," << field_to_string(row.main_ic) // - << "," << field_to_string(row.main_id) // - << "," << field_to_string(row.main_id_zero) // - << "," << field_to_string(row.main_ind_addr_a) // - << "," << field_to_string(row.main_ind_addr_b) // - << "," << field_to_string(row.main_ind_addr_c) // - << "," << field_to_string(row.main_ind_addr_d) // - << "," << field_to_string(row.main_internal_return_ptr) // - << "," << field_to_string(row.main_inv) // - << "," << field_to_string(row.main_l2_gas_op_cost) // - << "," << field_to_string(row.main_l2_gas_remaining) // - << "," << field_to_string(row.main_l2_out_of_gas) // - << "," << field_to_string(row.main_mem_addr_a) // - << "," << field_to_string(row.main_mem_addr_b) // - << "," << field_to_string(row.main_mem_addr_c) // - << "," << field_to_string(row.main_mem_addr_d) // - << "," << field_to_string(row.main_op_err) // - << "," << field_to_string(row.main_opcode_val) // - << "," << field_to_string(row.main_pc) // - << "," << field_to_string(row.main_r_in_tag) // - << "," << field_to_string(row.main_rwa) // - << "," << field_to_string(row.main_rwb) // - << "," << field_to_string(row.main_rwc) // - << "," << field_to_string(row.main_rwd) // - << "," << field_to_string(row.main_sel_alu) // - << "," << field_to_string(row.main_sel_bin) // - << "," << field_to_string(row.main_sel_calldata) // - << "," << field_to_string(row.main_sel_gas_accounting_active) // - << "," << field_to_string(row.main_sel_last) // - << "," << field_to_string(row.main_sel_mem_op_a) // - << "," << field_to_string(row.main_sel_mem_op_activate_gas) // - << "," << field_to_string(row.main_sel_mem_op_b) // - << "," << field_to_string(row.main_sel_mem_op_c) // - << "," << field_to_string(row.main_sel_mem_op_d) // - << "," << field_to_string(row.main_sel_mov_ia_to_ic) // - << "," << field_to_string(row.main_sel_mov_ib_to_ic) // - << "," << field_to_string(row.main_sel_op_add) // - << "," << field_to_string(row.main_sel_op_address) // - << "," << field_to_string(row.main_sel_op_and) // - << "," << field_to_string(row.main_sel_op_block_number) // - << "," << field_to_string(row.main_sel_op_calldata_copy) // - << "," << field_to_string(row.main_sel_op_cast) // - << "," << field_to_string(row.main_sel_op_chain_id) // - << "," << field_to_string(row.main_sel_op_cmov) // - << "," << field_to_string(row.main_sel_op_coinbase) // - << "," << field_to_string(row.main_sel_op_dagasleft) // - << "," << field_to_string(row.main_sel_op_div) // - << "," << field_to_string(row.main_sel_op_emit_l2_to_l1_msg) // - << "," << field_to_string(row.main_sel_op_emit_note_hash) // - << "," << field_to_string(row.main_sel_op_emit_nullifier) // - << "," << field_to_string(row.main_sel_op_emit_unencrypted_log) // - << "," << field_to_string(row.main_sel_op_eq) // - << "," << field_to_string(row.main_sel_op_external_call) // - << "," << field_to_string(row.main_sel_op_external_return) // - << "," << field_to_string(row.main_sel_op_fdiv) // - << "," << field_to_string(row.main_sel_op_fee_per_da_gas) // - << "," << field_to_string(row.main_sel_op_fee_per_l2_gas) // - << "," << field_to_string(row.main_sel_op_function_selector) // - << "," << field_to_string(row.main_sel_op_get_contract_instance) // - << "," << field_to_string(row.main_sel_op_halt) // - << "," << field_to_string(row.main_sel_op_internal_call) // - << "," << field_to_string(row.main_sel_op_internal_return) // - << "," << field_to_string(row.main_sel_op_jump) // - << "," << field_to_string(row.main_sel_op_jumpi) // - << "," << field_to_string(row.main_sel_op_keccak) // - << "," << field_to_string(row.main_sel_op_l1_to_l2_msg_exists) // - << "," << field_to_string(row.main_sel_op_l2gasleft) // - << "," << field_to_string(row.main_sel_op_lt) // - << "," << field_to_string(row.main_sel_op_lte) // - << "," << field_to_string(row.main_sel_op_mov) // - << "," << field_to_string(row.main_sel_op_mul) // - << "," << field_to_string(row.main_sel_op_not) // - << "," << field_to_string(row.main_sel_op_note_hash_exists) // - << "," << field_to_string(row.main_sel_op_nullifier_exists) // - << "," << field_to_string(row.main_sel_op_or) // - << "," << field_to_string(row.main_sel_op_pedersen) // - << "," << field_to_string(row.main_sel_op_poseidon2) // - << "," << field_to_string(row.main_sel_op_radix_le) // - << "," << field_to_string(row.main_sel_op_sender) // - << "," << field_to_string(row.main_sel_op_sha256) // - << "," << field_to_string(row.main_sel_op_shl) // - << "," << field_to_string(row.main_sel_op_shr) // - << "," << field_to_string(row.main_sel_op_sload) // - << "," << field_to_string(row.main_sel_op_sstore) // - << "," << field_to_string(row.main_sel_op_storage_address) // - << "," << field_to_string(row.main_sel_op_sub) // - << "," << field_to_string(row.main_sel_op_timestamp) // - << "," << field_to_string(row.main_sel_op_transaction_fee) // - << "," << field_to_string(row.main_sel_op_version) // - << "," << field_to_string(row.main_sel_op_xor) // - << "," << field_to_string(row.main_sel_q_kernel_lookup) // - << "," << field_to_string(row.main_sel_q_kernel_output_lookup) // - << "," << field_to_string(row.main_sel_resolve_ind_addr_a) // - << "," << field_to_string(row.main_sel_resolve_ind_addr_b) // - << "," << field_to_string(row.main_sel_resolve_ind_addr_c) // - << "," << field_to_string(row.main_sel_resolve_ind_addr_d) // - << "," << field_to_string(row.main_sel_returndata) // - << "," << field_to_string(row.main_sel_rng_16) // - << "," << field_to_string(row.main_sel_rng_8) // - << "," << field_to_string(row.main_sel_slice_gadget) // - << "," << field_to_string(row.main_space_id) // - << "," << field_to_string(row.main_tag_err) // - << "," << field_to_string(row.main_w_in_tag) // - << "," << field_to_string(row.mem_addr) // - << "," << field_to_string(row.mem_clk) // - << "," << field_to_string(row.mem_diff_hi) // - << "," << field_to_string(row.mem_diff_lo) // - << "," << field_to_string(row.mem_diff_mid) // - << "," << field_to_string(row.mem_glob_addr) // - << "," << field_to_string(row.mem_last) // - << "," << field_to_string(row.mem_lastAccess) // - << "," << field_to_string(row.mem_one_min_inv) // - << "," << field_to_string(row.mem_r_in_tag) // - << "," << field_to_string(row.mem_rw) // - << "," << field_to_string(row.mem_sel_mem) // - << "," << field_to_string(row.mem_sel_mov_ia_to_ic) // - << "," << field_to_string(row.mem_sel_mov_ib_to_ic) // - << "," << field_to_string(row.mem_sel_op_a) // - << "," << field_to_string(row.mem_sel_op_b) // - << "," << field_to_string(row.mem_sel_op_c) // - << "," << field_to_string(row.mem_sel_op_cmov) // - << "," << field_to_string(row.mem_sel_op_d) // - << "," << field_to_string(row.mem_sel_op_slice) // - << "," << field_to_string(row.mem_sel_resolve_ind_addr_a) // - << "," << field_to_string(row.mem_sel_resolve_ind_addr_b) // - << "," << field_to_string(row.mem_sel_resolve_ind_addr_c) // - << "," << field_to_string(row.mem_sel_resolve_ind_addr_d) // - << "," << field_to_string(row.mem_sel_rng_chk) // - << "," << field_to_string(row.mem_skip_check_tag) // - << "," << field_to_string(row.mem_space_id) // - << "," << field_to_string(row.mem_tag) // - << "," << field_to_string(row.mem_tag_err) // - << "," << field_to_string(row.mem_tsp) // - << "," << field_to_string(row.mem_val) // - << "," << field_to_string(row.mem_w_in_tag) // - << "," << field_to_string(row.pedersen_clk) // - << "," << field_to_string(row.pedersen_input) // - << "," << field_to_string(row.pedersen_output) // - << "," << field_to_string(row.pedersen_sel_pedersen) // - << "," << field_to_string(row.poseidon2_clk) // - << "," << field_to_string(row.poseidon2_input) // - << "," << field_to_string(row.poseidon2_output) // - << "," << field_to_string(row.poseidon2_sel_poseidon_perm) // - << "," << field_to_string(row.powers_power_of_2) // - << "," << field_to_string(row.sha256_clk) // - << "," << field_to_string(row.sha256_input) // - << "," << field_to_string(row.sha256_output) // - << "," << field_to_string(row.sha256_sel_sha256_compression) // - << "," << field_to_string(row.sha256_state) // - << "," << field_to_string(row.slice_addr) // - << "," << field_to_string(row.slice_clk) // - << "," << field_to_string(row.slice_cnt) // - << "," << field_to_string(row.slice_col_offset) // - << "," << field_to_string(row.slice_one_min_inv) // - << "," << field_to_string(row.slice_sel_cd_cpy) // - << "," << field_to_string(row.slice_sel_mem_active) // - << "," << field_to_string(row.slice_sel_return) // - << "," << field_to_string(row.slice_sel_start) // - << "," << field_to_string(row.slice_space_id) // - << "," << field_to_string(row.slice_val) // - << "," << field_to_string(row.perm_slice_mem) // - << "," << field_to_string(row.perm_main_alu) // - << "," << field_to_string(row.perm_main_bin) // - << "," << field_to_string(row.perm_main_conv) // - << "," << field_to_string(row.perm_main_pos2_perm) // - << "," << field_to_string(row.perm_main_pedersen) // - << "," << field_to_string(row.perm_main_slice) // - << "," << field_to_string(row.perm_main_mem_a) // - << "," << field_to_string(row.perm_main_mem_b) // - << "," << field_to_string(row.perm_main_mem_c) // - << "," << field_to_string(row.perm_main_mem_d) // - << "," << field_to_string(row.perm_main_mem_ind_addr_a) // - << "," << field_to_string(row.perm_main_mem_ind_addr_b) // - << "," << field_to_string(row.perm_main_mem_ind_addr_c) // - << "," << field_to_string(row.perm_main_mem_ind_addr_d) // - << "," << field_to_string(row.lookup_byte_lengths) // - << "," << field_to_string(row.lookup_byte_operations) // - << "," << field_to_string(row.lookup_cd_value) // - << "," << field_to_string(row.lookup_ret_value) // - << "," << field_to_string(row.lookup_opcode_gas) // - << "," << field_to_string(row.range_check_l2_gas_hi) // - << "," << field_to_string(row.range_check_l2_gas_lo) // - << "," << field_to_string(row.range_check_da_gas_hi) // - << "," << field_to_string(row.range_check_da_gas_lo) // - << "," << field_to_string(row.kernel_output_lookup) // - << "," << field_to_string(row.lookup_into_kernel) // - << "," << field_to_string(row.incl_main_tag_err) // - << "," << field_to_string(row.incl_mem_tag_err) // - << "," << field_to_string(row.lookup_mem_rng_chk_lo) // - << "," << field_to_string(row.lookup_mem_rng_chk_mid) // - << "," << field_to_string(row.lookup_mem_rng_chk_hi) // - << "," << field_to_string(row.lookup_pow_2_0) // - << "," << field_to_string(row.lookup_pow_2_1) // - << "," << field_to_string(row.lookup_u8_0) // - << "," << field_to_string(row.lookup_u8_1) // - << "," << field_to_string(row.lookup_u16_0) // - << "," << field_to_string(row.lookup_u16_1) // - << "," << field_to_string(row.lookup_u16_2) // - << "," << field_to_string(row.lookup_u16_3) // - << "," << field_to_string(row.lookup_u16_4) // - << "," << field_to_string(row.lookup_u16_5) // - << "," << field_to_string(row.lookup_u16_6) // - << "," << field_to_string(row.lookup_u16_7) // - << "," << field_to_string(row.lookup_u16_8) // - << "," << field_to_string(row.lookup_u16_9) // - << "," << field_to_string(row.lookup_u16_10) // - << "," << field_to_string(row.lookup_u16_11) // - << "," << field_to_string(row.lookup_u16_12) // - << "," << field_to_string(row.lookup_u16_13) // - << "," << field_to_string(row.lookup_u16_14) // - << "," << field_to_string(row.lookup_div_u16_0) // - << "," << field_to_string(row.lookup_div_u16_1) // - << "," << field_to_string(row.lookup_div_u16_2) // - << "," << field_to_string(row.lookup_div_u16_3) // - << "," << field_to_string(row.lookup_div_u16_4) // - << "," << field_to_string(row.lookup_div_u16_5) // - << "," << field_to_string(row.lookup_div_u16_6) // - << "," << field_to_string(row.lookup_div_u16_7) // - << "," << field_to_string(row.lookup_byte_lengths_counts) // - << "," << field_to_string(row.lookup_byte_operations_counts) // - << "," << field_to_string(row.lookup_cd_value_counts) // - << "," << field_to_string(row.lookup_ret_value_counts) // - << "," << field_to_string(row.lookup_opcode_gas_counts) // - << "," << field_to_string(row.range_check_l2_gas_hi_counts) // - << "," << field_to_string(row.range_check_l2_gas_lo_counts) // - << "," << field_to_string(row.range_check_da_gas_hi_counts) // - << "," << field_to_string(row.range_check_da_gas_lo_counts) // - << "," << field_to_string(row.kernel_output_lookup_counts) // - << "," << field_to_string(row.lookup_into_kernel_counts) // - << "," << field_to_string(row.incl_main_tag_err_counts) // - << "," << field_to_string(row.incl_mem_tag_err_counts) // - << "," << field_to_string(row.lookup_mem_rng_chk_lo_counts) // - << "," << field_to_string(row.lookup_mem_rng_chk_mid_counts) // - << "," << field_to_string(row.lookup_mem_rng_chk_hi_counts) // - << "," << field_to_string(row.lookup_pow_2_0_counts) // - << "," << field_to_string(row.lookup_pow_2_1_counts) // - << "," << field_to_string(row.lookup_u8_0_counts) // - << "," << field_to_string(row.lookup_u8_1_counts) // - << "," << field_to_string(row.lookup_u16_0_counts) // - << "," << field_to_string(row.lookup_u16_1_counts) // - << "," << field_to_string(row.lookup_u16_2_counts) // - << "," << field_to_string(row.lookup_u16_3_counts) // - << "," << field_to_string(row.lookup_u16_4_counts) // - << "," << field_to_string(row.lookup_u16_5_counts) // - << "," << field_to_string(row.lookup_u16_6_counts) // - << "," << field_to_string(row.lookup_u16_7_counts) // - << "," << field_to_string(row.lookup_u16_8_counts) // - << "," << field_to_string(row.lookup_u16_9_counts) // - << "," << field_to_string(row.lookup_u16_10_counts) // - << "," << field_to_string(row.lookup_u16_11_counts) // - << "," << field_to_string(row.lookup_u16_12_counts) // - << "," << field_to_string(row.lookup_u16_13_counts) // - << "," << field_to_string(row.lookup_u16_14_counts) // - << "," << field_to_string(row.lookup_div_u16_0_counts) // - << "," << field_to_string(row.lookup_div_u16_1_counts) // - << "," << field_to_string(row.lookup_div_u16_2_counts) // - << "," << field_to_string(row.lookup_div_u16_3_counts) // - << "," << field_to_string(row.lookup_div_u16_4_counts) // - << "," << field_to_string(row.lookup_div_u16_5_counts) // - << "," << field_to_string(row.lookup_div_u16_6_counts) // - << "," << field_to_string(row.lookup_div_u16_7_counts) // - ; -======= - return os - << field_to_string(row.main_clk) << "," << field_to_string(row.main_sel_first) << "," - << field_to_string(row.kernel_kernel_inputs) << "," << field_to_string(row.kernel_kernel_value_out) << "," - << field_to_string(row.kernel_kernel_side_effect_out) << "," - << field_to_string(row.kernel_kernel_metadata_out) << "," << field_to_string(row.main_calldata) << "," - << field_to_string(row.alu_a_hi) << "," << field_to_string(row.alu_a_lo) << "," - << field_to_string(row.alu_b_hi) << "," << field_to_string(row.alu_b_lo) << "," - << field_to_string(row.alu_borrow) << "," << field_to_string(row.alu_cf) << "," - << field_to_string(row.alu_clk) << "," << field_to_string(row.alu_cmp_rng_ctr) << "," - << field_to_string(row.alu_div_u16_r0) << "," << field_to_string(row.alu_div_u16_r1) << "," - << field_to_string(row.alu_div_u16_r2) << "," << field_to_string(row.alu_div_u16_r3) << "," - << field_to_string(row.alu_div_u16_r4) << "," << field_to_string(row.alu_div_u16_r5) << "," - << field_to_string(row.alu_div_u16_r6) << "," << field_to_string(row.alu_div_u16_r7) << "," - << field_to_string(row.alu_divisor_hi) << "," << field_to_string(row.alu_divisor_lo) << "," - << field_to_string(row.alu_ff_tag) << "," << field_to_string(row.alu_ia) << "," - << field_to_string(row.alu_ib) << "," << field_to_string(row.alu_ic) << "," - << field_to_string(row.alu_in_tag) << "," << field_to_string(row.alu_op_add) << "," - << field_to_string(row.alu_op_cast) << "," << field_to_string(row.alu_op_cast_prev) << "," - << field_to_string(row.alu_op_div) << "," << field_to_string(row.alu_op_div_a_lt_b) << "," - << field_to_string(row.alu_op_div_std) << "," << field_to_string(row.alu_op_eq) << "," - << field_to_string(row.alu_op_eq_diff_inv) << "," << field_to_string(row.alu_op_lt) << "," - << field_to_string(row.alu_op_lte) << "," << field_to_string(row.alu_op_mul) << "," - << field_to_string(row.alu_op_not) << "," << field_to_string(row.alu_op_shl) << "," - << field_to_string(row.alu_op_shr) << "," << field_to_string(row.alu_op_sub) << "," - << field_to_string(row.alu_p_a_borrow) << "," << field_to_string(row.alu_p_b_borrow) << "," - << field_to_string(row.alu_p_sub_a_hi) << "," << field_to_string(row.alu_p_sub_a_lo) << "," - << field_to_string(row.alu_p_sub_b_hi) << "," << field_to_string(row.alu_p_sub_b_lo) << "," - << field_to_string(row.alu_partial_prod_hi) << "," << field_to_string(row.alu_partial_prod_lo) << "," - << field_to_string(row.alu_quotient_hi) << "," << field_to_string(row.alu_quotient_lo) << "," - << field_to_string(row.alu_remainder) << "," << field_to_string(row.alu_res_hi) << "," - << field_to_string(row.alu_res_lo) << "," << field_to_string(row.alu_sel_alu) << "," - << field_to_string(row.alu_sel_cmp) << "," << field_to_string(row.alu_sel_div_rng_chk) << "," - << field_to_string(row.alu_sel_rng_chk) << "," << field_to_string(row.alu_sel_rng_chk_lookup) << "," - << field_to_string(row.alu_sel_shift_which) << "," << field_to_string(row.alu_shift_lt_bit_len) << "," - << field_to_string(row.alu_t_sub_s_bits) << "," << field_to_string(row.alu_two_pow_s) << "," - << field_to_string(row.alu_two_pow_t_sub_s) << "," << field_to_string(row.alu_u128_tag) << "," - << field_to_string(row.alu_u16_r0) << "," << field_to_string(row.alu_u16_r1) << "," - << field_to_string(row.alu_u16_r10) << "," << field_to_string(row.alu_u16_r11) << "," - << field_to_string(row.alu_u16_r12) << "," << field_to_string(row.alu_u16_r13) << "," - << field_to_string(row.alu_u16_r14) << "," << field_to_string(row.alu_u16_r2) << "," - << field_to_string(row.alu_u16_r3) << "," << field_to_string(row.alu_u16_r4) << "," - << field_to_string(row.alu_u16_r5) << "," << field_to_string(row.alu_u16_r6) << "," - << field_to_string(row.alu_u16_r7) << "," << field_to_string(row.alu_u16_r8) << "," - << field_to_string(row.alu_u16_r9) << "," << field_to_string(row.alu_u16_tag) << "," - << field_to_string(row.alu_u32_tag) << "," << field_to_string(row.alu_u64_tag) << "," - << field_to_string(row.alu_u8_r0) << "," << field_to_string(row.alu_u8_r1) << "," - << field_to_string(row.alu_u8_tag) << "," << field_to_string(row.binary_acc_ia) << "," - << field_to_string(row.binary_acc_ib) << "," << field_to_string(row.binary_acc_ic) << "," - << field_to_string(row.binary_clk) << "," << field_to_string(row.binary_ia_bytes) << "," - << field_to_string(row.binary_ib_bytes) << "," << field_to_string(row.binary_ic_bytes) << "," - << field_to_string(row.binary_in_tag) << "," << field_to_string(row.binary_mem_tag_ctr) << "," - << field_to_string(row.binary_mem_tag_ctr_inv) << "," << field_to_string(row.binary_op_id) << "," - << field_to_string(row.binary_sel_bin) << "," << field_to_string(row.binary_start) << "," - << field_to_string(row.byte_lookup_sel_bin) << "," << field_to_string(row.byte_lookup_table_byte_lengths) - << "," << field_to_string(row.byte_lookup_table_in_tags) << "," - << field_to_string(row.byte_lookup_table_input_a) << "," << field_to_string(row.byte_lookup_table_input_b) - << "," << field_to_string(row.byte_lookup_table_op_id) << "," - << field_to_string(row.byte_lookup_table_output) << "," << field_to_string(row.conversion_clk) << "," - << field_to_string(row.conversion_input) << "," << field_to_string(row.conversion_num_limbs) << "," - << field_to_string(row.conversion_radix) << "," << field_to_string(row.conversion_sel_to_radix_le) << "," - << field_to_string(row.gas_da_gas_fixed_table) << "," << field_to_string(row.gas_l2_gas_fixed_table) << "," - << field_to_string(row.gas_sel_gas_cost) << "," << field_to_string(row.keccakf1600_clk) << "," - << field_to_string(row.keccakf1600_input) << "," << field_to_string(row.keccakf1600_output) << "," - << field_to_string(row.keccakf1600_sel_keccakf1600) << "," - << field_to_string(row.kernel_emit_l2_to_l1_msg_write_offset) << "," - << field_to_string(row.kernel_emit_note_hash_write_offset) << "," - << field_to_string(row.kernel_emit_nullifier_write_offset) << "," - << field_to_string(row.kernel_emit_unencrypted_log_write_offset) << "," - << field_to_string(row.kernel_kernel_in_offset) << "," << field_to_string(row.kernel_kernel_out_offset) - << "," << field_to_string(row.kernel_l1_to_l2_msg_exists_write_offset) << "," - << field_to_string(row.kernel_note_hash_exist_write_offset) << "," - << field_to_string(row.kernel_nullifier_exists_write_offset) << "," - << field_to_string(row.kernel_nullifier_non_exists_write_offset) << "," - << field_to_string(row.kernel_q_public_input_kernel_add_to_table) << "," - << field_to_string(row.kernel_q_public_input_kernel_out_add_to_table) << "," - << field_to_string(row.kernel_side_effect_counter) << "," << field_to_string(row.kernel_sload_write_offset) - << "," << field_to_string(row.kernel_sstore_write_offset) << "," - << field_to_string(row.main_abs_da_rem_gas_hi) << "," << field_to_string(row.main_abs_da_rem_gas_lo) << "," - << field_to_string(row.main_abs_l2_rem_gas_hi) << "," << field_to_string(row.main_abs_l2_rem_gas_lo) << "," - << field_to_string(row.main_alu_in_tag) << "," << field_to_string(row.main_bin_op_id) << "," - << field_to_string(row.main_call_ptr) << "," << field_to_string(row.main_da_gas_op_cost) << "," - << field_to_string(row.main_da_gas_remaining) << "," << field_to_string(row.main_da_out_of_gas) << "," - << field_to_string(row.main_ia) << "," << field_to_string(row.main_ib) << "," << field_to_string(row.main_ic) - << "," << field_to_string(row.main_id) << "," << field_to_string(row.main_id_zero) << "," - << field_to_string(row.main_ind_addr_a) << "," << field_to_string(row.main_ind_addr_b) << "," - << field_to_string(row.main_ind_addr_c) << "," << field_to_string(row.main_ind_addr_d) << "," - << field_to_string(row.main_internal_return_ptr) << "," << field_to_string(row.main_inv) << "," - << field_to_string(row.main_l2_gas_op_cost) << "," << field_to_string(row.main_l2_gas_remaining) << "," - << field_to_string(row.main_l2_out_of_gas) << "," << field_to_string(row.main_mem_addr_a) << "," - << field_to_string(row.main_mem_addr_b) << "," << field_to_string(row.main_mem_addr_c) << "," - << field_to_string(row.main_mem_addr_d) << "," << field_to_string(row.main_op_err) << "," - << field_to_string(row.main_opcode_val) << "," << field_to_string(row.main_pc) << "," - << field_to_string(row.main_r_in_tag) << "," << field_to_string(row.main_rwa) << "," - << field_to_string(row.main_rwb) << "," << field_to_string(row.main_rwc) << "," - << field_to_string(row.main_rwd) << "," << field_to_string(row.main_sel_alu) << "," - << field_to_string(row.main_sel_bin) << "," << field_to_string(row.main_sel_gas_accounting_active) << "," - << field_to_string(row.main_sel_last) << "," << field_to_string(row.main_sel_mem_op_a) << "," - << field_to_string(row.main_sel_mem_op_activate_gas) << "," << field_to_string(row.main_sel_mem_op_b) << "," - << field_to_string(row.main_sel_mem_op_c) << "," << field_to_string(row.main_sel_mem_op_d) << "," - << field_to_string(row.main_sel_mov_ia_to_ic) << "," << field_to_string(row.main_sel_mov_ib_to_ic) << "," - << field_to_string(row.main_sel_op_add) << "," << field_to_string(row.main_sel_op_address) << "," - << field_to_string(row.main_sel_op_and) << "," << field_to_string(row.main_sel_op_block_number) << "," - << field_to_string(row.main_sel_op_cast) << "," << field_to_string(row.main_sel_op_chain_id) << "," - << field_to_string(row.main_sel_op_cmov) << "," << field_to_string(row.main_sel_op_coinbase) << "," - << field_to_string(row.main_sel_op_dagasleft) << "," << field_to_string(row.main_sel_op_div) << "," - << field_to_string(row.main_sel_op_emit_l2_to_l1_msg) << "," - << field_to_string(row.main_sel_op_emit_note_hash) << "," << field_to_string(row.main_sel_op_emit_nullifier) - << "," << field_to_string(row.main_sel_op_emit_unencrypted_log) << "," << field_to_string(row.main_sel_op_eq) - << "," << field_to_string(row.main_sel_op_external_call) << "," << field_to_string(row.main_sel_op_fdiv) - << "," << field_to_string(row.main_sel_op_fee_per_da_gas) << "," - << field_to_string(row.main_sel_op_fee_per_l2_gas) << "," - << field_to_string(row.main_sel_op_function_selector) << "," - << field_to_string(row.main_sel_op_get_contract_instance) << "," << field_to_string(row.main_sel_op_halt) - << "," << field_to_string(row.main_sel_op_internal_call) << "," - << field_to_string(row.main_sel_op_internal_return) << "," << field_to_string(row.main_sel_op_jump) << "," - << field_to_string(row.main_sel_op_jumpi) << "," << field_to_string(row.main_sel_op_keccak) << "," - << field_to_string(row.main_sel_op_l1_to_l2_msg_exists) << "," << field_to_string(row.main_sel_op_l2gasleft) - << "," << field_to_string(row.main_sel_op_lt) << "," << field_to_string(row.main_sel_op_lte) << "," - << field_to_string(row.main_sel_op_mov) << "," << field_to_string(row.main_sel_op_mul) << "," - << field_to_string(row.main_sel_op_not) << "," << field_to_string(row.main_sel_op_note_hash_exists) << "," - << field_to_string(row.main_sel_op_nullifier_exists) << "," << field_to_string(row.main_sel_op_or) << "," - << field_to_string(row.main_sel_op_pedersen) << "," << field_to_string(row.main_sel_op_poseidon2) << "," - << field_to_string(row.main_sel_op_radix_le) << "," << field_to_string(row.main_sel_op_sender) << "," - << field_to_string(row.main_sel_op_sha256) << "," << field_to_string(row.main_sel_op_shl) << "," - << field_to_string(row.main_sel_op_shr) << "," << field_to_string(row.main_sel_op_sload) << "," - << field_to_string(row.main_sel_op_sstore) << "," << field_to_string(row.main_sel_op_storage_address) << "," - << field_to_string(row.main_sel_op_sub) << "," << field_to_string(row.main_sel_op_timestamp) << "," - << field_to_string(row.main_sel_op_transaction_fee) << "," << field_to_string(row.main_sel_op_version) << "," - << field_to_string(row.main_sel_op_xor) << "," << field_to_string(row.main_sel_q_kernel_lookup) << "," - << field_to_string(row.main_sel_q_kernel_output_lookup) << "," - << field_to_string(row.main_sel_resolve_ind_addr_a) << "," - << field_to_string(row.main_sel_resolve_ind_addr_b) << "," - << field_to_string(row.main_sel_resolve_ind_addr_c) << "," - << field_to_string(row.main_sel_resolve_ind_addr_d) << "," << field_to_string(row.main_sel_rng_16) << "," - << field_to_string(row.main_sel_rng_8) << "," << field_to_string(row.main_space_id) << "," - << field_to_string(row.main_tag_err) << "," << field_to_string(row.main_w_in_tag) << "," - << field_to_string(row.mem_addr) << "," << field_to_string(row.mem_clk) << "," - << field_to_string(row.mem_diff_hi) << "," << field_to_string(row.mem_diff_lo) << "," - << field_to_string(row.mem_diff_mid) << "," << field_to_string(row.mem_glob_addr) << "," - << field_to_string(row.mem_last) << "," << field_to_string(row.mem_lastAccess) << "," - << field_to_string(row.mem_one_min_inv) << "," << field_to_string(row.mem_r_in_tag) << "," - << field_to_string(row.mem_rw) << "," << field_to_string(row.mem_sel_mem) << "," - << field_to_string(row.mem_sel_mov_ia_to_ic) << "," << field_to_string(row.mem_sel_mov_ib_to_ic) << "," - << field_to_string(row.mem_sel_op_a) << "," << field_to_string(row.mem_sel_op_b) << "," - << field_to_string(row.mem_sel_op_c) << "," << field_to_string(row.mem_sel_op_cmov) << "," - << field_to_string(row.mem_sel_op_d) << "," << field_to_string(row.mem_sel_resolve_ind_addr_a) << "," - << field_to_string(row.mem_sel_resolve_ind_addr_b) << "," << field_to_string(row.mem_sel_resolve_ind_addr_c) - << "," << field_to_string(row.mem_sel_resolve_ind_addr_d) << "," << field_to_string(row.mem_sel_rng_chk) - << "," << field_to_string(row.mem_skip_check_tag) << "," << field_to_string(row.mem_space_id) << "," - << field_to_string(row.mem_tag) << "," << field_to_string(row.mem_tag_err) << "," - << field_to_string(row.mem_tsp) << "," << field_to_string(row.mem_val) << "," - << field_to_string(row.mem_w_in_tag) << "," << field_to_string(row.pedersen_clk) << "," - << field_to_string(row.pedersen_input) << "," << field_to_string(row.pedersen_output) << "," - << field_to_string(row.pedersen_sel_pedersen) << "," << field_to_string(row.poseidon2_a_0) << "," - << field_to_string(row.poseidon2_a_1) << "," << field_to_string(row.poseidon2_a_2) << "," - << field_to_string(row.poseidon2_a_3) << "," << field_to_string(row.poseidon2_b_0) << "," - << field_to_string(row.poseidon2_b_1) << "," << field_to_string(row.poseidon2_b_2) << "," - << field_to_string(row.poseidon2_b_3) << "," << field_to_string(row.poseidon2_clk) << "," - << field_to_string(row.poseidon2_input) << "," << field_to_string(row.poseidon2_output) << "," - << field_to_string(row.poseidon2_sel_poseidon_perm) << "," << field_to_string(row.powers_power_of_2) << "," - << field_to_string(row.sha256_clk) << "," << field_to_string(row.sha256_input) << "," - << field_to_string(row.sha256_output) << "," << field_to_string(row.sha256_sel_sha256_compression) << "," - << field_to_string(row.sha256_state) << "," << field_to_string(row.perm_main_alu) << "," - << field_to_string(row.perm_main_bin) << "," << field_to_string(row.perm_main_conv) << "," - << field_to_string(row.perm_main_pos2_perm) << "," << field_to_string(row.perm_main_pedersen) << "," - << field_to_string(row.perm_main_mem_a) << "," << field_to_string(row.perm_main_mem_b) << "," - << field_to_string(row.perm_main_mem_c) << "," << field_to_string(row.perm_main_mem_d) << "," - << field_to_string(row.perm_main_mem_ind_addr_a) << "," << field_to_string(row.perm_main_mem_ind_addr_b) - << "," << field_to_string(row.perm_main_mem_ind_addr_c) << "," - << field_to_string(row.perm_main_mem_ind_addr_d) << "," << field_to_string(row.lookup_byte_lengths) << "," - << field_to_string(row.lookup_byte_operations) << "," << field_to_string(row.lookup_opcode_gas) << "," - << field_to_string(row.range_check_l2_gas_hi) << "," << field_to_string(row.range_check_l2_gas_lo) << "," - << field_to_string(row.range_check_da_gas_hi) << "," << field_to_string(row.range_check_da_gas_lo) << "," - << field_to_string(row.kernel_output_lookup) << "," << field_to_string(row.lookup_into_kernel) << "," - << field_to_string(row.incl_main_tag_err) << "," << field_to_string(row.incl_mem_tag_err) << "," - << field_to_string(row.lookup_mem_rng_chk_lo) << "," << field_to_string(row.lookup_mem_rng_chk_mid) << "," - << field_to_string(row.lookup_mem_rng_chk_hi) << "," << field_to_string(row.lookup_pow_2_0) << "," - << field_to_string(row.lookup_pow_2_1) << "," << field_to_string(row.lookup_u8_0) << "," - << field_to_string(row.lookup_u8_1) << "," << field_to_string(row.lookup_u16_0) << "," - << field_to_string(row.lookup_u16_1) << "," << field_to_string(row.lookup_u16_2) << "," - << field_to_string(row.lookup_u16_3) << "," << field_to_string(row.lookup_u16_4) << "," - << field_to_string(row.lookup_u16_5) << "," << field_to_string(row.lookup_u16_6) << "," - << field_to_string(row.lookup_u16_7) << "," << field_to_string(row.lookup_u16_8) << "," - << field_to_string(row.lookup_u16_9) << "," << field_to_string(row.lookup_u16_10) << "," - << field_to_string(row.lookup_u16_11) << "," << field_to_string(row.lookup_u16_12) << "," - << field_to_string(row.lookup_u16_13) << "," << field_to_string(row.lookup_u16_14) << "," - << field_to_string(row.lookup_div_u16_0) << "," << field_to_string(row.lookup_div_u16_1) << "," - << field_to_string(row.lookup_div_u16_2) << "," << field_to_string(row.lookup_div_u16_3) << "," - << field_to_string(row.lookup_div_u16_4) << "," << field_to_string(row.lookup_div_u16_5) << "," - << field_to_string(row.lookup_div_u16_6) << "," << field_to_string(row.lookup_div_u16_7) << "," - << field_to_string(row.lookup_byte_lengths_counts) << "," - << field_to_string(row.lookup_byte_operations_counts) << "," << field_to_string(row.lookup_opcode_gas_counts) - << "," << field_to_string(row.range_check_l2_gas_hi_counts) << "," - << field_to_string(row.range_check_l2_gas_lo_counts) << "," - << field_to_string(row.range_check_da_gas_hi_counts) << "," - << field_to_string(row.range_check_da_gas_lo_counts) << "," - << field_to_string(row.kernel_output_lookup_counts) << "," << field_to_string(row.lookup_into_kernel_counts) - << "," << field_to_string(row.incl_main_tag_err_counts) << "," - << field_to_string(row.incl_mem_tag_err_counts) << "," << field_to_string(row.lookup_mem_rng_chk_lo_counts) - << "," << field_to_string(row.lookup_mem_rng_chk_mid_counts) << "," - << field_to_string(row.lookup_mem_rng_chk_hi_counts) << "," << field_to_string(row.lookup_pow_2_0_counts) - << "," << field_to_string(row.lookup_pow_2_1_counts) << "," << field_to_string(row.lookup_u8_0_counts) << "," - << field_to_string(row.lookup_u8_1_counts) << "," << field_to_string(row.lookup_u16_0_counts) << "," - << field_to_string(row.lookup_u16_1_counts) << "," << field_to_string(row.lookup_u16_2_counts) << "," - << field_to_string(row.lookup_u16_3_counts) << "," << field_to_string(row.lookup_u16_4_counts) << "," - << field_to_string(row.lookup_u16_5_counts) << "," << field_to_string(row.lookup_u16_6_counts) << "," - << field_to_string(row.lookup_u16_7_counts) << "," << field_to_string(row.lookup_u16_8_counts) << "," - << field_to_string(row.lookup_u16_9_counts) << "," << field_to_string(row.lookup_u16_10_counts) << "," - << field_to_string(row.lookup_u16_11_counts) << "," << field_to_string(row.lookup_u16_12_counts) << "," - << field_to_string(row.lookup_u16_13_counts) << "," << field_to_string(row.lookup_u16_14_counts) << "," - << field_to_string(row.lookup_div_u16_0_counts) << "," << field_to_string(row.lookup_div_u16_1_counts) << "," - << field_to_string(row.lookup_div_u16_2_counts) << "," << field_to_string(row.lookup_div_u16_3_counts) << "," - << field_to_string(row.lookup_div_u16_4_counts) << "," << field_to_string(row.lookup_div_u16_5_counts) << "," - << field_to_string(row.lookup_div_u16_6_counts) << "," << field_to_string(row.lookup_div_u16_7_counts) - << "," - ""; ->>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) ->>>>>>> 822f92e90 (feat(avm): poseidon2 constraints) } // Explicit template instantiation. diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.hpp index dbc72265711b..0c5bc1fe28e3 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.hpp @@ -282,6 +282,10 @@ template struct AvmFullRow { FF mem_sel_op_c{}; FF mem_sel_op_cmov{}; FF mem_sel_op_d{}; + FF mem_sel_op_gadget_a{}; + FF mem_sel_op_gadget_b{}; + FF mem_sel_op_gadget_c{}; + FF mem_sel_op_gadget_d{}; FF mem_sel_op_slice{}; FF mem_sel_resolve_ind_addr_a{}; FF mem_sel_resolve_ind_addr_b{}; @@ -299,10 +303,286 @@ template struct AvmFullRow { FF pedersen_input{}; FF pedersen_output{}; FF pedersen_sel_pedersen{}; + FF poseidon2_B_10_0{}; + FF poseidon2_B_10_1{}; + FF poseidon2_B_10_2{}; + FF poseidon2_B_10_3{}; + FF poseidon2_B_11_0{}; + FF poseidon2_B_11_1{}; + FF poseidon2_B_11_2{}; + FF poseidon2_B_11_3{}; + FF poseidon2_B_12_0{}; + FF poseidon2_B_12_1{}; + FF poseidon2_B_12_2{}; + FF poseidon2_B_12_3{}; + FF poseidon2_B_13_0{}; + FF poseidon2_B_13_1{}; + FF poseidon2_B_13_2{}; + FF poseidon2_B_13_3{}; + FF poseidon2_B_14_0{}; + FF poseidon2_B_14_1{}; + FF poseidon2_B_14_2{}; + FF poseidon2_B_14_3{}; + FF poseidon2_B_15_0{}; + FF poseidon2_B_15_1{}; + FF poseidon2_B_15_2{}; + FF poseidon2_B_15_3{}; + FF poseidon2_B_16_0{}; + FF poseidon2_B_16_1{}; + FF poseidon2_B_16_2{}; + FF poseidon2_B_16_3{}; + FF poseidon2_B_17_0{}; + FF poseidon2_B_17_1{}; + FF poseidon2_B_17_2{}; + FF poseidon2_B_17_3{}; + FF poseidon2_B_18_0{}; + FF poseidon2_B_18_1{}; + FF poseidon2_B_18_2{}; + FF poseidon2_B_18_3{}; + FF poseidon2_B_19_0{}; + FF poseidon2_B_19_1{}; + FF poseidon2_B_19_2{}; + FF poseidon2_B_19_3{}; + FF poseidon2_B_20_0{}; + FF poseidon2_B_20_1{}; + FF poseidon2_B_20_2{}; + FF poseidon2_B_20_3{}; + FF poseidon2_B_21_0{}; + FF poseidon2_B_21_1{}; + FF poseidon2_B_21_2{}; + FF poseidon2_B_21_3{}; + FF poseidon2_B_22_0{}; + FF poseidon2_B_22_1{}; + FF poseidon2_B_22_2{}; + FF poseidon2_B_22_3{}; + FF poseidon2_B_23_0{}; + FF poseidon2_B_23_1{}; + FF poseidon2_B_23_2{}; + FF poseidon2_B_23_3{}; + FF poseidon2_B_24_0{}; + FF poseidon2_B_24_1{}; + FF poseidon2_B_24_2{}; + FF poseidon2_B_24_3{}; + FF poseidon2_B_25_0{}; + FF poseidon2_B_25_1{}; + FF poseidon2_B_25_2{}; + FF poseidon2_B_25_3{}; + FF poseidon2_B_26_0{}; + FF poseidon2_B_26_1{}; + FF poseidon2_B_26_2{}; + FF poseidon2_B_26_3{}; + FF poseidon2_B_27_0{}; + FF poseidon2_B_27_1{}; + FF poseidon2_B_27_2{}; + FF poseidon2_B_27_3{}; + FF poseidon2_B_28_0{}; + FF poseidon2_B_28_1{}; + FF poseidon2_B_28_2{}; + FF poseidon2_B_28_3{}; + FF poseidon2_B_29_0{}; + FF poseidon2_B_29_1{}; + FF poseidon2_B_29_2{}; + FF poseidon2_B_29_3{}; + FF poseidon2_B_30_0{}; + FF poseidon2_B_30_1{}; + FF poseidon2_B_30_2{}; + FF poseidon2_B_30_3{}; + FF poseidon2_B_31_0{}; + FF poseidon2_B_31_1{}; + FF poseidon2_B_31_2{}; + FF poseidon2_B_31_3{}; + FF poseidon2_B_32_0{}; + FF poseidon2_B_32_1{}; + FF poseidon2_B_32_2{}; + FF poseidon2_B_32_3{}; + FF poseidon2_B_33_0{}; + FF poseidon2_B_33_1{}; + FF poseidon2_B_33_2{}; + FF poseidon2_B_33_3{}; + FF poseidon2_B_34_0{}; + FF poseidon2_B_34_1{}; + FF poseidon2_B_34_2{}; + FF poseidon2_B_34_3{}; + FF poseidon2_B_35_0{}; + FF poseidon2_B_35_1{}; + FF poseidon2_B_35_2{}; + FF poseidon2_B_35_3{}; + FF poseidon2_B_36_0{}; + FF poseidon2_B_36_1{}; + FF poseidon2_B_36_2{}; + FF poseidon2_B_36_3{}; + FF poseidon2_B_37_0{}; + FF poseidon2_B_37_1{}; + FF poseidon2_B_37_2{}; + FF poseidon2_B_37_3{}; + FF poseidon2_B_38_0{}; + FF poseidon2_B_38_1{}; + FF poseidon2_B_38_2{}; + FF poseidon2_B_38_3{}; + FF poseidon2_B_39_0{}; + FF poseidon2_B_39_1{}; + FF poseidon2_B_39_2{}; + FF poseidon2_B_39_3{}; + FF poseidon2_B_40_0{}; + FF poseidon2_B_40_1{}; + FF poseidon2_B_40_2{}; + FF poseidon2_B_40_3{}; + FF poseidon2_B_41_0{}; + FF poseidon2_B_41_1{}; + FF poseidon2_B_41_2{}; + FF poseidon2_B_41_3{}; + FF poseidon2_B_42_0{}; + FF poseidon2_B_42_1{}; + FF poseidon2_B_42_2{}; + FF poseidon2_B_42_3{}; + FF poseidon2_B_43_0{}; + FF poseidon2_B_43_1{}; + FF poseidon2_B_43_2{}; + FF poseidon2_B_43_3{}; + FF poseidon2_B_44_0{}; + FF poseidon2_B_44_1{}; + FF poseidon2_B_44_2{}; + FF poseidon2_B_44_3{}; + FF poseidon2_B_45_0{}; + FF poseidon2_B_45_1{}; + FF poseidon2_B_45_2{}; + FF poseidon2_B_45_3{}; + FF poseidon2_B_46_0{}; + FF poseidon2_B_46_1{}; + FF poseidon2_B_46_2{}; + FF poseidon2_B_46_3{}; + FF poseidon2_B_47_0{}; + FF poseidon2_B_47_1{}; + FF poseidon2_B_47_2{}; + FF poseidon2_B_47_3{}; + FF poseidon2_B_48_0{}; + FF poseidon2_B_48_1{}; + FF poseidon2_B_48_2{}; + FF poseidon2_B_48_3{}; + FF poseidon2_B_49_0{}; + FF poseidon2_B_49_1{}; + FF poseidon2_B_49_2{}; + FF poseidon2_B_49_3{}; + FF poseidon2_B_4_0{}; + FF poseidon2_B_4_1{}; + FF poseidon2_B_4_2{}; + FF poseidon2_B_4_3{}; + FF poseidon2_B_50_0{}; + FF poseidon2_B_50_1{}; + FF poseidon2_B_50_2{}; + FF poseidon2_B_50_3{}; + FF poseidon2_B_51_0{}; + FF poseidon2_B_51_1{}; + FF poseidon2_B_51_2{}; + FF poseidon2_B_51_3{}; + FF poseidon2_B_52_0{}; + FF poseidon2_B_52_1{}; + FF poseidon2_B_52_2{}; + FF poseidon2_B_52_3{}; + FF poseidon2_B_53_0{}; + FF poseidon2_B_53_1{}; + FF poseidon2_B_53_2{}; + FF poseidon2_B_53_3{}; + FF poseidon2_B_54_0{}; + FF poseidon2_B_54_1{}; + FF poseidon2_B_54_2{}; + FF poseidon2_B_54_3{}; + FF poseidon2_B_55_0{}; + FF poseidon2_B_55_1{}; + FF poseidon2_B_55_2{}; + FF poseidon2_B_55_3{}; + FF poseidon2_B_56_0{}; + FF poseidon2_B_56_1{}; + FF poseidon2_B_56_2{}; + FF poseidon2_B_56_3{}; + FF poseidon2_B_57_0{}; + FF poseidon2_B_57_1{}; + FF poseidon2_B_57_2{}; + FF poseidon2_B_57_3{}; + FF poseidon2_B_58_0{}; + FF poseidon2_B_58_1{}; + FF poseidon2_B_58_2{}; + FF poseidon2_B_58_3{}; + FF poseidon2_B_59_0{}; + FF poseidon2_B_59_1{}; + FF poseidon2_B_59_2{}; + FF poseidon2_B_59_3{}; + FF poseidon2_B_5_0{}; + FF poseidon2_B_5_1{}; + FF poseidon2_B_5_2{}; + FF poseidon2_B_5_3{}; + FF poseidon2_B_6_0{}; + FF poseidon2_B_6_1{}; + FF poseidon2_B_6_2{}; + FF poseidon2_B_6_3{}; + FF poseidon2_B_7_0{}; + FF poseidon2_B_7_1{}; + FF poseidon2_B_7_2{}; + FF poseidon2_B_7_3{}; + FF poseidon2_B_8_0{}; + FF poseidon2_B_8_1{}; + FF poseidon2_B_8_2{}; + FF poseidon2_B_8_3{}; + FF poseidon2_B_9_0{}; + FF poseidon2_B_9_1{}; + FF poseidon2_B_9_2{}; + FF poseidon2_B_9_3{}; + FF poseidon2_EXT_LAYER_4{}; + FF poseidon2_EXT_LAYER_5{}; + FF poseidon2_EXT_LAYER_6{}; + FF poseidon2_EXT_LAYER_7{}; + FF poseidon2_T_0_4{}; + FF poseidon2_T_0_5{}; + FF poseidon2_T_0_6{}; + FF poseidon2_T_0_7{}; + FF poseidon2_T_1_4{}; + FF poseidon2_T_1_5{}; + FF poseidon2_T_1_6{}; + FF poseidon2_T_1_7{}; + FF poseidon2_T_2_4{}; + FF poseidon2_T_2_5{}; + FF poseidon2_T_2_6{}; + FF poseidon2_T_2_7{}; + FF poseidon2_T_3_4{}; + FF poseidon2_T_3_5{}; + FF poseidon2_T_3_6{}; + FF poseidon2_T_3_7{}; + FF poseidon2_T_60_4{}; + FF poseidon2_T_60_5{}; + FF poseidon2_T_60_6{}; + FF poseidon2_T_60_7{}; + FF poseidon2_T_61_4{}; + FF poseidon2_T_61_5{}; + FF poseidon2_T_61_6{}; + FF poseidon2_T_61_7{}; + FF poseidon2_T_62_4{}; + FF poseidon2_T_62_5{}; + FF poseidon2_T_62_6{}; + FF poseidon2_T_62_7{}; + FF poseidon2_T_63_4{}; + FF poseidon2_T_63_5{}; + FF poseidon2_T_63_6{}; + FF poseidon2_T_63_7{}; + FF poseidon2_a_0{}; + FF poseidon2_a_1{}; + FF poseidon2_a_2{}; + FF poseidon2_a_3{}; + FF poseidon2_b_0{}; + FF poseidon2_b_1{}; + FF poseidon2_b_2{}; + FF poseidon2_b_3{}; FF poseidon2_clk{}; - FF poseidon2_input{}; - FF poseidon2_output{}; + FF poseidon2_in_tag{}; + FF poseidon2_input_addr{}; + FF poseidon2_mem_addr_a{}; + FF poseidon2_mem_addr_b{}; + FF poseidon2_mem_addr_c{}; + FF poseidon2_mem_addr_d{}; + FF poseidon2_mem_op{}; + FF poseidon2_output_addr{}; + FF poseidon2_read_line{}; FF poseidon2_sel_poseidon_perm{}; + FF poseidon2_write_line{}; FF powers_power_of_2{}; FF sha256_clk{}; FF sha256_input{}; @@ -320,6 +600,10 @@ template struct AvmFullRow { FF slice_sel_start{}; FF slice_space_id{}; FF slice_val{}; + FF perm_pos_mem_a{}; + FF perm_pos_mem_b{}; + FF perm_pos_mem_c{}; + FF perm_pos_mem_d{}; FF perm_slice_mem{}; FF perm_main_alu{}; FF perm_main_bin{}; @@ -425,7 +709,7 @@ template struct AvmFullRow { RefVector as_vector() const; static std::vector names(); - static constexpr size_t SIZE = 411; + static constexpr size_t SIZE = 695; }; template std::ostream& operator<<(std::ostream& os, AvmFullRow const& row); diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/prover.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/prover.cpp index efea2c734f19..d5cbab1767e0 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/prover.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/prover.cpp @@ -61,786 +61,11 @@ void AvmProver::execute_wire_commitments_round() { // Commit to all polynomials (apart from logderivative inverse polynomials, which are committed to in the later // logderivative phase) -<<<<<<< HEAD auto wire_polys = prover_polynomials.get_wires(); auto labels = commitment_labels.get_wires(); for (size_t idx = 0; idx < wire_polys.size(); ++idx) { transcript->send_to_verifier(labels[idx], commitment_key->commit_sparse(wire_polys[idx])); } -======= - witness_commitments.kernel_kernel_inputs = commitment_key->commit(key->kernel_kernel_inputs); - witness_commitments.kernel_kernel_value_out = commitment_key->commit(key->kernel_kernel_value_out); - witness_commitments.kernel_kernel_side_effect_out = commitment_key->commit(key->kernel_kernel_side_effect_out); - witness_commitments.kernel_kernel_metadata_out = commitment_key->commit(key->kernel_kernel_metadata_out); - witness_commitments.main_calldata = commitment_key->commit(key->main_calldata); - witness_commitments.alu_a_hi = commitment_key->commit(key->alu_a_hi); - witness_commitments.alu_a_lo = commitment_key->commit(key->alu_a_lo); - witness_commitments.alu_b_hi = commitment_key->commit(key->alu_b_hi); - witness_commitments.alu_b_lo = commitment_key->commit(key->alu_b_lo); - witness_commitments.alu_borrow = commitment_key->commit(key->alu_borrow); - witness_commitments.alu_cf = commitment_key->commit(key->alu_cf); - witness_commitments.alu_clk = commitment_key->commit(key->alu_clk); - witness_commitments.alu_cmp_rng_ctr = commitment_key->commit(key->alu_cmp_rng_ctr); - witness_commitments.alu_div_u16_r0 = commitment_key->commit(key->alu_div_u16_r0); - witness_commitments.alu_div_u16_r1 = commitment_key->commit(key->alu_div_u16_r1); - witness_commitments.alu_div_u16_r2 = commitment_key->commit(key->alu_div_u16_r2); - witness_commitments.alu_div_u16_r3 = commitment_key->commit(key->alu_div_u16_r3); - witness_commitments.alu_div_u16_r4 = commitment_key->commit(key->alu_div_u16_r4); - witness_commitments.alu_div_u16_r5 = commitment_key->commit(key->alu_div_u16_r5); - witness_commitments.alu_div_u16_r6 = commitment_key->commit(key->alu_div_u16_r6); - witness_commitments.alu_div_u16_r7 = commitment_key->commit(key->alu_div_u16_r7); - witness_commitments.alu_divisor_hi = commitment_key->commit(key->alu_divisor_hi); - witness_commitments.alu_divisor_lo = commitment_key->commit(key->alu_divisor_lo); - witness_commitments.alu_ff_tag = commitment_key->commit(key->alu_ff_tag); - witness_commitments.alu_ia = commitment_key->commit(key->alu_ia); - witness_commitments.alu_ib = commitment_key->commit(key->alu_ib); - witness_commitments.alu_ic = commitment_key->commit(key->alu_ic); - witness_commitments.alu_in_tag = commitment_key->commit(key->alu_in_tag); - witness_commitments.alu_op_add = commitment_key->commit(key->alu_op_add); - witness_commitments.alu_op_cast = commitment_key->commit(key->alu_op_cast); - witness_commitments.alu_op_cast_prev = commitment_key->commit(key->alu_op_cast_prev); - witness_commitments.alu_op_div = commitment_key->commit(key->alu_op_div); - witness_commitments.alu_op_div_a_lt_b = commitment_key->commit(key->alu_op_div_a_lt_b); - witness_commitments.alu_op_div_std = commitment_key->commit(key->alu_op_div_std); - witness_commitments.alu_op_eq = commitment_key->commit(key->alu_op_eq); - witness_commitments.alu_op_eq_diff_inv = commitment_key->commit(key->alu_op_eq_diff_inv); - witness_commitments.alu_op_lt = commitment_key->commit(key->alu_op_lt); - witness_commitments.alu_op_lte = commitment_key->commit(key->alu_op_lte); - witness_commitments.alu_op_mul = commitment_key->commit(key->alu_op_mul); - witness_commitments.alu_op_not = commitment_key->commit(key->alu_op_not); - witness_commitments.alu_op_shl = commitment_key->commit(key->alu_op_shl); - witness_commitments.alu_op_shr = commitment_key->commit(key->alu_op_shr); - witness_commitments.alu_op_sub = commitment_key->commit(key->alu_op_sub); - witness_commitments.alu_p_a_borrow = commitment_key->commit(key->alu_p_a_borrow); - witness_commitments.alu_p_b_borrow = commitment_key->commit(key->alu_p_b_borrow); - witness_commitments.alu_p_sub_a_hi = commitment_key->commit(key->alu_p_sub_a_hi); - witness_commitments.alu_p_sub_a_lo = commitment_key->commit(key->alu_p_sub_a_lo); - witness_commitments.alu_p_sub_b_hi = commitment_key->commit(key->alu_p_sub_b_hi); - witness_commitments.alu_p_sub_b_lo = commitment_key->commit(key->alu_p_sub_b_lo); - witness_commitments.alu_partial_prod_hi = commitment_key->commit(key->alu_partial_prod_hi); - witness_commitments.alu_partial_prod_lo = commitment_key->commit(key->alu_partial_prod_lo); - witness_commitments.alu_quotient_hi = commitment_key->commit(key->alu_quotient_hi); - witness_commitments.alu_quotient_lo = commitment_key->commit(key->alu_quotient_lo); - witness_commitments.alu_remainder = commitment_key->commit(key->alu_remainder); - witness_commitments.alu_res_hi = commitment_key->commit(key->alu_res_hi); - witness_commitments.alu_res_lo = commitment_key->commit(key->alu_res_lo); - witness_commitments.alu_sel_alu = commitment_key->commit(key->alu_sel_alu); - witness_commitments.alu_sel_cmp = commitment_key->commit(key->alu_sel_cmp); - witness_commitments.alu_sel_div_rng_chk = commitment_key->commit(key->alu_sel_div_rng_chk); - witness_commitments.alu_sel_rng_chk = commitment_key->commit(key->alu_sel_rng_chk); - witness_commitments.alu_sel_rng_chk_lookup = commitment_key->commit(key->alu_sel_rng_chk_lookup); - witness_commitments.alu_sel_shift_which = commitment_key->commit(key->alu_sel_shift_which); - witness_commitments.alu_shift_lt_bit_len = commitment_key->commit(key->alu_shift_lt_bit_len); - witness_commitments.alu_t_sub_s_bits = commitment_key->commit(key->alu_t_sub_s_bits); - witness_commitments.alu_two_pow_s = commitment_key->commit(key->alu_two_pow_s); - witness_commitments.alu_two_pow_t_sub_s = commitment_key->commit(key->alu_two_pow_t_sub_s); - witness_commitments.alu_u128_tag = commitment_key->commit(key->alu_u128_tag); - witness_commitments.alu_u16_r0 = commitment_key->commit(key->alu_u16_r0); - witness_commitments.alu_u16_r1 = commitment_key->commit(key->alu_u16_r1); - witness_commitments.alu_u16_r10 = commitment_key->commit(key->alu_u16_r10); - witness_commitments.alu_u16_r11 = commitment_key->commit(key->alu_u16_r11); - witness_commitments.alu_u16_r12 = commitment_key->commit(key->alu_u16_r12); - witness_commitments.alu_u16_r13 = commitment_key->commit(key->alu_u16_r13); - witness_commitments.alu_u16_r14 = commitment_key->commit(key->alu_u16_r14); - witness_commitments.alu_u16_r2 = commitment_key->commit(key->alu_u16_r2); - witness_commitments.alu_u16_r3 = commitment_key->commit(key->alu_u16_r3); - witness_commitments.alu_u16_r4 = commitment_key->commit(key->alu_u16_r4); - witness_commitments.alu_u16_r5 = commitment_key->commit(key->alu_u16_r5); - witness_commitments.alu_u16_r6 = commitment_key->commit(key->alu_u16_r6); - witness_commitments.alu_u16_r7 = commitment_key->commit(key->alu_u16_r7); - witness_commitments.alu_u16_r8 = commitment_key->commit(key->alu_u16_r8); - witness_commitments.alu_u16_r9 = commitment_key->commit(key->alu_u16_r9); - witness_commitments.alu_u16_tag = commitment_key->commit(key->alu_u16_tag); - witness_commitments.alu_u32_tag = commitment_key->commit(key->alu_u32_tag); - witness_commitments.alu_u64_tag = commitment_key->commit(key->alu_u64_tag); - witness_commitments.alu_u8_r0 = commitment_key->commit(key->alu_u8_r0); - witness_commitments.alu_u8_r1 = commitment_key->commit(key->alu_u8_r1); - witness_commitments.alu_u8_tag = commitment_key->commit(key->alu_u8_tag); - witness_commitments.binary_acc_ia = commitment_key->commit(key->binary_acc_ia); - witness_commitments.binary_acc_ib = commitment_key->commit(key->binary_acc_ib); - witness_commitments.binary_acc_ic = commitment_key->commit(key->binary_acc_ic); - witness_commitments.binary_clk = commitment_key->commit(key->binary_clk); - witness_commitments.binary_ia_bytes = commitment_key->commit(key->binary_ia_bytes); - witness_commitments.binary_ib_bytes = commitment_key->commit(key->binary_ib_bytes); - witness_commitments.binary_ic_bytes = commitment_key->commit(key->binary_ic_bytes); - witness_commitments.binary_in_tag = commitment_key->commit(key->binary_in_tag); - witness_commitments.binary_mem_tag_ctr = commitment_key->commit(key->binary_mem_tag_ctr); - witness_commitments.binary_mem_tag_ctr_inv = commitment_key->commit(key->binary_mem_tag_ctr_inv); - witness_commitments.binary_op_id = commitment_key->commit(key->binary_op_id); - witness_commitments.binary_sel_bin = commitment_key->commit(key->binary_sel_bin); - witness_commitments.binary_start = commitment_key->commit(key->binary_start); - witness_commitments.byte_lookup_sel_bin = commitment_key->commit(key->byte_lookup_sel_bin); - witness_commitments.byte_lookup_table_byte_lengths = commitment_key->commit(key->byte_lookup_table_byte_lengths); - witness_commitments.byte_lookup_table_in_tags = commitment_key->commit(key->byte_lookup_table_in_tags); - witness_commitments.byte_lookup_table_input_a = commitment_key->commit(key->byte_lookup_table_input_a); - witness_commitments.byte_lookup_table_input_b = commitment_key->commit(key->byte_lookup_table_input_b); - witness_commitments.byte_lookup_table_op_id = commitment_key->commit(key->byte_lookup_table_op_id); - witness_commitments.byte_lookup_table_output = commitment_key->commit(key->byte_lookup_table_output); - witness_commitments.conversion_clk = commitment_key->commit(key->conversion_clk); - witness_commitments.conversion_input = commitment_key->commit(key->conversion_input); - witness_commitments.conversion_num_limbs = commitment_key->commit(key->conversion_num_limbs); - witness_commitments.conversion_radix = commitment_key->commit(key->conversion_radix); - witness_commitments.conversion_sel_to_radix_le = commitment_key->commit(key->conversion_sel_to_radix_le); - witness_commitments.gas_da_gas_fixed_table = commitment_key->commit(key->gas_da_gas_fixed_table); - witness_commitments.gas_l2_gas_fixed_table = commitment_key->commit(key->gas_l2_gas_fixed_table); - witness_commitments.gas_sel_gas_cost = commitment_key->commit(key->gas_sel_gas_cost); - witness_commitments.keccakf1600_clk = commitment_key->commit(key->keccakf1600_clk); - witness_commitments.keccakf1600_input = commitment_key->commit(key->keccakf1600_input); - witness_commitments.keccakf1600_output = commitment_key->commit(key->keccakf1600_output); - witness_commitments.keccakf1600_sel_keccakf1600 = commitment_key->commit(key->keccakf1600_sel_keccakf1600); - witness_commitments.kernel_emit_l2_to_l1_msg_write_offset = - commitment_key->commit(key->kernel_emit_l2_to_l1_msg_write_offset); - witness_commitments.kernel_emit_note_hash_write_offset = - commitment_key->commit(key->kernel_emit_note_hash_write_offset); - witness_commitments.kernel_emit_nullifier_write_offset = - commitment_key->commit(key->kernel_emit_nullifier_write_offset); - witness_commitments.kernel_emit_unencrypted_log_write_offset = - commitment_key->commit(key->kernel_emit_unencrypted_log_write_offset); - witness_commitments.kernel_kernel_in_offset = commitment_key->commit(key->kernel_kernel_in_offset); - witness_commitments.kernel_kernel_out_offset = commitment_key->commit(key->kernel_kernel_out_offset); - witness_commitments.kernel_l1_to_l2_msg_exists_write_offset = - commitment_key->commit(key->kernel_l1_to_l2_msg_exists_write_offset); - witness_commitments.kernel_note_hash_exist_write_offset = - commitment_key->commit(key->kernel_note_hash_exist_write_offset); - witness_commitments.kernel_nullifier_exists_write_offset = - commitment_key->commit(key->kernel_nullifier_exists_write_offset); - witness_commitments.kernel_nullifier_non_exists_write_offset = - commitment_key->commit(key->kernel_nullifier_non_exists_write_offset); - witness_commitments.kernel_q_public_input_kernel_add_to_table = - commitment_key->commit(key->kernel_q_public_input_kernel_add_to_table); - witness_commitments.kernel_q_public_input_kernel_out_add_to_table = - commitment_key->commit(key->kernel_q_public_input_kernel_out_add_to_table); - witness_commitments.kernel_side_effect_counter = commitment_key->commit(key->kernel_side_effect_counter); - witness_commitments.kernel_sload_write_offset = commitment_key->commit(key->kernel_sload_write_offset); - witness_commitments.kernel_sstore_write_offset = commitment_key->commit(key->kernel_sstore_write_offset); - witness_commitments.main_abs_da_rem_gas_hi = commitment_key->commit(key->main_abs_da_rem_gas_hi); - witness_commitments.main_abs_da_rem_gas_lo = commitment_key->commit(key->main_abs_da_rem_gas_lo); - witness_commitments.main_abs_l2_rem_gas_hi = commitment_key->commit(key->main_abs_l2_rem_gas_hi); - witness_commitments.main_abs_l2_rem_gas_lo = commitment_key->commit(key->main_abs_l2_rem_gas_lo); - witness_commitments.main_alu_in_tag = commitment_key->commit(key->main_alu_in_tag); - witness_commitments.main_bin_op_id = commitment_key->commit(key->main_bin_op_id); - witness_commitments.main_call_ptr = commitment_key->commit(key->main_call_ptr); - witness_commitments.main_da_gas_op_cost = commitment_key->commit(key->main_da_gas_op_cost); - witness_commitments.main_da_gas_remaining = commitment_key->commit(key->main_da_gas_remaining); - witness_commitments.main_da_out_of_gas = commitment_key->commit(key->main_da_out_of_gas); - witness_commitments.main_ia = commitment_key->commit(key->main_ia); - witness_commitments.main_ib = commitment_key->commit(key->main_ib); - witness_commitments.main_ic = commitment_key->commit(key->main_ic); - witness_commitments.main_id = commitment_key->commit(key->main_id); - witness_commitments.main_id_zero = commitment_key->commit(key->main_id_zero); - witness_commitments.main_ind_addr_a = commitment_key->commit(key->main_ind_addr_a); - witness_commitments.main_ind_addr_b = commitment_key->commit(key->main_ind_addr_b); - witness_commitments.main_ind_addr_c = commitment_key->commit(key->main_ind_addr_c); - witness_commitments.main_ind_addr_d = commitment_key->commit(key->main_ind_addr_d); - witness_commitments.main_internal_return_ptr = commitment_key->commit(key->main_internal_return_ptr); - witness_commitments.main_inv = commitment_key->commit(key->main_inv); - witness_commitments.main_l2_gas_op_cost = commitment_key->commit(key->main_l2_gas_op_cost); - witness_commitments.main_l2_gas_remaining = commitment_key->commit(key->main_l2_gas_remaining); - witness_commitments.main_l2_out_of_gas = commitment_key->commit(key->main_l2_out_of_gas); - witness_commitments.main_mem_addr_a = commitment_key->commit(key->main_mem_addr_a); - witness_commitments.main_mem_addr_b = commitment_key->commit(key->main_mem_addr_b); - witness_commitments.main_mem_addr_c = commitment_key->commit(key->main_mem_addr_c); - witness_commitments.main_mem_addr_d = commitment_key->commit(key->main_mem_addr_d); - witness_commitments.main_op_err = commitment_key->commit(key->main_op_err); - witness_commitments.main_opcode_val = commitment_key->commit(key->main_opcode_val); - witness_commitments.main_pc = commitment_key->commit(key->main_pc); - witness_commitments.main_r_in_tag = commitment_key->commit(key->main_r_in_tag); - witness_commitments.main_rwa = commitment_key->commit(key->main_rwa); - witness_commitments.main_rwb = commitment_key->commit(key->main_rwb); - witness_commitments.main_rwc = commitment_key->commit(key->main_rwc); - witness_commitments.main_rwd = commitment_key->commit(key->main_rwd); - witness_commitments.main_sel_alu = commitment_key->commit(key->main_sel_alu); - witness_commitments.main_sel_bin = commitment_key->commit(key->main_sel_bin); - witness_commitments.main_sel_gas_accounting_active = commitment_key->commit(key->main_sel_gas_accounting_active); - witness_commitments.main_sel_last = commitment_key->commit(key->main_sel_last); - witness_commitments.main_sel_mem_op_a = commitment_key->commit(key->main_sel_mem_op_a); - witness_commitments.main_sel_mem_op_activate_gas = commitment_key->commit(key->main_sel_mem_op_activate_gas); - witness_commitments.main_sel_mem_op_b = commitment_key->commit(key->main_sel_mem_op_b); - witness_commitments.main_sel_mem_op_c = commitment_key->commit(key->main_sel_mem_op_c); - witness_commitments.main_sel_mem_op_d = commitment_key->commit(key->main_sel_mem_op_d); - witness_commitments.main_sel_mov_ia_to_ic = commitment_key->commit(key->main_sel_mov_ia_to_ic); - witness_commitments.main_sel_mov_ib_to_ic = commitment_key->commit(key->main_sel_mov_ib_to_ic); - witness_commitments.main_sel_op_add = commitment_key->commit(key->main_sel_op_add); - witness_commitments.main_sel_op_address = commitment_key->commit(key->main_sel_op_address); - witness_commitments.main_sel_op_and = commitment_key->commit(key->main_sel_op_and); - witness_commitments.main_sel_op_block_number = commitment_key->commit(key->main_sel_op_block_number); - witness_commitments.main_sel_op_cast = commitment_key->commit(key->main_sel_op_cast); - witness_commitments.main_sel_op_chain_id = commitment_key->commit(key->main_sel_op_chain_id); - witness_commitments.main_sel_op_cmov = commitment_key->commit(key->main_sel_op_cmov); - witness_commitments.main_sel_op_coinbase = commitment_key->commit(key->main_sel_op_coinbase); - witness_commitments.main_sel_op_dagasleft = commitment_key->commit(key->main_sel_op_dagasleft); - witness_commitments.main_sel_op_div = commitment_key->commit(key->main_sel_op_div); - witness_commitments.main_sel_op_emit_l2_to_l1_msg = commitment_key->commit(key->main_sel_op_emit_l2_to_l1_msg); - witness_commitments.main_sel_op_emit_note_hash = commitment_key->commit(key->main_sel_op_emit_note_hash); - witness_commitments.main_sel_op_emit_nullifier = commitment_key->commit(key->main_sel_op_emit_nullifier); - witness_commitments.main_sel_op_emit_unencrypted_log = - commitment_key->commit(key->main_sel_op_emit_unencrypted_log); - witness_commitments.main_sel_op_eq = commitment_key->commit(key->main_sel_op_eq); - witness_commitments.main_sel_op_external_call = commitment_key->commit(key->main_sel_op_external_call); - witness_commitments.main_sel_op_fdiv = commitment_key->commit(key->main_sel_op_fdiv); - witness_commitments.main_sel_op_fee_per_da_gas = commitment_key->commit(key->main_sel_op_fee_per_da_gas); - witness_commitments.main_sel_op_fee_per_l2_gas = commitment_key->commit(key->main_sel_op_fee_per_l2_gas); - witness_commitments.main_sel_op_function_selector = commitment_key->commit(key->main_sel_op_function_selector); - witness_commitments.main_sel_op_get_contract_instance = - commitment_key->commit(key->main_sel_op_get_contract_instance); - witness_commitments.main_sel_op_halt = commitment_key->commit(key->main_sel_op_halt); - witness_commitments.main_sel_op_internal_call = commitment_key->commit(key->main_sel_op_internal_call); - witness_commitments.main_sel_op_internal_return = commitment_key->commit(key->main_sel_op_internal_return); - witness_commitments.main_sel_op_jump = commitment_key->commit(key->main_sel_op_jump); - witness_commitments.main_sel_op_jumpi = commitment_key->commit(key->main_sel_op_jumpi); - witness_commitments.main_sel_op_keccak = commitment_key->commit(key->main_sel_op_keccak); - witness_commitments.main_sel_op_l1_to_l2_msg_exists = commitment_key->commit(key->main_sel_op_l1_to_l2_msg_exists); - witness_commitments.main_sel_op_l2gasleft = commitment_key->commit(key->main_sel_op_l2gasleft); - witness_commitments.main_sel_op_lt = commitment_key->commit(key->main_sel_op_lt); - witness_commitments.main_sel_op_lte = commitment_key->commit(key->main_sel_op_lte); - witness_commitments.main_sel_op_mov = commitment_key->commit(key->main_sel_op_mov); - witness_commitments.main_sel_op_mul = commitment_key->commit(key->main_sel_op_mul); - witness_commitments.main_sel_op_not = commitment_key->commit(key->main_sel_op_not); - witness_commitments.main_sel_op_note_hash_exists = commitment_key->commit(key->main_sel_op_note_hash_exists); - witness_commitments.main_sel_op_nullifier_exists = commitment_key->commit(key->main_sel_op_nullifier_exists); - witness_commitments.main_sel_op_or = commitment_key->commit(key->main_sel_op_or); - witness_commitments.main_sel_op_pedersen = commitment_key->commit(key->main_sel_op_pedersen); - witness_commitments.main_sel_op_poseidon2 = commitment_key->commit(key->main_sel_op_poseidon2); - witness_commitments.main_sel_op_radix_le = commitment_key->commit(key->main_sel_op_radix_le); - witness_commitments.main_sel_op_sender = commitment_key->commit(key->main_sel_op_sender); - witness_commitments.main_sel_op_sha256 = commitment_key->commit(key->main_sel_op_sha256); - witness_commitments.main_sel_op_shl = commitment_key->commit(key->main_sel_op_shl); - witness_commitments.main_sel_op_shr = commitment_key->commit(key->main_sel_op_shr); - witness_commitments.main_sel_op_sload = commitment_key->commit(key->main_sel_op_sload); - witness_commitments.main_sel_op_sstore = commitment_key->commit(key->main_sel_op_sstore); - witness_commitments.main_sel_op_storage_address = commitment_key->commit(key->main_sel_op_storage_address); - witness_commitments.main_sel_op_sub = commitment_key->commit(key->main_sel_op_sub); - witness_commitments.main_sel_op_timestamp = commitment_key->commit(key->main_sel_op_timestamp); - witness_commitments.main_sel_op_transaction_fee = commitment_key->commit(key->main_sel_op_transaction_fee); - witness_commitments.main_sel_op_version = commitment_key->commit(key->main_sel_op_version); - witness_commitments.main_sel_op_xor = commitment_key->commit(key->main_sel_op_xor); - witness_commitments.main_sel_q_kernel_lookup = commitment_key->commit(key->main_sel_q_kernel_lookup); - witness_commitments.main_sel_q_kernel_output_lookup = commitment_key->commit(key->main_sel_q_kernel_output_lookup); - witness_commitments.main_sel_resolve_ind_addr_a = commitment_key->commit(key->main_sel_resolve_ind_addr_a); - witness_commitments.main_sel_resolve_ind_addr_b = commitment_key->commit(key->main_sel_resolve_ind_addr_b); - witness_commitments.main_sel_resolve_ind_addr_c = commitment_key->commit(key->main_sel_resolve_ind_addr_c); - witness_commitments.main_sel_resolve_ind_addr_d = commitment_key->commit(key->main_sel_resolve_ind_addr_d); - witness_commitments.main_sel_rng_16 = commitment_key->commit(key->main_sel_rng_16); - witness_commitments.main_sel_rng_8 = commitment_key->commit(key->main_sel_rng_8); - witness_commitments.main_space_id = commitment_key->commit(key->main_space_id); - witness_commitments.main_tag_err = commitment_key->commit(key->main_tag_err); - witness_commitments.main_w_in_tag = commitment_key->commit(key->main_w_in_tag); - witness_commitments.mem_addr = commitment_key->commit(key->mem_addr); - witness_commitments.mem_clk = commitment_key->commit(key->mem_clk); - witness_commitments.mem_diff_hi = commitment_key->commit(key->mem_diff_hi); - witness_commitments.mem_diff_lo = commitment_key->commit(key->mem_diff_lo); - witness_commitments.mem_diff_mid = commitment_key->commit(key->mem_diff_mid); - witness_commitments.mem_glob_addr = commitment_key->commit(key->mem_glob_addr); - witness_commitments.mem_last = commitment_key->commit(key->mem_last); - witness_commitments.mem_lastAccess = commitment_key->commit(key->mem_lastAccess); - witness_commitments.mem_one_min_inv = commitment_key->commit(key->mem_one_min_inv); - witness_commitments.mem_r_in_tag = commitment_key->commit(key->mem_r_in_tag); - witness_commitments.mem_rw = commitment_key->commit(key->mem_rw); - witness_commitments.mem_sel_mem = commitment_key->commit(key->mem_sel_mem); - witness_commitments.mem_sel_mov_ia_to_ic = commitment_key->commit(key->mem_sel_mov_ia_to_ic); - witness_commitments.mem_sel_mov_ib_to_ic = commitment_key->commit(key->mem_sel_mov_ib_to_ic); - witness_commitments.mem_sel_op_a = commitment_key->commit(key->mem_sel_op_a); - witness_commitments.mem_sel_op_b = commitment_key->commit(key->mem_sel_op_b); - witness_commitments.mem_sel_op_c = commitment_key->commit(key->mem_sel_op_c); - witness_commitments.mem_sel_op_cmov = commitment_key->commit(key->mem_sel_op_cmov); - witness_commitments.mem_sel_op_d = commitment_key->commit(key->mem_sel_op_d); - witness_commitments.mem_sel_resolve_ind_addr_a = commitment_key->commit(key->mem_sel_resolve_ind_addr_a); - witness_commitments.mem_sel_resolve_ind_addr_b = commitment_key->commit(key->mem_sel_resolve_ind_addr_b); - witness_commitments.mem_sel_resolve_ind_addr_c = commitment_key->commit(key->mem_sel_resolve_ind_addr_c); - witness_commitments.mem_sel_resolve_ind_addr_d = commitment_key->commit(key->mem_sel_resolve_ind_addr_d); - witness_commitments.mem_sel_rng_chk = commitment_key->commit(key->mem_sel_rng_chk); - witness_commitments.mem_skip_check_tag = commitment_key->commit(key->mem_skip_check_tag); - witness_commitments.mem_space_id = commitment_key->commit(key->mem_space_id); - witness_commitments.mem_tag = commitment_key->commit(key->mem_tag); - witness_commitments.mem_tag_err = commitment_key->commit(key->mem_tag_err); - witness_commitments.mem_tsp = commitment_key->commit(key->mem_tsp); - witness_commitments.mem_val = commitment_key->commit(key->mem_val); - witness_commitments.mem_w_in_tag = commitment_key->commit(key->mem_w_in_tag); - witness_commitments.pedersen_clk = commitment_key->commit(key->pedersen_clk); - witness_commitments.pedersen_input = commitment_key->commit(key->pedersen_input); - witness_commitments.pedersen_output = commitment_key->commit(key->pedersen_output); - witness_commitments.pedersen_sel_pedersen = commitment_key->commit(key->pedersen_sel_pedersen); - witness_commitments.poseidon2_a_0 = commitment_key->commit(key->poseidon2_a_0); - witness_commitments.poseidon2_a_1 = commitment_key->commit(key->poseidon2_a_1); - witness_commitments.poseidon2_a_2 = commitment_key->commit(key->poseidon2_a_2); - witness_commitments.poseidon2_a_3 = commitment_key->commit(key->poseidon2_a_3); - witness_commitments.poseidon2_b_0 = commitment_key->commit(key->poseidon2_b_0); - witness_commitments.poseidon2_b_1 = commitment_key->commit(key->poseidon2_b_1); - witness_commitments.poseidon2_b_2 = commitment_key->commit(key->poseidon2_b_2); - witness_commitments.poseidon2_b_3 = commitment_key->commit(key->poseidon2_b_3); - witness_commitments.poseidon2_clk = commitment_key->commit(key->poseidon2_clk); - witness_commitments.poseidon2_input = commitment_key->commit(key->poseidon2_input); - witness_commitments.poseidon2_output = commitment_key->commit(key->poseidon2_output); - witness_commitments.poseidon2_sel_poseidon_perm = commitment_key->commit(key->poseidon2_sel_poseidon_perm); - witness_commitments.powers_power_of_2 = commitment_key->commit(key->powers_power_of_2); - witness_commitments.sha256_clk = commitment_key->commit(key->sha256_clk); - witness_commitments.sha256_input = commitment_key->commit(key->sha256_input); - witness_commitments.sha256_output = commitment_key->commit(key->sha256_output); - witness_commitments.sha256_sel_sha256_compression = commitment_key->commit(key->sha256_sel_sha256_compression); - witness_commitments.sha256_state = commitment_key->commit(key->sha256_state); - witness_commitments.lookup_byte_lengths_counts = commitment_key->commit(key->lookup_byte_lengths_counts); - witness_commitments.lookup_byte_operations_counts = commitment_key->commit(key->lookup_byte_operations_counts); - witness_commitments.lookup_opcode_gas_counts = commitment_key->commit(key->lookup_opcode_gas_counts); - witness_commitments.range_check_l2_gas_hi_counts = commitment_key->commit(key->range_check_l2_gas_hi_counts); - witness_commitments.range_check_l2_gas_lo_counts = commitment_key->commit(key->range_check_l2_gas_lo_counts); - witness_commitments.range_check_da_gas_hi_counts = commitment_key->commit(key->range_check_da_gas_hi_counts); - witness_commitments.range_check_da_gas_lo_counts = commitment_key->commit(key->range_check_da_gas_lo_counts); - witness_commitments.kernel_output_lookup_counts = commitment_key->commit(key->kernel_output_lookup_counts); - witness_commitments.lookup_into_kernel_counts = commitment_key->commit(key->lookup_into_kernel_counts); - witness_commitments.incl_main_tag_err_counts = commitment_key->commit(key->incl_main_tag_err_counts); - witness_commitments.incl_mem_tag_err_counts = commitment_key->commit(key->incl_mem_tag_err_counts); - witness_commitments.lookup_mem_rng_chk_lo_counts = commitment_key->commit(key->lookup_mem_rng_chk_lo_counts); - witness_commitments.lookup_mem_rng_chk_mid_counts = commitment_key->commit(key->lookup_mem_rng_chk_mid_counts); - witness_commitments.lookup_mem_rng_chk_hi_counts = commitment_key->commit(key->lookup_mem_rng_chk_hi_counts); - witness_commitments.lookup_pow_2_0_counts = commitment_key->commit(key->lookup_pow_2_0_counts); - witness_commitments.lookup_pow_2_1_counts = commitment_key->commit(key->lookup_pow_2_1_counts); - witness_commitments.lookup_u8_0_counts = commitment_key->commit(key->lookup_u8_0_counts); - witness_commitments.lookup_u8_1_counts = commitment_key->commit(key->lookup_u8_1_counts); - witness_commitments.lookup_u16_0_counts = commitment_key->commit(key->lookup_u16_0_counts); - witness_commitments.lookup_u16_1_counts = commitment_key->commit(key->lookup_u16_1_counts); - witness_commitments.lookup_u16_2_counts = commitment_key->commit(key->lookup_u16_2_counts); - witness_commitments.lookup_u16_3_counts = commitment_key->commit(key->lookup_u16_3_counts); - witness_commitments.lookup_u16_4_counts = commitment_key->commit(key->lookup_u16_4_counts); - witness_commitments.lookup_u16_5_counts = commitment_key->commit(key->lookup_u16_5_counts); - witness_commitments.lookup_u16_6_counts = commitment_key->commit(key->lookup_u16_6_counts); - witness_commitments.lookup_u16_7_counts = commitment_key->commit(key->lookup_u16_7_counts); - witness_commitments.lookup_u16_8_counts = commitment_key->commit(key->lookup_u16_8_counts); - witness_commitments.lookup_u16_9_counts = commitment_key->commit(key->lookup_u16_9_counts); - witness_commitments.lookup_u16_10_counts = commitment_key->commit(key->lookup_u16_10_counts); - witness_commitments.lookup_u16_11_counts = commitment_key->commit(key->lookup_u16_11_counts); - witness_commitments.lookup_u16_12_counts = commitment_key->commit(key->lookup_u16_12_counts); - witness_commitments.lookup_u16_13_counts = commitment_key->commit(key->lookup_u16_13_counts); - witness_commitments.lookup_u16_14_counts = commitment_key->commit(key->lookup_u16_14_counts); - witness_commitments.lookup_div_u16_0_counts = commitment_key->commit(key->lookup_div_u16_0_counts); - witness_commitments.lookup_div_u16_1_counts = commitment_key->commit(key->lookup_div_u16_1_counts); - witness_commitments.lookup_div_u16_2_counts = commitment_key->commit(key->lookup_div_u16_2_counts); - witness_commitments.lookup_div_u16_3_counts = commitment_key->commit(key->lookup_div_u16_3_counts); - witness_commitments.lookup_div_u16_4_counts = commitment_key->commit(key->lookup_div_u16_4_counts); - witness_commitments.lookup_div_u16_5_counts = commitment_key->commit(key->lookup_div_u16_5_counts); - witness_commitments.lookup_div_u16_6_counts = commitment_key->commit(key->lookup_div_u16_6_counts); - witness_commitments.lookup_div_u16_7_counts = commitment_key->commit(key->lookup_div_u16_7_counts); - - // Send all commitments to the verifier - transcript->send_to_verifier(commitment_labels.kernel_kernel_inputs, witness_commitments.kernel_kernel_inputs); - transcript->send_to_verifier(commitment_labels.kernel_kernel_value_out, - witness_commitments.kernel_kernel_value_out); - transcript->send_to_verifier(commitment_labels.kernel_kernel_side_effect_out, - witness_commitments.kernel_kernel_side_effect_out); - transcript->send_to_verifier(commitment_labels.kernel_kernel_metadata_out, - witness_commitments.kernel_kernel_metadata_out); - transcript->send_to_verifier(commitment_labels.main_calldata, witness_commitments.main_calldata); - transcript->send_to_verifier(commitment_labels.alu_a_hi, witness_commitments.alu_a_hi); - transcript->send_to_verifier(commitment_labels.alu_a_lo, witness_commitments.alu_a_lo); - transcript->send_to_verifier(commitment_labels.alu_b_hi, witness_commitments.alu_b_hi); - transcript->send_to_verifier(commitment_labels.alu_b_lo, witness_commitments.alu_b_lo); - transcript->send_to_verifier(commitment_labels.alu_borrow, witness_commitments.alu_borrow); - transcript->send_to_verifier(commitment_labels.alu_cf, witness_commitments.alu_cf); - transcript->send_to_verifier(commitment_labels.alu_clk, witness_commitments.alu_clk); - transcript->send_to_verifier(commitment_labels.alu_cmp_rng_ctr, witness_commitments.alu_cmp_rng_ctr); - transcript->send_to_verifier(commitment_labels.alu_div_u16_r0, witness_commitments.alu_div_u16_r0); - transcript->send_to_verifier(commitment_labels.alu_div_u16_r1, witness_commitments.alu_div_u16_r1); - transcript->send_to_verifier(commitment_labels.alu_div_u16_r2, witness_commitments.alu_div_u16_r2); - transcript->send_to_verifier(commitment_labels.alu_div_u16_r3, witness_commitments.alu_div_u16_r3); - transcript->send_to_verifier(commitment_labels.alu_div_u16_r4, witness_commitments.alu_div_u16_r4); - transcript->send_to_verifier(commitment_labels.alu_div_u16_r5, witness_commitments.alu_div_u16_r5); - transcript->send_to_verifier(commitment_labels.alu_div_u16_r6, witness_commitments.alu_div_u16_r6); - transcript->send_to_verifier(commitment_labels.alu_div_u16_r7, witness_commitments.alu_div_u16_r7); - transcript->send_to_verifier(commitment_labels.alu_divisor_hi, witness_commitments.alu_divisor_hi); - transcript->send_to_verifier(commitment_labels.alu_divisor_lo, witness_commitments.alu_divisor_lo); - transcript->send_to_verifier(commitment_labels.alu_ff_tag, witness_commitments.alu_ff_tag); - transcript->send_to_verifier(commitment_labels.alu_ia, witness_commitments.alu_ia); - transcript->send_to_verifier(commitment_labels.alu_ib, witness_commitments.alu_ib); - transcript->send_to_verifier(commitment_labels.alu_ic, witness_commitments.alu_ic); - transcript->send_to_verifier(commitment_labels.alu_in_tag, witness_commitments.alu_in_tag); - transcript->send_to_verifier(commitment_labels.alu_op_add, witness_commitments.alu_op_add); - transcript->send_to_verifier(commitment_labels.alu_op_cast, witness_commitments.alu_op_cast); - transcript->send_to_verifier(commitment_labels.alu_op_cast_prev, witness_commitments.alu_op_cast_prev); - transcript->send_to_verifier(commitment_labels.alu_op_div, witness_commitments.alu_op_div); - transcript->send_to_verifier(commitment_labels.alu_op_div_a_lt_b, witness_commitments.alu_op_div_a_lt_b); - transcript->send_to_verifier(commitment_labels.alu_op_div_std, witness_commitments.alu_op_div_std); - transcript->send_to_verifier(commitment_labels.alu_op_eq, witness_commitments.alu_op_eq); - transcript->send_to_verifier(commitment_labels.alu_op_eq_diff_inv, witness_commitments.alu_op_eq_diff_inv); - transcript->send_to_verifier(commitment_labels.alu_op_lt, witness_commitments.alu_op_lt); - transcript->send_to_verifier(commitment_labels.alu_op_lte, witness_commitments.alu_op_lte); - transcript->send_to_verifier(commitment_labels.alu_op_mul, witness_commitments.alu_op_mul); - transcript->send_to_verifier(commitment_labels.alu_op_not, witness_commitments.alu_op_not); - transcript->send_to_verifier(commitment_labels.alu_op_shl, witness_commitments.alu_op_shl); - transcript->send_to_verifier(commitment_labels.alu_op_shr, witness_commitments.alu_op_shr); - transcript->send_to_verifier(commitment_labels.alu_op_sub, witness_commitments.alu_op_sub); - transcript->send_to_verifier(commitment_labels.alu_p_a_borrow, witness_commitments.alu_p_a_borrow); - transcript->send_to_verifier(commitment_labels.alu_p_b_borrow, witness_commitments.alu_p_b_borrow); - transcript->send_to_verifier(commitment_labels.alu_p_sub_a_hi, witness_commitments.alu_p_sub_a_hi); - transcript->send_to_verifier(commitment_labels.alu_p_sub_a_lo, witness_commitments.alu_p_sub_a_lo); - transcript->send_to_verifier(commitment_labels.alu_p_sub_b_hi, witness_commitments.alu_p_sub_b_hi); - transcript->send_to_verifier(commitment_labels.alu_p_sub_b_lo, witness_commitments.alu_p_sub_b_lo); - transcript->send_to_verifier(commitment_labels.alu_partial_prod_hi, witness_commitments.alu_partial_prod_hi); - transcript->send_to_verifier(commitment_labels.alu_partial_prod_lo, witness_commitments.alu_partial_prod_lo); - transcript->send_to_verifier(commitment_labels.alu_quotient_hi, witness_commitments.alu_quotient_hi); - transcript->send_to_verifier(commitment_labels.alu_quotient_lo, witness_commitments.alu_quotient_lo); - transcript->send_to_verifier(commitment_labels.alu_remainder, witness_commitments.alu_remainder); - transcript->send_to_verifier(commitment_labels.alu_res_hi, witness_commitments.alu_res_hi); - transcript->send_to_verifier(commitment_labels.alu_res_lo, witness_commitments.alu_res_lo); - transcript->send_to_verifier(commitment_labels.alu_sel_alu, witness_commitments.alu_sel_alu); - transcript->send_to_verifier(commitment_labels.alu_sel_cmp, witness_commitments.alu_sel_cmp); - transcript->send_to_verifier(commitment_labels.alu_sel_div_rng_chk, witness_commitments.alu_sel_div_rng_chk); - transcript->send_to_verifier(commitment_labels.alu_sel_rng_chk, witness_commitments.alu_sel_rng_chk); - transcript->send_to_verifier(commitment_labels.alu_sel_rng_chk_lookup, witness_commitments.alu_sel_rng_chk_lookup); - transcript->send_to_verifier(commitment_labels.alu_sel_shift_which, witness_commitments.alu_sel_shift_which); - transcript->send_to_verifier(commitment_labels.alu_shift_lt_bit_len, witness_commitments.alu_shift_lt_bit_len); - transcript->send_to_verifier(commitment_labels.alu_t_sub_s_bits, witness_commitments.alu_t_sub_s_bits); - transcript->send_to_verifier(commitment_labels.alu_two_pow_s, witness_commitments.alu_two_pow_s); - transcript->send_to_verifier(commitment_labels.alu_two_pow_t_sub_s, witness_commitments.alu_two_pow_t_sub_s); - transcript->send_to_verifier(commitment_labels.alu_u128_tag, witness_commitments.alu_u128_tag); - transcript->send_to_verifier(commitment_labels.alu_u16_r0, witness_commitments.alu_u16_r0); - transcript->send_to_verifier(commitment_labels.alu_u16_r1, witness_commitments.alu_u16_r1); - transcript->send_to_verifier(commitment_labels.alu_u16_r10, witness_commitments.alu_u16_r10); - transcript->send_to_verifier(commitment_labels.alu_u16_r11, witness_commitments.alu_u16_r11); - transcript->send_to_verifier(commitment_labels.alu_u16_r12, witness_commitments.alu_u16_r12); - transcript->send_to_verifier(commitment_labels.alu_u16_r13, witness_commitments.alu_u16_r13); - transcript->send_to_verifier(commitment_labels.alu_u16_r14, witness_commitments.alu_u16_r14); - transcript->send_to_verifier(commitment_labels.alu_u16_r2, witness_commitments.alu_u16_r2); - transcript->send_to_verifier(commitment_labels.alu_u16_r3, witness_commitments.alu_u16_r3); - transcript->send_to_verifier(commitment_labels.alu_u16_r4, witness_commitments.alu_u16_r4); - transcript->send_to_verifier(commitment_labels.alu_u16_r5, witness_commitments.alu_u16_r5); - transcript->send_to_verifier(commitment_labels.alu_u16_r6, witness_commitments.alu_u16_r6); - transcript->send_to_verifier(commitment_labels.alu_u16_r7, witness_commitments.alu_u16_r7); - transcript->send_to_verifier(commitment_labels.alu_u16_r8, witness_commitments.alu_u16_r8); - transcript->send_to_verifier(commitment_labels.alu_u16_r9, witness_commitments.alu_u16_r9); - transcript->send_to_verifier(commitment_labels.alu_u16_tag, witness_commitments.alu_u16_tag); - transcript->send_to_verifier(commitment_labels.alu_u32_tag, witness_commitments.alu_u32_tag); - transcript->send_to_verifier(commitment_labels.alu_u64_tag, witness_commitments.alu_u64_tag); - transcript->send_to_verifier(commitment_labels.alu_u8_r0, witness_commitments.alu_u8_r0); - transcript->send_to_verifier(commitment_labels.alu_u8_r1, witness_commitments.alu_u8_r1); - transcript->send_to_verifier(commitment_labels.alu_u8_tag, witness_commitments.alu_u8_tag); - transcript->send_to_verifier(commitment_labels.binary_acc_ia, witness_commitments.binary_acc_ia); - transcript->send_to_verifier(commitment_labels.binary_acc_ib, witness_commitments.binary_acc_ib); - transcript->send_to_verifier(commitment_labels.binary_acc_ic, witness_commitments.binary_acc_ic); - transcript->send_to_verifier(commitment_labels.binary_clk, witness_commitments.binary_clk); - transcript->send_to_verifier(commitment_labels.binary_ia_bytes, witness_commitments.binary_ia_bytes); - transcript->send_to_verifier(commitment_labels.binary_ib_bytes, witness_commitments.binary_ib_bytes); - transcript->send_to_verifier(commitment_labels.binary_ic_bytes, witness_commitments.binary_ic_bytes); - transcript->send_to_verifier(commitment_labels.binary_in_tag, witness_commitments.binary_in_tag); - transcript->send_to_verifier(commitment_labels.binary_mem_tag_ctr, witness_commitments.binary_mem_tag_ctr); - transcript->send_to_verifier(commitment_labels.binary_mem_tag_ctr_inv, witness_commitments.binary_mem_tag_ctr_inv); - transcript->send_to_verifier(commitment_labels.binary_op_id, witness_commitments.binary_op_id); - transcript->send_to_verifier(commitment_labels.binary_sel_bin, witness_commitments.binary_sel_bin); - transcript->send_to_verifier(commitment_labels.binary_start, witness_commitments.binary_start); - transcript->send_to_verifier(commitment_labels.byte_lookup_sel_bin, witness_commitments.byte_lookup_sel_bin); - transcript->send_to_verifier(commitment_labels.byte_lookup_table_byte_lengths, - witness_commitments.byte_lookup_table_byte_lengths); - transcript->send_to_verifier(commitment_labels.byte_lookup_table_in_tags, - witness_commitments.byte_lookup_table_in_tags); - transcript->send_to_verifier(commitment_labels.byte_lookup_table_input_a, - witness_commitments.byte_lookup_table_input_a); - transcript->send_to_verifier(commitment_labels.byte_lookup_table_input_b, - witness_commitments.byte_lookup_table_input_b); - transcript->send_to_verifier(commitment_labels.byte_lookup_table_op_id, - witness_commitments.byte_lookup_table_op_id); - transcript->send_to_verifier(commitment_labels.byte_lookup_table_output, - witness_commitments.byte_lookup_table_output); - transcript->send_to_verifier(commitment_labels.conversion_clk, witness_commitments.conversion_clk); - transcript->send_to_verifier(commitment_labels.conversion_input, witness_commitments.conversion_input); - transcript->send_to_verifier(commitment_labels.conversion_num_limbs, witness_commitments.conversion_num_limbs); - transcript->send_to_verifier(commitment_labels.conversion_radix, witness_commitments.conversion_radix); - transcript->send_to_verifier(commitment_labels.conversion_sel_to_radix_le, - witness_commitments.conversion_sel_to_radix_le); - transcript->send_to_verifier(commitment_labels.gas_da_gas_fixed_table, witness_commitments.gas_da_gas_fixed_table); - transcript->send_to_verifier(commitment_labels.gas_l2_gas_fixed_table, witness_commitments.gas_l2_gas_fixed_table); - transcript->send_to_verifier(commitment_labels.gas_sel_gas_cost, witness_commitments.gas_sel_gas_cost); - transcript->send_to_verifier(commitment_labels.keccakf1600_clk, witness_commitments.keccakf1600_clk); - transcript->send_to_verifier(commitment_labels.keccakf1600_input, witness_commitments.keccakf1600_input); - transcript->send_to_verifier(commitment_labels.keccakf1600_output, witness_commitments.keccakf1600_output); - transcript->send_to_verifier(commitment_labels.keccakf1600_sel_keccakf1600, - witness_commitments.keccakf1600_sel_keccakf1600); - transcript->send_to_verifier(commitment_labels.kernel_emit_l2_to_l1_msg_write_offset, - witness_commitments.kernel_emit_l2_to_l1_msg_write_offset); - transcript->send_to_verifier(commitment_labels.kernel_emit_note_hash_write_offset, - witness_commitments.kernel_emit_note_hash_write_offset); - transcript->send_to_verifier(commitment_labels.kernel_emit_nullifier_write_offset, - witness_commitments.kernel_emit_nullifier_write_offset); - transcript->send_to_verifier(commitment_labels.kernel_emit_unencrypted_log_write_offset, - witness_commitments.kernel_emit_unencrypted_log_write_offset); - transcript->send_to_verifier(commitment_labels.kernel_kernel_in_offset, - witness_commitments.kernel_kernel_in_offset); - transcript->send_to_verifier(commitment_labels.kernel_kernel_out_offset, - witness_commitments.kernel_kernel_out_offset); - transcript->send_to_verifier(commitment_labels.kernel_l1_to_l2_msg_exists_write_offset, - witness_commitments.kernel_l1_to_l2_msg_exists_write_offset); - transcript->send_to_verifier(commitment_labels.kernel_note_hash_exist_write_offset, - witness_commitments.kernel_note_hash_exist_write_offset); - transcript->send_to_verifier(commitment_labels.kernel_nullifier_exists_write_offset, - witness_commitments.kernel_nullifier_exists_write_offset); - transcript->send_to_verifier(commitment_labels.kernel_nullifier_non_exists_write_offset, - witness_commitments.kernel_nullifier_non_exists_write_offset); - transcript->send_to_verifier(commitment_labels.kernel_q_public_input_kernel_add_to_table, - witness_commitments.kernel_q_public_input_kernel_add_to_table); - transcript->send_to_verifier(commitment_labels.kernel_q_public_input_kernel_out_add_to_table, - witness_commitments.kernel_q_public_input_kernel_out_add_to_table); - transcript->send_to_verifier(commitment_labels.kernel_side_effect_counter, - witness_commitments.kernel_side_effect_counter); - transcript->send_to_verifier(commitment_labels.kernel_sload_write_offset, - witness_commitments.kernel_sload_write_offset); - transcript->send_to_verifier(commitment_labels.kernel_sstore_write_offset, - witness_commitments.kernel_sstore_write_offset); - transcript->send_to_verifier(commitment_labels.main_abs_da_rem_gas_hi, witness_commitments.main_abs_da_rem_gas_hi); - transcript->send_to_verifier(commitment_labels.main_abs_da_rem_gas_lo, witness_commitments.main_abs_da_rem_gas_lo); - transcript->send_to_verifier(commitment_labels.main_abs_l2_rem_gas_hi, witness_commitments.main_abs_l2_rem_gas_hi); - transcript->send_to_verifier(commitment_labels.main_abs_l2_rem_gas_lo, witness_commitments.main_abs_l2_rem_gas_lo); - transcript->send_to_verifier(commitment_labels.main_alu_in_tag, witness_commitments.main_alu_in_tag); - transcript->send_to_verifier(commitment_labels.main_bin_op_id, witness_commitments.main_bin_op_id); - transcript->send_to_verifier(commitment_labels.main_call_ptr, witness_commitments.main_call_ptr); - transcript->send_to_verifier(commitment_labels.main_da_gas_op_cost, witness_commitments.main_da_gas_op_cost); - transcript->send_to_verifier(commitment_labels.main_da_gas_remaining, witness_commitments.main_da_gas_remaining); - transcript->send_to_verifier(commitment_labels.main_da_out_of_gas, witness_commitments.main_da_out_of_gas); - transcript->send_to_verifier(commitment_labels.main_ia, witness_commitments.main_ia); - transcript->send_to_verifier(commitment_labels.main_ib, witness_commitments.main_ib); - transcript->send_to_verifier(commitment_labels.main_ic, witness_commitments.main_ic); - transcript->send_to_verifier(commitment_labels.main_id, witness_commitments.main_id); - transcript->send_to_verifier(commitment_labels.main_id_zero, witness_commitments.main_id_zero); - transcript->send_to_verifier(commitment_labels.main_ind_addr_a, witness_commitments.main_ind_addr_a); - transcript->send_to_verifier(commitment_labels.main_ind_addr_b, witness_commitments.main_ind_addr_b); - transcript->send_to_verifier(commitment_labels.main_ind_addr_c, witness_commitments.main_ind_addr_c); - transcript->send_to_verifier(commitment_labels.main_ind_addr_d, witness_commitments.main_ind_addr_d); - transcript->send_to_verifier(commitment_labels.main_internal_return_ptr, - witness_commitments.main_internal_return_ptr); - transcript->send_to_verifier(commitment_labels.main_inv, witness_commitments.main_inv); - transcript->send_to_verifier(commitment_labels.main_l2_gas_op_cost, witness_commitments.main_l2_gas_op_cost); - transcript->send_to_verifier(commitment_labels.main_l2_gas_remaining, witness_commitments.main_l2_gas_remaining); - transcript->send_to_verifier(commitment_labels.main_l2_out_of_gas, witness_commitments.main_l2_out_of_gas); - transcript->send_to_verifier(commitment_labels.main_mem_addr_a, witness_commitments.main_mem_addr_a); - transcript->send_to_verifier(commitment_labels.main_mem_addr_b, witness_commitments.main_mem_addr_b); - transcript->send_to_verifier(commitment_labels.main_mem_addr_c, witness_commitments.main_mem_addr_c); - transcript->send_to_verifier(commitment_labels.main_mem_addr_d, witness_commitments.main_mem_addr_d); - transcript->send_to_verifier(commitment_labels.main_op_err, witness_commitments.main_op_err); - transcript->send_to_verifier(commitment_labels.main_opcode_val, witness_commitments.main_opcode_val); - transcript->send_to_verifier(commitment_labels.main_pc, witness_commitments.main_pc); - transcript->send_to_verifier(commitment_labels.main_r_in_tag, witness_commitments.main_r_in_tag); - transcript->send_to_verifier(commitment_labels.main_rwa, witness_commitments.main_rwa); - transcript->send_to_verifier(commitment_labels.main_rwb, witness_commitments.main_rwb); - transcript->send_to_verifier(commitment_labels.main_rwc, witness_commitments.main_rwc); - transcript->send_to_verifier(commitment_labels.main_rwd, witness_commitments.main_rwd); - transcript->send_to_verifier(commitment_labels.main_sel_alu, witness_commitments.main_sel_alu); - transcript->send_to_verifier(commitment_labels.main_sel_bin, witness_commitments.main_sel_bin); - transcript->send_to_verifier(commitment_labels.main_sel_gas_accounting_active, - witness_commitments.main_sel_gas_accounting_active); - transcript->send_to_verifier(commitment_labels.main_sel_last, witness_commitments.main_sel_last); - transcript->send_to_verifier(commitment_labels.main_sel_mem_op_a, witness_commitments.main_sel_mem_op_a); - transcript->send_to_verifier(commitment_labels.main_sel_mem_op_activate_gas, - witness_commitments.main_sel_mem_op_activate_gas); - transcript->send_to_verifier(commitment_labels.main_sel_mem_op_b, witness_commitments.main_sel_mem_op_b); - transcript->send_to_verifier(commitment_labels.main_sel_mem_op_c, witness_commitments.main_sel_mem_op_c); - transcript->send_to_verifier(commitment_labels.main_sel_mem_op_d, witness_commitments.main_sel_mem_op_d); - transcript->send_to_verifier(commitment_labels.main_sel_mov_ia_to_ic, witness_commitments.main_sel_mov_ia_to_ic); - transcript->send_to_verifier(commitment_labels.main_sel_mov_ib_to_ic, witness_commitments.main_sel_mov_ib_to_ic); - transcript->send_to_verifier(commitment_labels.main_sel_op_add, witness_commitments.main_sel_op_add); - transcript->send_to_verifier(commitment_labels.main_sel_op_address, witness_commitments.main_sel_op_address); - transcript->send_to_verifier(commitment_labels.main_sel_op_and, witness_commitments.main_sel_op_and); - transcript->send_to_verifier(commitment_labels.main_sel_op_block_number, - witness_commitments.main_sel_op_block_number); - transcript->send_to_verifier(commitment_labels.main_sel_op_cast, witness_commitments.main_sel_op_cast); - transcript->send_to_verifier(commitment_labels.main_sel_op_chain_id, witness_commitments.main_sel_op_chain_id); - transcript->send_to_verifier(commitment_labels.main_sel_op_cmov, witness_commitments.main_sel_op_cmov); - transcript->send_to_verifier(commitment_labels.main_sel_op_coinbase, witness_commitments.main_sel_op_coinbase); - transcript->send_to_verifier(commitment_labels.main_sel_op_dagasleft, witness_commitments.main_sel_op_dagasleft); - transcript->send_to_verifier(commitment_labels.main_sel_op_div, witness_commitments.main_sel_op_div); - transcript->send_to_verifier(commitment_labels.main_sel_op_emit_l2_to_l1_msg, - witness_commitments.main_sel_op_emit_l2_to_l1_msg); - transcript->send_to_verifier(commitment_labels.main_sel_op_emit_note_hash, - witness_commitments.main_sel_op_emit_note_hash); - transcript->send_to_verifier(commitment_labels.main_sel_op_emit_nullifier, - witness_commitments.main_sel_op_emit_nullifier); - transcript->send_to_verifier(commitment_labels.main_sel_op_emit_unencrypted_log, - witness_commitments.main_sel_op_emit_unencrypted_log); - transcript->send_to_verifier(commitment_labels.main_sel_op_eq, witness_commitments.main_sel_op_eq); - transcript->send_to_verifier(commitment_labels.main_sel_op_external_call, - witness_commitments.main_sel_op_external_call); - transcript->send_to_verifier(commitment_labels.main_sel_op_fdiv, witness_commitments.main_sel_op_fdiv); - transcript->send_to_verifier(commitment_labels.main_sel_op_fee_per_da_gas, - witness_commitments.main_sel_op_fee_per_da_gas); - transcript->send_to_verifier(commitment_labels.main_sel_op_fee_per_l2_gas, - witness_commitments.main_sel_op_fee_per_l2_gas); - transcript->send_to_verifier(commitment_labels.main_sel_op_function_selector, - witness_commitments.main_sel_op_function_selector); - transcript->send_to_verifier(commitment_labels.main_sel_op_get_contract_instance, - witness_commitments.main_sel_op_get_contract_instance); - transcript->send_to_verifier(commitment_labels.main_sel_op_halt, witness_commitments.main_sel_op_halt); - transcript->send_to_verifier(commitment_labels.main_sel_op_internal_call, - witness_commitments.main_sel_op_internal_call); - transcript->send_to_verifier(commitment_labels.main_sel_op_internal_return, - witness_commitments.main_sel_op_internal_return); - transcript->send_to_verifier(commitment_labels.main_sel_op_jump, witness_commitments.main_sel_op_jump); - transcript->send_to_verifier(commitment_labels.main_sel_op_jumpi, witness_commitments.main_sel_op_jumpi); - transcript->send_to_verifier(commitment_labels.main_sel_op_keccak, witness_commitments.main_sel_op_keccak); - transcript->send_to_verifier(commitment_labels.main_sel_op_l1_to_l2_msg_exists, - witness_commitments.main_sel_op_l1_to_l2_msg_exists); - transcript->send_to_verifier(commitment_labels.main_sel_op_l2gasleft, witness_commitments.main_sel_op_l2gasleft); - transcript->send_to_verifier(commitment_labels.main_sel_op_lt, witness_commitments.main_sel_op_lt); - transcript->send_to_verifier(commitment_labels.main_sel_op_lte, witness_commitments.main_sel_op_lte); - transcript->send_to_verifier(commitment_labels.main_sel_op_mov, witness_commitments.main_sel_op_mov); - transcript->send_to_verifier(commitment_labels.main_sel_op_mul, witness_commitments.main_sel_op_mul); - transcript->send_to_verifier(commitment_labels.main_sel_op_not, witness_commitments.main_sel_op_not); - transcript->send_to_verifier(commitment_labels.main_sel_op_note_hash_exists, - witness_commitments.main_sel_op_note_hash_exists); - transcript->send_to_verifier(commitment_labels.main_sel_op_nullifier_exists, - witness_commitments.main_sel_op_nullifier_exists); - transcript->send_to_verifier(commitment_labels.main_sel_op_or, witness_commitments.main_sel_op_or); - transcript->send_to_verifier(commitment_labels.main_sel_op_pedersen, witness_commitments.main_sel_op_pedersen); - transcript->send_to_verifier(commitment_labels.main_sel_op_poseidon2, witness_commitments.main_sel_op_poseidon2); - transcript->send_to_verifier(commitment_labels.main_sel_op_radix_le, witness_commitments.main_sel_op_radix_le); - transcript->send_to_verifier(commitment_labels.main_sel_op_sender, witness_commitments.main_sel_op_sender); - transcript->send_to_verifier(commitment_labels.main_sel_op_sha256, witness_commitments.main_sel_op_sha256); - transcript->send_to_verifier(commitment_labels.main_sel_op_shl, witness_commitments.main_sel_op_shl); - transcript->send_to_verifier(commitment_labels.main_sel_op_shr, witness_commitments.main_sel_op_shr); - transcript->send_to_verifier(commitment_labels.main_sel_op_sload, witness_commitments.main_sel_op_sload); - transcript->send_to_verifier(commitment_labels.main_sel_op_sstore, witness_commitments.main_sel_op_sstore); - transcript->send_to_verifier(commitment_labels.main_sel_op_storage_address, - witness_commitments.main_sel_op_storage_address); - transcript->send_to_verifier(commitment_labels.main_sel_op_sub, witness_commitments.main_sel_op_sub); - transcript->send_to_verifier(commitment_labels.main_sel_op_timestamp, witness_commitments.main_sel_op_timestamp); - transcript->send_to_verifier(commitment_labels.main_sel_op_transaction_fee, - witness_commitments.main_sel_op_transaction_fee); - transcript->send_to_verifier(commitment_labels.main_sel_op_version, witness_commitments.main_sel_op_version); - transcript->send_to_verifier(commitment_labels.main_sel_op_xor, witness_commitments.main_sel_op_xor); - transcript->send_to_verifier(commitment_labels.main_sel_q_kernel_lookup, - witness_commitments.main_sel_q_kernel_lookup); - transcript->send_to_verifier(commitment_labels.main_sel_q_kernel_output_lookup, - witness_commitments.main_sel_q_kernel_output_lookup); - transcript->send_to_verifier(commitment_labels.main_sel_resolve_ind_addr_a, - witness_commitments.main_sel_resolve_ind_addr_a); - transcript->send_to_verifier(commitment_labels.main_sel_resolve_ind_addr_b, - witness_commitments.main_sel_resolve_ind_addr_b); - transcript->send_to_verifier(commitment_labels.main_sel_resolve_ind_addr_c, - witness_commitments.main_sel_resolve_ind_addr_c); - transcript->send_to_verifier(commitment_labels.main_sel_resolve_ind_addr_d, - witness_commitments.main_sel_resolve_ind_addr_d); - transcript->send_to_verifier(commitment_labels.main_sel_rng_16, witness_commitments.main_sel_rng_16); - transcript->send_to_verifier(commitment_labels.main_sel_rng_8, witness_commitments.main_sel_rng_8); - transcript->send_to_verifier(commitment_labels.main_space_id, witness_commitments.main_space_id); - transcript->send_to_verifier(commitment_labels.main_tag_err, witness_commitments.main_tag_err); - transcript->send_to_verifier(commitment_labels.main_w_in_tag, witness_commitments.main_w_in_tag); - transcript->send_to_verifier(commitment_labels.mem_addr, witness_commitments.mem_addr); - transcript->send_to_verifier(commitment_labels.mem_clk, witness_commitments.mem_clk); - transcript->send_to_verifier(commitment_labels.mem_diff_hi, witness_commitments.mem_diff_hi); - transcript->send_to_verifier(commitment_labels.mem_diff_lo, witness_commitments.mem_diff_lo); - transcript->send_to_verifier(commitment_labels.mem_diff_mid, witness_commitments.mem_diff_mid); - transcript->send_to_verifier(commitment_labels.mem_glob_addr, witness_commitments.mem_glob_addr); - transcript->send_to_verifier(commitment_labels.mem_last, witness_commitments.mem_last); - transcript->send_to_verifier(commitment_labels.mem_lastAccess, witness_commitments.mem_lastAccess); - transcript->send_to_verifier(commitment_labels.mem_one_min_inv, witness_commitments.mem_one_min_inv); - transcript->send_to_verifier(commitment_labels.mem_r_in_tag, witness_commitments.mem_r_in_tag); - transcript->send_to_verifier(commitment_labels.mem_rw, witness_commitments.mem_rw); - transcript->send_to_verifier(commitment_labels.mem_sel_mem, witness_commitments.mem_sel_mem); - transcript->send_to_verifier(commitment_labels.mem_sel_mov_ia_to_ic, witness_commitments.mem_sel_mov_ia_to_ic); - transcript->send_to_verifier(commitment_labels.mem_sel_mov_ib_to_ic, witness_commitments.mem_sel_mov_ib_to_ic); - transcript->send_to_verifier(commitment_labels.mem_sel_op_a, witness_commitments.mem_sel_op_a); - transcript->send_to_verifier(commitment_labels.mem_sel_op_b, witness_commitments.mem_sel_op_b); - transcript->send_to_verifier(commitment_labels.mem_sel_op_c, witness_commitments.mem_sel_op_c); - transcript->send_to_verifier(commitment_labels.mem_sel_op_cmov, witness_commitments.mem_sel_op_cmov); - transcript->send_to_verifier(commitment_labels.mem_sel_op_d, witness_commitments.mem_sel_op_d); - transcript->send_to_verifier(commitment_labels.mem_sel_resolve_ind_addr_a, - witness_commitments.mem_sel_resolve_ind_addr_a); - transcript->send_to_verifier(commitment_labels.mem_sel_resolve_ind_addr_b, - witness_commitments.mem_sel_resolve_ind_addr_b); - transcript->send_to_verifier(commitment_labels.mem_sel_resolve_ind_addr_c, - witness_commitments.mem_sel_resolve_ind_addr_c); - transcript->send_to_verifier(commitment_labels.mem_sel_resolve_ind_addr_d, - witness_commitments.mem_sel_resolve_ind_addr_d); - transcript->send_to_verifier(commitment_labels.mem_sel_rng_chk, witness_commitments.mem_sel_rng_chk); - transcript->send_to_verifier(commitment_labels.mem_skip_check_tag, witness_commitments.mem_skip_check_tag); - transcript->send_to_verifier(commitment_labels.mem_space_id, witness_commitments.mem_space_id); - transcript->send_to_verifier(commitment_labels.mem_tag, witness_commitments.mem_tag); - transcript->send_to_verifier(commitment_labels.mem_tag_err, witness_commitments.mem_tag_err); - transcript->send_to_verifier(commitment_labels.mem_tsp, witness_commitments.mem_tsp); - transcript->send_to_verifier(commitment_labels.mem_val, witness_commitments.mem_val); - transcript->send_to_verifier(commitment_labels.mem_w_in_tag, witness_commitments.mem_w_in_tag); - transcript->send_to_verifier(commitment_labels.pedersen_clk, witness_commitments.pedersen_clk); - transcript->send_to_verifier(commitment_labels.pedersen_input, witness_commitments.pedersen_input); - transcript->send_to_verifier(commitment_labels.pedersen_output, witness_commitments.pedersen_output); - transcript->send_to_verifier(commitment_labels.pedersen_sel_pedersen, witness_commitments.pedersen_sel_pedersen); - transcript->send_to_verifier(commitment_labels.poseidon2_a_0, witness_commitments.poseidon2_a_0); - transcript->send_to_verifier(commitment_labels.poseidon2_a_1, witness_commitments.poseidon2_a_1); - transcript->send_to_verifier(commitment_labels.poseidon2_a_2, witness_commitments.poseidon2_a_2); - transcript->send_to_verifier(commitment_labels.poseidon2_a_3, witness_commitments.poseidon2_a_3); - transcript->send_to_verifier(commitment_labels.poseidon2_b_0, witness_commitments.poseidon2_b_0); - transcript->send_to_verifier(commitment_labels.poseidon2_b_1, witness_commitments.poseidon2_b_1); - transcript->send_to_verifier(commitment_labels.poseidon2_b_2, witness_commitments.poseidon2_b_2); - transcript->send_to_verifier(commitment_labels.poseidon2_b_3, witness_commitments.poseidon2_b_3); - transcript->send_to_verifier(commitment_labels.poseidon2_clk, witness_commitments.poseidon2_clk); - transcript->send_to_verifier(commitment_labels.poseidon2_input, witness_commitments.poseidon2_input); - transcript->send_to_verifier(commitment_labels.poseidon2_output, witness_commitments.poseidon2_output); - transcript->send_to_verifier(commitment_labels.poseidon2_sel_poseidon_perm, - witness_commitments.poseidon2_sel_poseidon_perm); - transcript->send_to_verifier(commitment_labels.powers_power_of_2, witness_commitments.powers_power_of_2); - transcript->send_to_verifier(commitment_labels.sha256_clk, witness_commitments.sha256_clk); - transcript->send_to_verifier(commitment_labels.sha256_input, witness_commitments.sha256_input); - transcript->send_to_verifier(commitment_labels.sha256_output, witness_commitments.sha256_output); - transcript->send_to_verifier(commitment_labels.sha256_sel_sha256_compression, - witness_commitments.sha256_sel_sha256_compression); - transcript->send_to_verifier(commitment_labels.sha256_state, witness_commitments.sha256_state); - transcript->send_to_verifier(commitment_labels.lookup_byte_lengths_counts, - witness_commitments.lookup_byte_lengths_counts); - transcript->send_to_verifier(commitment_labels.lookup_byte_operations_counts, - witness_commitments.lookup_byte_operations_counts); - transcript->send_to_verifier(commitment_labels.lookup_opcode_gas_counts, - witness_commitments.lookup_opcode_gas_counts); - transcript->send_to_verifier(commitment_labels.range_check_l2_gas_hi_counts, - witness_commitments.range_check_l2_gas_hi_counts); - transcript->send_to_verifier(commitment_labels.range_check_l2_gas_lo_counts, - witness_commitments.range_check_l2_gas_lo_counts); - transcript->send_to_verifier(commitment_labels.range_check_da_gas_hi_counts, - witness_commitments.range_check_da_gas_hi_counts); - transcript->send_to_verifier(commitment_labels.range_check_da_gas_lo_counts, - witness_commitments.range_check_da_gas_lo_counts); - transcript->send_to_verifier(commitment_labels.kernel_output_lookup_counts, - witness_commitments.kernel_output_lookup_counts); - transcript->send_to_verifier(commitment_labels.lookup_into_kernel_counts, - witness_commitments.lookup_into_kernel_counts); - transcript->send_to_verifier(commitment_labels.incl_main_tag_err_counts, - witness_commitments.incl_main_tag_err_counts); - transcript->send_to_verifier(commitment_labels.incl_mem_tag_err_counts, - witness_commitments.incl_mem_tag_err_counts); - transcript->send_to_verifier(commitment_labels.lookup_mem_rng_chk_lo_counts, - witness_commitments.lookup_mem_rng_chk_lo_counts); - transcript->send_to_verifier(commitment_labels.lookup_mem_rng_chk_mid_counts, - witness_commitments.lookup_mem_rng_chk_mid_counts); - transcript->send_to_verifier(commitment_labels.lookup_mem_rng_chk_hi_counts, - witness_commitments.lookup_mem_rng_chk_hi_counts); - transcript->send_to_verifier(commitment_labels.lookup_pow_2_0_counts, witness_commitments.lookup_pow_2_0_counts); - transcript->send_to_verifier(commitment_labels.lookup_pow_2_1_counts, witness_commitments.lookup_pow_2_1_counts); - transcript->send_to_verifier(commitment_labels.lookup_u8_0_counts, witness_commitments.lookup_u8_0_counts); - transcript->send_to_verifier(commitment_labels.lookup_u8_1_counts, witness_commitments.lookup_u8_1_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_0_counts, witness_commitments.lookup_u16_0_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_1_counts, witness_commitments.lookup_u16_1_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_2_counts, witness_commitments.lookup_u16_2_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_3_counts, witness_commitments.lookup_u16_3_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_4_counts, witness_commitments.lookup_u16_4_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_5_counts, witness_commitments.lookup_u16_5_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_6_counts, witness_commitments.lookup_u16_6_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_7_counts, witness_commitments.lookup_u16_7_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_8_counts, witness_commitments.lookup_u16_8_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_9_counts, witness_commitments.lookup_u16_9_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_10_counts, witness_commitments.lookup_u16_10_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_11_counts, witness_commitments.lookup_u16_11_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_12_counts, witness_commitments.lookup_u16_12_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_13_counts, witness_commitments.lookup_u16_13_counts); - transcript->send_to_verifier(commitment_labels.lookup_u16_14_counts, witness_commitments.lookup_u16_14_counts); - transcript->send_to_verifier(commitment_labels.lookup_div_u16_0_counts, - witness_commitments.lookup_div_u16_0_counts); - transcript->send_to_verifier(commitment_labels.lookup_div_u16_1_counts, - witness_commitments.lookup_div_u16_1_counts); - transcript->send_to_verifier(commitment_labels.lookup_div_u16_2_counts, - witness_commitments.lookup_div_u16_2_counts); - transcript->send_to_verifier(commitment_labels.lookup_div_u16_3_counts, - witness_commitments.lookup_div_u16_3_counts); - transcript->send_to_verifier(commitment_labels.lookup_div_u16_4_counts, - witness_commitments.lookup_div_u16_4_counts); - transcript->send_to_verifier(commitment_labels.lookup_div_u16_5_counts, - witness_commitments.lookup_div_u16_5_counts); - transcript->send_to_verifier(commitment_labels.lookup_div_u16_6_counts, - witness_commitments.lookup_div_u16_6_counts); - transcript->send_to_verifier(commitment_labels.lookup_div_u16_7_counts, - witness_commitments.lookup_div_u16_7_counts); ->>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) } void AvmProver::execute_log_derivative_inverse_round() diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/mem.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/mem.hpp index 3b8c0709aca6..80819ffd785c 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/mem.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/mem.hpp @@ -30,6 +30,10 @@ template struct MemRow { FF mem_sel_op_c{}; FF mem_sel_op_cmov{}; FF mem_sel_op_d{}; + FF mem_sel_op_gadget_a{}; + FF mem_sel_op_gadget_b{}; + FF mem_sel_op_gadget_c{}; + FF mem_sel_op_gadget_d{}; FF mem_sel_op_slice{}; FF mem_sel_resolve_ind_addr_a{}; FF mem_sel_resolve_ind_addr_b{}; @@ -142,14 +146,15 @@ template class memImpl { } { using Accumulator = typename std::tuple_element_t<13, ContainerOverSubrelations>; - auto tmp = (new_term.mem_sel_mem - - ((((((((new_term.mem_sel_op_a + new_term.mem_sel_op_b) + new_term.mem_sel_op_c) + - new_term.mem_sel_op_d) + - new_term.mem_sel_resolve_ind_addr_a) + - new_term.mem_sel_resolve_ind_addr_b) + - new_term.mem_sel_resolve_ind_addr_c) + - new_term.mem_sel_resolve_ind_addr_d) + - new_term.mem_sel_op_slice)); + auto tmp = (new_term.mem_sel_mem - (((((((((new_term.mem_sel_op_a + new_term.mem_sel_op_gadget_a) + + (new_term.mem_sel_op_b + new_term.mem_sel_op_gadget_b)) + + (new_term.mem_sel_op_c + new_term.mem_sel_op_gadget_c)) + + (new_term.mem_sel_op_d + new_term.mem_sel_op_gadget_d)) + + new_term.mem_sel_resolve_ind_addr_a) + + new_term.mem_sel_resolve_ind_addr_b) + + new_term.mem_sel_resolve_ind_addr_c) + + new_term.mem_sel_resolve_ind_addr_d) + + new_term.mem_sel_op_slice)); tmp *= scaling_factor; std::get<13>(evals) += typename Accumulator::View(tmp); } @@ -186,18 +191,21 @@ template class memImpl { } { using Accumulator = typename std::tuple_element_t<19, ContainerOverSubrelations>; - auto tmp = (new_term.mem_tsp - - ((new_term.mem_clk * FF(12)) + - (new_term.mem_sel_mem * - ((((new_term.mem_sel_resolve_ind_addr_b + new_term.mem_sel_op_b) + - ((new_term.mem_sel_resolve_ind_addr_c + new_term.mem_sel_op_c) * FF(2))) + - ((new_term.mem_sel_resolve_ind_addr_d + new_term.mem_sel_op_d) * FF(3))) + - (((-(((new_term.mem_sel_resolve_ind_addr_a + new_term.mem_sel_resolve_ind_addr_b) + - new_term.mem_sel_resolve_ind_addr_c) + - new_term.mem_sel_resolve_ind_addr_d) + - FF(1)) + - new_term.mem_rw) * - FF(4)))))); + auto tmp = + (new_term.mem_tsp - + ((new_term.mem_clk * FF(12)) + + (new_term.mem_sel_mem * + ((((new_term.mem_sel_resolve_ind_addr_b + (new_term.mem_sel_op_b + new_term.mem_sel_op_gadget_b)) + + ((new_term.mem_sel_resolve_ind_addr_c + (new_term.mem_sel_op_c + new_term.mem_sel_op_gadget_c)) * + FF(2))) + + ((new_term.mem_sel_resolve_ind_addr_d + (new_term.mem_sel_op_d + new_term.mem_sel_op_gadget_d)) * + FF(3))) + + (((-(((new_term.mem_sel_resolve_ind_addr_a + new_term.mem_sel_resolve_ind_addr_b) + + new_term.mem_sel_resolve_ind_addr_c) + + new_term.mem_sel_resolve_ind_addr_d) + + FF(1)) + + new_term.mem_rw) * + FF(4)))))); tmp *= scaling_factor; std::get<19>(evals) += typename Accumulator::View(tmp); } diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_main_pos2_perm.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_main_pos2_perm.hpp index d27882918642..039aafc23d65 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_main_pos2_perm.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_main_pos2_perm.hpp @@ -25,11 +25,11 @@ class perm_main_pos2_perm_permutation_settings { in.main_sel_op_poseidon2, in.poseidon2_sel_poseidon_perm, in.main_clk, - in.main_ia, - in.main_ib, + in.main_mem_addr_a, + in.main_mem_addr_b, in.poseidon2_clk, - in.poseidon2_input, - in.poseidon2_output); + in.poseidon2_input_addr, + in.poseidon2_output_addr); } template static inline auto get_nonconst_entities(AllEntities& in) @@ -39,11 +39,11 @@ class perm_main_pos2_perm_permutation_settings { in.main_sel_op_poseidon2, in.poseidon2_sel_poseidon_perm, in.main_clk, - in.main_ia, - in.main_ib, + in.main_mem_addr_a, + in.main_mem_addr_b, in.poseidon2_clk, - in.poseidon2_input, - in.poseidon2_output); + in.poseidon2_input_addr, + in.poseidon2_output_addr); } }; diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/poseidon2.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/poseidon2.hpp index 63775d398a1a..77397586b7f0 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/poseidon2.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/poseidon2.hpp @@ -7,14 +7,303 @@ namespace bb::Avm_vm { template struct Poseidon2Row { + FF poseidon2_B_10_0{}; + FF poseidon2_B_10_1{}; + FF poseidon2_B_10_2{}; + FF poseidon2_B_10_3{}; + FF poseidon2_B_11_0{}; + FF poseidon2_B_11_1{}; + FF poseidon2_B_11_2{}; + FF poseidon2_B_11_3{}; + FF poseidon2_B_12_0{}; + FF poseidon2_B_12_1{}; + FF poseidon2_B_12_2{}; + FF poseidon2_B_12_3{}; + FF poseidon2_B_13_0{}; + FF poseidon2_B_13_1{}; + FF poseidon2_B_13_2{}; + FF poseidon2_B_13_3{}; + FF poseidon2_B_14_0{}; + FF poseidon2_B_14_1{}; + FF poseidon2_B_14_2{}; + FF poseidon2_B_14_3{}; + FF poseidon2_B_15_0{}; + FF poseidon2_B_15_1{}; + FF poseidon2_B_15_2{}; + FF poseidon2_B_15_3{}; + FF poseidon2_B_16_0{}; + FF poseidon2_B_16_1{}; + FF poseidon2_B_16_2{}; + FF poseidon2_B_16_3{}; + FF poseidon2_B_17_0{}; + FF poseidon2_B_17_1{}; + FF poseidon2_B_17_2{}; + FF poseidon2_B_17_3{}; + FF poseidon2_B_18_0{}; + FF poseidon2_B_18_1{}; + FF poseidon2_B_18_2{}; + FF poseidon2_B_18_3{}; + FF poseidon2_B_19_0{}; + FF poseidon2_B_19_1{}; + FF poseidon2_B_19_2{}; + FF poseidon2_B_19_3{}; + FF poseidon2_B_20_0{}; + FF poseidon2_B_20_1{}; + FF poseidon2_B_20_2{}; + FF poseidon2_B_20_3{}; + FF poseidon2_B_21_0{}; + FF poseidon2_B_21_1{}; + FF poseidon2_B_21_2{}; + FF poseidon2_B_21_3{}; + FF poseidon2_B_22_0{}; + FF poseidon2_B_22_1{}; + FF poseidon2_B_22_2{}; + FF poseidon2_B_22_3{}; + FF poseidon2_B_23_0{}; + FF poseidon2_B_23_1{}; + FF poseidon2_B_23_2{}; + FF poseidon2_B_23_3{}; + FF poseidon2_B_24_0{}; + FF poseidon2_B_24_1{}; + FF poseidon2_B_24_2{}; + FF poseidon2_B_24_3{}; + FF poseidon2_B_25_0{}; + FF poseidon2_B_25_1{}; + FF poseidon2_B_25_2{}; + FF poseidon2_B_25_3{}; + FF poseidon2_B_26_0{}; + FF poseidon2_B_26_1{}; + FF poseidon2_B_26_2{}; + FF poseidon2_B_26_3{}; + FF poseidon2_B_27_0{}; + FF poseidon2_B_27_1{}; + FF poseidon2_B_27_2{}; + FF poseidon2_B_27_3{}; + FF poseidon2_B_28_0{}; + FF poseidon2_B_28_1{}; + FF poseidon2_B_28_2{}; + FF poseidon2_B_28_3{}; + FF poseidon2_B_29_0{}; + FF poseidon2_B_29_1{}; + FF poseidon2_B_29_2{}; + FF poseidon2_B_29_3{}; + FF poseidon2_B_30_0{}; + FF poseidon2_B_30_1{}; + FF poseidon2_B_30_2{}; + FF poseidon2_B_30_3{}; + FF poseidon2_B_31_0{}; + FF poseidon2_B_31_1{}; + FF poseidon2_B_31_2{}; + FF poseidon2_B_31_3{}; + FF poseidon2_B_32_0{}; + FF poseidon2_B_32_1{}; + FF poseidon2_B_32_2{}; + FF poseidon2_B_32_3{}; + FF poseidon2_B_33_0{}; + FF poseidon2_B_33_1{}; + FF poseidon2_B_33_2{}; + FF poseidon2_B_33_3{}; + FF poseidon2_B_34_0{}; + FF poseidon2_B_34_1{}; + FF poseidon2_B_34_2{}; + FF poseidon2_B_34_3{}; + FF poseidon2_B_35_0{}; + FF poseidon2_B_35_1{}; + FF poseidon2_B_35_2{}; + FF poseidon2_B_35_3{}; + FF poseidon2_B_36_0{}; + FF poseidon2_B_36_1{}; + FF poseidon2_B_36_2{}; + FF poseidon2_B_36_3{}; + FF poseidon2_B_37_0{}; + FF poseidon2_B_37_1{}; + FF poseidon2_B_37_2{}; + FF poseidon2_B_37_3{}; + FF poseidon2_B_38_0{}; + FF poseidon2_B_38_1{}; + FF poseidon2_B_38_2{}; + FF poseidon2_B_38_3{}; + FF poseidon2_B_39_0{}; + FF poseidon2_B_39_1{}; + FF poseidon2_B_39_2{}; + FF poseidon2_B_39_3{}; + FF poseidon2_B_40_0{}; + FF poseidon2_B_40_1{}; + FF poseidon2_B_40_2{}; + FF poseidon2_B_40_3{}; + FF poseidon2_B_41_0{}; + FF poseidon2_B_41_1{}; + FF poseidon2_B_41_2{}; + FF poseidon2_B_41_3{}; + FF poseidon2_B_42_0{}; + FF poseidon2_B_42_1{}; + FF poseidon2_B_42_2{}; + FF poseidon2_B_42_3{}; + FF poseidon2_B_43_0{}; + FF poseidon2_B_43_1{}; + FF poseidon2_B_43_2{}; + FF poseidon2_B_43_3{}; + FF poseidon2_B_44_0{}; + FF poseidon2_B_44_1{}; + FF poseidon2_B_44_2{}; + FF poseidon2_B_44_3{}; + FF poseidon2_B_45_0{}; + FF poseidon2_B_45_1{}; + FF poseidon2_B_45_2{}; + FF poseidon2_B_45_3{}; + FF poseidon2_B_46_0{}; + FF poseidon2_B_46_1{}; + FF poseidon2_B_46_2{}; + FF poseidon2_B_46_3{}; + FF poseidon2_B_47_0{}; + FF poseidon2_B_47_1{}; + FF poseidon2_B_47_2{}; + FF poseidon2_B_47_3{}; + FF poseidon2_B_48_0{}; + FF poseidon2_B_48_1{}; + FF poseidon2_B_48_2{}; + FF poseidon2_B_48_3{}; + FF poseidon2_B_49_0{}; + FF poseidon2_B_49_1{}; + FF poseidon2_B_49_2{}; + FF poseidon2_B_49_3{}; + FF poseidon2_B_4_0{}; + FF poseidon2_B_4_1{}; + FF poseidon2_B_4_2{}; + FF poseidon2_B_4_3{}; + FF poseidon2_B_50_0{}; + FF poseidon2_B_50_1{}; + FF poseidon2_B_50_2{}; + FF poseidon2_B_50_3{}; + FF poseidon2_B_51_0{}; + FF poseidon2_B_51_1{}; + FF poseidon2_B_51_2{}; + FF poseidon2_B_51_3{}; + FF poseidon2_B_52_0{}; + FF poseidon2_B_52_1{}; + FF poseidon2_B_52_2{}; + FF poseidon2_B_52_3{}; + FF poseidon2_B_53_0{}; + FF poseidon2_B_53_1{}; + FF poseidon2_B_53_2{}; + FF poseidon2_B_53_3{}; + FF poseidon2_B_54_0{}; + FF poseidon2_B_54_1{}; + FF poseidon2_B_54_2{}; + FF poseidon2_B_54_3{}; + FF poseidon2_B_55_0{}; + FF poseidon2_B_55_1{}; + FF poseidon2_B_55_2{}; + FF poseidon2_B_55_3{}; + FF poseidon2_B_56_0{}; + FF poseidon2_B_56_1{}; + FF poseidon2_B_56_2{}; + FF poseidon2_B_56_3{}; + FF poseidon2_B_57_0{}; + FF poseidon2_B_57_1{}; + FF poseidon2_B_57_2{}; + FF poseidon2_B_57_3{}; + FF poseidon2_B_58_0{}; + FF poseidon2_B_58_1{}; + FF poseidon2_B_58_2{}; + FF poseidon2_B_58_3{}; + FF poseidon2_B_59_0{}; + FF poseidon2_B_59_1{}; + FF poseidon2_B_59_2{}; + FF poseidon2_B_59_3{}; + FF poseidon2_B_5_0{}; + FF poseidon2_B_5_1{}; + FF poseidon2_B_5_2{}; + FF poseidon2_B_5_3{}; + FF poseidon2_B_6_0{}; + FF poseidon2_B_6_1{}; + FF poseidon2_B_6_2{}; + FF poseidon2_B_6_3{}; + FF poseidon2_B_7_0{}; + FF poseidon2_B_7_1{}; + FF poseidon2_B_7_2{}; + FF poseidon2_B_7_3{}; + FF poseidon2_B_8_0{}; + FF poseidon2_B_8_1{}; + FF poseidon2_B_8_2{}; + FF poseidon2_B_8_3{}; + FF poseidon2_B_9_0{}; + FF poseidon2_B_9_1{}; + FF poseidon2_B_9_2{}; + FF poseidon2_B_9_3{}; + FF poseidon2_EXT_LAYER_4{}; + FF poseidon2_EXT_LAYER_5{}; + FF poseidon2_EXT_LAYER_6{}; + FF poseidon2_EXT_LAYER_7{}; + FF poseidon2_T_0_4{}; + FF poseidon2_T_0_5{}; + FF poseidon2_T_0_6{}; + FF poseidon2_T_0_7{}; + FF poseidon2_T_1_4{}; + FF poseidon2_T_1_5{}; + FF poseidon2_T_1_6{}; + FF poseidon2_T_1_7{}; + FF poseidon2_T_2_4{}; + FF poseidon2_T_2_5{}; + FF poseidon2_T_2_6{}; + FF poseidon2_T_2_7{}; + FF poseidon2_T_3_4{}; + FF poseidon2_T_3_5{}; + FF poseidon2_T_3_6{}; + FF poseidon2_T_3_7{}; + FF poseidon2_T_60_4{}; + FF poseidon2_T_60_5{}; + FF poseidon2_T_60_6{}; + FF poseidon2_T_60_7{}; + FF poseidon2_T_61_4{}; + FF poseidon2_T_61_5{}; + FF poseidon2_T_61_6{}; + FF poseidon2_T_61_7{}; + FF poseidon2_T_62_4{}; + FF poseidon2_T_62_5{}; + FF poseidon2_T_62_6{}; + FF poseidon2_T_62_7{}; + FF poseidon2_T_63_4{}; + FF poseidon2_T_63_5{}; + FF poseidon2_T_63_6{}; + FF poseidon2_T_63_7{}; + FF poseidon2_a_0{}; + FF poseidon2_a_0_shift{}; + FF poseidon2_a_1{}; + FF poseidon2_a_1_shift{}; + FF poseidon2_a_2{}; + FF poseidon2_a_2_shift{}; + FF poseidon2_a_3{}; + FF poseidon2_a_3_shift{}; + FF poseidon2_in_tag{}; + FF poseidon2_input_addr{}; + FF poseidon2_mem_addr_a{}; + FF poseidon2_mem_addr_b{}; + FF poseidon2_mem_addr_c{}; + FF poseidon2_mem_addr_d{}; + FF poseidon2_mem_op{}; + FF poseidon2_output_addr{}; + FF poseidon2_read_line{}; FF poseidon2_sel_poseidon_perm{}; + FF poseidon2_sel_poseidon_perm_shift{}; + FF poseidon2_write_line{}; + FF poseidon2_write_line_shift{}; }; template class poseidon2Impl { public: using FF = FF_; - static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { 3 }; + static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { + 3, 3, 3, 3, 2, 2, 2, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 7, + 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, + 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, + 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, + 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, + 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, + 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, + 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 3, 3, 3, 3 + }; template void static accumulate(ContainerOverSubrelations& evals, @@ -28,6 +317,11684 @@ template class poseidon2Impl { tmp *= scaling_factor; std::get<0>(evals) += typename Accumulator::View(tmp); } + { + using Accumulator = typename std::tuple_element_t<1, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * new_term.poseidon2_sel_poseidon_perm_shift); + tmp *= scaling_factor; + std::get<1>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<2, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_read_line * (-new_term.poseidon2_read_line + FF(1))); + tmp *= scaling_factor; + std::get<2>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<3, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_write_line * (-new_term.poseidon2_write_line + FF(1))); + tmp *= scaling_factor; + std::get<3>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<4, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm - new_term.poseidon2_read_line); + tmp *= scaling_factor; + std::get<4>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<5, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm - new_term.poseidon2_write_line_shift); + tmp *= scaling_factor; + std::get<5>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<6, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_mem_op - (new_term.poseidon2_read_line + new_term.poseidon2_write_line)); + tmp *= scaling_factor; + std::get<6>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<7, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_mem_op * (-new_term.poseidon2_mem_op + FF(1))); + tmp *= scaling_factor; + std::get<7>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<8, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_mem_op * (new_term.poseidon2_in_tag - FF(6))); + tmp *= scaling_factor; + std::get<8>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<9, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_mem_op * + (new_term.poseidon2_mem_addr_a - ((new_term.poseidon2_read_line * new_term.poseidon2_input_addr) + + (new_term.poseidon2_write_line * new_term.poseidon2_output_addr)))); + tmp *= scaling_factor; + std::get<9>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<10, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_mem_op * + (new_term.poseidon2_mem_addr_b - (((new_term.poseidon2_read_line * new_term.poseidon2_input_addr) + + (new_term.poseidon2_write_line * new_term.poseidon2_output_addr)) + + FF(1)))); + tmp *= scaling_factor; + std::get<10>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<11, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_mem_op * + (new_term.poseidon2_mem_addr_c - (((new_term.poseidon2_read_line * new_term.poseidon2_input_addr) + + (new_term.poseidon2_write_line * new_term.poseidon2_output_addr)) + + FF(2)))); + tmp *= scaling_factor; + std::get<11>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<12, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_mem_op * + (new_term.poseidon2_mem_addr_d - (((new_term.poseidon2_read_line * new_term.poseidon2_input_addr) + + (new_term.poseidon2_write_line * new_term.poseidon2_output_addr)) + + FF(3)))); + tmp *= scaling_factor; + std::get<12>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<13, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_EXT_LAYER_4 - + (((new_term.poseidon2_a_2 + new_term.poseidon2_a_3) * FF(4)) + + ((new_term.poseidon2_a_3 * FF(2)) + (new_term.poseidon2_a_0 + new_term.poseidon2_a_1))))); + tmp *= scaling_factor; + std::get<13>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<14, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_EXT_LAYER_5 - + (((new_term.poseidon2_a_0 + new_term.poseidon2_a_1) * FF(4)) + + ((new_term.poseidon2_a_1 * FF(2)) + (new_term.poseidon2_a_2 + new_term.poseidon2_a_3))))); + tmp *= scaling_factor; + std::get<14>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<15, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_EXT_LAYER_6 - + (((new_term.poseidon2_a_3 * FF(2)) + (new_term.poseidon2_a_0 + new_term.poseidon2_a_1)) + + new_term.poseidon2_EXT_LAYER_5))); + tmp *= scaling_factor; + std::get<15>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<16, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_EXT_LAYER_7 - + (((new_term.poseidon2_a_1 * FF(2)) + (new_term.poseidon2_a_2 + new_term.poseidon2_a_3)) + + new_term.poseidon2_EXT_LAYER_4))); + tmp *= scaling_factor; + std::get<16>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<17, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_0_4 - + ((((((((new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL })) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) + + (((((new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL })) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL })))) * + FF(4)) + + (((((((new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL })) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + FF(2)) + + ((((((new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL })) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) + + (((((new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL })) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL })))))))); + tmp *= scaling_factor; + std::get<17>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<18, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_0_5 - + ((((((((new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL })) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) + + (((((new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL })) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL })))) * + FF(4)) + + (((((((new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL })) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + FF(2)) + + ((((((new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL })) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) + + (((((new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL })) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL })))))))); + tmp *= scaling_factor; + std::get<18>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<19, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_0_6 - + ((((((((new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL })) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + FF(2)) + + ((((((new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL })) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) * + (new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, + 196898842818127395UL, + 5249540449481148995UL, + 1853312570062057576UL }))) + + (((((new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL })) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))))) + + new_term.poseidon2_T_0_5))); + tmp *= scaling_factor; + std::get<19>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<20, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_0_7 - + ((((((((new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL })) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + (new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, + 2372038863109147677UL, + 8230667498854222355UL, + 2764611904404804029UL }))) * + FF(2)) + + ((((((new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL })) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) * + (new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, + 4686185096558265002UL, + 16210260819355521378UL, + 1844031548168280073UL }))) + + (((((new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL })) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))) * + (new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, + 5581154705073500415UL, + 1229208533183169201UL, + 1549225070791782920UL }))))) + + new_term.poseidon2_T_0_4))); + tmp *= scaling_factor; + std::get<20>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<21, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_1_4 - + ((((((((new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL })) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) + + (((((new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL })) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL })) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL })) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) + + (((((new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL })) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL })))))))); + tmp *= scaling_factor; + std::get<21>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<22, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_1_5 - + ((((((((new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL })) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) + + (((((new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL })) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL })) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL })) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) + + (((((new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL })) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL })))))))); + tmp *= scaling_factor; + std::get<22>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<23, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_1_6 - + ((((((((new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL })) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL })) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) * + (new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, + 798761732958817262UL, + 6904962453156279281UL, + 3335412762186210716UL }))) + + (((((new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL })) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))))) + + new_term.poseidon2_T_1_5))); + tmp *= scaling_factor; + std::get<23>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<24, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_1_7 - + ((((((((new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL })) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + (new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, + 14640933461146357672UL, + 957840840567621315UL, + 1024001058677493842UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL })) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) * + (new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, + 12239068001133297662UL, + 428134084092645147UL, + 2673682960814460689UL }))) + + (((((new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL })) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))) * + (new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, + 17923963059035301363UL, + 10985380589240272449UL, + 1430464474809378870UL }))))) + + new_term.poseidon2_T_1_4))); + tmp *= scaling_factor; + std::get<24>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<25, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_2_4 - + ((((((((new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL })) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) + + (((((new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL })) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL })) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL })) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) + + (((((new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL })) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL })))))))); + tmp *= scaling_factor; + std::get<25>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<26, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_2_5 - + ((((((((new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL })) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) + + (((((new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL })) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL })) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + + FF(uint256_t{ + 2323272968957708806UL, 354488099726909104UL, 115174089281514891UL, 80808271106704719UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL })) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) + + (((((new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL })) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL })))))))); + tmp *= scaling_factor; + std::get<26>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<27, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_2_6 - + ((((((((new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL })) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL })) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) * + (new_term.poseidon2_T_1_6 + FF(uint256_t{ 5109255232332580664UL, + 11913027714091798733UL, + 4449570166290740355UL, + 864862123557185234UL }))) + + (((((new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL })) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))))) + + new_term.poseidon2_T_2_5))); + tmp *= scaling_factor; + std::get<27>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<28, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_2_7 - + ((((((((new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL })) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + FF(uint256_t{ 2323272968957708806UL, + 354488099726909104UL, + 115174089281514891UL, + 80808271106704719UL }))) * + (new_term.poseidon2_T_1_5 + + FF(uint256_t{ + 2323272968957708806UL, 354488099726909104UL, 115174089281514891UL, 80808271106704719UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL })) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) * + (new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, + 3404572679246369876UL, + 2350204275212843361UL, + 1069216089054537871UL }))) + + (((((new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL })) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))) * + (new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, + 4245857056683447103UL, + 2426504795124362174UL, + 350059533408463330UL }))))) + + new_term.poseidon2_T_2_4))); + tmp *= scaling_factor; + std::get<28>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<29, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_3_4 - + ((((((((new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL })) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) + + (((((new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL })) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL })) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL })) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) + + (((((new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL })) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL })))))))); + tmp *= scaling_factor; + std::get<29>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<30, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_3_5 - + ((((((((new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL })) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) + + (((((new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL })) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL })) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL })) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) + + (((((new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL })) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL })))))))); + tmp *= scaling_factor; + std::get<30>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<31, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_3_6 - + ((((((((new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL })) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL })) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) * + (new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, + 6932857857384975351UL, + 7976037835777844091UL, + 738350885205242785UL }))) + + (((((new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL })) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))))) + + new_term.poseidon2_T_3_5))); + tmp *= scaling_factor; + std::get<31>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<32, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_3_7 - + ((((((((new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL })) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + (new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, + 4157368317794149558UL, + 10343110624935622906UL, + 2709590753056582169UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL })) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) * + (new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, + 8594508728147436821UL, + 15629690186821248127UL, + 2936193411053712582UL }))) + + (((((new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL })) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))) * + (new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, + 14086280776151114414UL, + 2804088968006330580UL, + 728643340397380469UL }))))) + + new_term.poseidon2_T_3_4))); + tmp *= scaling_factor; + std::get<32>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<33, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_4_0 - + (((((((new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL })) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL })) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) + + (new_term.poseidon2_T_3_5 + FF(0))) + + (new_term.poseidon2_T_3_7 + FF(0))) + + (new_term.poseidon2_T_3_4 + FF(0)))))); + tmp *= scaling_factor; + std::get<33>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<34, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_4_1 - + (((new_term.poseidon2_T_3_5 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL })) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) + + (new_term.poseidon2_T_3_5 + FF(0))) + + (new_term.poseidon2_T_3_7 + FF(0))) + + (new_term.poseidon2_T_3_4 + FF(0)))))); + tmp *= scaling_factor; + std::get<34>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<35, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_4_2 - + (((new_term.poseidon2_T_3_7 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL })) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) + + (new_term.poseidon2_T_3_5 + FF(0))) + + (new_term.poseidon2_T_3_7 + FF(0))) + + (new_term.poseidon2_T_3_4 + FF(0)))))); + tmp *= scaling_factor; + std::get<35>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<36, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_4_3 - + (((new_term.poseidon2_T_3_4 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL })) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) * + (new_term.poseidon2_T_3_6 + FF(uint256_t{ 12986735346000814543UL, + 6140074342411686364UL, + 6041575944194691717UL, + 896092723329689904UL }))) + + (new_term.poseidon2_T_3_5 + FF(0))) + + (new_term.poseidon2_T_3_7 + FF(0))) + + (new_term.poseidon2_T_3_4 + FF(0)))))); + tmp *= scaling_factor; + std::get<36>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<37, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_5_0 - + (((((((new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL })) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL })) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) + + (new_term.poseidon2_B_4_1 + FF(0))) + + (new_term.poseidon2_B_4_2 + FF(0))) + + (new_term.poseidon2_B_4_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<37>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<38, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_5_1 - + (((new_term.poseidon2_B_4_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL })) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) + + (new_term.poseidon2_B_4_1 + FF(0))) + + (new_term.poseidon2_B_4_2 + FF(0))) + + (new_term.poseidon2_B_4_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<38>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<39, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_5_2 - + (((new_term.poseidon2_B_4_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL })) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) + + (new_term.poseidon2_B_4_1 + FF(0))) + + (new_term.poseidon2_B_4_2 + FF(0))) + + (new_term.poseidon2_B_4_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<39>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<40, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_5_3 - + (((new_term.poseidon2_B_4_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL })) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) * + (new_term.poseidon2_B_4_0 + FF(uint256_t{ 9573905030842087441UL, + 12243211539080976096UL, + 15287161151491266826UL, + 1310836290481124728UL }))) + + (new_term.poseidon2_B_4_1 + FF(0))) + + (new_term.poseidon2_B_4_2 + FF(0))) + + (new_term.poseidon2_B_4_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<40>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<41, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_6_0 - + (((((((new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL })) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL })) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) + + (new_term.poseidon2_B_5_1 + FF(0))) + + (new_term.poseidon2_B_5_2 + FF(0))) + + (new_term.poseidon2_B_5_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<41>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<42, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_6_1 - + (((new_term.poseidon2_B_5_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL })) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) + + (new_term.poseidon2_B_5_1 + FF(0))) + + (new_term.poseidon2_B_5_2 + FF(0))) + + (new_term.poseidon2_B_5_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<42>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<43, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_6_2 - + (((new_term.poseidon2_B_5_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL })) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) + + (new_term.poseidon2_B_5_1 + FF(0))) + + (new_term.poseidon2_B_5_2 + FF(0))) + + (new_term.poseidon2_B_5_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<43>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<44, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_6_3 - + (((new_term.poseidon2_B_5_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL })) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) * + (new_term.poseidon2_B_5_0 + FF(uint256_t{ 8865134002163281525UL, + 6813849753829831047UL, + 9066778847678578696UL, + 2801725307463304665UL }))) + + (new_term.poseidon2_B_5_1 + FF(0))) + + (new_term.poseidon2_B_5_2 + FF(0))) + + (new_term.poseidon2_B_5_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<44>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<45, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_7_0 - + (((((((new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL })) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL })) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) + + (new_term.poseidon2_B_6_1 + FF(0))) + + (new_term.poseidon2_B_6_2 + FF(0))) + + (new_term.poseidon2_B_6_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<45>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<46, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_7_1 - + (((new_term.poseidon2_B_6_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL })) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) + + (new_term.poseidon2_B_6_1 + FF(0))) + + (new_term.poseidon2_B_6_2 + FF(0))) + + (new_term.poseidon2_B_6_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<46>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<47, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_7_2 - + (((new_term.poseidon2_B_6_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL })) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) + + (new_term.poseidon2_B_6_1 + FF(0))) + + (new_term.poseidon2_B_6_2 + FF(0))) + + (new_term.poseidon2_B_6_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<47>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<48, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_7_3 - + (((new_term.poseidon2_B_6_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL })) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) * + (new_term.poseidon2_B_6_0 + FF(uint256_t{ 4931814869361681093UL, + 13712769805002511750UL, + 1776191062268299644UL, + 2068661504023016414UL }))) + + (new_term.poseidon2_B_6_1 + FF(0))) + + (new_term.poseidon2_B_6_2 + FF(0))) + + (new_term.poseidon2_B_6_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<48>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<49, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_8_0 - + (((((((new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL })) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL })) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) + + (new_term.poseidon2_B_7_1 + FF(0))) + + (new_term.poseidon2_B_7_2 + FF(0))) + + (new_term.poseidon2_B_7_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<49>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<50, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_8_1 - + (((new_term.poseidon2_B_7_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL })) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) + + (new_term.poseidon2_B_7_1 + FF(0))) + + (new_term.poseidon2_B_7_2 + FF(0))) + + (new_term.poseidon2_B_7_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<50>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<51, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_8_2 - + (((new_term.poseidon2_B_7_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL })) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) + + (new_term.poseidon2_B_7_1 + FF(0))) + + (new_term.poseidon2_B_7_2 + FF(0))) + + (new_term.poseidon2_B_7_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<51>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<52, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_8_3 - + (((new_term.poseidon2_B_7_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL })) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) * + (new_term.poseidon2_B_7_0 + FF(uint256_t{ 8161631444256445904UL, + 3049786034047984668UL, + 1021328518293651309UL, + 2147500022207188878UL }))) + + (new_term.poseidon2_B_7_1 + FF(0))) + + (new_term.poseidon2_B_7_2 + FF(0))) + + (new_term.poseidon2_B_7_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<52>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<53, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_9_0 - + (((((((new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL })) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL })) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) + + (new_term.poseidon2_B_8_1 + FF(0))) + + (new_term.poseidon2_B_8_2 + FF(0))) + + (new_term.poseidon2_B_8_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<53>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<54, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_9_1 - + (((new_term.poseidon2_B_8_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL })) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) + + (new_term.poseidon2_B_8_1 + FF(0))) + + (new_term.poseidon2_B_8_2 + FF(0))) + + (new_term.poseidon2_B_8_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<54>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<55, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_9_2 - + (((new_term.poseidon2_B_8_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL })) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) + + (new_term.poseidon2_B_8_1 + FF(0))) + + (new_term.poseidon2_B_8_2 + FF(0))) + + (new_term.poseidon2_B_8_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<55>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<56, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_9_3 - + (((new_term.poseidon2_B_8_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL })) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) * + (new_term.poseidon2_B_8_0 + FF(uint256_t{ 12766468767470212468UL, + 926098071429114297UL, + 17691598410912255471UL, + 76565467953470566UL }))) + + (new_term.poseidon2_B_8_1 + FF(0))) + + (new_term.poseidon2_B_8_2 + FF(0))) + + (new_term.poseidon2_B_8_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<56>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<57, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_10_0 - + (((((((new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL })) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL })) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) + + (new_term.poseidon2_B_9_1 + FF(0))) + + (new_term.poseidon2_B_9_2 + FF(0))) + + (new_term.poseidon2_B_9_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<57>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<58, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_10_1 - + (((new_term.poseidon2_B_9_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL })) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) + + (new_term.poseidon2_B_9_1 + FF(0))) + + (new_term.poseidon2_B_9_2 + FF(0))) + + (new_term.poseidon2_B_9_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<58>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<59, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_10_2 - + (((new_term.poseidon2_B_9_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL })) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) + + (new_term.poseidon2_B_9_1 + FF(0))) + + (new_term.poseidon2_B_9_2 + FF(0))) + + (new_term.poseidon2_B_9_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<59>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<60, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_10_3 - + (((new_term.poseidon2_B_9_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL })) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) * + (new_term.poseidon2_B_9_0 + FF(uint256_t{ 15547843034426617484UL, + 13465733818561903358UL, + 11157089789589945854UL, + 3107062195097242290UL }))) + + (new_term.poseidon2_B_9_1 + FF(0))) + + (new_term.poseidon2_B_9_2 + FF(0))) + + (new_term.poseidon2_B_9_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<60>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<61, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_11_0 - + (((((((new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL })) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL })) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) + + (new_term.poseidon2_B_10_1 + FF(0))) + + (new_term.poseidon2_B_10_2 + FF(0))) + + (new_term.poseidon2_B_10_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<61>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<62, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_11_1 - + (((new_term.poseidon2_B_10_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL })) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) + + (new_term.poseidon2_B_10_1 + FF(0))) + + (new_term.poseidon2_B_10_2 + FF(0))) + + (new_term.poseidon2_B_10_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<62>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<63, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_11_2 - + (((new_term.poseidon2_B_10_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL })) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) + + (new_term.poseidon2_B_10_1 + FF(0))) + + (new_term.poseidon2_B_10_2 + FF(0))) + + (new_term.poseidon2_B_10_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<63>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<64, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_11_3 - + (((new_term.poseidon2_B_10_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL })) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) * + (new_term.poseidon2_B_10_0 + FF(uint256_t{ 16908372174309343397UL, + 17264932925429761530UL, + 11508063480483774160UL, + 2682419245684831641UL }))) + + (new_term.poseidon2_B_10_1 + FF(0))) + + (new_term.poseidon2_B_10_2 + FF(0))) + + (new_term.poseidon2_B_10_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<64>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<65, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_12_0 - + (((((((new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL })) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL })) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) + + (new_term.poseidon2_B_11_1 + FF(0))) + + (new_term.poseidon2_B_11_2 + FF(0))) + + (new_term.poseidon2_B_11_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<65>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<66, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_12_1 - + (((new_term.poseidon2_B_11_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL })) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) + + (new_term.poseidon2_B_11_1 + FF(0))) + + (new_term.poseidon2_B_11_2 + FF(0))) + + (new_term.poseidon2_B_11_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<66>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<67, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_12_2 - + (((new_term.poseidon2_B_11_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL })) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) + + (new_term.poseidon2_B_11_1 + FF(0))) + + (new_term.poseidon2_B_11_2 + FF(0))) + + (new_term.poseidon2_B_11_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<67>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<68, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_12_3 - + (((new_term.poseidon2_B_11_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL })) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) * + (new_term.poseidon2_B_11_0 + FF(uint256_t{ 4870692136216401181UL, + 17645600130793395310UL, + 2758876031472241166UL, + 874943362207641089UL }))) + + (new_term.poseidon2_B_11_1 + FF(0))) + + (new_term.poseidon2_B_11_2 + FF(0))) + + (new_term.poseidon2_B_11_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<68>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<69, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_13_0 - + (((((((new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL })) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL })) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) + + (new_term.poseidon2_B_12_1 + FF(0))) + + (new_term.poseidon2_B_12_2 + FF(0))) + + (new_term.poseidon2_B_12_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<69>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<70, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_13_1 - + (((new_term.poseidon2_B_12_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL })) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) + + (new_term.poseidon2_B_12_1 + FF(0))) + + (new_term.poseidon2_B_12_2 + FF(0))) + + (new_term.poseidon2_B_12_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<70>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<71, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_13_2 - + (((new_term.poseidon2_B_12_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL })) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) + + (new_term.poseidon2_B_12_1 + FF(0))) + + (new_term.poseidon2_B_12_2 + FF(0))) + + (new_term.poseidon2_B_12_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<71>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<72, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_13_3 - + (((new_term.poseidon2_B_12_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL })) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) * + (new_term.poseidon2_B_12_0 + FF(uint256_t{ 4540479402638267003UL, + 13477556963426049071UL, + 6055112305493291757UL, + 1810598527648098537UL }))) + + (new_term.poseidon2_B_12_1 + FF(0))) + + (new_term.poseidon2_B_12_2 + FF(0))) + + (new_term.poseidon2_B_12_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<72>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<73, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_14_0 - + (((((((new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL })) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL })) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) + + (new_term.poseidon2_B_13_1 + FF(0))) + + (new_term.poseidon2_B_13_2 + FF(0))) + + (new_term.poseidon2_B_13_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<73>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<74, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_14_1 - + (((new_term.poseidon2_B_13_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL })) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) + + (new_term.poseidon2_B_13_1 + FF(0))) + + (new_term.poseidon2_B_13_2 + FF(0))) + + (new_term.poseidon2_B_13_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<74>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<75, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_14_2 - + (((new_term.poseidon2_B_13_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL })) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) + + (new_term.poseidon2_B_13_1 + FF(0))) + + (new_term.poseidon2_B_13_2 + FF(0))) + + (new_term.poseidon2_B_13_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<75>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<76, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_14_3 - + (((new_term.poseidon2_B_13_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL })) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) * + (new_term.poseidon2_B_13_0 + FF(uint256_t{ 7894770769272900997UL, + 9595210915998428021UL, + 7642295683223718917UL, + 2210716392790471408UL }))) + + (new_term.poseidon2_B_13_1 + FF(0))) + + (new_term.poseidon2_B_13_2 + FF(0))) + + (new_term.poseidon2_B_13_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<76>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<77, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_15_0 - + (((((((new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL })) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL })) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) + + (new_term.poseidon2_B_14_1 + FF(0))) + + (new_term.poseidon2_B_14_2 + FF(0))) + + (new_term.poseidon2_B_14_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<77>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<78, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_15_1 - + (((new_term.poseidon2_B_14_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL })) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) + + (new_term.poseidon2_B_14_1 + FF(0))) + + (new_term.poseidon2_B_14_2 + FF(0))) + + (new_term.poseidon2_B_14_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<78>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<79, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_15_2 - + (((new_term.poseidon2_B_14_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL })) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) + + (new_term.poseidon2_B_14_1 + FF(0))) + + (new_term.poseidon2_B_14_2 + FF(0))) + + (new_term.poseidon2_B_14_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<79>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<80, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_15_3 - + (((new_term.poseidon2_B_14_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL })) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) * + (new_term.poseidon2_B_14_0 + FF(uint256_t{ 10910178561156475899UL, + 15811627963917441510UL, + 16460518660187536520UL, + 1698297851221778809UL }))) + + (new_term.poseidon2_B_14_1 + FF(0))) + + (new_term.poseidon2_B_14_2 + FF(0))) + + (new_term.poseidon2_B_14_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<80>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<81, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_16_0 - + (((((((new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL })) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL })) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) + + (new_term.poseidon2_B_15_1 + FF(0))) + + (new_term.poseidon2_B_15_2 + FF(0))) + + (new_term.poseidon2_B_15_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<81>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<82, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_16_1 - + (((new_term.poseidon2_B_15_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL })) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) + + (new_term.poseidon2_B_15_1 + FF(0))) + + (new_term.poseidon2_B_15_2 + FF(0))) + + (new_term.poseidon2_B_15_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<82>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<83, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_16_2 - + (((new_term.poseidon2_B_15_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL })) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) + + (new_term.poseidon2_B_15_1 + FF(0))) + + (new_term.poseidon2_B_15_2 + FF(0))) + + (new_term.poseidon2_B_15_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<83>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<84, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_16_3 - + (((new_term.poseidon2_B_15_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL })) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) * + (new_term.poseidon2_B_15_0 + FF(uint256_t{ 7831732902708890908UL, + 1464390598836302271UL, + 8568564606321342514UL, + 3007171090439369509UL }))) + + (new_term.poseidon2_B_15_1 + FF(0))) + + (new_term.poseidon2_B_15_2 + FF(0))) + + (new_term.poseidon2_B_15_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<84>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<85, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_17_0 - + (((((((new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL })) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL })) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) + + (new_term.poseidon2_B_16_1 + FF(0))) + + (new_term.poseidon2_B_16_2 + FF(0))) + + (new_term.poseidon2_B_16_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<85>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<86, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_17_1 - + (((new_term.poseidon2_B_16_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL })) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) + + (new_term.poseidon2_B_16_1 + FF(0))) + + (new_term.poseidon2_B_16_2 + FF(0))) + + (new_term.poseidon2_B_16_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<86>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<87, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_17_2 - + (((new_term.poseidon2_B_16_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL })) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) + + (new_term.poseidon2_B_16_1 + FF(0))) + + (new_term.poseidon2_B_16_2 + FF(0))) + + (new_term.poseidon2_B_16_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<87>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<88, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_17_3 - + (((new_term.poseidon2_B_16_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL })) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) * + (new_term.poseidon2_B_16_0 + FF(uint256_t{ 12758232712903990792UL, + 5937193763836963893UL, + 4629415695575460109UL, + 2476198378403296665UL }))) + + (new_term.poseidon2_B_16_1 + FF(0))) + + (new_term.poseidon2_B_16_2 + FF(0))) + + (new_term.poseidon2_B_16_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<88>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<89, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_18_0 - + (((((((new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL })) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL })) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) + + (new_term.poseidon2_B_17_1 + FF(0))) + + (new_term.poseidon2_B_17_2 + FF(0))) + + (new_term.poseidon2_B_17_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<89>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<90, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_18_1 - + (((new_term.poseidon2_B_17_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL })) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) + + (new_term.poseidon2_B_17_1 + FF(0))) + + (new_term.poseidon2_B_17_2 + FF(0))) + + (new_term.poseidon2_B_17_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<90>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<91, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_18_2 - + (((new_term.poseidon2_B_17_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL })) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) + + (new_term.poseidon2_B_17_1 + FF(0))) + + (new_term.poseidon2_B_17_2 + FF(0))) + + (new_term.poseidon2_B_17_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<91>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<92, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_18_3 - + (((new_term.poseidon2_B_17_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL })) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) * + (new_term.poseidon2_B_17_0 + FF(uint256_t{ 16185652584871361881UL, + 3161867062328690813UL, + 8447947510117581907UL, + 452436262606194895UL }))) + + (new_term.poseidon2_B_17_1 + FF(0))) + + (new_term.poseidon2_B_17_2 + FF(0))) + + (new_term.poseidon2_B_17_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<92>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<93, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_19_0 - + (((((((new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL })) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL })) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) + + (new_term.poseidon2_B_18_1 + FF(0))) + + (new_term.poseidon2_B_18_2 + FF(0))) + + (new_term.poseidon2_B_18_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<93>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<94, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_19_1 - + (((new_term.poseidon2_B_18_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL })) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) + + (new_term.poseidon2_B_18_1 + FF(0))) + + (new_term.poseidon2_B_18_2 + FF(0))) + + (new_term.poseidon2_B_18_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<94>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<95, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_19_2 - + (((new_term.poseidon2_B_18_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL })) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) + + (new_term.poseidon2_B_18_1 + FF(0))) + + (new_term.poseidon2_B_18_2 + FF(0))) + + (new_term.poseidon2_B_18_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<95>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<96, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_19_3 - + (((new_term.poseidon2_B_18_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL })) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) * + (new_term.poseidon2_B_18_0 + FF(uint256_t{ 10531967515434376071UL, + 5577695765815843856UL, + 9164856352050088505UL, + 1205339682110411496UL }))) + + (new_term.poseidon2_B_18_1 + FF(0))) + + (new_term.poseidon2_B_18_2 + FF(0))) + + (new_term.poseidon2_B_18_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<96>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<97, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_20_0 - + (((((((new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL })) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL })) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) + + (new_term.poseidon2_B_19_1 + FF(0))) + + (new_term.poseidon2_B_19_2 + FF(0))) + + (new_term.poseidon2_B_19_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<97>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<98, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_20_1 - + (((new_term.poseidon2_B_19_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL })) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) + + (new_term.poseidon2_B_19_1 + FF(0))) + + (new_term.poseidon2_B_19_2 + FF(0))) + + (new_term.poseidon2_B_19_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<98>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<99, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_20_2 - + (((new_term.poseidon2_B_19_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL })) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) + + (new_term.poseidon2_B_19_1 + FF(0))) + + (new_term.poseidon2_B_19_2 + FF(0))) + + (new_term.poseidon2_B_19_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<99>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<100, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_20_3 - + (((new_term.poseidon2_B_19_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL })) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) * + (new_term.poseidon2_B_19_0 + FF(uint256_t{ 3898841196333713180UL, + 14650521577519770525UL, + 5736581618852866049UL, + 1010789789328495026UL }))) + + (new_term.poseidon2_B_19_1 + FF(0))) + + (new_term.poseidon2_B_19_2 + FF(0))) + + (new_term.poseidon2_B_19_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<100>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<101, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_21_0 - + (((((((new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL })) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL })) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) + + (new_term.poseidon2_B_20_1 + FF(0))) + + (new_term.poseidon2_B_20_2 + FF(0))) + + (new_term.poseidon2_B_20_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<101>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<102, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_21_1 - + (((new_term.poseidon2_B_20_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL })) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) + + (new_term.poseidon2_B_20_1 + FF(0))) + + (new_term.poseidon2_B_20_2 + FF(0))) + + (new_term.poseidon2_B_20_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<102>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<103, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_21_2 - + (((new_term.poseidon2_B_20_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL })) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) + + (new_term.poseidon2_B_20_1 + FF(0))) + + (new_term.poseidon2_B_20_2 + FF(0))) + + (new_term.poseidon2_B_20_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<103>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<104, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_21_3 - + (((new_term.poseidon2_B_20_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL })) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) * + (new_term.poseidon2_B_20_0 + FF(uint256_t{ 12103741763020280571UL, + 14760208106156268938UL, + 15246749619665902195UL, + 1987439155030896717UL }))) + + (new_term.poseidon2_B_20_1 + FF(0))) + + (new_term.poseidon2_B_20_2 + FF(0))) + + (new_term.poseidon2_B_20_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<104>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<105, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_22_0 - + (((((((new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL })) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL })) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) + + (new_term.poseidon2_B_21_1 + FF(0))) + + (new_term.poseidon2_B_21_2 + FF(0))) + + (new_term.poseidon2_B_21_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<105>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<106, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_22_1 - + (((new_term.poseidon2_B_21_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL })) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) + + (new_term.poseidon2_B_21_1 + FF(0))) + + (new_term.poseidon2_B_21_2 + FF(0))) + + (new_term.poseidon2_B_21_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<106>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<107, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_22_2 - + (((new_term.poseidon2_B_21_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL })) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) + + (new_term.poseidon2_B_21_1 + FF(0))) + + (new_term.poseidon2_B_21_2 + FF(0))) + + (new_term.poseidon2_B_21_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<107>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<108, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_22_3 - + (((new_term.poseidon2_B_21_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL })) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) * + (new_term.poseidon2_B_21_0 + FF(uint256_t{ 326429241861474059UL, + 11335157279655967493UL, + 16233357323017397007UL, + 2124770605461456708UL }))) + + (new_term.poseidon2_B_21_1 + FF(0))) + + (new_term.poseidon2_B_21_2 + FF(0))) + + (new_term.poseidon2_B_21_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<108>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<109, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_23_0 - + (((((((new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL })) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL })) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) + + (new_term.poseidon2_B_22_1 + FF(0))) + + (new_term.poseidon2_B_22_2 + FF(0))) + + (new_term.poseidon2_B_22_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<109>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<110, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_23_1 - + (((new_term.poseidon2_B_22_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL })) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) + + (new_term.poseidon2_B_22_1 + FF(0))) + + (new_term.poseidon2_B_22_2 + FF(0))) + + (new_term.poseidon2_B_22_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<110>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<111, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_23_2 - + (((new_term.poseidon2_B_22_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL })) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) + + (new_term.poseidon2_B_22_1 + FF(0))) + + (new_term.poseidon2_B_22_2 + FF(0))) + + (new_term.poseidon2_B_22_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<111>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<112, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_23_3 - + (((new_term.poseidon2_B_22_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL })) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) * + (new_term.poseidon2_B_22_0 + FF(uint256_t{ 13507610432344102875UL, + 9765425316929074945UL, + 10455054851855122687UL, + 3371280263716451574UL }))) + + (new_term.poseidon2_B_22_1 + FF(0))) + + (new_term.poseidon2_B_22_2 + FF(0))) + + (new_term.poseidon2_B_22_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<112>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<113, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_24_0 - + (((((((new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL })) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL })) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) + + (new_term.poseidon2_B_23_1 + FF(0))) + + (new_term.poseidon2_B_23_2 + FF(0))) + + (new_term.poseidon2_B_23_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<113>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<114, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_24_1 - + (((new_term.poseidon2_B_23_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL })) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) + + (new_term.poseidon2_B_23_1 + FF(0))) + + (new_term.poseidon2_B_23_2 + FF(0))) + + (new_term.poseidon2_B_23_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<114>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<115, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_24_2 - + (((new_term.poseidon2_B_23_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL })) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) + + (new_term.poseidon2_B_23_1 + FF(0))) + + (new_term.poseidon2_B_23_2 + FF(0))) + + (new_term.poseidon2_B_23_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<115>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<116, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_24_3 - + (((new_term.poseidon2_B_23_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL })) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) * + (new_term.poseidon2_B_23_0 + FF(uint256_t{ 9433430149246843174UL, + 16916651192445074064UL, + 12002862125451454299UL, + 3293088726774108791UL }))) + + (new_term.poseidon2_B_23_1 + FF(0))) + + (new_term.poseidon2_B_23_2 + FF(0))) + + (new_term.poseidon2_B_23_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<116>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<117, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_25_0 - + (((((((new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL })) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL })) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) + + (new_term.poseidon2_B_24_1 + FF(0))) + + (new_term.poseidon2_B_24_2 + FF(0))) + + (new_term.poseidon2_B_24_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<117>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<118, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_25_1 - + (((new_term.poseidon2_B_24_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL })) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) + + (new_term.poseidon2_B_24_1 + FF(0))) + + (new_term.poseidon2_B_24_2 + FF(0))) + + (new_term.poseidon2_B_24_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<118>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<119, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_25_2 - + (((new_term.poseidon2_B_24_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL })) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) + + (new_term.poseidon2_B_24_1 + FF(0))) + + (new_term.poseidon2_B_24_2 + FF(0))) + + (new_term.poseidon2_B_24_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<119>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<120, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_25_3 - + (((new_term.poseidon2_B_24_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL })) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) * + (new_term.poseidon2_B_24_0 + FF(uint256_t{ 15895963712096768440UL, + 10975964170403460506UL, + 7594578539046143282UL, + 441635248990433378UL }))) + + (new_term.poseidon2_B_24_1 + FF(0))) + + (new_term.poseidon2_B_24_2 + FF(0))) + + (new_term.poseidon2_B_24_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<120>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<121, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_26_0 - + (((((((new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL })) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + + FF(uint256_t{ + 55564641555031451UL, 2316046008873247993UL, 6273091099984972305UL, 531938487375579818UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL })) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) + + (new_term.poseidon2_B_25_1 + FF(0))) + + (new_term.poseidon2_B_25_2 + FF(0))) + + (new_term.poseidon2_B_25_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<121>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<122, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_26_1 - + (((new_term.poseidon2_B_25_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL })) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) + + (new_term.poseidon2_B_25_1 + FF(0))) + + (new_term.poseidon2_B_25_2 + FF(0))) + + (new_term.poseidon2_B_25_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<122>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<123, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_26_2 - + (((new_term.poseidon2_B_25_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL })) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) + + (new_term.poseidon2_B_25_1 + FF(0))) + + (new_term.poseidon2_B_25_2 + FF(0))) + + (new_term.poseidon2_B_25_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<123>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<124, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_26_3 - + (((new_term.poseidon2_B_25_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL })) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) * + (new_term.poseidon2_B_25_0 + FF(uint256_t{ 55564641555031451UL, + 2316046008873247993UL, + 6273091099984972305UL, + 531938487375579818UL }))) + + (new_term.poseidon2_B_25_1 + FF(0))) + + (new_term.poseidon2_B_25_2 + FF(0))) + + (new_term.poseidon2_B_25_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<124>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<125, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_27_0 - + (((((((new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL })) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL })) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) + + (new_term.poseidon2_B_26_1 + FF(0))) + + (new_term.poseidon2_B_26_2 + FF(0))) + + (new_term.poseidon2_B_26_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<125>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<126, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_27_1 - + (((new_term.poseidon2_B_26_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL })) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) + + (new_term.poseidon2_B_26_1 + FF(0))) + + (new_term.poseidon2_B_26_2 + FF(0))) + + (new_term.poseidon2_B_26_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<126>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<127, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_27_2 - + (((new_term.poseidon2_B_26_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL })) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) + + (new_term.poseidon2_B_26_1 + FF(0))) + + (new_term.poseidon2_B_26_2 + FF(0))) + + (new_term.poseidon2_B_26_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<127>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<128, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_27_3 - + (((new_term.poseidon2_B_26_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL })) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) * + (new_term.poseidon2_B_26_0 + FF(uint256_t{ 17845282940759944461UL, + 6735239388814238924UL, + 3181517889518583601UL, + 2376846283559998361UL }))) + + (new_term.poseidon2_B_26_1 + FF(0))) + + (new_term.poseidon2_B_26_2 + FF(0))) + + (new_term.poseidon2_B_26_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<128>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<129, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_28_0 - + (((((((new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL })) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL })) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) + + (new_term.poseidon2_B_27_1 + FF(0))) + + (new_term.poseidon2_B_27_2 + FF(0))) + + (new_term.poseidon2_B_27_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<129>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<130, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_28_1 - + (((new_term.poseidon2_B_27_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL })) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) + + (new_term.poseidon2_B_27_1 + FF(0))) + + (new_term.poseidon2_B_27_2 + FF(0))) + + (new_term.poseidon2_B_27_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<130>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<131, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_28_2 - + (((new_term.poseidon2_B_27_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL })) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) + + (new_term.poseidon2_B_27_1 + FF(0))) + + (new_term.poseidon2_B_27_2 + FF(0))) + + (new_term.poseidon2_B_27_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<131>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<132, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_28_3 - + (((new_term.poseidon2_B_27_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL })) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) * + (new_term.poseidon2_B_27_0 + FF(uint256_t{ 14097127963645492314UL, + 1165420652731038559UL, + 12527303660854712762UL, + 2717289076364278965UL }))) + + (new_term.poseidon2_B_27_1 + FF(0))) + + (new_term.poseidon2_B_27_2 + FF(0))) + + (new_term.poseidon2_B_27_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<132>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<133, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_29_0 - + (((((((new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL })) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL })) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) + + (new_term.poseidon2_B_28_1 + FF(0))) + + (new_term.poseidon2_B_28_2 + FF(0))) + + (new_term.poseidon2_B_28_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<133>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<134, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_29_1 - + (((new_term.poseidon2_B_28_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL })) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) + + (new_term.poseidon2_B_28_1 + FF(0))) + + (new_term.poseidon2_B_28_2 + FF(0))) + + (new_term.poseidon2_B_28_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<134>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<135, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_29_2 - + (((new_term.poseidon2_B_28_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL })) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) + + (new_term.poseidon2_B_28_1 + FF(0))) + + (new_term.poseidon2_B_28_2 + FF(0))) + + (new_term.poseidon2_B_28_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<135>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<136, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_29_3 - + (((new_term.poseidon2_B_28_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL })) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) * + (new_term.poseidon2_B_28_0 + FF(uint256_t{ 15600044695084040011UL, + 255324662529267034UL, + 11859356122961343981UL, + 2571979992654075442UL }))) + + (new_term.poseidon2_B_28_1 + FF(0))) + + (new_term.poseidon2_B_28_2 + FF(0))) + + (new_term.poseidon2_B_28_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<136>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<137, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_30_0 - + (((((((new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL })) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL })) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) + + (new_term.poseidon2_B_29_1 + FF(0))) + + (new_term.poseidon2_B_29_2 + FF(0))) + + (new_term.poseidon2_B_29_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<137>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<138, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_30_1 - + (((new_term.poseidon2_B_29_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL })) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) + + (new_term.poseidon2_B_29_1 + FF(0))) + + (new_term.poseidon2_B_29_2 + FF(0))) + + (new_term.poseidon2_B_29_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<138>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<139, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_30_2 - + (((new_term.poseidon2_B_29_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL })) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) + + (new_term.poseidon2_B_29_1 + FF(0))) + + (new_term.poseidon2_B_29_2 + FF(0))) + + (new_term.poseidon2_B_29_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<139>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<140, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_30_3 - + (((new_term.poseidon2_B_29_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL })) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) * + (new_term.poseidon2_B_29_0 + FF(uint256_t{ 1589817027469470176UL, + 1086723465680833706UL, + 6948011514366564799UL, + 2482410610948543635UL }))) + + (new_term.poseidon2_B_29_1 + FF(0))) + + (new_term.poseidon2_B_29_2 + FF(0))) + + (new_term.poseidon2_B_29_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<140>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<141, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_31_0 - + (((((((new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL })) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL })) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) + + (new_term.poseidon2_B_30_1 + FF(0))) + + (new_term.poseidon2_B_30_2 + FF(0))) + + (new_term.poseidon2_B_30_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<141>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<142, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_31_1 - + (((new_term.poseidon2_B_30_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL })) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) + + (new_term.poseidon2_B_30_1 + FF(0))) + + (new_term.poseidon2_B_30_2 + FF(0))) + + (new_term.poseidon2_B_30_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<142>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<143, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_31_2 - + (((new_term.poseidon2_B_30_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL })) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) + + (new_term.poseidon2_B_30_1 + FF(0))) + + (new_term.poseidon2_B_30_2 + FF(0))) + + (new_term.poseidon2_B_30_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<143>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<144, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_31_3 - + (((new_term.poseidon2_B_30_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL })) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) * + (new_term.poseidon2_B_30_0 + FF(uint256_t{ 6071201116374785253UL, + 16554668458221199618UL, + 16319484688832471879UL, + 2792452762383364279UL }))) + + (new_term.poseidon2_B_30_1 + FF(0))) + + (new_term.poseidon2_B_30_2 + FF(0))) + + (new_term.poseidon2_B_30_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<144>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<145, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_32_0 - + (((((((new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL })) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL })) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) + + (new_term.poseidon2_B_31_1 + FF(0))) + + (new_term.poseidon2_B_31_2 + FF(0))) + + (new_term.poseidon2_B_31_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<145>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<146, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_32_1 - + (((new_term.poseidon2_B_31_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL })) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) + + (new_term.poseidon2_B_31_1 + FF(0))) + + (new_term.poseidon2_B_31_2 + FF(0))) + + (new_term.poseidon2_B_31_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<146>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<147, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_32_2 - + (((new_term.poseidon2_B_31_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL })) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) + + (new_term.poseidon2_B_31_1 + FF(0))) + + (new_term.poseidon2_B_31_2 + FF(0))) + + (new_term.poseidon2_B_31_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<147>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<148, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_32_3 - + (((new_term.poseidon2_B_31_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL })) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) * + (new_term.poseidon2_B_31_0 + FF(uint256_t{ 13535048470209809113UL, + 1831807297936988201UL, + 16757520396573457190UL, + 508291910620511162UL }))) + + (new_term.poseidon2_B_31_1 + FF(0))) + + (new_term.poseidon2_B_31_2 + FF(0))) + + (new_term.poseidon2_B_31_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<148>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<149, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_33_0 - + (((((((new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL })) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL })) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) + + (new_term.poseidon2_B_32_1 + FF(0))) + + (new_term.poseidon2_B_32_2 + FF(0))) + + (new_term.poseidon2_B_32_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<149>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<150, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_33_1 - + (((new_term.poseidon2_B_32_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL })) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) + + (new_term.poseidon2_B_32_1 + FF(0))) + + (new_term.poseidon2_B_32_2 + FF(0))) + + (new_term.poseidon2_B_32_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<150>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<151, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_33_2 - + (((new_term.poseidon2_B_32_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL })) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) + + (new_term.poseidon2_B_32_1 + FF(0))) + + (new_term.poseidon2_B_32_2 + FF(0))) + + (new_term.poseidon2_B_32_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<151>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<152, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_33_3 - + (((new_term.poseidon2_B_32_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL })) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) * + (new_term.poseidon2_B_32_0 + FF(uint256_t{ 6946737468087619802UL, + 14033399912488027565UL, + 12701200401813783486UL, + 1348363389498465135UL }))) + + (new_term.poseidon2_B_32_1 + FF(0))) + + (new_term.poseidon2_B_32_2 + FF(0))) + + (new_term.poseidon2_B_32_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<152>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<153, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_34_0 - + (((((((new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL })) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL })) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) + + (new_term.poseidon2_B_33_1 + FF(0))) + + (new_term.poseidon2_B_33_2 + FF(0))) + + (new_term.poseidon2_B_33_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<153>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<154, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_34_1 - + (((new_term.poseidon2_B_33_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL })) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) + + (new_term.poseidon2_B_33_1 + FF(0))) + + (new_term.poseidon2_B_33_2 + FF(0))) + + (new_term.poseidon2_B_33_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<154>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<155, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_34_2 - + (((new_term.poseidon2_B_33_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL })) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) + + (new_term.poseidon2_B_33_1 + FF(0))) + + (new_term.poseidon2_B_33_2 + FF(0))) + + (new_term.poseidon2_B_33_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<155>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<156, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_34_3 - + (((new_term.poseidon2_B_33_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL })) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) * + (new_term.poseidon2_B_33_0 + FF(uint256_t{ 6788008051328210729UL, + 13866524545426155292UL, + 4317879914214157329UL, + 2633928310905799638UL }))) + + (new_term.poseidon2_B_33_1 + FF(0))) + + (new_term.poseidon2_B_33_2 + FF(0))) + + (new_term.poseidon2_B_33_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<156>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<157, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_35_0 - + (((((((new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL })) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL })) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) + + (new_term.poseidon2_B_34_1 + FF(0))) + + (new_term.poseidon2_B_34_2 + FF(0))) + + (new_term.poseidon2_B_34_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<157>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<158, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_35_1 - + (((new_term.poseidon2_B_34_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL })) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) + + (new_term.poseidon2_B_34_1 + FF(0))) + + (new_term.poseidon2_B_34_2 + FF(0))) + + (new_term.poseidon2_B_34_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<158>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<159, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_35_2 - + (((new_term.poseidon2_B_34_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL })) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) + + (new_term.poseidon2_B_34_1 + FF(0))) + + (new_term.poseidon2_B_34_2 + FF(0))) + + (new_term.poseidon2_B_34_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<159>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<160, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_35_3 - + (((new_term.poseidon2_B_34_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL })) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) * + (new_term.poseidon2_B_34_0 + FF(uint256_t{ 1183626302001490602UL, + 10035686235057284266UL, + 1656321729167440177UL, + 1887128381037099784UL }))) + + (new_term.poseidon2_B_34_1 + FF(0))) + + (new_term.poseidon2_B_34_2 + FF(0))) + + (new_term.poseidon2_B_34_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<160>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<161, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_36_0 - + (((((((new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL })) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL })) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) + + (new_term.poseidon2_B_35_1 + FF(0))) + + (new_term.poseidon2_B_35_2 + FF(0))) + + (new_term.poseidon2_B_35_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<161>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<162, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_36_1 - + (((new_term.poseidon2_B_35_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL })) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) + + (new_term.poseidon2_B_35_1 + FF(0))) + + (new_term.poseidon2_B_35_2 + FF(0))) + + (new_term.poseidon2_B_35_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<162>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<163, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_36_2 - + (((new_term.poseidon2_B_35_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL })) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) + + (new_term.poseidon2_B_35_1 + FF(0))) + + (new_term.poseidon2_B_35_2 + FF(0))) + + (new_term.poseidon2_B_35_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<163>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<164, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_36_3 - + (((new_term.poseidon2_B_35_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL })) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) * + (new_term.poseidon2_B_35_0 + FF(uint256_t{ 964566190254741199UL, + 17650087760652370459UL, + 14904592615785317921UL, + 2929864473487096026UL }))) + + (new_term.poseidon2_B_35_1 + FF(0))) + + (new_term.poseidon2_B_35_2 + FF(0))) + + (new_term.poseidon2_B_35_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<164>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<165, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_37_0 - + (((((((new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL })) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL })) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) + + (new_term.poseidon2_B_36_1 + FF(0))) + + (new_term.poseidon2_B_36_2 + FF(0))) + + (new_term.poseidon2_B_36_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<165>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<166, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_37_1 - + (((new_term.poseidon2_B_36_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL })) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) + + (new_term.poseidon2_B_36_1 + FF(0))) + + (new_term.poseidon2_B_36_2 + FF(0))) + + (new_term.poseidon2_B_36_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<166>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<167, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_37_2 - + (((new_term.poseidon2_B_36_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL })) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) + + (new_term.poseidon2_B_36_1 + FF(0))) + + (new_term.poseidon2_B_36_2 + FF(0))) + + (new_term.poseidon2_B_36_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<167>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<168, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_37_3 - + (((new_term.poseidon2_B_36_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL })) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) * + (new_term.poseidon2_B_36_0 + FF(uint256_t{ 13584300701347139198UL, + 512534187550045064UL, + 13489711551083721364UL, + 41824696873363624UL }))) + + (new_term.poseidon2_B_36_1 + FF(0))) + + (new_term.poseidon2_B_36_2 + FF(0))) + + (new_term.poseidon2_B_36_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<168>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<169, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_38_0 - + (((((((new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL })) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL })) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) + + (new_term.poseidon2_B_37_1 + FF(0))) + + (new_term.poseidon2_B_37_2 + FF(0))) + + (new_term.poseidon2_B_37_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<169>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<170, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_38_1 - + (((new_term.poseidon2_B_37_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL })) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) + + (new_term.poseidon2_B_37_1 + FF(0))) + + (new_term.poseidon2_B_37_2 + FF(0))) + + (new_term.poseidon2_B_37_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<170>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<171, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_38_2 - + (((new_term.poseidon2_B_37_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL })) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) + + (new_term.poseidon2_B_37_1 + FF(0))) + + (new_term.poseidon2_B_37_2 + FF(0))) + + (new_term.poseidon2_B_37_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<171>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<172, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_38_3 - + (((new_term.poseidon2_B_37_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL })) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) * + (new_term.poseidon2_B_37_0 + FF(uint256_t{ 17586611824788147557UL, + 6430987250922925699UL, + 9294838151373947091UL, + 348446557360066429UL }))) + + (new_term.poseidon2_B_37_1 + FF(0))) + + (new_term.poseidon2_B_37_2 + FF(0))) + + (new_term.poseidon2_B_37_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<172>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<173, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_39_0 - + (((((((new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL })) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL })) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) + + (new_term.poseidon2_B_38_1 + FF(0))) + + (new_term.poseidon2_B_38_2 + FF(0))) + + (new_term.poseidon2_B_38_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<173>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<174, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_39_1 - + (((new_term.poseidon2_B_38_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL })) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) + + (new_term.poseidon2_B_38_1 + FF(0))) + + (new_term.poseidon2_B_38_2 + FF(0))) + + (new_term.poseidon2_B_38_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<174>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<175, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_39_2 - + (((new_term.poseidon2_B_38_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL })) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) + + (new_term.poseidon2_B_38_1 + FF(0))) + + (new_term.poseidon2_B_38_2 + FF(0))) + + (new_term.poseidon2_B_38_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<175>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<176, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_39_3 - + (((new_term.poseidon2_B_38_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL })) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) * + (new_term.poseidon2_B_38_0 + FF(uint256_t{ 15025298913764434311UL, + 14393211163878018166UL, + 7154440178410267241UL, + 3057088631006286899UL }))) + + (new_term.poseidon2_B_38_1 + FF(0))) + + (new_term.poseidon2_B_38_2 + FF(0))) + + (new_term.poseidon2_B_38_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<176>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<177, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_40_0 - + (((((((new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL })) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL })) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) + + (new_term.poseidon2_B_39_1 + FF(0))) + + (new_term.poseidon2_B_39_2 + FF(0))) + + (new_term.poseidon2_B_39_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<177>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<178, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_40_1 - + (((new_term.poseidon2_B_39_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL })) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) + + (new_term.poseidon2_B_39_1 + FF(0))) + + (new_term.poseidon2_B_39_2 + FF(0))) + + (new_term.poseidon2_B_39_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<178>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<179, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_40_2 - + (((new_term.poseidon2_B_39_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL })) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) + + (new_term.poseidon2_B_39_1 + FF(0))) + + (new_term.poseidon2_B_39_2 + FF(0))) + + (new_term.poseidon2_B_39_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<179>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<180, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_40_3 - + (((new_term.poseidon2_B_39_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL })) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) * + (new_term.poseidon2_B_39_0 + FF(uint256_t{ 13451769229280519155UL, + 17839347496757587523UL, + 10553299811918798519UL, + 2523373819901075642UL }))) + + (new_term.poseidon2_B_39_1 + FF(0))) + + (new_term.poseidon2_B_39_2 + FF(0))) + + (new_term.poseidon2_B_39_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<180>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<181, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_41_0 - + (((((((new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL })) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL })) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) + + (new_term.poseidon2_B_40_1 + FF(0))) + + (new_term.poseidon2_B_40_2 + FF(0))) + + (new_term.poseidon2_B_40_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<181>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<182, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_41_1 - + (((new_term.poseidon2_B_40_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL })) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) + + (new_term.poseidon2_B_40_1 + FF(0))) + + (new_term.poseidon2_B_40_2 + FF(0))) + + (new_term.poseidon2_B_40_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<182>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<183, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_41_2 - + (((new_term.poseidon2_B_40_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL })) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) + + (new_term.poseidon2_B_40_1 + FF(0))) + + (new_term.poseidon2_B_40_2 + FF(0))) + + (new_term.poseidon2_B_40_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<183>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<184, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_41_3 - + (((new_term.poseidon2_B_40_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL })) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) * + (new_term.poseidon2_B_40_0 + FF(uint256_t{ 16267315463205810352UL, + 13830706729545301172UL, + 15413288900478726729UL, + 287556136711008934UL }))) + + (new_term.poseidon2_B_40_1 + FF(0))) + + (new_term.poseidon2_B_40_2 + FF(0))) + + (new_term.poseidon2_B_40_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<184>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<185, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_42_0 - + (((((((new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL })) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL })) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) + + (new_term.poseidon2_B_41_1 + FF(0))) + + (new_term.poseidon2_B_41_2 + FF(0))) + + (new_term.poseidon2_B_41_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<185>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<186, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_42_1 - + (((new_term.poseidon2_B_41_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL })) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) + + (new_term.poseidon2_B_41_1 + FF(0))) + + (new_term.poseidon2_B_41_2 + FF(0))) + + (new_term.poseidon2_B_41_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<186>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<187, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_42_2 - + (((new_term.poseidon2_B_41_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL })) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) + + (new_term.poseidon2_B_41_1 + FF(0))) + + (new_term.poseidon2_B_41_2 + FF(0))) + + (new_term.poseidon2_B_41_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<187>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<188, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_42_3 - + (((new_term.poseidon2_B_41_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL })) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) * + (new_term.poseidon2_B_41_0 + FF(uint256_t{ 4573780169675443044UL, + 8758089751960064775UL, + 2470295096511057988UL, + 51551212240288730UL }))) + + (new_term.poseidon2_B_41_1 + FF(0))) + + (new_term.poseidon2_B_41_2 + FF(0))) + + (new_term.poseidon2_B_41_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<188>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<189, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_43_0 - + (((((((new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL })) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL })) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) + + (new_term.poseidon2_B_42_1 + FF(0))) + + (new_term.poseidon2_B_42_2 + FF(0))) + + (new_term.poseidon2_B_42_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<189>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<190, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_43_1 - + (((new_term.poseidon2_B_42_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL })) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) + + (new_term.poseidon2_B_42_1 + FF(0))) + + (new_term.poseidon2_B_42_2 + FF(0))) + + (new_term.poseidon2_B_42_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<190>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<191, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_43_2 - + (((new_term.poseidon2_B_42_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL })) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) + + (new_term.poseidon2_B_42_1 + FF(0))) + + (new_term.poseidon2_B_42_2 + FF(0))) + + (new_term.poseidon2_B_42_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<191>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<192, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_43_3 - + (((new_term.poseidon2_B_42_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL })) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) * + (new_term.poseidon2_B_42_0 + FF(uint256_t{ 7093949836145798554UL, + 12771428392262798771UL, + 17021632567931004395UL, + 1558106578814965657UL }))) + + (new_term.poseidon2_B_42_1 + FF(0))) + + (new_term.poseidon2_B_42_2 + FF(0))) + + (new_term.poseidon2_B_42_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<192>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<193, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_44_0 - + (((((((new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL })) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL })) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) + + (new_term.poseidon2_B_43_1 + FF(0))) + + (new_term.poseidon2_B_43_2 + FF(0))) + + (new_term.poseidon2_B_43_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<193>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<194, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_44_1 - + (((new_term.poseidon2_B_43_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL })) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) + + (new_term.poseidon2_B_43_1 + FF(0))) + + (new_term.poseidon2_B_43_2 + FF(0))) + + (new_term.poseidon2_B_43_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<194>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<195, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_44_2 - + (((new_term.poseidon2_B_43_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL })) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) + + (new_term.poseidon2_B_43_1 + FF(0))) + + (new_term.poseidon2_B_43_2 + FF(0))) + + (new_term.poseidon2_B_43_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<195>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<196, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_44_3 - + (((new_term.poseidon2_B_43_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL })) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) * + (new_term.poseidon2_B_43_0 + FF(uint256_t{ 8205915653008540447UL, + 10376314495036230740UL, + 5774593793305666491UL, + 2231830927015656581UL }))) + + (new_term.poseidon2_B_43_1 + FF(0))) + + (new_term.poseidon2_B_43_2 + FF(0))) + + (new_term.poseidon2_B_43_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<196>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<197, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_45_0 - + (((((((new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL })) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL })) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) + + (new_term.poseidon2_B_44_1 + FF(0))) + + (new_term.poseidon2_B_44_2 + FF(0))) + + (new_term.poseidon2_B_44_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<197>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<198, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_45_1 - + (((new_term.poseidon2_B_44_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL })) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) + + (new_term.poseidon2_B_44_1 + FF(0))) + + (new_term.poseidon2_B_44_2 + FF(0))) + + (new_term.poseidon2_B_44_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<198>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<199, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_45_2 - + (((new_term.poseidon2_B_44_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL })) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) + + (new_term.poseidon2_B_44_1 + FF(0))) + + (new_term.poseidon2_B_44_2 + FF(0))) + + (new_term.poseidon2_B_44_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<199>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<200, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_45_3 - + (((new_term.poseidon2_B_44_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL })) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) * + (new_term.poseidon2_B_44_0 + FF(uint256_t{ 10783762484003267341UL, + 10229708558604896492UL, + 1831638669050696278UL, + 2190429714552610800UL }))) + + (new_term.poseidon2_B_44_1 + FF(0))) + + (new_term.poseidon2_B_44_2 + FF(0))) + + (new_term.poseidon2_B_44_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<200>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<201, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_46_0 - + (((((((new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL })) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL })) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) + + (new_term.poseidon2_B_45_1 + FF(0))) + + (new_term.poseidon2_B_45_2 + FF(0))) + + (new_term.poseidon2_B_45_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<201>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<202, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_46_1 - + (((new_term.poseidon2_B_45_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL })) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) + + (new_term.poseidon2_B_45_1 + FF(0))) + + (new_term.poseidon2_B_45_2 + FF(0))) + + (new_term.poseidon2_B_45_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<202>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<203, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_46_2 - + (((new_term.poseidon2_B_45_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL })) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) + + (new_term.poseidon2_B_45_1 + FF(0))) + + (new_term.poseidon2_B_45_2 + FF(0))) + + (new_term.poseidon2_B_45_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<203>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<204, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_46_3 - + (((new_term.poseidon2_B_45_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL })) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) * + (new_term.poseidon2_B_45_0 + FF(uint256_t{ 7310961803978392383UL, + 12793746113455595394UL, + 17036245927795997300UL, + 3106081169494120044UL }))) + + (new_term.poseidon2_B_45_1 + FF(0))) + + (new_term.poseidon2_B_45_2 + FF(0))) + + (new_term.poseidon2_B_45_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<204>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<205, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_47_0 - + (((((((new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL })) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL })) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) + + (new_term.poseidon2_B_46_1 + FF(0))) + + (new_term.poseidon2_B_46_2 + FF(0))) + + (new_term.poseidon2_B_46_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<205>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<206, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_47_1 - + (((new_term.poseidon2_B_46_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL })) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) + + (new_term.poseidon2_B_46_1 + FF(0))) + + (new_term.poseidon2_B_46_2 + FF(0))) + + (new_term.poseidon2_B_46_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<206>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<207, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_47_2 - + (((new_term.poseidon2_B_46_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL })) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) + + (new_term.poseidon2_B_46_1 + FF(0))) + + (new_term.poseidon2_B_46_2 + FF(0))) + + (new_term.poseidon2_B_46_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<207>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<208, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_47_3 - + (((new_term.poseidon2_B_46_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL })) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) * + (new_term.poseidon2_B_46_0 + FF(uint256_t{ 17421859032088162675UL, + 7339791467855418851UL, + 4622175020331968961UL, + 590786792834928630UL }))) + + (new_term.poseidon2_B_46_1 + FF(0))) + + (new_term.poseidon2_B_46_2 + FF(0))) + + (new_term.poseidon2_B_46_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<208>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<209, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_48_0 - + (((((((new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL })) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL })) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) + + (new_term.poseidon2_B_47_1 + FF(0))) + + (new_term.poseidon2_B_47_2 + FF(0))) + + (new_term.poseidon2_B_47_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<209>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<210, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_48_1 - + (((new_term.poseidon2_B_47_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL })) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) + + (new_term.poseidon2_B_47_1 + FF(0))) + + (new_term.poseidon2_B_47_2 + FF(0))) + + (new_term.poseidon2_B_47_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<210>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<211, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_48_2 - + (((new_term.poseidon2_B_47_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL })) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) + + (new_term.poseidon2_B_47_1 + FF(0))) + + (new_term.poseidon2_B_47_2 + FF(0))) + + (new_term.poseidon2_B_47_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<211>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<212, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_48_3 - + (((new_term.poseidon2_B_47_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL })) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) * + (new_term.poseidon2_B_47_0 + FF(uint256_t{ 14242884250645212438UL, + 12806057845811725595UL, + 7743423753614082490UL, + 213381026777379804UL }))) + + (new_term.poseidon2_B_47_1 + FF(0))) + + (new_term.poseidon2_B_47_2 + FF(0))) + + (new_term.poseidon2_B_47_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<212>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<213, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_49_0 - + (((((((new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL })) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL })) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) + + (new_term.poseidon2_B_48_1 + FF(0))) + + (new_term.poseidon2_B_48_2 + FF(0))) + + (new_term.poseidon2_B_48_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<213>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<214, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_49_1 - + (((new_term.poseidon2_B_48_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL })) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) + + (new_term.poseidon2_B_48_1 + FF(0))) + + (new_term.poseidon2_B_48_2 + FF(0))) + + (new_term.poseidon2_B_48_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<214>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<215, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_49_2 - + (((new_term.poseidon2_B_48_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL })) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) + + (new_term.poseidon2_B_48_1 + FF(0))) + + (new_term.poseidon2_B_48_2 + FF(0))) + + (new_term.poseidon2_B_48_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<215>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<216, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_49_3 - + (((new_term.poseidon2_B_48_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL })) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) * + (new_term.poseidon2_B_48_0 + FF(uint256_t{ 1110713325513004805UL, + 8318407684973846516UL, + 15952888485475298710UL, + 1018983205230111328UL }))) + + (new_term.poseidon2_B_48_1 + FF(0))) + + (new_term.poseidon2_B_48_2 + FF(0))) + + (new_term.poseidon2_B_48_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<216>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<217, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_50_0 - + (((((((new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL })) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL })) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) + + (new_term.poseidon2_B_49_1 + FF(0))) + + (new_term.poseidon2_B_49_2 + FF(0))) + + (new_term.poseidon2_B_49_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<217>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<218, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_50_1 - + (((new_term.poseidon2_B_49_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL })) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) + + (new_term.poseidon2_B_49_1 + FF(0))) + + (new_term.poseidon2_B_49_2 + FF(0))) + + (new_term.poseidon2_B_49_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<218>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<219, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_50_2 - + (((new_term.poseidon2_B_49_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL })) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) + + (new_term.poseidon2_B_49_1 + FF(0))) + + (new_term.poseidon2_B_49_2 + FF(0))) + + (new_term.poseidon2_B_49_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<219>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<220, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_50_3 - + (((new_term.poseidon2_B_49_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL })) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) * + (new_term.poseidon2_B_49_0 + FF(uint256_t{ 533883137631233338UL, + 333001117808183237UL, + 16968583542443855481UL, + 329716098711096173UL }))) + + (new_term.poseidon2_B_49_1 + FF(0))) + + (new_term.poseidon2_B_49_2 + FF(0))) + + (new_term.poseidon2_B_49_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<220>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<221, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_51_0 - + (((((((new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL })) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL })) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) + + (new_term.poseidon2_B_50_1 + FF(0))) + + (new_term.poseidon2_B_50_2 + FF(0))) + + (new_term.poseidon2_B_50_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<221>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<222, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_51_1 - + (((new_term.poseidon2_B_50_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL })) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) + + (new_term.poseidon2_B_50_1 + FF(0))) + + (new_term.poseidon2_B_50_2 + FF(0))) + + (new_term.poseidon2_B_50_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<222>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<223, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_51_2 - + (((new_term.poseidon2_B_50_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL })) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) + + (new_term.poseidon2_B_50_1 + FF(0))) + + (new_term.poseidon2_B_50_2 + FF(0))) + + (new_term.poseidon2_B_50_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<223>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<224, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_51_3 - + (((new_term.poseidon2_B_50_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL })) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) * + (new_term.poseidon2_B_50_0 + FF(uint256_t{ 4449676039486426793UL, + 7760073051300251162UL, + 5615103291054015906UL, + 2516053143677338215UL }))) + + (new_term.poseidon2_B_50_1 + FF(0))) + + (new_term.poseidon2_B_50_2 + FF(0))) + + (new_term.poseidon2_B_50_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<224>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<225, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_52_0 - + (((((((new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL })) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL })) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) + + (new_term.poseidon2_B_51_1 + FF(0))) + + (new_term.poseidon2_B_51_2 + FF(0))) + + (new_term.poseidon2_B_51_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<225>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<226, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_52_1 - + (((new_term.poseidon2_B_51_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL })) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) + + (new_term.poseidon2_B_51_1 + FF(0))) + + (new_term.poseidon2_B_51_2 + FF(0))) + + (new_term.poseidon2_B_51_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<226>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<227, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_52_2 - + (((new_term.poseidon2_B_51_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL })) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) + + (new_term.poseidon2_B_51_1 + FF(0))) + + (new_term.poseidon2_B_51_2 + FF(0))) + + (new_term.poseidon2_B_51_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<227>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<228, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_52_3 - + (((new_term.poseidon2_B_51_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL })) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) * + (new_term.poseidon2_B_51_0 + FF(uint256_t{ 16503526645482286870UL, + 6358830762575712333UL, + 12313512559299087688UL, + 2716767262544184013UL }))) + + (new_term.poseidon2_B_51_1 + FF(0))) + + (new_term.poseidon2_B_51_2 + FF(0))) + + (new_term.poseidon2_B_51_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<228>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<229, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_53_0 - + (((((((new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL })) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL })) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) + + (new_term.poseidon2_B_52_1 + FF(0))) + + (new_term.poseidon2_B_52_2 + FF(0))) + + (new_term.poseidon2_B_52_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<229>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<230, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_53_1 - + (((new_term.poseidon2_B_52_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL })) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) + + (new_term.poseidon2_B_52_1 + FF(0))) + + (new_term.poseidon2_B_52_2 + FF(0))) + + (new_term.poseidon2_B_52_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<230>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<231, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_53_2 - + (((new_term.poseidon2_B_52_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL })) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) + + (new_term.poseidon2_B_52_1 + FF(0))) + + (new_term.poseidon2_B_52_2 + FF(0))) + + (new_term.poseidon2_B_52_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<231>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<232, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_53_3 - + (((new_term.poseidon2_B_52_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL })) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) * + (new_term.poseidon2_B_52_0 + FF(uint256_t{ 5426798011730033104UL, + 13085704829880126552UL, + 6356732802364281819UL, + 2175930396888807151UL }))) + + (new_term.poseidon2_B_52_1 + FF(0))) + + (new_term.poseidon2_B_52_2 + FF(0))) + + (new_term.poseidon2_B_52_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<232>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<233, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_54_0 - + (((((((new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL })) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL })) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) + + (new_term.poseidon2_B_53_1 + FF(0))) + + (new_term.poseidon2_B_53_2 + FF(0))) + + (new_term.poseidon2_B_53_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<233>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<234, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_54_1 - + (((new_term.poseidon2_B_53_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL })) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) + + (new_term.poseidon2_B_53_1 + FF(0))) + + (new_term.poseidon2_B_53_2 + FF(0))) + + (new_term.poseidon2_B_53_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<234>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<235, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_54_2 - + (((new_term.poseidon2_B_53_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL })) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) + + (new_term.poseidon2_B_53_1 + FF(0))) + + (new_term.poseidon2_B_53_2 + FF(0))) + + (new_term.poseidon2_B_53_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<235>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<236, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_54_3 - + (((new_term.poseidon2_B_53_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL })) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) * + (new_term.poseidon2_B_53_0 + FF(uint256_t{ 8262282602783970021UL, + 2576069526442506486UL, + 14199683559983367515UL, + 3432491072538425468UL }))) + + (new_term.poseidon2_B_53_1 + FF(0))) + + (new_term.poseidon2_B_53_2 + FF(0))) + + (new_term.poseidon2_B_53_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<236>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<237, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_55_0 - + (((((((new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL })) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL })) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) + + (new_term.poseidon2_B_54_1 + FF(0))) + + (new_term.poseidon2_B_54_2 + FF(0))) + + (new_term.poseidon2_B_54_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<237>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<238, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_55_1 - + (((new_term.poseidon2_B_54_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL })) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) + + (new_term.poseidon2_B_54_1 + FF(0))) + + (new_term.poseidon2_B_54_2 + FF(0))) + + (new_term.poseidon2_B_54_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<238>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<239, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_55_2 - + (((new_term.poseidon2_B_54_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL })) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) + + (new_term.poseidon2_B_54_1 + FF(0))) + + (new_term.poseidon2_B_54_2 + FF(0))) + + (new_term.poseidon2_B_54_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<239>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<240, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_55_3 - + (((new_term.poseidon2_B_54_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL })) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) * + (new_term.poseidon2_B_54_0 + FF(uint256_t{ 14778817021916755205UL, + 6110468871588391807UL, + 2850248286812407967UL, + 3411084787375678665UL }))) + + (new_term.poseidon2_B_54_1 + FF(0))) + + (new_term.poseidon2_B_54_2 + FF(0))) + + (new_term.poseidon2_B_54_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<240>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<241, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_56_0 - + (((((((new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL })) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL })) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) + + (new_term.poseidon2_B_55_1 + FF(0))) + + (new_term.poseidon2_B_55_2 + FF(0))) + + (new_term.poseidon2_B_55_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<241>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<242, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_56_1 - + (((new_term.poseidon2_B_55_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL })) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) + + (new_term.poseidon2_B_55_1 + FF(0))) + + (new_term.poseidon2_B_55_2 + FF(0))) + + (new_term.poseidon2_B_55_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<242>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<243, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_56_2 - + (((new_term.poseidon2_B_55_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL })) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) + + (new_term.poseidon2_B_55_1 + FF(0))) + + (new_term.poseidon2_B_55_2 + FF(0))) + + (new_term.poseidon2_B_55_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<243>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<244, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_56_3 - + (((new_term.poseidon2_B_55_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL })) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) * + (new_term.poseidon2_B_55_0 + FF(uint256_t{ 4906200604739023933UL, + 12096549814065429793UL, + 5988343102643160344UL, + 309820751832846301UL }))) + + (new_term.poseidon2_B_55_1 + FF(0))) + + (new_term.poseidon2_B_55_2 + FF(0))) + + (new_term.poseidon2_B_55_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<244>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<245, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_57_0 - + (((((((new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL })) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL })) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) + + (new_term.poseidon2_B_56_1 + FF(0))) + + (new_term.poseidon2_B_56_2 + FF(0))) + + (new_term.poseidon2_B_56_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<245>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<246, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_57_1 - + (((new_term.poseidon2_B_56_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL })) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) + + (new_term.poseidon2_B_56_1 + FF(0))) + + (new_term.poseidon2_B_56_2 + FF(0))) + + (new_term.poseidon2_B_56_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<246>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<247, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_57_2 - + (((new_term.poseidon2_B_56_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL })) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) + + (new_term.poseidon2_B_56_1 + FF(0))) + + (new_term.poseidon2_B_56_2 + FF(0))) + + (new_term.poseidon2_B_56_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<247>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<248, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_57_3 - + (((new_term.poseidon2_B_56_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL })) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) * + (new_term.poseidon2_B_56_0 + FF(uint256_t{ 8709336210313678885UL, + 10520000332606345601UL, + 4756441214598660785UL, + 2483744946546306397UL }))) + + (new_term.poseidon2_B_56_1 + FF(0))) + + (new_term.poseidon2_B_56_2 + FF(0))) + + (new_term.poseidon2_B_56_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<248>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<249, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_58_0 - + (((((((new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL })) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL })) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) + + (new_term.poseidon2_B_57_1 + FF(0))) + + (new_term.poseidon2_B_57_2 + FF(0))) + + (new_term.poseidon2_B_57_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<249>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<250, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_58_1 - + (((new_term.poseidon2_B_57_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL })) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) + + (new_term.poseidon2_B_57_1 + FF(0))) + + (new_term.poseidon2_B_57_2 + FF(0))) + + (new_term.poseidon2_B_57_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<250>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<251, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_58_2 - + (((new_term.poseidon2_B_57_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL })) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) + + (new_term.poseidon2_B_57_1 + FF(0))) + + (new_term.poseidon2_B_57_2 + FF(0))) + + (new_term.poseidon2_B_57_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<251>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<252, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_58_3 - + (((new_term.poseidon2_B_57_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL })) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) * + (new_term.poseidon2_B_57_0 + FF(uint256_t{ 9617950371599090517UL, + 6702332727289490762UL, + 7078214601245292934UL, + 215269160536524476UL }))) + + (new_term.poseidon2_B_57_1 + FF(0))) + + (new_term.poseidon2_B_57_2 + FF(0))) + + (new_term.poseidon2_B_57_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<252>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<253, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_59_0 - + (((((((new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL })) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + FF(uint256_t{ + 13071735289386612455UL, 937867514930142591UL, 338297992309721356UL, 1214967615784395659UL })) + + ((((((((new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL })) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) + + (new_term.poseidon2_B_58_1 + FF(0))) + + (new_term.poseidon2_B_58_2 + FF(0))) + + (new_term.poseidon2_B_58_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<253>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<254, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_59_1 - + (((new_term.poseidon2_B_58_1 + FF(0)) * + FF(uint256_t{ + 12135856085615145995UL, 11087747206803725188UL, 92802976007797685UL, 875972510381039422UL })) + + ((((((((new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL })) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) + + (new_term.poseidon2_B_58_1 + FF(0))) + + (new_term.poseidon2_B_58_2 + FF(0))) + + (new_term.poseidon2_B_58_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<254>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<255, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_59_2 - + (((new_term.poseidon2_B_58_2 + FF(0)) * + FF(uint256_t{ + 8072276821399088149UL, 12835106910674049377UL, 12882375598172350360UL, 23726925003953432UL })) + + ((((((((new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL })) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) + + (new_term.poseidon2_B_58_1 + FF(0))) + + (new_term.poseidon2_B_58_2 + FF(0))) + + (new_term.poseidon2_B_58_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<255>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<256, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_B_59_3 - + (((new_term.poseidon2_B_58_3 + FF(0)) * + FF(uint256_t{ + 1422103134736368267UL, 5972060781611222310UL, 3327741120806881763UL, 2462344296021899375UL })) + + ((((((((new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL })) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) * + (new_term.poseidon2_B_58_0 + FF(uint256_t{ 14694170287735041964UL, + 13462371741453101277UL, + 7691247574208617782UL, + 1078917709155142535UL }))) + + (new_term.poseidon2_B_58_1 + FF(0))) + + (new_term.poseidon2_B_58_2 + FF(0))) + + (new_term.poseidon2_B_58_3 + FF(0)))))); + tmp *= scaling_factor; + std::get<256>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<257, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_60_4 - + ((((((((new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL })) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) + + (((((new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL })) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL })))) * + FF(4)) + + (((((((new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL })) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + FF(2)) + + ((((((new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL })) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) + + (((((new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL })) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL })))))))); + tmp *= scaling_factor; + std::get<257>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<258, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_60_5 - + ((((((((new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL })) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) + + (((((new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL })) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL })))) * + FF(4)) + + (((((((new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL })) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + FF(2)) + + ((((((new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL })) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) + + (((((new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL })) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL })))))))); + tmp *= scaling_factor; + std::get<258>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<259, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_60_6 - + ((((((((new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL })) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + FF(2)) + + ((((((new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL })) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) * + (new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, + 12326273425107991305UL, + 8641129484519639030UL, + 1699848340767391255UL }))) + + (((((new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL })) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))))) + + new_term.poseidon2_T_60_5))); + tmp *= scaling_factor; + std::get<259>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<260, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_60_7 - + ((((((((new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL })) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + (new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, + 10123891284815211853UL, + 3676846437799665248UL, + 753827773683953838UL }))) * + FF(2)) + + ((((((new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL })) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) * + (new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, + 17940782720817522247UL, + 11666428030894512886UL, + 2305765957929457259UL }))) + + (((((new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL })) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))) * + (new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, + 6885928680245806601UL, + 6031863836827793624UL, + 2698250255620259624UL }))))) + + new_term.poseidon2_T_60_4))); + tmp *= scaling_factor; + std::get<260>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<261, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_61_4 - + ((((((((new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL })) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) + + (((((new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL })) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL })) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL })) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) + + (((((new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL })) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL })))))))); + tmp *= scaling_factor; + std::get<261>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<262, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_61_5 - + ((((((((new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL })) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) + + (((((new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL })) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL })) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL })) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) + + (((((new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL })) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL })))))))); + tmp *= scaling_factor; + std::get<262>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<263, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_61_6 - + ((((((((new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL })) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL })) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) * + (new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, + 12516844188945734293UL, + 2404426354458718742UL, + 901141949721836097UL }))) + + (((((new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL })) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))))) + + new_term.poseidon2_T_61_5))); + tmp *= scaling_factor; + std::get<263>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<264, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_61_7 - + ((((((((new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL })) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + (new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, + 16108523113696338432UL, + 11492645026300260534UL, + 1417477149741880787UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL })) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) * + (new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, + 6637113826221079930UL, + 1364449097464563400UL, + 2379869735503406314UL }))) + + (((((new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL })) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))) * + (new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, + 17422837239624809585UL, + 12296960536238467913UL, + 2434905421004621494UL }))))) + + new_term.poseidon2_T_61_4))); + tmp *= scaling_factor; + std::get<264>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<265, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_62_4 - + ((((((((new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL })) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) + + (((((new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL })) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL })) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL })) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) + + (((((new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL })) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL })))))))); + tmp *= scaling_factor; + std::get<265>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<266, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_62_5 - + ((((((((new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL })) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) + + (((((new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL })) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL })) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL })) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) + + (((((new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL })) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL })))))))); + tmp *= scaling_factor; + std::get<266>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<267, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_62_6 - + ((((((((new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL })) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL })) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) * + (new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, + 2959376558854333994UL, + 6697398963915560134UL, + 417944321386245900UL }))) + + (((((new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL })) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))))) + + new_term.poseidon2_T_62_5))); + tmp *= scaling_factor; + std::get<267>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<268, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_62_7 - + ((((((((new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL })) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + (new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, + 1640712307042701286UL, + 16457516735210998920UL, + 1084862449077757478UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL })) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) * + (new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, + 5178010365334480003UL, + 7014208314719145622UL, + 385149140585498380UL }))) + + (((((new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL })) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))) * + (new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, + 10541991787372042848UL, + 14909749656931548440UL, + 708152185224876794UL }))))) + + new_term.poseidon2_T_62_4))); + tmp *= scaling_factor; + std::get<268>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<269, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_63_4 - + ((((((((new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL })) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) + + (((((new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL })) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL })) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL })) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) + + (((((new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL })) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL })))))))); + tmp *= scaling_factor; + std::get<269>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<270, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_63_5 - + ((((((((new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL })) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) + + (((((new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL })) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL })))) * + FF(4)) + + (((((((new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL })) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL })) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) + + (((((new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL })) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL })))))))); + tmp *= scaling_factor; + std::get<270>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<271, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_63_6 - + ((((((((new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL })) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL })) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) * + (new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, + 17455832130858697862UL, + 5278085098799702411UL, + 227655898188482835UL }))) + + (((((new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL })) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))))) + + new_term.poseidon2_T_63_5))); + tmp *= scaling_factor; + std::get<271>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<272, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_T_63_7 - + ((((((((new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL })) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + (new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, + 16689913387728553544UL, + 2568326884589391367UL, + 3166155980659486882UL }))) * + FF(2)) + + ((((((new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL })) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) * + (new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, + 15490006495937952898UL, + 7249042245074469654UL, + 2138985910652398451UL }))) + + (((((new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL })) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))) * + (new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, + 2230284817967990783UL, + 5095423606777193313UL, + 1685862792723606183UL }))))) + + new_term.poseidon2_T_63_4))); + tmp *= scaling_factor; + std::get<272>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<273, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_a_0_shift - new_term.poseidon2_T_63_6)); + tmp *= scaling_factor; + std::get<273>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<274, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_a_1_shift - new_term.poseidon2_T_63_5)); + tmp *= scaling_factor; + std::get<274>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<275, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_a_2_shift - new_term.poseidon2_T_63_7)); + tmp *= scaling_factor; + std::get<275>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<276, ContainerOverSubrelations>; + auto tmp = + (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_a_3_shift - new_term.poseidon2_T_63_4)); + tmp *= scaling_factor; + std::get<276>(evals) += typename Accumulator::View(tmp); + } } }; diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/tests/execution.test.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/tests/execution.test.cpp index 14a990366c97..9bc4936b02aa 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/tests/execution.test.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/tests/execution.test.cpp @@ -957,26 +957,31 @@ TEST_F(AvmExecutionTests, poseidon2PermutationOpCode) std::string bytecode_hex = to_hex(OpCode::CALLDATACOPY) + // opcode CALL DATA COPY "00" // Indirect Flag "00000000" // cd_offset - "00000004" // copy_size + "00000002" // copy_size "00000001" // dst_offset 1 - + to_hex(OpCode::SET) + // opcode SET for indirect src (input) - "00" // Indirect flag - "03" // U32 - "00000001" // value 1 (i.e. where the src will be read from) - "00000024" // dst_offset 36 - + to_hex(OpCode::SET) + // opcode SET for indirect dst (output) - "00" // Indirect flag - "03" // U32 - "00000009" // value 9 (i.e. where the ouput will be written to) - "00000023" // dst_offset 35 - + to_hex(OpCode::POSEIDON2) + // opcode POSEIDON2 - "03" // Indirect flag (first 2 operands indirect) - "00000024" // input offset (indirect 36) - "00000023" // output offset (indirect 35) - + to_hex(OpCode::RETURN) + // opcode RETURN - "00" // Indirect flag - "00000009" // ret offset 256 - "00000004"; // ret size 8 + + to_hex(OpCode::CALLDATACOPY) + + "00" + "00000002" + "00000002" + "00000003" + + to_hex(OpCode::SET) + // opcode SET for indirect src (input) + "00" // Indirect flag + "03" // U32 + "00000001" // value 1 (i.e. where the src will be read from) + "00000024" // dst_offset 36 + + to_hex(OpCode::SET) + // opcode SET for indirect dst (output) + "00" // Indirect flag + "03" // U32 + "00000009" // value 9 (i.e. where the ouput will be written to) + "00000023" // dst_offset 35 + + to_hex(OpCode::POSEIDON2) + // opcode POSEIDON2 + "03" // Indirect flag (first 2 operands indirect) + "00000024" // input offset (indirect 36) + "00000023" // output offset (indirect 35) + + to_hex(OpCode::RETURN) + // opcode RETURN + "00" // Indirect flag + "00000009" // ret offset 256 + "00000004"; // ret size 8 auto bytecode = hex_to_bytes(bytecode_hex); auto instructions = Deserialization::parse(bytecode); diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.cpp index d3b6b61b45c6..ce9474ed5f0e 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.cpp @@ -14,14 +14,56 @@ void AvmPoseidon2TraceBuilder::reset() poseidon2_trace.clear(); } -std::array AvmPoseidon2TraceBuilder::poseidon2_permutation(const std::array& input, uint32_t clk) +std::array AvmPoseidon2TraceBuilder::poseidon2_permutation(std::array const& input, + uint32_t clk, + uint32_t input_addr, + uint32_t output_addr) { - std::array output = - crypto::Poseidon2Permutation::permutation(input); + // Currently we commit to intermediate round values, changes to codegen might reduce the number of committed polys - poseidon2_trace.push_back(Poseidon2TraceEntry{ clk, input, output }); + // This is lifted from bb::poeidon2, we need to extract the intermediate round values here. + using State = std::array; + using Poseidon2 = crypto::Poseidon2Permutation; + std::array interm_round_vals; + State current_state(input); - return output; + // Apply 1st linear layer + Poseidon2::matrix_multiplication_external(current_state); + std::array first_ext = current_state; + // First set of external rounds + constexpr size_t rounds_f_beginning = Poseidon2::rounds_f / 2; + for (size_t i = 0; i < rounds_f_beginning; ++i) { + Poseidon2::add_round_constants(current_state, Poseidon2::round_constants[i]); + Poseidon2::apply_sbox(current_state); + Poseidon2::matrix_multiplication_external(current_state); + // Store end of round state + interm_round_vals[i] = current_state; + } + + // Internal rounds + const size_t p_end = rounds_f_beginning + Poseidon2::rounds_p; + for (size_t i = rounds_f_beginning; i < p_end; ++i) { + current_state[0] += Poseidon2::round_constants[i][0]; + Poseidon2::apply_single_sbox(current_state[0]); + Poseidon2::matrix_multiplication_internal(current_state); + // Store end of round state + interm_round_vals[i] = current_state; + } + + // Remaining external rounds + for (size_t i = p_end; i < Poseidon2::NUM_ROUNDS; ++i) { + Poseidon2::add_round_constants(current_state, Poseidon2::round_constants[i]); + Poseidon2::apply_sbox(current_state); + Poseidon2::matrix_multiplication_external(current_state); + // Store end of round state + interm_round_vals[i] = current_state; + } + + // Current state is the output + poseidon2_trace.push_back( + Poseidon2TraceEntry{ clk, input, current_state, first_ext, interm_round_vals, input_addr, output_addr }); + + return current_state; } } // namespace bb::avm_trace diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.hpp index 2e8e2becea6e..8b154ad1712f 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.hpp @@ -10,10 +10,15 @@ namespace bb::avm_trace { class AvmPoseidon2TraceBuilder { public: + using Poseidon2Row = bb::avm_trace::Poseidon2Row; struct Poseidon2TraceEntry { uint32_t clk = 0; std::array input; std::array output; + std::array first_ext; + std::array, 64> interm_round_vals; + uint32_t input_addr; + uint32_t output_addr; }; AvmPoseidon2TraceBuilder() = default; @@ -21,10 +26,598 @@ class AvmPoseidon2TraceBuilder { // Finalize the trace std::vector finalize(); - std::array poseidon2_permutation(const std::array& input, uint32_t clk); + std::array poseidon2_permutation(std::array const& input, + uint32_t clk, + uint32_t input_addr, + uint32_t output_addr); + + std::pair static into_canonical(Poseidon2TraceEntry const& src) + { + // The secondary write row, which is used to write the output of the permutation to memory + Poseidon2Row write_row; + write_row.poseidon2_a_0 = src.output[0]; + write_row.poseidon2_a_1 = src.output[1]; + write_row.poseidon2_a_2 = src.output[2]; + write_row.poseidon2_a_3 = src.output[3]; + write_row.poseidon2_input_addr = src.input_addr; + write_row.poseidon2_output_addr = src.output_addr; + write_row.poseidon2_write_line = FF(1); + write_row.poseidon2_mem_op = FF(1); + write_row.poseidon2_mem_addr_a = src.output_addr; + write_row.poseidon2_mem_addr_b = src.output_addr + 1; + write_row.poseidon2_mem_addr_c = src.output_addr + 2; + write_row.poseidon2_mem_addr_d = src.output_addr + 3; + write_row.poseidon2_in_tag = FF(6); + + // The primary input row, which is used to read the input of the permutation from memory + Poseidon2Row dest; + // Mem Stuff + dest.poseidon2_a_0 = src.input[0]; + dest.poseidon2_a_1 = src.input[1]; + dest.poseidon2_a_2 = src.input[2]; + dest.poseidon2_a_3 = src.input[3]; + dest.poseidon2_input_addr = src.input_addr; + dest.poseidon2_output_addr = src.output_addr; + dest.poseidon2_mem_addr_a = src.input_addr; + dest.poseidon2_mem_addr_b = src.input_addr + 1; + dest.poseidon2_mem_addr_c = src.input_addr + 2; + dest.poseidon2_mem_addr_d = src.input_addr + 3; + dest.poseidon2_mem_op = FF(1); + dest.poseidon2_read_line = FF(1); + dest.poseidon2_sel_poseidon_perm = FF(1); + dest.poseidon2_in_tag = FF(6); + // First Ext Round + dest.poseidon2_EXT_LAYER_6 = src.first_ext[0]; + dest.poseidon2_EXT_LAYER_5 = src.first_ext[1]; + dest.poseidon2_EXT_LAYER_7 = src.first_ext[2]; + dest.poseidon2_EXT_LAYER_4 = src.first_ext[3]; + // Full rounds + dest.poseidon2_T_0_6 = src.interm_round_vals[0][0]; + dest.poseidon2_T_0_5 = src.interm_round_vals[0][1]; + dest.poseidon2_T_0_7 = src.interm_round_vals[0][2]; + dest.poseidon2_T_0_4 = src.interm_round_vals[0][3]; + dest.poseidon2_T_1_6 = src.interm_round_vals[1][0]; + dest.poseidon2_T_1_5 = src.interm_round_vals[1][1]; + dest.poseidon2_T_1_7 = src.interm_round_vals[1][2]; + dest.poseidon2_T_1_4 = src.interm_round_vals[1][3]; + dest.poseidon2_T_2_6 = src.interm_round_vals[2][0]; + dest.poseidon2_T_2_5 = src.interm_round_vals[2][1]; + dest.poseidon2_T_2_7 = src.interm_round_vals[2][2]; + dest.poseidon2_T_2_4 = src.interm_round_vals[2][3]; + dest.poseidon2_T_3_6 = src.interm_round_vals[3][0]; + dest.poseidon2_T_3_5 = src.interm_round_vals[3][1]; + dest.poseidon2_T_3_7 = src.interm_round_vals[3][2]; + dest.poseidon2_T_3_4 = src.interm_round_vals[3][3]; + // Partial rounds + dest.poseidon2_B_4_0 = src.interm_round_vals[4][0]; + dest.poseidon2_B_4_1 = src.interm_round_vals[4][1]; + dest.poseidon2_B_4_2 = src.interm_round_vals[4][2]; + dest.poseidon2_B_4_3 = src.interm_round_vals[4][3]; + dest.poseidon2_B_5_0 = src.interm_round_vals[5][0]; + dest.poseidon2_B_5_1 = src.interm_round_vals[5][1]; + dest.poseidon2_B_5_2 = src.interm_round_vals[5][2]; + dest.poseidon2_B_5_3 = src.interm_round_vals[5][3]; + dest.poseidon2_B_6_0 = src.interm_round_vals[6][0]; + dest.poseidon2_B_6_1 = src.interm_round_vals[6][1]; + dest.poseidon2_B_6_2 = src.interm_round_vals[6][2]; + dest.poseidon2_B_6_3 = src.interm_round_vals[6][3]; + dest.poseidon2_B_7_0 = src.interm_round_vals[7][0]; + dest.poseidon2_B_7_1 = src.interm_round_vals[7][1]; + dest.poseidon2_B_7_2 = src.interm_round_vals[7][2]; + dest.poseidon2_B_7_3 = src.interm_round_vals[7][3]; + dest.poseidon2_B_8_0 = src.interm_round_vals[8][0]; + dest.poseidon2_B_8_1 = src.interm_round_vals[8][1]; + dest.poseidon2_B_8_2 = src.interm_round_vals[8][2]; + dest.poseidon2_B_8_3 = src.interm_round_vals[8][3]; + dest.poseidon2_B_9_0 = src.interm_round_vals[9][0]; + dest.poseidon2_B_9_1 = src.interm_round_vals[9][1]; + dest.poseidon2_B_9_2 = src.interm_round_vals[9][2]; + dest.poseidon2_B_9_3 = src.interm_round_vals[9][3]; + dest.poseidon2_B_10_0 = src.interm_round_vals[10][0]; + dest.poseidon2_B_10_1 = src.interm_round_vals[10][1]; + dest.poseidon2_B_10_2 = src.interm_round_vals[10][2]; + dest.poseidon2_B_10_3 = src.interm_round_vals[10][3]; + dest.poseidon2_B_11_0 = src.interm_round_vals[11][0]; + dest.poseidon2_B_11_1 = src.interm_round_vals[11][1]; + dest.poseidon2_B_11_2 = src.interm_round_vals[11][2]; + dest.poseidon2_B_11_3 = src.interm_round_vals[11][3]; + dest.poseidon2_B_12_0 = src.interm_round_vals[12][0]; + dest.poseidon2_B_12_1 = src.interm_round_vals[12][1]; + dest.poseidon2_B_12_2 = src.interm_round_vals[12][2]; + dest.poseidon2_B_12_3 = src.interm_round_vals[12][3]; + dest.poseidon2_B_13_0 = src.interm_round_vals[13][0]; + dest.poseidon2_B_13_1 = src.interm_round_vals[13][1]; + dest.poseidon2_B_13_2 = src.interm_round_vals[13][2]; + dest.poseidon2_B_13_3 = src.interm_round_vals[13][3]; + dest.poseidon2_B_14_0 = src.interm_round_vals[14][0]; + dest.poseidon2_B_14_1 = src.interm_round_vals[14][1]; + dest.poseidon2_B_14_2 = src.interm_round_vals[14][2]; + dest.poseidon2_B_14_3 = src.interm_round_vals[14][3]; + dest.poseidon2_B_15_0 = src.interm_round_vals[15][0]; + dest.poseidon2_B_15_1 = src.interm_round_vals[15][1]; + dest.poseidon2_B_15_2 = src.interm_round_vals[15][2]; + dest.poseidon2_B_15_3 = src.interm_round_vals[15][3]; + dest.poseidon2_B_16_0 = src.interm_round_vals[16][0]; + dest.poseidon2_B_16_1 = src.interm_round_vals[16][1]; + dest.poseidon2_B_16_2 = src.interm_round_vals[16][2]; + dest.poseidon2_B_16_3 = src.interm_round_vals[16][3]; + dest.poseidon2_B_17_0 = src.interm_round_vals[17][0]; + dest.poseidon2_B_17_1 = src.interm_round_vals[17][1]; + dest.poseidon2_B_17_2 = src.interm_round_vals[17][2]; + dest.poseidon2_B_17_3 = src.interm_round_vals[17][3]; + dest.poseidon2_B_18_0 = src.interm_round_vals[18][0]; + dest.poseidon2_B_18_1 = src.interm_round_vals[18][1]; + dest.poseidon2_B_18_2 = src.interm_round_vals[18][2]; + dest.poseidon2_B_18_3 = src.interm_round_vals[18][3]; + dest.poseidon2_B_19_0 = src.interm_round_vals[19][0]; + dest.poseidon2_B_19_1 = src.interm_round_vals[19][1]; + dest.poseidon2_B_19_2 = src.interm_round_vals[19][2]; + dest.poseidon2_B_19_3 = src.interm_round_vals[19][3]; + dest.poseidon2_B_20_0 = src.interm_round_vals[20][0]; + dest.poseidon2_B_20_1 = src.interm_round_vals[20][1]; + dest.poseidon2_B_20_2 = src.interm_round_vals[20][2]; + dest.poseidon2_B_20_3 = src.interm_round_vals[20][3]; + dest.poseidon2_B_21_0 = src.interm_round_vals[21][0]; + dest.poseidon2_B_21_1 = src.interm_round_vals[21][1]; + dest.poseidon2_B_21_2 = src.interm_round_vals[21][2]; + dest.poseidon2_B_21_3 = src.interm_round_vals[21][3]; + dest.poseidon2_B_22_0 = src.interm_round_vals[22][0]; + dest.poseidon2_B_22_1 = src.interm_round_vals[22][1]; + dest.poseidon2_B_22_2 = src.interm_round_vals[22][2]; + dest.poseidon2_B_22_3 = src.interm_round_vals[22][3]; + dest.poseidon2_B_23_0 = src.interm_round_vals[23][0]; + dest.poseidon2_B_23_1 = src.interm_round_vals[23][1]; + dest.poseidon2_B_23_2 = src.interm_round_vals[23][2]; + dest.poseidon2_B_23_3 = src.interm_round_vals[23][3]; + dest.poseidon2_B_24_0 = src.interm_round_vals[24][0]; + dest.poseidon2_B_24_1 = src.interm_round_vals[24][1]; + dest.poseidon2_B_24_2 = src.interm_round_vals[24][2]; + dest.poseidon2_B_24_3 = src.interm_round_vals[24][3]; + dest.poseidon2_B_25_0 = src.interm_round_vals[25][0]; + dest.poseidon2_B_25_1 = src.interm_round_vals[25][1]; + dest.poseidon2_B_25_2 = src.interm_round_vals[25][2]; + dest.poseidon2_B_25_3 = src.interm_round_vals[25][3]; + dest.poseidon2_B_26_0 = src.interm_round_vals[26][0]; + dest.poseidon2_B_26_1 = src.interm_round_vals[26][1]; + dest.poseidon2_B_26_2 = src.interm_round_vals[26][2]; + dest.poseidon2_B_26_3 = src.interm_round_vals[26][3]; + dest.poseidon2_B_27_0 = src.interm_round_vals[27][0]; + dest.poseidon2_B_27_1 = src.interm_round_vals[27][1]; + dest.poseidon2_B_27_2 = src.interm_round_vals[27][2]; + dest.poseidon2_B_27_3 = src.interm_round_vals[27][3]; + dest.poseidon2_B_28_0 = src.interm_round_vals[28][0]; + dest.poseidon2_B_28_1 = src.interm_round_vals[28][1]; + dest.poseidon2_B_28_2 = src.interm_round_vals[28][2]; + dest.poseidon2_B_28_3 = src.interm_round_vals[28][3]; + dest.poseidon2_B_29_0 = src.interm_round_vals[29][0]; + dest.poseidon2_B_29_1 = src.interm_round_vals[29][1]; + dest.poseidon2_B_29_2 = src.interm_round_vals[29][2]; + dest.poseidon2_B_29_3 = src.interm_round_vals[29][3]; + dest.poseidon2_B_30_0 = src.interm_round_vals[30][0]; + dest.poseidon2_B_30_1 = src.interm_round_vals[30][1]; + dest.poseidon2_B_30_2 = src.interm_round_vals[30][2]; + dest.poseidon2_B_30_3 = src.interm_round_vals[30][3]; + dest.poseidon2_B_31_0 = src.interm_round_vals[31][0]; + dest.poseidon2_B_31_1 = src.interm_round_vals[31][1]; + dest.poseidon2_B_31_2 = src.interm_round_vals[31][2]; + dest.poseidon2_B_31_3 = src.interm_round_vals[31][3]; + dest.poseidon2_B_32_0 = src.interm_round_vals[32][0]; + dest.poseidon2_B_32_1 = src.interm_round_vals[32][1]; + dest.poseidon2_B_32_2 = src.interm_round_vals[32][2]; + dest.poseidon2_B_32_3 = src.interm_round_vals[32][3]; + dest.poseidon2_B_33_0 = src.interm_round_vals[33][0]; + dest.poseidon2_B_33_1 = src.interm_round_vals[33][1]; + dest.poseidon2_B_33_2 = src.interm_round_vals[33][2]; + dest.poseidon2_B_33_3 = src.interm_round_vals[33][3]; + dest.poseidon2_B_34_0 = src.interm_round_vals[34][0]; + dest.poseidon2_B_34_1 = src.interm_round_vals[34][1]; + dest.poseidon2_B_34_2 = src.interm_round_vals[34][2]; + dest.poseidon2_B_34_3 = src.interm_round_vals[34][3]; + dest.poseidon2_B_35_0 = src.interm_round_vals[35][0]; + dest.poseidon2_B_35_1 = src.interm_round_vals[35][1]; + dest.poseidon2_B_35_2 = src.interm_round_vals[35][2]; + dest.poseidon2_B_35_3 = src.interm_round_vals[35][3]; + dest.poseidon2_B_36_0 = src.interm_round_vals[36][0]; + dest.poseidon2_B_36_1 = src.interm_round_vals[36][1]; + dest.poseidon2_B_36_2 = src.interm_round_vals[36][2]; + dest.poseidon2_B_36_3 = src.interm_round_vals[36][3]; + dest.poseidon2_B_37_0 = src.interm_round_vals[37][0]; + dest.poseidon2_B_37_1 = src.interm_round_vals[37][1]; + dest.poseidon2_B_37_2 = src.interm_round_vals[37][2]; + dest.poseidon2_B_37_3 = src.interm_round_vals[37][3]; + dest.poseidon2_B_38_0 = src.interm_round_vals[38][0]; + dest.poseidon2_B_38_1 = src.interm_round_vals[38][1]; + dest.poseidon2_B_38_2 = src.interm_round_vals[38][2]; + dest.poseidon2_B_38_3 = src.interm_round_vals[38][3]; + dest.poseidon2_B_39_0 = src.interm_round_vals[39][0]; + dest.poseidon2_B_39_1 = src.interm_round_vals[39][1]; + dest.poseidon2_B_39_2 = src.interm_round_vals[39][2]; + dest.poseidon2_B_39_3 = src.interm_round_vals[39][3]; + dest.poseidon2_B_40_0 = src.interm_round_vals[40][0]; + dest.poseidon2_B_40_1 = src.interm_round_vals[40][1]; + dest.poseidon2_B_40_2 = src.interm_round_vals[40][2]; + dest.poseidon2_B_40_3 = src.interm_round_vals[40][3]; + dest.poseidon2_B_41_0 = src.interm_round_vals[41][0]; + dest.poseidon2_B_41_1 = src.interm_round_vals[41][1]; + dest.poseidon2_B_41_2 = src.interm_round_vals[41][2]; + dest.poseidon2_B_41_3 = src.interm_round_vals[41][3]; + dest.poseidon2_B_42_0 = src.interm_round_vals[42][0]; + dest.poseidon2_B_42_1 = src.interm_round_vals[42][1]; + dest.poseidon2_B_42_2 = src.interm_round_vals[42][2]; + dest.poseidon2_B_42_3 = src.interm_round_vals[42][3]; + dest.poseidon2_B_43_0 = src.interm_round_vals[43][0]; + dest.poseidon2_B_43_1 = src.interm_round_vals[43][1]; + dest.poseidon2_B_43_2 = src.interm_round_vals[43][2]; + dest.poseidon2_B_43_3 = src.interm_round_vals[43][3]; + dest.poseidon2_B_44_0 = src.interm_round_vals[44][0]; + dest.poseidon2_B_44_1 = src.interm_round_vals[44][1]; + dest.poseidon2_B_44_2 = src.interm_round_vals[44][2]; + dest.poseidon2_B_44_3 = src.interm_round_vals[44][3]; + dest.poseidon2_B_45_0 = src.interm_round_vals[45][0]; + dest.poseidon2_B_45_1 = src.interm_round_vals[45][1]; + dest.poseidon2_B_45_2 = src.interm_round_vals[45][2]; + dest.poseidon2_B_45_3 = src.interm_round_vals[45][3]; + dest.poseidon2_B_46_0 = src.interm_round_vals[46][0]; + dest.poseidon2_B_46_1 = src.interm_round_vals[46][1]; + dest.poseidon2_B_46_2 = src.interm_round_vals[46][2]; + dest.poseidon2_B_46_3 = src.interm_round_vals[46][3]; + dest.poseidon2_B_47_0 = src.interm_round_vals[47][0]; + dest.poseidon2_B_47_1 = src.interm_round_vals[47][1]; + dest.poseidon2_B_47_2 = src.interm_round_vals[47][2]; + dest.poseidon2_B_47_3 = src.interm_round_vals[47][3]; + dest.poseidon2_B_48_0 = src.interm_round_vals[48][0]; + dest.poseidon2_B_48_1 = src.interm_round_vals[48][1]; + dest.poseidon2_B_48_2 = src.interm_round_vals[48][2]; + dest.poseidon2_B_48_3 = src.interm_round_vals[48][3]; + dest.poseidon2_B_49_0 = src.interm_round_vals[49][0]; + dest.poseidon2_B_49_1 = src.interm_round_vals[49][1]; + dest.poseidon2_B_49_2 = src.interm_round_vals[49][2]; + dest.poseidon2_B_49_3 = src.interm_round_vals[49][3]; + dest.poseidon2_B_50_0 = src.interm_round_vals[50][0]; + dest.poseidon2_B_50_1 = src.interm_round_vals[50][1]; + dest.poseidon2_B_50_2 = src.interm_round_vals[50][2]; + dest.poseidon2_B_50_3 = src.interm_round_vals[50][3]; + dest.poseidon2_B_51_0 = src.interm_round_vals[51][0]; + dest.poseidon2_B_51_1 = src.interm_round_vals[51][1]; + dest.poseidon2_B_51_2 = src.interm_round_vals[51][2]; + dest.poseidon2_B_51_3 = src.interm_round_vals[51][3]; + dest.poseidon2_B_52_0 = src.interm_round_vals[52][0]; + dest.poseidon2_B_52_1 = src.interm_round_vals[52][1]; + dest.poseidon2_B_52_2 = src.interm_round_vals[52][2]; + dest.poseidon2_B_52_3 = src.interm_round_vals[52][3]; + dest.poseidon2_B_53_0 = src.interm_round_vals[53][0]; + dest.poseidon2_B_53_1 = src.interm_round_vals[53][1]; + dest.poseidon2_B_53_2 = src.interm_round_vals[53][2]; + dest.poseidon2_B_53_3 = src.interm_round_vals[53][3]; + dest.poseidon2_B_54_0 = src.interm_round_vals[54][0]; + dest.poseidon2_B_54_1 = src.interm_round_vals[54][1]; + dest.poseidon2_B_54_2 = src.interm_round_vals[54][2]; + dest.poseidon2_B_54_3 = src.interm_round_vals[54][3]; + dest.poseidon2_B_55_0 = src.interm_round_vals[55][0]; + dest.poseidon2_B_55_1 = src.interm_round_vals[55][1]; + dest.poseidon2_B_55_2 = src.interm_round_vals[55][2]; + dest.poseidon2_B_55_3 = src.interm_round_vals[55][3]; + dest.poseidon2_B_56_0 = src.interm_round_vals[56][0]; + dest.poseidon2_B_56_1 = src.interm_round_vals[56][1]; + dest.poseidon2_B_56_2 = src.interm_round_vals[56][2]; + dest.poseidon2_B_56_3 = src.interm_round_vals[56][3]; + dest.poseidon2_B_57_0 = src.interm_round_vals[57][0]; + dest.poseidon2_B_57_1 = src.interm_round_vals[57][1]; + dest.poseidon2_B_57_2 = src.interm_round_vals[57][2]; + dest.poseidon2_B_57_3 = src.interm_round_vals[57][3]; + dest.poseidon2_B_58_0 = src.interm_round_vals[58][0]; + dest.poseidon2_B_58_1 = src.interm_round_vals[58][1]; + dest.poseidon2_B_58_2 = src.interm_round_vals[58][2]; + dest.poseidon2_B_58_3 = src.interm_round_vals[58][3]; + dest.poseidon2_B_59_0 = src.interm_round_vals[59][0]; + dest.poseidon2_B_59_1 = src.interm_round_vals[59][1]; + dest.poseidon2_B_59_2 = src.interm_round_vals[59][2]; + dest.poseidon2_B_59_3 = src.interm_round_vals[59][3]; + // Full rounds + dest.poseidon2_T_60_6 = src.interm_round_vals[60][0]; + dest.poseidon2_T_60_5 = src.interm_round_vals[60][1]; + dest.poseidon2_T_60_7 = src.interm_round_vals[60][2]; + dest.poseidon2_T_60_4 = src.interm_round_vals[60][3]; + + dest.poseidon2_T_61_6 = src.interm_round_vals[61][0]; + dest.poseidon2_T_61_5 = src.interm_round_vals[61][1]; + dest.poseidon2_T_61_7 = src.interm_round_vals[61][2]; + dest.poseidon2_T_61_4 = src.interm_round_vals[61][3]; + + dest.poseidon2_T_62_6 = src.interm_round_vals[62][0]; + dest.poseidon2_T_62_5 = src.interm_round_vals[62][1]; + dest.poseidon2_T_62_7 = src.interm_round_vals[62][2]; + dest.poseidon2_T_62_4 = src.interm_round_vals[62][3]; + + dest.poseidon2_T_63_6 = src.interm_round_vals[63][0]; + dest.poseidon2_T_63_5 = src.interm_round_vals[63][1]; + dest.poseidon2_T_63_7 = src.interm_round_vals[63][2]; + dest.poseidon2_T_63_4 = src.interm_round_vals[63][3]; + + return { dest, write_row }; + } + + template void merge_into(DestRow& dest, Poseidon2Row const& src) + { + dest.poseidon2_B_10_0 = src.poseidon2_B_10_0; + dest.poseidon2_B_10_1 = src.poseidon2_B_10_1; + dest.poseidon2_B_10_2 = src.poseidon2_B_10_2; + dest.poseidon2_B_10_3 = src.poseidon2_B_10_3; + dest.poseidon2_B_11_0 = src.poseidon2_B_11_0; + dest.poseidon2_B_11_1 = src.poseidon2_B_11_1; + dest.poseidon2_B_11_2 = src.poseidon2_B_11_2; + dest.poseidon2_B_11_3 = src.poseidon2_B_11_3; + dest.poseidon2_B_12_0 = src.poseidon2_B_12_0; + dest.poseidon2_B_12_1 = src.poseidon2_B_12_1; + dest.poseidon2_B_12_2 = src.poseidon2_B_12_2; + dest.poseidon2_B_12_3 = src.poseidon2_B_12_3; + dest.poseidon2_B_13_0 = src.poseidon2_B_13_0; + dest.poseidon2_B_13_1 = src.poseidon2_B_13_1; + dest.poseidon2_B_13_2 = src.poseidon2_B_13_2; + dest.poseidon2_B_13_3 = src.poseidon2_B_13_3; + dest.poseidon2_B_14_0 = src.poseidon2_B_14_0; + dest.poseidon2_B_14_1 = src.poseidon2_B_14_1; + dest.poseidon2_B_14_2 = src.poseidon2_B_14_2; + dest.poseidon2_B_14_3 = src.poseidon2_B_14_3; + dest.poseidon2_B_15_0 = src.poseidon2_B_15_0; + dest.poseidon2_B_15_1 = src.poseidon2_B_15_1; + dest.poseidon2_B_15_2 = src.poseidon2_B_15_2; + dest.poseidon2_B_15_3 = src.poseidon2_B_15_3; + dest.poseidon2_B_16_0 = src.poseidon2_B_16_0; + dest.poseidon2_B_16_1 = src.poseidon2_B_16_1; + dest.poseidon2_B_16_2 = src.poseidon2_B_16_2; + dest.poseidon2_B_16_3 = src.poseidon2_B_16_3; + dest.poseidon2_B_17_0 = src.poseidon2_B_17_0; + dest.poseidon2_B_17_1 = src.poseidon2_B_17_1; + dest.poseidon2_B_17_2 = src.poseidon2_B_17_2; + dest.poseidon2_B_17_3 = src.poseidon2_B_17_3; + dest.poseidon2_B_18_0 = src.poseidon2_B_18_0; + dest.poseidon2_B_18_1 = src.poseidon2_B_18_1; + dest.poseidon2_B_18_2 = src.poseidon2_B_18_2; + dest.poseidon2_B_18_3 = src.poseidon2_B_18_3; + dest.poseidon2_B_19_0 = src.poseidon2_B_19_0; + dest.poseidon2_B_19_1 = src.poseidon2_B_19_1; + dest.poseidon2_B_19_2 = src.poseidon2_B_19_2; + dest.poseidon2_B_19_3 = src.poseidon2_B_19_3; + dest.poseidon2_B_20_0 = src.poseidon2_B_20_0; + dest.poseidon2_B_20_1 = src.poseidon2_B_20_1; + dest.poseidon2_B_20_2 = src.poseidon2_B_20_2; + dest.poseidon2_B_20_3 = src.poseidon2_B_20_3; + dest.poseidon2_B_21_0 = src.poseidon2_B_21_0; + dest.poseidon2_B_21_1 = src.poseidon2_B_21_1; + dest.poseidon2_B_21_2 = src.poseidon2_B_21_2; + dest.poseidon2_B_21_3 = src.poseidon2_B_21_3; + dest.poseidon2_B_22_0 = src.poseidon2_B_22_0; + dest.poseidon2_B_22_1 = src.poseidon2_B_22_1; + dest.poseidon2_B_22_2 = src.poseidon2_B_22_2; + dest.poseidon2_B_22_3 = src.poseidon2_B_22_3; + dest.poseidon2_B_23_0 = src.poseidon2_B_23_0; + dest.poseidon2_B_23_1 = src.poseidon2_B_23_1; + dest.poseidon2_B_23_2 = src.poseidon2_B_23_2; + dest.poseidon2_B_23_3 = src.poseidon2_B_23_3; + dest.poseidon2_B_24_0 = src.poseidon2_B_24_0; + dest.poseidon2_B_24_1 = src.poseidon2_B_24_1; + dest.poseidon2_B_24_2 = src.poseidon2_B_24_2; + dest.poseidon2_B_24_3 = src.poseidon2_B_24_3; + dest.poseidon2_B_25_0 = src.poseidon2_B_25_0; + dest.poseidon2_B_25_1 = src.poseidon2_B_25_1; + dest.poseidon2_B_25_2 = src.poseidon2_B_25_2; + dest.poseidon2_B_25_3 = src.poseidon2_B_25_3; + dest.poseidon2_B_26_0 = src.poseidon2_B_26_0; + dest.poseidon2_B_26_1 = src.poseidon2_B_26_1; + dest.poseidon2_B_26_2 = src.poseidon2_B_26_2; + dest.poseidon2_B_26_3 = src.poseidon2_B_26_3; + dest.poseidon2_B_27_0 = src.poseidon2_B_27_0; + dest.poseidon2_B_27_1 = src.poseidon2_B_27_1; + dest.poseidon2_B_27_2 = src.poseidon2_B_27_2; + dest.poseidon2_B_27_3 = src.poseidon2_B_27_3; + dest.poseidon2_B_28_0 = src.poseidon2_B_28_0; + dest.poseidon2_B_28_1 = src.poseidon2_B_28_1; + dest.poseidon2_B_28_2 = src.poseidon2_B_28_2; + dest.poseidon2_B_28_3 = src.poseidon2_B_28_3; + dest.poseidon2_B_29_0 = src.poseidon2_B_29_0; + dest.poseidon2_B_29_1 = src.poseidon2_B_29_1; + dest.poseidon2_B_29_2 = src.poseidon2_B_29_2; + dest.poseidon2_B_29_3 = src.poseidon2_B_29_3; + dest.poseidon2_B_30_0 = src.poseidon2_B_30_0; + dest.poseidon2_B_30_1 = src.poseidon2_B_30_1; + dest.poseidon2_B_30_2 = src.poseidon2_B_30_2; + dest.poseidon2_B_30_3 = src.poseidon2_B_30_3; + dest.poseidon2_B_31_0 = src.poseidon2_B_31_0; + dest.poseidon2_B_31_1 = src.poseidon2_B_31_1; + dest.poseidon2_B_31_2 = src.poseidon2_B_31_2; + dest.poseidon2_B_31_3 = src.poseidon2_B_31_3; + dest.poseidon2_B_32_0 = src.poseidon2_B_32_0; + dest.poseidon2_B_32_1 = src.poseidon2_B_32_1; + dest.poseidon2_B_32_2 = src.poseidon2_B_32_2; + dest.poseidon2_B_32_3 = src.poseidon2_B_32_3; + dest.poseidon2_B_33_0 = src.poseidon2_B_33_0; + dest.poseidon2_B_33_1 = src.poseidon2_B_33_1; + dest.poseidon2_B_33_2 = src.poseidon2_B_33_2; + dest.poseidon2_B_33_3 = src.poseidon2_B_33_3; + dest.poseidon2_B_34_0 = src.poseidon2_B_34_0; + dest.poseidon2_B_34_1 = src.poseidon2_B_34_1; + dest.poseidon2_B_34_2 = src.poseidon2_B_34_2; + dest.poseidon2_B_34_3 = src.poseidon2_B_34_3; + dest.poseidon2_B_35_0 = src.poseidon2_B_35_0; + dest.poseidon2_B_35_1 = src.poseidon2_B_35_1; + dest.poseidon2_B_35_2 = src.poseidon2_B_35_2; + dest.poseidon2_B_35_3 = src.poseidon2_B_35_3; + dest.poseidon2_B_36_0 = src.poseidon2_B_36_0; + dest.poseidon2_B_36_1 = src.poseidon2_B_36_1; + dest.poseidon2_B_36_2 = src.poseidon2_B_36_2; + dest.poseidon2_B_36_3 = src.poseidon2_B_36_3; + dest.poseidon2_B_37_0 = src.poseidon2_B_37_0; + dest.poseidon2_B_37_1 = src.poseidon2_B_37_1; + dest.poseidon2_B_37_2 = src.poseidon2_B_37_2; + dest.poseidon2_B_37_3 = src.poseidon2_B_37_3; + dest.poseidon2_B_38_0 = src.poseidon2_B_38_0; + dest.poseidon2_B_38_1 = src.poseidon2_B_38_1; + dest.poseidon2_B_38_2 = src.poseidon2_B_38_2; + dest.poseidon2_B_38_3 = src.poseidon2_B_38_3; + dest.poseidon2_B_39_0 = src.poseidon2_B_39_0; + dest.poseidon2_B_39_1 = src.poseidon2_B_39_1; + dest.poseidon2_B_39_2 = src.poseidon2_B_39_2; + dest.poseidon2_B_39_3 = src.poseidon2_B_39_3; + dest.poseidon2_B_40_0 = src.poseidon2_B_40_0; + dest.poseidon2_B_40_1 = src.poseidon2_B_40_1; + dest.poseidon2_B_40_2 = src.poseidon2_B_40_2; + dest.poseidon2_B_40_3 = src.poseidon2_B_40_3; + dest.poseidon2_B_41_0 = src.poseidon2_B_41_0; + dest.poseidon2_B_41_1 = src.poseidon2_B_41_1; + dest.poseidon2_B_41_2 = src.poseidon2_B_41_2; + dest.poseidon2_B_41_3 = src.poseidon2_B_41_3; + dest.poseidon2_B_42_0 = src.poseidon2_B_42_0; + dest.poseidon2_B_42_1 = src.poseidon2_B_42_1; + dest.poseidon2_B_42_2 = src.poseidon2_B_42_2; + dest.poseidon2_B_42_3 = src.poseidon2_B_42_3; + dest.poseidon2_B_43_0 = src.poseidon2_B_43_0; + dest.poseidon2_B_43_1 = src.poseidon2_B_43_1; + dest.poseidon2_B_43_2 = src.poseidon2_B_43_2; + dest.poseidon2_B_43_3 = src.poseidon2_B_43_3; + dest.poseidon2_B_44_0 = src.poseidon2_B_44_0; + dest.poseidon2_B_44_1 = src.poseidon2_B_44_1; + dest.poseidon2_B_44_2 = src.poseidon2_B_44_2; + dest.poseidon2_B_44_3 = src.poseidon2_B_44_3; + dest.poseidon2_B_45_0 = src.poseidon2_B_45_0; + dest.poseidon2_B_45_1 = src.poseidon2_B_45_1; + dest.poseidon2_B_45_2 = src.poseidon2_B_45_2; + dest.poseidon2_B_45_3 = src.poseidon2_B_45_3; + dest.poseidon2_B_46_0 = src.poseidon2_B_46_0; + dest.poseidon2_B_46_1 = src.poseidon2_B_46_1; + dest.poseidon2_B_46_2 = src.poseidon2_B_46_2; + dest.poseidon2_B_46_3 = src.poseidon2_B_46_3; + dest.poseidon2_B_47_0 = src.poseidon2_B_47_0; + dest.poseidon2_B_47_1 = src.poseidon2_B_47_1; + dest.poseidon2_B_47_2 = src.poseidon2_B_47_2; + dest.poseidon2_B_47_3 = src.poseidon2_B_47_3; + dest.poseidon2_B_48_0 = src.poseidon2_B_48_0; + dest.poseidon2_B_48_1 = src.poseidon2_B_48_1; + dest.poseidon2_B_48_2 = src.poseidon2_B_48_2; + dest.poseidon2_B_48_3 = src.poseidon2_B_48_3; + dest.poseidon2_B_49_0 = src.poseidon2_B_49_0; + dest.poseidon2_B_49_1 = src.poseidon2_B_49_1; + dest.poseidon2_B_49_2 = src.poseidon2_B_49_2; + dest.poseidon2_B_49_3 = src.poseidon2_B_49_3; + dest.poseidon2_B_4_0 = src.poseidon2_B_4_0; + dest.poseidon2_B_4_1 = src.poseidon2_B_4_1; + dest.poseidon2_B_4_2 = src.poseidon2_B_4_2; + dest.poseidon2_B_4_3 = src.poseidon2_B_4_3; + dest.poseidon2_B_50_0 = src.poseidon2_B_50_0; + dest.poseidon2_B_50_1 = src.poseidon2_B_50_1; + dest.poseidon2_B_50_2 = src.poseidon2_B_50_2; + dest.poseidon2_B_50_3 = src.poseidon2_B_50_3; + dest.poseidon2_B_51_0 = src.poseidon2_B_51_0; + dest.poseidon2_B_51_1 = src.poseidon2_B_51_1; + dest.poseidon2_B_51_2 = src.poseidon2_B_51_2; + dest.poseidon2_B_51_3 = src.poseidon2_B_51_3; + dest.poseidon2_B_52_0 = src.poseidon2_B_52_0; + dest.poseidon2_B_52_1 = src.poseidon2_B_52_1; + dest.poseidon2_B_52_2 = src.poseidon2_B_52_2; + dest.poseidon2_B_52_3 = src.poseidon2_B_52_3; + dest.poseidon2_B_53_0 = src.poseidon2_B_53_0; + dest.poseidon2_B_53_1 = src.poseidon2_B_53_1; + dest.poseidon2_B_53_2 = src.poseidon2_B_53_2; + dest.poseidon2_B_53_3 = src.poseidon2_B_53_3; + dest.poseidon2_B_54_0 = src.poseidon2_B_54_0; + dest.poseidon2_B_54_1 = src.poseidon2_B_54_1; + dest.poseidon2_B_54_2 = src.poseidon2_B_54_2; + dest.poseidon2_B_54_3 = src.poseidon2_B_54_3; + dest.poseidon2_B_55_0 = src.poseidon2_B_55_0; + dest.poseidon2_B_55_1 = src.poseidon2_B_55_1; + dest.poseidon2_B_55_2 = src.poseidon2_B_55_2; + dest.poseidon2_B_55_3 = src.poseidon2_B_55_3; + dest.poseidon2_B_56_0 = src.poseidon2_B_56_0; + dest.poseidon2_B_56_1 = src.poseidon2_B_56_1; + dest.poseidon2_B_56_2 = src.poseidon2_B_56_2; + dest.poseidon2_B_56_3 = src.poseidon2_B_56_3; + dest.poseidon2_B_57_0 = src.poseidon2_B_57_0; + dest.poseidon2_B_57_1 = src.poseidon2_B_57_1; + dest.poseidon2_B_57_2 = src.poseidon2_B_57_2; + dest.poseidon2_B_57_3 = src.poseidon2_B_57_3; + dest.poseidon2_B_58_0 = src.poseidon2_B_58_0; + dest.poseidon2_B_58_1 = src.poseidon2_B_58_1; + dest.poseidon2_B_58_2 = src.poseidon2_B_58_2; + dest.poseidon2_B_58_3 = src.poseidon2_B_58_3; + dest.poseidon2_B_59_0 = src.poseidon2_B_59_0; + dest.poseidon2_B_59_1 = src.poseidon2_B_59_1; + dest.poseidon2_B_59_2 = src.poseidon2_B_59_2; + dest.poseidon2_B_59_3 = src.poseidon2_B_59_3; + dest.poseidon2_B_5_0 = src.poseidon2_B_5_0; + dest.poseidon2_B_5_1 = src.poseidon2_B_5_1; + dest.poseidon2_B_5_2 = src.poseidon2_B_5_2; + dest.poseidon2_B_5_3 = src.poseidon2_B_5_3; + dest.poseidon2_B_6_0 = src.poseidon2_B_6_0; + dest.poseidon2_B_6_1 = src.poseidon2_B_6_1; + dest.poseidon2_B_6_2 = src.poseidon2_B_6_2; + dest.poseidon2_B_6_3 = src.poseidon2_B_6_3; + dest.poseidon2_B_7_0 = src.poseidon2_B_7_0; + dest.poseidon2_B_7_1 = src.poseidon2_B_7_1; + dest.poseidon2_B_7_2 = src.poseidon2_B_7_2; + dest.poseidon2_B_7_3 = src.poseidon2_B_7_3; + dest.poseidon2_B_8_0 = src.poseidon2_B_8_0; + dest.poseidon2_B_8_1 = src.poseidon2_B_8_1; + dest.poseidon2_B_8_2 = src.poseidon2_B_8_2; + dest.poseidon2_B_8_3 = src.poseidon2_B_8_3; + dest.poseidon2_B_9_0 = src.poseidon2_B_9_0; + dest.poseidon2_B_9_1 = src.poseidon2_B_9_1; + dest.poseidon2_B_9_2 = src.poseidon2_B_9_2; + dest.poseidon2_B_9_3 = src.poseidon2_B_9_3; + dest.poseidon2_T_0_4 = src.poseidon2_T_0_4; + dest.poseidon2_T_0_5 = src.poseidon2_T_0_5; + dest.poseidon2_T_0_6 = src.poseidon2_T_0_6; + dest.poseidon2_T_0_7 = src.poseidon2_T_0_7; + dest.poseidon2_T_1_4 = src.poseidon2_T_1_4; + dest.poseidon2_T_1_5 = src.poseidon2_T_1_5; + dest.poseidon2_T_1_6 = src.poseidon2_T_1_6; + dest.poseidon2_T_1_7 = src.poseidon2_T_1_7; + dest.poseidon2_T_2_4 = src.poseidon2_T_2_4; + dest.poseidon2_T_2_5 = src.poseidon2_T_2_5; + dest.poseidon2_T_2_6 = src.poseidon2_T_2_6; + dest.poseidon2_T_2_7 = src.poseidon2_T_2_7; + dest.poseidon2_T_3_4 = src.poseidon2_T_3_4; + dest.poseidon2_T_3_5 = src.poseidon2_T_3_5; + dest.poseidon2_T_3_6 = src.poseidon2_T_3_6; + dest.poseidon2_T_3_7 = src.poseidon2_T_3_7; + dest.poseidon2_T_60_4 = src.poseidon2_T_60_4; + dest.poseidon2_T_60_5 = src.poseidon2_T_60_5; + dest.poseidon2_T_60_6 = src.poseidon2_T_60_6; + dest.poseidon2_T_60_7 = src.poseidon2_T_60_7; + dest.poseidon2_T_61_4 = src.poseidon2_T_61_4; + dest.poseidon2_T_61_5 = src.poseidon2_T_61_5; + dest.poseidon2_T_61_6 = src.poseidon2_T_61_6; + dest.poseidon2_T_61_7 = src.poseidon2_T_61_7; + dest.poseidon2_T_62_4 = src.poseidon2_T_62_4; + dest.poseidon2_T_62_5 = src.poseidon2_T_62_5; + dest.poseidon2_T_62_6 = src.poseidon2_T_62_6; + dest.poseidon2_T_62_7 = src.poseidon2_T_62_7; + dest.poseidon2_T_63_4 = src.poseidon2_T_63_4; + dest.poseidon2_T_63_5 = src.poseidon2_T_63_5; + dest.poseidon2_T_63_6 = src.poseidon2_T_63_6; + dest.poseidon2_T_63_7 = src.poseidon2_T_63_7; + dest.poseidon2_a_0 = src.poseidon2_a_0; + dest.poseidon2_a_1 = src.poseidon2_a_1; + dest.poseidon2_a_2 = src.poseidon2_a_2; + dest.poseidon2_a_3 = src.poseidon2_a_3; + dest.poseidon2_input_addr = src.poseidon2_input_addr; + dest.poseidon2_mem_addr_a = src.poseidon2_mem_addr_a; + dest.poseidon2_mem_addr_b = src.poseidon2_mem_addr_b; + dest.poseidon2_mem_addr_c = src.poseidon2_mem_addr_c; + dest.poseidon2_mem_addr_d = src.poseidon2_mem_addr_d; + dest.poseidon2_mem_op = src.poseidon2_mem_op; + dest.poseidon2_output_addr = src.poseidon2_output_addr; + dest.poseidon2_read_line = src.poseidon2_read_line; + dest.poseidon2_sel_poseidon_perm = src.poseidon2_sel_poseidon_perm; + dest.poseidon2_write_line = src.poseidon2_write_line; + dest.poseidon2_in_tag = src.poseidon2_in_tag; + dest.poseidon2_EXT_LAYER_6 = src.poseidon2_EXT_LAYER_6; + dest.poseidon2_EXT_LAYER_5 = src.poseidon2_EXT_LAYER_5; + dest.poseidon2_EXT_LAYER_7 = src.poseidon2_EXT_LAYER_7; + dest.poseidon2_EXT_LAYER_4 = src.poseidon2_EXT_LAYER_4; + } private: std::vector poseidon2_trace; -}; +}; // namespace bb::avm_trace } // namespace bb::avm_trace diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.cpp index b766197c33e4..c3ccbdda3fbd 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.cpp @@ -60,9 +60,9 @@ void AvmMemTraceBuilder::insert_in_mem_trace(uint8_t space_id, AvmMemoryTag r_in_tag, AvmMemoryTag w_in_tag, bool m_rw, - bool m_sel_op_slice) + MemOpOwner mem_op_owner = MemOpOwner::MAIN) { - mem_trace.emplace_back(MemoryTraceEntry{ .m_space_id = space_id, + auto mem_trace_entry = MemoryTraceEntry{ .m_space_id = space_id, .m_clk = m_clk, .m_sub_clk = m_sub_clk, .m_addr = m_addr, @@ -70,8 +70,18 @@ void AvmMemTraceBuilder::insert_in_mem_trace(uint8_t space_id, .m_tag = m_tag, .r_in_tag = r_in_tag, .w_in_tag = w_in_tag, - .m_rw = m_rw, - .m_sel_op_slice = m_sel_op_slice }); + .m_rw = m_rw }; + switch (mem_op_owner) { + case MemOpOwner::MAIN: + break; + case MemOpOwner::SLICE: + mem_trace_entry.m_sel_op_slice = true; + break; + case MemOpOwner::POSEIDON2: + mem_trace_entry.gadget_mem_op = true; + break; + } + mem_trace.emplace_back(mem_trace_entry); } // Memory operations need to be performed before the addition of the corresponding row in @@ -145,13 +155,14 @@ bool AvmMemTraceBuilder::load_from_mem_trace(uint8_t space_id, uint32_t addr, FF const& val, AvmMemoryTag r_in_tag, - AvmMemoryTag w_in_tag) + AvmMemoryTag w_in_tag, + MemOpOwner mem_op_owner) { auto& mem_space = memory.at(space_id); AvmMemoryTag m_tag = mem_space.contains(addr) ? mem_space.at(addr).tag : AvmMemoryTag::U0; if (m_tag == AvmMemoryTag::U0 || m_tag == r_in_tag) { - insert_in_mem_trace(space_id, clk, sub_clk, addr, val, m_tag, r_in_tag, w_in_tag, false); + insert_in_mem_trace(space_id, clk, sub_clk, addr, val, m_tag, r_in_tag, w_in_tag, false, mem_op_owner); return true; } @@ -178,7 +189,8 @@ void AvmMemTraceBuilder::store_in_mem_trace(uint8_t space_id, uint32_t addr, FF const& val, AvmMemoryTag r_in_tag, - AvmMemoryTag w_in_tag) + AvmMemoryTag w_in_tag, + MemOpOwner mem_op_owner) { uint32_t sub_clk = 0; switch (interm_reg) { @@ -196,7 +208,7 @@ void AvmMemTraceBuilder::store_in_mem_trace(uint8_t space_id, break; } - insert_in_mem_trace(space_id, clk, sub_clk, addr, val, w_in_tag, r_in_tag, w_in_tag, true); + insert_in_mem_trace(space_id, clk, sub_clk, addr, val, w_in_tag, r_in_tag, w_in_tag, true, mem_op_owner); } /** @@ -394,7 +406,8 @@ AvmMemTraceBuilder::MemRead AvmMemTraceBuilder::read_and_load_from_memory(uint8_ IntermRegister const interm_reg, uint32_t const addr, AvmMemoryTag const r_in_tag, - AvmMemoryTag const w_in_tag) + AvmMemoryTag const w_in_tag, + MemOpOwner mem_op_owner) { uint32_t sub_clk = 0; switch (interm_reg) { @@ -413,7 +426,7 @@ AvmMemTraceBuilder::MemRead AvmMemTraceBuilder::read_and_load_from_memory(uint8_ } auto& mem_space = memory.at(space_id); FF val = mem_space.contains(addr) ? mem_space.at(addr).val : 0; - bool tagMatch = load_from_mem_trace(space_id, clk, sub_clk, addr, val, r_in_tag, w_in_tag); + bool tagMatch = load_from_mem_trace(space_id, clk, sub_clk, addr, val, r_in_tag, w_in_tag, mem_op_owner); return MemRead{ .tag_match = tagMatch, @@ -471,10 +484,11 @@ void AvmMemTraceBuilder::write_into_memory(uint8_t space_id, uint32_t addr, FF const& val, AvmMemoryTag r_in_tag, - AvmMemoryTag w_in_tag) + AvmMemoryTag w_in_tag, + MemOpOwner mem_op_owner) { write_in_simulated_mem_table(space_id, addr, val, w_in_tag); - store_in_mem_trace(space_id, clk, interm_reg, addr, val, r_in_tag, w_in_tag); + store_in_mem_trace(space_id, clk, interm_reg, addr, val, r_in_tag, w_in_tag, mem_op_owner); } void AvmMemTraceBuilder::write_calldata_copy(std::vector const& calldata, @@ -497,7 +511,7 @@ void AvmMemTraceBuilder::write_calldata_copy(std::vector const& calldata, AvmMemoryTag::FF, AvmMemoryTag::FF, true, - true); + MemOpOwner::SLICE); } } @@ -523,7 +537,7 @@ std::vector AvmMemTraceBuilder::read_return_opcode(uint32_t clk, AvmMemoryTag::FF, AvmMemoryTag::FF, false, - true); + MemOpOwner::SLICE); returndata.push_back(val); } diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.hpp index fb4735ee905d..7cc6fb62b69f 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.hpp @@ -45,6 +45,8 @@ class AvmMemTraceBuilder { bool m_tag_err_count_relevant = false; bool m_sel_op_slice = false; + bool gadget_mem_op = false; + /** * @brief A comparator on MemoryTraceEntry to be used by sorting algorithm. We sort first by * ascending address (m_addr), then by clock (m_clk) and finally sub-clock (m_sub_clk). @@ -64,6 +66,13 @@ class AvmMemTraceBuilder { FF val{}; }; + // Enum to define which subtable triggered and manages (via perm) the memory operation. + enum MemOpOwner { + MAIN, + SLICE, + POSEIDON2, + }; + AvmMemTraceBuilder(); void reset(); @@ -80,7 +89,8 @@ class AvmMemTraceBuilder { IntermRegister interm_reg, uint32_t addr, AvmMemoryTag r_in_tag, - AvmMemoryTag w_in_tag); + AvmMemoryTag w_in_tag, + MemOpOwner mem_op_owner = MAIN); MemRead indirect_read_and_load_from_memory(uint8_t space_id, uint32_t clk, IndirectRegister ind_reg, uint32_t addr); void write_into_memory(uint8_t space_id, uint32_t clk, @@ -88,7 +98,8 @@ class AvmMemTraceBuilder { uint32_t addr, FF const& val, AvmMemoryTag r_in_tag, - AvmMemoryTag w_in_tag); + AvmMemoryTag w_in_tag, + MemOpOwner mem_op_owner = MAIN); void write_calldata_copy(std::vector const& calldata, uint32_t clk, uint8_t space_id, @@ -112,7 +123,7 @@ class AvmMemTraceBuilder { AvmMemoryTag r_in_tag, AvmMemoryTag w_in_tag, bool m_rw, - bool m_sel_op_slice = false); + MemOpOwner mem_op_owner); void load_mismatch_tag_in_mem_trace(uint8_t space_id, uint32_t m_clk, @@ -129,14 +140,16 @@ class AvmMemTraceBuilder { uint32_t addr, FF const& val, AvmMemoryTag r_in_tag, - AvmMemoryTag w_in_tag); + AvmMemoryTag w_in_tag, + MemOpOwner mem_op_owner = MAIN); void store_in_mem_trace(uint8_t space_id, uint32_t clk, IntermRegister interm_reg, uint32_t addr, FF const& val, AvmMemoryTag r_in_tag, - AvmMemoryTag w_in_tag); + AvmMemoryTag w_in_tag, + MemOpOwner mem_op_owner = MAIN); void write_in_simulated_mem_table(uint8_t space_id, uint32_t addr, FF const& val, AvmMemoryTag w_in_tag); }; } // namespace bb::avm_trace diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.cpp index e3f582d3953a..921aa59c8ce8 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.cpp @@ -217,7 +217,8 @@ AvmTraceBuilder::MemOp AvmTraceBuilder::constrained_read_from_memory(uint8_t spa AddressWithMode addr, AvmMemoryTag read_tag, AvmMemoryTag write_tag, - IntermRegister reg) + IntermRegister reg, + bool is_gadget_mem_op) { // Get the same matching indirect register for the given intermediate register. // This is a hack that we can replace with a mapping of IntermediateRegister to IndirectRegister. @@ -237,7 +238,14 @@ AvmTraceBuilder::MemOp AvmTraceBuilder::constrained_read_from_memory(uint8_t spa } direct_offset = uint32_t(read_ind.val); } - auto read_dir = mem_trace_builder.read_and_load_from_memory(space_id, clk, reg, direct_offset, read_tag, write_tag); + auto read_dir = mem_trace_builder.read_and_load_from_memory( + space_id, + clk, + reg, + direct_offset, + read_tag, + write_tag, + is_gadget_mem_op ? AvmMemTraceBuilder::MemOpOwner::POSEIDON2 : AvmMemTraceBuilder::MAIN); return MemOp{ .is_indirect = is_indirect, @@ -260,7 +268,8 @@ AvmTraceBuilder::MemOp AvmTraceBuilder::constrained_write_to_memory(uint8_t spac FF const& value, AvmMemoryTag read_tag, AvmMemoryTag write_tag, - IntermRegister reg) + IntermRegister reg, + bool is_gadget_mem_op) { auto indirect_reg = static_cast(reg); uint32_t direct_offset = addr.offset; @@ -277,7 +286,14 @@ AvmTraceBuilder::MemOp AvmTraceBuilder::constrained_write_to_memory(uint8_t spac } direct_offset = uint32_t(read_ind.val); } - mem_trace_builder.write_into_memory(space_id, clk, reg, direct_offset, value, read_tag, write_tag); + mem_trace_builder.write_into_memory(space_id, + clk, + reg, + direct_offset, + value, + read_tag, + write_tag, + is_gadget_mem_op ? AvmMemTraceBuilder::POSEIDON2 : AvmMemTraceBuilder::MAIN); return MemOp{ .is_indirect = is_indirect, .indirect_address = indirect_offset, .direct_address = direct_offset, @@ -2926,61 +2942,93 @@ void AvmTraceBuilder::op_poseidon2_permutation(uint8_t indirect, uint32_t input_ auto [resolved_input_offset, resolved_output_offset] = unpack_indirects<2>(indirect, { input_offset, output_offset }); - auto read_a = constrained_read_from_memory( - call_ptr, clk, resolved_input_offset, AvmMemoryTag::FF, AvmMemoryTag::U0, IntermRegister::IA); - auto read_b = constrained_read_from_memory( - call_ptr, clk, resolved_output_offset, AvmMemoryTag::FF, AvmMemoryTag::U0, IntermRegister::IB); - bool tag_match = read_a.tag_match && read_b.tag_match; + // Resolve indirects in the main trace. Do not resolve the value stored in direct addresses. + uint32_t direct_input_offset = input_offset; + uint32_t direct_output_offset = output_offset; + uint32_t indirect_input_offset = 0; + uint32_t indirect_output_offset = 0; + if (resolved_input_offset.mode == AddressingMode::INDIRECT) { + auto ind_read_a = mem_trace_builder.indirect_read_and_load_from_memory( + call_ptr, clk, IndirectRegister::IND_A, resolved_input_offset.offset); + indirect_input_offset = input_offset; + direct_input_offset = uint32_t(ind_read_a.val); + } + if (resolved_output_offset.mode == AddressingMode::INDIRECT) { + auto ind_read_b = mem_trace_builder.indirect_read_and_load_from_memory( + call_ptr, clk, IndirectRegister::IND_B, resolved_output_offset.offset); + indirect_output_offset = output_offset; + direct_output_offset = uint32_t(ind_read_b.val); + } // Constrain gas cost gas_trace_builder.constrain_gas_lookup(clk, OpCode::POSEIDON2); + // Main trace contains on operand values from the bytecode and resolved indirects main_trace.push_back(Row{ .main_clk = clk, - .main_ia = read_a.val, // First element of input - .main_ib = read_b.val, // First element of output (trivially zero) - .main_ind_addr_a = FF(read_a.indirect_address), - .main_ind_addr_b = FF(read_b.indirect_address), + .main_ind_addr_a = FF(indirect_input_offset), + .main_ind_addr_b = FF(indirect_output_offset), .main_internal_return_ptr = FF(internal_return_ptr), - .main_mem_addr_a = FF(read_a.direct_address), - .main_mem_addr_b = FF(read_b.direct_address), + .main_mem_addr_a = direct_input_offset, + .main_mem_addr_b = direct_output_offset, .main_pc = FF(pc++), - .main_r_in_tag = FF(static_cast(AvmMemoryTag::FF)), - .main_sel_mem_op_a = FF(1), - .main_sel_mem_op_b = FF(1), .main_sel_op_poseidon2 = FF(1), - .main_sel_resolve_ind_addr_a = FF(static_cast(read_a.is_indirect)), - .main_sel_resolve_ind_addr_b = FF(static_cast(read_b.is_indirect)), - .main_tag_err = FF(static_cast(!tag_match)), + .main_sel_resolve_ind_addr_a = + FF(static_cast(resolved_input_offset.mode == AddressingMode::INDIRECT)), + .main_sel_resolve_ind_addr_b = + FF(static_cast(resolved_output_offset.mode == AddressingMode::INDIRECT)), }); - // We store the current clk this main trace row occurred so that we can line up the poseidon2 gadget operation - // at the same clk later. - auto poseidon_op_clk = clk; - // We need to increment the clk - clk++; - // Read results are written to input array. - std::vector input_vec; - read_slice_to_memory(call_ptr, - clk, - resolved_input_offset, - AvmMemoryTag::FF, - AvmMemoryTag::U0, - FF(internal_return_ptr), - 4, - input_vec); - - // Increment the clock by 1 since (4 reads / 4 reads per row = 1) - clk += 1; - std::array input = vec_to_arr(input_vec); - std::array result = poseidon2_trace_builder.poseidon2_permutation(input, poseidon_op_clk); + // These read patterns will be refactored - we perform them here instead of in the poseidon gadget trace + // even though they are "performed" by the gadget. + AddressWithMode direct_src_offset = { AddressingMode::DIRECT, direct_input_offset }; + // This is because passing the mem_builder to the gadget causes some issues regarding copy-move semantics in cpp + auto read_a = constrained_read_from_memory( + call_ptr, clk, direct_src_offset, AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::IA, true); + auto read_b = constrained_read_from_memory( + call_ptr, clk, direct_src_offset + 1, AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::IB, true); + auto read_c = constrained_read_from_memory( + call_ptr, clk, direct_src_offset + 2, AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::IC, true); + auto read_d = constrained_read_from_memory( + call_ptr, clk, direct_src_offset + 3, AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::ID, true); + + std::array input = { read_a.val, read_b.val, read_c.val, read_d.val }; + std::array result = + poseidon2_trace_builder.poseidon2_permutation(input, clk, direct_input_offset, direct_output_offset); + std::vector ff_result; for (uint32_t i = 0; i < 4; i++) { ff_result.emplace_back(result[i]); } - // // Write the result to memory after - write_slice_to_memory( - call_ptr, clk, resolved_output_offset, AvmMemoryTag::U0, AvmMemoryTag::FF, FF(internal_return_ptr), ff_result); + // Write the result to memory after, see the comments at read to understand why this happens here. + AddressWithMode direct_dst_offset = { AddressingMode::DIRECT, direct_output_offset }; + constrained_write_to_memory( + call_ptr, clk, direct_dst_offset, ff_result[0], AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::IA, true); + constrained_write_to_memory(call_ptr, + clk, + direct_dst_offset + 1, + ff_result[1], + AvmMemoryTag::FF, + AvmMemoryTag::FF, + IntermRegister::IB, + true); + constrained_write_to_memory(call_ptr, + clk, + direct_dst_offset + 2, + ff_result[2], + AvmMemoryTag::FF, + AvmMemoryTag::FF, + IntermRegister::IC, + true); + + constrained_write_to_memory(call_ptr, + clk, + direct_dst_offset + 3, + ff_result[3], + AvmMemoryTag::FF, + AvmMemoryTag::FF, + IntermRegister::ID, + true); } /** @@ -3911,6 +3959,7 @@ std::vector AvmTraceBuilder::finalize(uint32_t min_trace_size, bool range_c if (mem_trace_size > 0) { main_trace.at(0).mem_tsp = FF(AvmMemTraceBuilder::NUM_SUB_CLK * mem_trace.at(0).m_clk + mem_trace.at(0).m_sub_clk); + main_trace.at(0).mem_glob_addr = FF(mem_trace.at(0).m_addr + (static_cast(mem_trace.at(0).m_space_id) << 32)); } @@ -3937,24 +3986,43 @@ std::vector AvmTraceBuilder::finalize(uint32_t min_trace_size, bool range_c dest.incl_mem_tag_err_counts = FF(static_cast(src.m_tag_err_count_relevant)); - // Calldatacopy/return memory operations are handled differently and are activated by m_sel_op_slice. + // TODO: Should be a cleaner way to do this in the future. Perhaps an "into_canoncal" function in + // mem_trace_builder if (!src.m_sel_op_slice) { switch (src.m_sub_clk) { case AvmMemTraceBuilder::SUB_CLK_LOAD_A: case AvmMemTraceBuilder::SUB_CLK_STORE_A: - dest.mem_sel_op_a = 1; + // TODO: This is temporary, since we need to distinguish between gadget and main trace reads + // in future it would be nice to place this inside the mem_trace_builder + if (src.gadget_mem_op) { + dest.mem_sel_op_gadget_a = 1; + } else { + dest.mem_sel_op_a = 1; + } break; case AvmMemTraceBuilder::SUB_CLK_LOAD_B: case AvmMemTraceBuilder::SUB_CLK_STORE_B: - dest.mem_sel_op_b = 1; + if (src.gadget_mem_op) { + dest.mem_sel_op_gadget_b = 1; + } else { + dest.mem_sel_op_b = 1; + } break; case AvmMemTraceBuilder::SUB_CLK_LOAD_C: case AvmMemTraceBuilder::SUB_CLK_STORE_C: - dest.mem_sel_op_c = 1; + if (src.gadget_mem_op) { + dest.mem_sel_op_gadget_c = 1; + } else { + dest.mem_sel_op_c = 1; + } break; case AvmMemTraceBuilder::SUB_CLK_LOAD_D: case AvmMemTraceBuilder::SUB_CLK_STORE_D: - dest.mem_sel_op_d = 1; + if (src.gadget_mem_op) { + dest.mem_sel_op_gadget_d = 1; + } else { + dest.mem_sel_op_d = 1; + } break; case AvmMemTraceBuilder::SUB_CLK_IND_LOAD_A: dest.mem_sel_resolve_ind_addr_a = 1; @@ -4193,13 +4261,14 @@ std::vector AvmTraceBuilder::finalize(uint32_t min_trace_size, bool range_c // Add Poseidon2 Gadget table for (size_t i = 0; i < poseidon2_trace_size; i++) { + auto& dest = main_trace.at(2 * i); + auto& write_row = main_trace.at(2 * i + 1); auto const& src = poseidon2_trace.at(i); - auto& dest = main_trace.at(i); + auto canonical_trace_rows = bb::avm_trace::AvmPoseidon2TraceBuilder::into_canonical(src); dest.poseidon2_clk = FF(src.clk); - dest.poseidon2_input = src.input[0]; - // TODO: This will need to be enabled later - // dest.poseidon2_output = src.output[0]; - dest.poseidon2_sel_poseidon_perm = FF(1); + poseidon2_trace_builder.merge_into(dest, canonical_trace_rows.first); + write_row.poseidon2_clk = FF(src.clk); + poseidon2_trace_builder.merge_into(write_row, canonical_trace_rows.second); } // Add KeccakF1600 Gadget table diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.hpp index 6df84612d009..ffebc83ac69a 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.hpp @@ -28,6 +28,9 @@ enum class AddressingMode { struct AddressWithMode { AddressingMode mode; uint32_t offset; + + // Dont mutate + AddressWithMode operator+(uint val) { return { mode, offset + val }; } }; // This is the internal context that we keep along the lifecycle of bytecode execution @@ -242,14 +245,16 @@ class AvmTraceBuilder { AddressWithMode addr, AvmMemoryTag read_tag, AvmMemoryTag write_tag, - IntermRegister reg); + IntermRegister reg, + bool gadget_mem_op = false); MemOp constrained_write_to_memory(uint8_t space_id, uint32_t clk, AddressWithMode addr, FF const& value, AvmMemoryTag read_tag, AvmMemoryTag write_tag, - IntermRegister reg); + IntermRegister reg, + bool gadget_mem_op = false); // TODO(ilyas: #6383): Temporary way to bulk read slices template diff --git a/barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp b/barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp index 114cf3bbc711..f9236b49451f 100644 --- a/barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp @@ -18,411 +18,6 @@ namespace bb { -<<<<<<< HEAD -======= -template struct AvmFullRow { - FF main_clk{}; - FF main_sel_first{}; - FF kernel_kernel_inputs{}; - FF kernel_kernel_value_out{}; - FF kernel_kernel_side_effect_out{}; - FF kernel_kernel_metadata_out{}; - FF main_calldata{}; - FF alu_a_hi{}; - FF alu_a_lo{}; - FF alu_b_hi{}; - FF alu_b_lo{}; - FF alu_borrow{}; - FF alu_cf{}; - FF alu_clk{}; - FF alu_cmp_rng_ctr{}; - FF alu_div_u16_r0{}; - FF alu_div_u16_r1{}; - FF alu_div_u16_r2{}; - FF alu_div_u16_r3{}; - FF alu_div_u16_r4{}; - FF alu_div_u16_r5{}; - FF alu_div_u16_r6{}; - FF alu_div_u16_r7{}; - FF alu_divisor_hi{}; - FF alu_divisor_lo{}; - FF alu_ff_tag{}; - FF alu_ia{}; - FF alu_ib{}; - FF alu_ic{}; - FF alu_in_tag{}; - FF alu_op_add{}; - FF alu_op_cast{}; - FF alu_op_cast_prev{}; - FF alu_op_div{}; - FF alu_op_div_a_lt_b{}; - FF alu_op_div_std{}; - FF alu_op_eq{}; - FF alu_op_eq_diff_inv{}; - FF alu_op_lt{}; - FF alu_op_lte{}; - FF alu_op_mul{}; - FF alu_op_not{}; - FF alu_op_shl{}; - FF alu_op_shr{}; - FF alu_op_sub{}; - FF alu_p_a_borrow{}; - FF alu_p_b_borrow{}; - FF alu_p_sub_a_hi{}; - FF alu_p_sub_a_lo{}; - FF alu_p_sub_b_hi{}; - FF alu_p_sub_b_lo{}; - FF alu_partial_prod_hi{}; - FF alu_partial_prod_lo{}; - FF alu_quotient_hi{}; - FF alu_quotient_lo{}; - FF alu_remainder{}; - FF alu_res_hi{}; - FF alu_res_lo{}; - FF alu_sel_alu{}; - FF alu_sel_cmp{}; - FF alu_sel_div_rng_chk{}; - FF alu_sel_rng_chk{}; - FF alu_sel_rng_chk_lookup{}; - FF alu_sel_shift_which{}; - FF alu_shift_lt_bit_len{}; - FF alu_t_sub_s_bits{}; - FF alu_two_pow_s{}; - FF alu_two_pow_t_sub_s{}; - FF alu_u128_tag{}; - FF alu_u16_r0{}; - FF alu_u16_r1{}; - FF alu_u16_r10{}; - FF alu_u16_r11{}; - FF alu_u16_r12{}; - FF alu_u16_r13{}; - FF alu_u16_r14{}; - FF alu_u16_r2{}; - FF alu_u16_r3{}; - FF alu_u16_r4{}; - FF alu_u16_r5{}; - FF alu_u16_r6{}; - FF alu_u16_r7{}; - FF alu_u16_r8{}; - FF alu_u16_r9{}; - FF alu_u16_tag{}; - FF alu_u32_tag{}; - FF alu_u64_tag{}; - FF alu_u8_r0{}; - FF alu_u8_r1{}; - FF alu_u8_tag{}; - FF binary_acc_ia{}; - FF binary_acc_ib{}; - FF binary_acc_ic{}; - FF binary_clk{}; - FF binary_ia_bytes{}; - FF binary_ib_bytes{}; - FF binary_ic_bytes{}; - FF binary_in_tag{}; - FF binary_mem_tag_ctr{}; - FF binary_mem_tag_ctr_inv{}; - FF binary_op_id{}; - FF binary_sel_bin{}; - FF binary_start{}; - FF byte_lookup_sel_bin{}; - FF byte_lookup_table_byte_lengths{}; - FF byte_lookup_table_in_tags{}; - FF byte_lookup_table_input_a{}; - FF byte_lookup_table_input_b{}; - FF byte_lookup_table_op_id{}; - FF byte_lookup_table_output{}; - FF conversion_clk{}; - FF conversion_input{}; - FF conversion_num_limbs{}; - FF conversion_radix{}; - FF conversion_sel_to_radix_le{}; - FF gas_da_gas_fixed_table{}; - FF gas_l2_gas_fixed_table{}; - FF gas_sel_gas_cost{}; - FF keccakf1600_clk{}; - FF keccakf1600_input{}; - FF keccakf1600_output{}; - FF keccakf1600_sel_keccakf1600{}; - FF kernel_emit_l2_to_l1_msg_write_offset{}; - FF kernel_emit_note_hash_write_offset{}; - FF kernel_emit_nullifier_write_offset{}; - FF kernel_emit_unencrypted_log_write_offset{}; - FF kernel_kernel_in_offset{}; - FF kernel_kernel_out_offset{}; - FF kernel_l1_to_l2_msg_exists_write_offset{}; - FF kernel_note_hash_exist_write_offset{}; - FF kernel_nullifier_exists_write_offset{}; - FF kernel_nullifier_non_exists_write_offset{}; - FF kernel_q_public_input_kernel_add_to_table{}; - FF kernel_q_public_input_kernel_out_add_to_table{}; - FF kernel_side_effect_counter{}; - FF kernel_sload_write_offset{}; - FF kernel_sstore_write_offset{}; - FF main_abs_da_rem_gas_hi{}; - FF main_abs_da_rem_gas_lo{}; - FF main_abs_l2_rem_gas_hi{}; - FF main_abs_l2_rem_gas_lo{}; - FF main_alu_in_tag{}; - FF main_bin_op_id{}; - FF main_call_ptr{}; - FF main_da_gas_op_cost{}; - FF main_da_gas_remaining{}; - FF main_da_out_of_gas{}; - FF main_ia{}; - FF main_ib{}; - FF main_ic{}; - FF main_id{}; - FF main_id_zero{}; - FF main_ind_addr_a{}; - FF main_ind_addr_b{}; - FF main_ind_addr_c{}; - FF main_ind_addr_d{}; - FF main_internal_return_ptr{}; - FF main_inv{}; - FF main_l2_gas_op_cost{}; - FF main_l2_gas_remaining{}; - FF main_l2_out_of_gas{}; - FF main_mem_addr_a{}; - FF main_mem_addr_b{}; - FF main_mem_addr_c{}; - FF main_mem_addr_d{}; - FF main_op_err{}; - FF main_opcode_val{}; - FF main_pc{}; - FF main_r_in_tag{}; - FF main_rwa{}; - FF main_rwb{}; - FF main_rwc{}; - FF main_rwd{}; - FF main_sel_alu{}; - FF main_sel_bin{}; - FF main_sel_gas_accounting_active{}; - FF main_sel_last{}; - FF main_sel_mem_op_a{}; - FF main_sel_mem_op_activate_gas{}; - FF main_sel_mem_op_b{}; - FF main_sel_mem_op_c{}; - FF main_sel_mem_op_d{}; - FF main_sel_mov_ia_to_ic{}; - FF main_sel_mov_ib_to_ic{}; - FF main_sel_op_add{}; - FF main_sel_op_address{}; - FF main_sel_op_and{}; - FF main_sel_op_block_number{}; - FF main_sel_op_cast{}; - FF main_sel_op_chain_id{}; - FF main_sel_op_cmov{}; - FF main_sel_op_coinbase{}; - FF main_sel_op_dagasleft{}; - FF main_sel_op_div{}; - FF main_sel_op_emit_l2_to_l1_msg{}; - FF main_sel_op_emit_note_hash{}; - FF main_sel_op_emit_nullifier{}; - FF main_sel_op_emit_unencrypted_log{}; - FF main_sel_op_eq{}; - FF main_sel_op_external_call{}; - FF main_sel_op_fdiv{}; - FF main_sel_op_fee_per_da_gas{}; - FF main_sel_op_fee_per_l2_gas{}; - FF main_sel_op_function_selector{}; - FF main_sel_op_get_contract_instance{}; - FF main_sel_op_halt{}; - FF main_sel_op_internal_call{}; - FF main_sel_op_internal_return{}; - FF main_sel_op_jump{}; - FF main_sel_op_jumpi{}; - FF main_sel_op_keccak{}; - FF main_sel_op_l1_to_l2_msg_exists{}; - FF main_sel_op_l2gasleft{}; - FF main_sel_op_lt{}; - FF main_sel_op_lte{}; - FF main_sel_op_mov{}; - FF main_sel_op_mul{}; - FF main_sel_op_not{}; - FF main_sel_op_note_hash_exists{}; - FF main_sel_op_nullifier_exists{}; - FF main_sel_op_or{}; - FF main_sel_op_pedersen{}; - FF main_sel_op_poseidon2{}; - FF main_sel_op_radix_le{}; - FF main_sel_op_sender{}; - FF main_sel_op_sha256{}; - FF main_sel_op_shl{}; - FF main_sel_op_shr{}; - FF main_sel_op_sload{}; - FF main_sel_op_sstore{}; - FF main_sel_op_storage_address{}; - FF main_sel_op_sub{}; - FF main_sel_op_timestamp{}; - FF main_sel_op_transaction_fee{}; - FF main_sel_op_version{}; - FF main_sel_op_xor{}; - FF main_sel_q_kernel_lookup{}; - FF main_sel_q_kernel_output_lookup{}; - FF main_sel_resolve_ind_addr_a{}; - FF main_sel_resolve_ind_addr_b{}; - FF main_sel_resolve_ind_addr_c{}; - FF main_sel_resolve_ind_addr_d{}; - FF main_sel_rng_16{}; - FF main_sel_rng_8{}; - FF main_space_id{}; - FF main_tag_err{}; - FF main_w_in_tag{}; - FF mem_addr{}; - FF mem_clk{}; - FF mem_diff_hi{}; - FF mem_diff_lo{}; - FF mem_diff_mid{}; - FF mem_glob_addr{}; - FF mem_last{}; - FF mem_lastAccess{}; - FF mem_one_min_inv{}; - FF mem_r_in_tag{}; - FF mem_rw{}; - FF mem_sel_mem{}; - FF mem_sel_mov_ia_to_ic{}; - FF mem_sel_mov_ib_to_ic{}; - FF mem_sel_op_a{}; - FF mem_sel_op_b{}; - FF mem_sel_op_c{}; - FF mem_sel_op_cmov{}; - FF mem_sel_op_d{}; - FF mem_sel_resolve_ind_addr_a{}; - FF mem_sel_resolve_ind_addr_b{}; - FF mem_sel_resolve_ind_addr_c{}; - FF mem_sel_resolve_ind_addr_d{}; - FF mem_sel_rng_chk{}; - FF mem_skip_check_tag{}; - FF mem_space_id{}; - FF mem_tag{}; - FF mem_tag_err{}; - FF mem_tsp{}; - FF mem_val{}; - FF mem_w_in_tag{}; - FF pedersen_clk{}; - FF pedersen_input{}; - FF pedersen_output{}; - FF pedersen_sel_pedersen{}; - FF poseidon2_a_0{}; - FF poseidon2_a_1{}; - FF poseidon2_a_2{}; - FF poseidon2_a_3{}; - FF poseidon2_b_0{}; - FF poseidon2_b_1{}; - FF poseidon2_b_2{}; - FF poseidon2_b_3{}; - FF poseidon2_clk{}; - FF poseidon2_input{}; - FF poseidon2_output{}; - FF poseidon2_sel_poseidon_perm{}; - FF powers_power_of_2{}; - FF sha256_clk{}; - FF sha256_input{}; - FF sha256_output{}; - FF sha256_sel_sha256_compression{}; - FF sha256_state{}; - FF perm_main_alu{}; - FF perm_main_bin{}; - FF perm_main_conv{}; - FF perm_main_pos2_perm{}; - FF perm_main_pedersen{}; - FF perm_main_mem_a{}; - FF perm_main_mem_b{}; - FF perm_main_mem_c{}; - FF perm_main_mem_d{}; - FF perm_main_mem_ind_addr_a{}; - FF perm_main_mem_ind_addr_b{}; - FF perm_main_mem_ind_addr_c{}; - FF perm_main_mem_ind_addr_d{}; - FF lookup_byte_lengths{}; - FF lookup_byte_operations{}; - FF lookup_opcode_gas{}; - FF range_check_l2_gas_hi{}; - FF range_check_l2_gas_lo{}; - FF range_check_da_gas_hi{}; - FF range_check_da_gas_lo{}; - FF kernel_output_lookup{}; - FF lookup_into_kernel{}; - FF incl_main_tag_err{}; - FF incl_mem_tag_err{}; - FF lookup_mem_rng_chk_lo{}; - FF lookup_mem_rng_chk_mid{}; - FF lookup_mem_rng_chk_hi{}; - FF lookup_pow_2_0{}; - FF lookup_pow_2_1{}; - FF lookup_u8_0{}; - FF lookup_u8_1{}; - FF lookup_u16_0{}; - FF lookup_u16_1{}; - FF lookup_u16_2{}; - FF lookup_u16_3{}; - FF lookup_u16_4{}; - FF lookup_u16_5{}; - FF lookup_u16_6{}; - FF lookup_u16_7{}; - FF lookup_u16_8{}; - FF lookup_u16_9{}; - FF lookup_u16_10{}; - FF lookup_u16_11{}; - FF lookup_u16_12{}; - FF lookup_u16_13{}; - FF lookup_u16_14{}; - FF lookup_div_u16_0{}; - FF lookup_div_u16_1{}; - FF lookup_div_u16_2{}; - FF lookup_div_u16_3{}; - FF lookup_div_u16_4{}; - FF lookup_div_u16_5{}; - FF lookup_div_u16_6{}; - FF lookup_div_u16_7{}; - FF lookup_byte_lengths_counts{}; - FF lookup_byte_operations_counts{}; - FF lookup_opcode_gas_counts{}; - FF range_check_l2_gas_hi_counts{}; - FF range_check_l2_gas_lo_counts{}; - FF range_check_da_gas_hi_counts{}; - FF range_check_da_gas_lo_counts{}; - FF kernel_output_lookup_counts{}; - FF lookup_into_kernel_counts{}; - FF incl_main_tag_err_counts{}; - FF incl_mem_tag_err_counts{}; - FF lookup_mem_rng_chk_lo_counts{}; - FF lookup_mem_rng_chk_mid_counts{}; - FF lookup_mem_rng_chk_hi_counts{}; - FF lookup_pow_2_0_counts{}; - FF lookup_pow_2_1_counts{}; - FF lookup_u8_0_counts{}; - FF lookup_u8_1_counts{}; - FF lookup_u16_0_counts{}; - FF lookup_u16_1_counts{}; - FF lookup_u16_2_counts{}; - FF lookup_u16_3_counts{}; - FF lookup_u16_4_counts{}; - FF lookup_u16_5_counts{}; - FF lookup_u16_6_counts{}; - FF lookup_u16_7_counts{}; - FF lookup_u16_8_counts{}; - FF lookup_u16_9_counts{}; - FF lookup_u16_10_counts{}; - FF lookup_u16_11_counts{}; - FF lookup_u16_12_counts{}; - FF lookup_u16_13_counts{}; - FF lookup_u16_14_counts{}; - FF lookup_div_u16_0_counts{}; - FF lookup_div_u16_1_counts{}; - FF lookup_div_u16_2_counts{}; - FF lookup_div_u16_3_counts{}; - FF lookup_div_u16_4_counts{}; - FF lookup_div_u16_5_counts{}; - FF lookup_div_u16_6_counts{}; - FF lookup_div_u16_7_counts{}; - - [[maybe_unused]] static std::vector names(); -}; - -template std::ostream& operator<<(std::ostream& os, AvmFullRow const& row); - ->>>>>>> 520b7216c (feat(avm): poseidon2 constraints) class AvmCircuitBuilder { public: using Flavor = bb::AvmFlavor; @@ -433,28 +28,8 @@ class AvmCircuitBuilder { using Polynomial = Flavor::Polynomial; using ProverPolynomials = Flavor::ProverPolynomials; -<<<<<<< HEAD - static constexpr size_t num_fixed_columns = 411; - static constexpr size_t num_polys = 411 + 74; -======= -<<<<<<< HEAD - static constexpr size_t num_fixed_columns = 387; - static constexpr size_t num_polys = 387 + 65; -======= -<<<<<<< HEAD - static constexpr size_t num_fixed_columns = 452; - static constexpr size_t num_polys = 387; -======= -<<<<<<< HEAD - static constexpr size_t num_fixed_columns = 451; - static constexpr size_t num_polys = 386; -======= - static constexpr size_t num_fixed_columns = 458; - static constexpr size_t num_polys = 393; ->>>>>>> 91347fba1 (feat(avm): poseidon2 constraints) ->>>>>>> dfd3ca77d (feat(avm): poseidon2 constraints) ->>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) ->>>>>>> 804a62263 (feat(avm): poseidon2 constraints) + static constexpr size_t num_fixed_columns = 695; + static constexpr size_t num_polys = 695 + 80; std::vector rows; void set_trace(std::vector&& trace) { rows = std::move(trace); } @@ -743,6 +318,10 @@ class AvmCircuitBuilder { polys.mem_sel_op_c[i] = rows[i].mem_sel_op_c; polys.mem_sel_op_cmov[i] = rows[i].mem_sel_op_cmov; polys.mem_sel_op_d[i] = rows[i].mem_sel_op_d; + polys.mem_sel_op_gadget_a[i] = rows[i].mem_sel_op_gadget_a; + polys.mem_sel_op_gadget_b[i] = rows[i].mem_sel_op_gadget_b; + polys.mem_sel_op_gadget_c[i] = rows[i].mem_sel_op_gadget_c; + polys.mem_sel_op_gadget_d[i] = rows[i].mem_sel_op_gadget_d; polys.mem_sel_op_slice[i] = rows[i].mem_sel_op_slice; polys.mem_sel_resolve_ind_addr_a[i] = rows[i].mem_sel_resolve_ind_addr_a; polys.mem_sel_resolve_ind_addr_b[i] = rows[i].mem_sel_resolve_ind_addr_b; @@ -760,6 +339,266 @@ class AvmCircuitBuilder { polys.pedersen_input[i] = rows[i].pedersen_input; polys.pedersen_output[i] = rows[i].pedersen_output; polys.pedersen_sel_pedersen[i] = rows[i].pedersen_sel_pedersen; + polys.poseidon2_B_10_0[i] = rows[i].poseidon2_B_10_0; + polys.poseidon2_B_10_1[i] = rows[i].poseidon2_B_10_1; + polys.poseidon2_B_10_2[i] = rows[i].poseidon2_B_10_2; + polys.poseidon2_B_10_3[i] = rows[i].poseidon2_B_10_3; + polys.poseidon2_B_11_0[i] = rows[i].poseidon2_B_11_0; + polys.poseidon2_B_11_1[i] = rows[i].poseidon2_B_11_1; + polys.poseidon2_B_11_2[i] = rows[i].poseidon2_B_11_2; + polys.poseidon2_B_11_3[i] = rows[i].poseidon2_B_11_3; + polys.poseidon2_B_12_0[i] = rows[i].poseidon2_B_12_0; + polys.poseidon2_B_12_1[i] = rows[i].poseidon2_B_12_1; + polys.poseidon2_B_12_2[i] = rows[i].poseidon2_B_12_2; + polys.poseidon2_B_12_3[i] = rows[i].poseidon2_B_12_3; + polys.poseidon2_B_13_0[i] = rows[i].poseidon2_B_13_0; + polys.poseidon2_B_13_1[i] = rows[i].poseidon2_B_13_1; + polys.poseidon2_B_13_2[i] = rows[i].poseidon2_B_13_2; + polys.poseidon2_B_13_3[i] = rows[i].poseidon2_B_13_3; + polys.poseidon2_B_14_0[i] = rows[i].poseidon2_B_14_0; + polys.poseidon2_B_14_1[i] = rows[i].poseidon2_B_14_1; + polys.poseidon2_B_14_2[i] = rows[i].poseidon2_B_14_2; + polys.poseidon2_B_14_3[i] = rows[i].poseidon2_B_14_3; + polys.poseidon2_B_15_0[i] = rows[i].poseidon2_B_15_0; + polys.poseidon2_B_15_1[i] = rows[i].poseidon2_B_15_1; + polys.poseidon2_B_15_2[i] = rows[i].poseidon2_B_15_2; + polys.poseidon2_B_15_3[i] = rows[i].poseidon2_B_15_3; + polys.poseidon2_B_16_0[i] = rows[i].poseidon2_B_16_0; + polys.poseidon2_B_16_1[i] = rows[i].poseidon2_B_16_1; + polys.poseidon2_B_16_2[i] = rows[i].poseidon2_B_16_2; + polys.poseidon2_B_16_3[i] = rows[i].poseidon2_B_16_3; + polys.poseidon2_B_17_0[i] = rows[i].poseidon2_B_17_0; + polys.poseidon2_B_17_1[i] = rows[i].poseidon2_B_17_1; + polys.poseidon2_B_17_2[i] = rows[i].poseidon2_B_17_2; + polys.poseidon2_B_17_3[i] = rows[i].poseidon2_B_17_3; + polys.poseidon2_B_18_0[i] = rows[i].poseidon2_B_18_0; + polys.poseidon2_B_18_1[i] = rows[i].poseidon2_B_18_1; + polys.poseidon2_B_18_2[i] = rows[i].poseidon2_B_18_2; + polys.poseidon2_B_18_3[i] = rows[i].poseidon2_B_18_3; + polys.poseidon2_B_19_0[i] = rows[i].poseidon2_B_19_0; + polys.poseidon2_B_19_1[i] = rows[i].poseidon2_B_19_1; + polys.poseidon2_B_19_2[i] = rows[i].poseidon2_B_19_2; + polys.poseidon2_B_19_3[i] = rows[i].poseidon2_B_19_3; + polys.poseidon2_B_20_0[i] = rows[i].poseidon2_B_20_0; + polys.poseidon2_B_20_1[i] = rows[i].poseidon2_B_20_1; + polys.poseidon2_B_20_2[i] = rows[i].poseidon2_B_20_2; + polys.poseidon2_B_20_3[i] = rows[i].poseidon2_B_20_3; + polys.poseidon2_B_21_0[i] = rows[i].poseidon2_B_21_0; + polys.poseidon2_B_21_1[i] = rows[i].poseidon2_B_21_1; + polys.poseidon2_B_21_2[i] = rows[i].poseidon2_B_21_2; + polys.poseidon2_B_21_3[i] = rows[i].poseidon2_B_21_3; + polys.poseidon2_B_22_0[i] = rows[i].poseidon2_B_22_0; + polys.poseidon2_B_22_1[i] = rows[i].poseidon2_B_22_1; + polys.poseidon2_B_22_2[i] = rows[i].poseidon2_B_22_2; + polys.poseidon2_B_22_3[i] = rows[i].poseidon2_B_22_3; + polys.poseidon2_B_23_0[i] = rows[i].poseidon2_B_23_0; + polys.poseidon2_B_23_1[i] = rows[i].poseidon2_B_23_1; + polys.poseidon2_B_23_2[i] = rows[i].poseidon2_B_23_2; + polys.poseidon2_B_23_3[i] = rows[i].poseidon2_B_23_3; + polys.poseidon2_B_24_0[i] = rows[i].poseidon2_B_24_0; + polys.poseidon2_B_24_1[i] = rows[i].poseidon2_B_24_1; + polys.poseidon2_B_24_2[i] = rows[i].poseidon2_B_24_2; + polys.poseidon2_B_24_3[i] = rows[i].poseidon2_B_24_3; + polys.poseidon2_B_25_0[i] = rows[i].poseidon2_B_25_0; + polys.poseidon2_B_25_1[i] = rows[i].poseidon2_B_25_1; + polys.poseidon2_B_25_2[i] = rows[i].poseidon2_B_25_2; + polys.poseidon2_B_25_3[i] = rows[i].poseidon2_B_25_3; + polys.poseidon2_B_26_0[i] = rows[i].poseidon2_B_26_0; + polys.poseidon2_B_26_1[i] = rows[i].poseidon2_B_26_1; + polys.poseidon2_B_26_2[i] = rows[i].poseidon2_B_26_2; + polys.poseidon2_B_26_3[i] = rows[i].poseidon2_B_26_3; + polys.poseidon2_B_27_0[i] = rows[i].poseidon2_B_27_0; + polys.poseidon2_B_27_1[i] = rows[i].poseidon2_B_27_1; + polys.poseidon2_B_27_2[i] = rows[i].poseidon2_B_27_2; + polys.poseidon2_B_27_3[i] = rows[i].poseidon2_B_27_3; + polys.poseidon2_B_28_0[i] = rows[i].poseidon2_B_28_0; + polys.poseidon2_B_28_1[i] = rows[i].poseidon2_B_28_1; + polys.poseidon2_B_28_2[i] = rows[i].poseidon2_B_28_2; + polys.poseidon2_B_28_3[i] = rows[i].poseidon2_B_28_3; + polys.poseidon2_B_29_0[i] = rows[i].poseidon2_B_29_0; + polys.poseidon2_B_29_1[i] = rows[i].poseidon2_B_29_1; + polys.poseidon2_B_29_2[i] = rows[i].poseidon2_B_29_2; + polys.poseidon2_B_29_3[i] = rows[i].poseidon2_B_29_3; + polys.poseidon2_B_30_0[i] = rows[i].poseidon2_B_30_0; + polys.poseidon2_B_30_1[i] = rows[i].poseidon2_B_30_1; + polys.poseidon2_B_30_2[i] = rows[i].poseidon2_B_30_2; + polys.poseidon2_B_30_3[i] = rows[i].poseidon2_B_30_3; + polys.poseidon2_B_31_0[i] = rows[i].poseidon2_B_31_0; + polys.poseidon2_B_31_1[i] = rows[i].poseidon2_B_31_1; + polys.poseidon2_B_31_2[i] = rows[i].poseidon2_B_31_2; + polys.poseidon2_B_31_3[i] = rows[i].poseidon2_B_31_3; + polys.poseidon2_B_32_0[i] = rows[i].poseidon2_B_32_0; + polys.poseidon2_B_32_1[i] = rows[i].poseidon2_B_32_1; + polys.poseidon2_B_32_2[i] = rows[i].poseidon2_B_32_2; + polys.poseidon2_B_32_3[i] = rows[i].poseidon2_B_32_3; + polys.poseidon2_B_33_0[i] = rows[i].poseidon2_B_33_0; + polys.poseidon2_B_33_1[i] = rows[i].poseidon2_B_33_1; + polys.poseidon2_B_33_2[i] = rows[i].poseidon2_B_33_2; + polys.poseidon2_B_33_3[i] = rows[i].poseidon2_B_33_3; + polys.poseidon2_B_34_0[i] = rows[i].poseidon2_B_34_0; + polys.poseidon2_B_34_1[i] = rows[i].poseidon2_B_34_1; + polys.poseidon2_B_34_2[i] = rows[i].poseidon2_B_34_2; + polys.poseidon2_B_34_3[i] = rows[i].poseidon2_B_34_3; + polys.poseidon2_B_35_0[i] = rows[i].poseidon2_B_35_0; + polys.poseidon2_B_35_1[i] = rows[i].poseidon2_B_35_1; + polys.poseidon2_B_35_2[i] = rows[i].poseidon2_B_35_2; + polys.poseidon2_B_35_3[i] = rows[i].poseidon2_B_35_3; + polys.poseidon2_B_36_0[i] = rows[i].poseidon2_B_36_0; + polys.poseidon2_B_36_1[i] = rows[i].poseidon2_B_36_1; + polys.poseidon2_B_36_2[i] = rows[i].poseidon2_B_36_2; + polys.poseidon2_B_36_3[i] = rows[i].poseidon2_B_36_3; + polys.poseidon2_B_37_0[i] = rows[i].poseidon2_B_37_0; + polys.poseidon2_B_37_1[i] = rows[i].poseidon2_B_37_1; + polys.poseidon2_B_37_2[i] = rows[i].poseidon2_B_37_2; + polys.poseidon2_B_37_3[i] = rows[i].poseidon2_B_37_3; + polys.poseidon2_B_38_0[i] = rows[i].poseidon2_B_38_0; + polys.poseidon2_B_38_1[i] = rows[i].poseidon2_B_38_1; + polys.poseidon2_B_38_2[i] = rows[i].poseidon2_B_38_2; + polys.poseidon2_B_38_3[i] = rows[i].poseidon2_B_38_3; + polys.poseidon2_B_39_0[i] = rows[i].poseidon2_B_39_0; + polys.poseidon2_B_39_1[i] = rows[i].poseidon2_B_39_1; + polys.poseidon2_B_39_2[i] = rows[i].poseidon2_B_39_2; + polys.poseidon2_B_39_3[i] = rows[i].poseidon2_B_39_3; + polys.poseidon2_B_40_0[i] = rows[i].poseidon2_B_40_0; + polys.poseidon2_B_40_1[i] = rows[i].poseidon2_B_40_1; + polys.poseidon2_B_40_2[i] = rows[i].poseidon2_B_40_2; + polys.poseidon2_B_40_3[i] = rows[i].poseidon2_B_40_3; + polys.poseidon2_B_41_0[i] = rows[i].poseidon2_B_41_0; + polys.poseidon2_B_41_1[i] = rows[i].poseidon2_B_41_1; + polys.poseidon2_B_41_2[i] = rows[i].poseidon2_B_41_2; + polys.poseidon2_B_41_3[i] = rows[i].poseidon2_B_41_3; + polys.poseidon2_B_42_0[i] = rows[i].poseidon2_B_42_0; + polys.poseidon2_B_42_1[i] = rows[i].poseidon2_B_42_1; + polys.poseidon2_B_42_2[i] = rows[i].poseidon2_B_42_2; + polys.poseidon2_B_42_3[i] = rows[i].poseidon2_B_42_3; + polys.poseidon2_B_43_0[i] = rows[i].poseidon2_B_43_0; + polys.poseidon2_B_43_1[i] = rows[i].poseidon2_B_43_1; + polys.poseidon2_B_43_2[i] = rows[i].poseidon2_B_43_2; + polys.poseidon2_B_43_3[i] = rows[i].poseidon2_B_43_3; + polys.poseidon2_B_44_0[i] = rows[i].poseidon2_B_44_0; + polys.poseidon2_B_44_1[i] = rows[i].poseidon2_B_44_1; + polys.poseidon2_B_44_2[i] = rows[i].poseidon2_B_44_2; + polys.poseidon2_B_44_3[i] = rows[i].poseidon2_B_44_3; + polys.poseidon2_B_45_0[i] = rows[i].poseidon2_B_45_0; + polys.poseidon2_B_45_1[i] = rows[i].poseidon2_B_45_1; + polys.poseidon2_B_45_2[i] = rows[i].poseidon2_B_45_2; + polys.poseidon2_B_45_3[i] = rows[i].poseidon2_B_45_3; + polys.poseidon2_B_46_0[i] = rows[i].poseidon2_B_46_0; + polys.poseidon2_B_46_1[i] = rows[i].poseidon2_B_46_1; + polys.poseidon2_B_46_2[i] = rows[i].poseidon2_B_46_2; + polys.poseidon2_B_46_3[i] = rows[i].poseidon2_B_46_3; + polys.poseidon2_B_47_0[i] = rows[i].poseidon2_B_47_0; + polys.poseidon2_B_47_1[i] = rows[i].poseidon2_B_47_1; + polys.poseidon2_B_47_2[i] = rows[i].poseidon2_B_47_2; + polys.poseidon2_B_47_3[i] = rows[i].poseidon2_B_47_3; + polys.poseidon2_B_48_0[i] = rows[i].poseidon2_B_48_0; + polys.poseidon2_B_48_1[i] = rows[i].poseidon2_B_48_1; + polys.poseidon2_B_48_2[i] = rows[i].poseidon2_B_48_2; + polys.poseidon2_B_48_3[i] = rows[i].poseidon2_B_48_3; + polys.poseidon2_B_49_0[i] = rows[i].poseidon2_B_49_0; + polys.poseidon2_B_49_1[i] = rows[i].poseidon2_B_49_1; + polys.poseidon2_B_49_2[i] = rows[i].poseidon2_B_49_2; + polys.poseidon2_B_49_3[i] = rows[i].poseidon2_B_49_3; + polys.poseidon2_B_4_0[i] = rows[i].poseidon2_B_4_0; + polys.poseidon2_B_4_1[i] = rows[i].poseidon2_B_4_1; + polys.poseidon2_B_4_2[i] = rows[i].poseidon2_B_4_2; + polys.poseidon2_B_4_3[i] = rows[i].poseidon2_B_4_3; + polys.poseidon2_B_50_0[i] = rows[i].poseidon2_B_50_0; + polys.poseidon2_B_50_1[i] = rows[i].poseidon2_B_50_1; + polys.poseidon2_B_50_2[i] = rows[i].poseidon2_B_50_2; + polys.poseidon2_B_50_3[i] = rows[i].poseidon2_B_50_3; + polys.poseidon2_B_51_0[i] = rows[i].poseidon2_B_51_0; + polys.poseidon2_B_51_1[i] = rows[i].poseidon2_B_51_1; + polys.poseidon2_B_51_2[i] = rows[i].poseidon2_B_51_2; + polys.poseidon2_B_51_3[i] = rows[i].poseidon2_B_51_3; + polys.poseidon2_B_52_0[i] = rows[i].poseidon2_B_52_0; + polys.poseidon2_B_52_1[i] = rows[i].poseidon2_B_52_1; + polys.poseidon2_B_52_2[i] = rows[i].poseidon2_B_52_2; + polys.poseidon2_B_52_3[i] = rows[i].poseidon2_B_52_3; + polys.poseidon2_B_53_0[i] = rows[i].poseidon2_B_53_0; + polys.poseidon2_B_53_1[i] = rows[i].poseidon2_B_53_1; + polys.poseidon2_B_53_2[i] = rows[i].poseidon2_B_53_2; + polys.poseidon2_B_53_3[i] = rows[i].poseidon2_B_53_3; + polys.poseidon2_B_54_0[i] = rows[i].poseidon2_B_54_0; + polys.poseidon2_B_54_1[i] = rows[i].poseidon2_B_54_1; + polys.poseidon2_B_54_2[i] = rows[i].poseidon2_B_54_2; + polys.poseidon2_B_54_3[i] = rows[i].poseidon2_B_54_3; + polys.poseidon2_B_55_0[i] = rows[i].poseidon2_B_55_0; + polys.poseidon2_B_55_1[i] = rows[i].poseidon2_B_55_1; + polys.poseidon2_B_55_2[i] = rows[i].poseidon2_B_55_2; + polys.poseidon2_B_55_3[i] = rows[i].poseidon2_B_55_3; + polys.poseidon2_B_56_0[i] = rows[i].poseidon2_B_56_0; + polys.poseidon2_B_56_1[i] = rows[i].poseidon2_B_56_1; + polys.poseidon2_B_56_2[i] = rows[i].poseidon2_B_56_2; + polys.poseidon2_B_56_3[i] = rows[i].poseidon2_B_56_3; + polys.poseidon2_B_57_0[i] = rows[i].poseidon2_B_57_0; + polys.poseidon2_B_57_1[i] = rows[i].poseidon2_B_57_1; + polys.poseidon2_B_57_2[i] = rows[i].poseidon2_B_57_2; + polys.poseidon2_B_57_3[i] = rows[i].poseidon2_B_57_3; + polys.poseidon2_B_58_0[i] = rows[i].poseidon2_B_58_0; + polys.poseidon2_B_58_1[i] = rows[i].poseidon2_B_58_1; + polys.poseidon2_B_58_2[i] = rows[i].poseidon2_B_58_2; + polys.poseidon2_B_58_3[i] = rows[i].poseidon2_B_58_3; + polys.poseidon2_B_59_0[i] = rows[i].poseidon2_B_59_0; + polys.poseidon2_B_59_1[i] = rows[i].poseidon2_B_59_1; + polys.poseidon2_B_59_2[i] = rows[i].poseidon2_B_59_2; + polys.poseidon2_B_59_3[i] = rows[i].poseidon2_B_59_3; + polys.poseidon2_B_5_0[i] = rows[i].poseidon2_B_5_0; + polys.poseidon2_B_5_1[i] = rows[i].poseidon2_B_5_1; + polys.poseidon2_B_5_2[i] = rows[i].poseidon2_B_5_2; + polys.poseidon2_B_5_3[i] = rows[i].poseidon2_B_5_3; + polys.poseidon2_B_6_0[i] = rows[i].poseidon2_B_6_0; + polys.poseidon2_B_6_1[i] = rows[i].poseidon2_B_6_1; + polys.poseidon2_B_6_2[i] = rows[i].poseidon2_B_6_2; + polys.poseidon2_B_6_3[i] = rows[i].poseidon2_B_6_3; + polys.poseidon2_B_7_0[i] = rows[i].poseidon2_B_7_0; + polys.poseidon2_B_7_1[i] = rows[i].poseidon2_B_7_1; + polys.poseidon2_B_7_2[i] = rows[i].poseidon2_B_7_2; + polys.poseidon2_B_7_3[i] = rows[i].poseidon2_B_7_3; + polys.poseidon2_B_8_0[i] = rows[i].poseidon2_B_8_0; + polys.poseidon2_B_8_1[i] = rows[i].poseidon2_B_8_1; + polys.poseidon2_B_8_2[i] = rows[i].poseidon2_B_8_2; + polys.poseidon2_B_8_3[i] = rows[i].poseidon2_B_8_3; + polys.poseidon2_B_9_0[i] = rows[i].poseidon2_B_9_0; + polys.poseidon2_B_9_1[i] = rows[i].poseidon2_B_9_1; + polys.poseidon2_B_9_2[i] = rows[i].poseidon2_B_9_2; + polys.poseidon2_B_9_3[i] = rows[i].poseidon2_B_9_3; + polys.poseidon2_EXT_LAYER_4[i] = rows[i].poseidon2_EXT_LAYER_4; + polys.poseidon2_EXT_LAYER_5[i] = rows[i].poseidon2_EXT_LAYER_5; + polys.poseidon2_EXT_LAYER_6[i] = rows[i].poseidon2_EXT_LAYER_6; + polys.poseidon2_EXT_LAYER_7[i] = rows[i].poseidon2_EXT_LAYER_7; + polys.poseidon2_T_0_4[i] = rows[i].poseidon2_T_0_4; + polys.poseidon2_T_0_5[i] = rows[i].poseidon2_T_0_5; + polys.poseidon2_T_0_6[i] = rows[i].poseidon2_T_0_6; + polys.poseidon2_T_0_7[i] = rows[i].poseidon2_T_0_7; + polys.poseidon2_T_1_4[i] = rows[i].poseidon2_T_1_4; + polys.poseidon2_T_1_5[i] = rows[i].poseidon2_T_1_5; + polys.poseidon2_T_1_6[i] = rows[i].poseidon2_T_1_6; + polys.poseidon2_T_1_7[i] = rows[i].poseidon2_T_1_7; + polys.poseidon2_T_2_4[i] = rows[i].poseidon2_T_2_4; + polys.poseidon2_T_2_5[i] = rows[i].poseidon2_T_2_5; + polys.poseidon2_T_2_6[i] = rows[i].poseidon2_T_2_6; + polys.poseidon2_T_2_7[i] = rows[i].poseidon2_T_2_7; + polys.poseidon2_T_3_4[i] = rows[i].poseidon2_T_3_4; + polys.poseidon2_T_3_5[i] = rows[i].poseidon2_T_3_5; + polys.poseidon2_T_3_6[i] = rows[i].poseidon2_T_3_6; + polys.poseidon2_T_3_7[i] = rows[i].poseidon2_T_3_7; + polys.poseidon2_T_60_4[i] = rows[i].poseidon2_T_60_4; + polys.poseidon2_T_60_5[i] = rows[i].poseidon2_T_60_5; + polys.poseidon2_T_60_6[i] = rows[i].poseidon2_T_60_6; + polys.poseidon2_T_60_7[i] = rows[i].poseidon2_T_60_7; + polys.poseidon2_T_61_4[i] = rows[i].poseidon2_T_61_4; + polys.poseidon2_T_61_5[i] = rows[i].poseidon2_T_61_5; + polys.poseidon2_T_61_6[i] = rows[i].poseidon2_T_61_6; + polys.poseidon2_T_61_7[i] = rows[i].poseidon2_T_61_7; + polys.poseidon2_T_62_4[i] = rows[i].poseidon2_T_62_4; + polys.poseidon2_T_62_5[i] = rows[i].poseidon2_T_62_5; + polys.poseidon2_T_62_6[i] = rows[i].poseidon2_T_62_6; + polys.poseidon2_T_62_7[i] = rows[i].poseidon2_T_62_7; + polys.poseidon2_T_63_4[i] = rows[i].poseidon2_T_63_4; + polys.poseidon2_T_63_5[i] = rows[i].poseidon2_T_63_5; + polys.poseidon2_T_63_6[i] = rows[i].poseidon2_T_63_6; + polys.poseidon2_T_63_7[i] = rows[i].poseidon2_T_63_7; polys.poseidon2_a_0[i] = rows[i].poseidon2_a_0; polys.poseidon2_a_1[i] = rows[i].poseidon2_a_1; polys.poseidon2_a_2[i] = rows[i].poseidon2_a_2; @@ -769,9 +608,17 @@ class AvmCircuitBuilder { polys.poseidon2_b_2[i] = rows[i].poseidon2_b_2; polys.poseidon2_b_3[i] = rows[i].poseidon2_b_3; polys.poseidon2_clk[i] = rows[i].poseidon2_clk; - polys.poseidon2_input[i] = rows[i].poseidon2_input; - polys.poseidon2_output[i] = rows[i].poseidon2_output; + polys.poseidon2_in_tag[i] = rows[i].poseidon2_in_tag; + polys.poseidon2_input_addr[i] = rows[i].poseidon2_input_addr; + polys.poseidon2_mem_addr_a[i] = rows[i].poseidon2_mem_addr_a; + polys.poseidon2_mem_addr_b[i] = rows[i].poseidon2_mem_addr_b; + polys.poseidon2_mem_addr_c[i] = rows[i].poseidon2_mem_addr_c; + polys.poseidon2_mem_addr_d[i] = rows[i].poseidon2_mem_addr_d; + polys.poseidon2_mem_op[i] = rows[i].poseidon2_mem_op; + polys.poseidon2_output_addr[i] = rows[i].poseidon2_output_addr; + polys.poseidon2_read_line[i] = rows[i].poseidon2_read_line; polys.poseidon2_sel_poseidon_perm[i] = rows[i].poseidon2_sel_poseidon_perm; + polys.poseidon2_write_line[i] = rows[i].poseidon2_write_line; polys.powers_power_of_2[i] = rows[i].powers_power_of_2; polys.sha256_clk[i] = rows[i].sha256_clk; polys.sha256_input[i] = rows[i].sha256_input; diff --git a/barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp b/barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp index 9d19571b59b8..a27ec015c004 100644 --- a/barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp @@ -83,6 +83,10 @@ #include "barretenberg/relations/generated/avm/perm_main_pedersen.hpp" #include "barretenberg/relations/generated/avm/perm_main_pos2_perm.hpp" #include "barretenberg/relations/generated/avm/perm_main_slice.hpp" +#include "barretenberg/relations/generated/avm/perm_pos_mem_a.hpp" +#include "barretenberg/relations/generated/avm/perm_pos_mem_b.hpp" +#include "barretenberg/relations/generated/avm/perm_pos_mem_c.hpp" +#include "barretenberg/relations/generated/avm/perm_pos_mem_d.hpp" #include "barretenberg/relations/generated/avm/perm_slice_mem.hpp" #include "barretenberg/relations/generated/avm/range_check_da_gas_hi.hpp" #include "barretenberg/relations/generated/avm/range_check_da_gas_lo.hpp" @@ -95,10 +99,10 @@ template using tuple_cat_t = decltype(std::tuple_cat(std:: // The entities that will be used in the flavor. // clang-format off #define PRECOMPUTED_ENTITIES main_clk, main_sel_first -#define WIRE_ENTITIES kernel_kernel_inputs, kernel_kernel_value_out, kernel_kernel_side_effect_out, kernel_kernel_metadata_out, main_calldata, main_returndata, alu_a_hi, alu_a_lo, alu_b_hi, alu_b_lo, alu_borrow, alu_cf, alu_clk, alu_cmp_rng_ctr, alu_div_u16_r0, alu_div_u16_r1, alu_div_u16_r2, alu_div_u16_r3, alu_div_u16_r4, alu_div_u16_r5, alu_div_u16_r6, alu_div_u16_r7, alu_divisor_hi, alu_divisor_lo, alu_ff_tag, alu_ia, alu_ib, alu_ic, alu_in_tag, alu_op_add, alu_op_cast, alu_op_cast_prev, alu_op_div, alu_op_div_a_lt_b, alu_op_div_std, alu_op_eq, alu_op_eq_diff_inv, alu_op_lt, alu_op_lte, alu_op_mul, alu_op_not, alu_op_shl, alu_op_shr, alu_op_sub, alu_p_a_borrow, alu_p_b_borrow, alu_p_sub_a_hi, alu_p_sub_a_lo, alu_p_sub_b_hi, alu_p_sub_b_lo, alu_partial_prod_hi, alu_partial_prod_lo, alu_quotient_hi, alu_quotient_lo, alu_remainder, alu_res_hi, alu_res_lo, alu_sel_alu, alu_sel_cmp, alu_sel_div_rng_chk, alu_sel_rng_chk, alu_sel_rng_chk_lookup, alu_sel_shift_which, alu_shift_lt_bit_len, alu_t_sub_s_bits, alu_two_pow_s, alu_two_pow_t_sub_s, alu_u128_tag, alu_u16_r0, alu_u16_r1, alu_u16_r10, alu_u16_r11, alu_u16_r12, alu_u16_r13, alu_u16_r14, alu_u16_r2, alu_u16_r3, alu_u16_r4, alu_u16_r5, alu_u16_r6, alu_u16_r7, alu_u16_r8, alu_u16_r9, alu_u16_tag, alu_u32_tag, alu_u64_tag, alu_u8_r0, alu_u8_r1, alu_u8_tag, binary_acc_ia, binary_acc_ib, binary_acc_ic, binary_clk, binary_ia_bytes, binary_ib_bytes, binary_ic_bytes, binary_in_tag, binary_mem_tag_ctr, binary_mem_tag_ctr_inv, binary_op_id, binary_sel_bin, binary_start, byte_lookup_sel_bin, byte_lookup_table_byte_lengths, byte_lookup_table_in_tags, byte_lookup_table_input_a, byte_lookup_table_input_b, byte_lookup_table_op_id, byte_lookup_table_output, conversion_clk, conversion_input, conversion_num_limbs, conversion_radix, conversion_sel_to_radix_le, gas_da_gas_fixed_table, gas_l2_gas_fixed_table, gas_sel_gas_cost, keccakf1600_clk, keccakf1600_input, keccakf1600_output, keccakf1600_sel_keccakf1600, kernel_emit_l2_to_l1_msg_write_offset, kernel_emit_note_hash_write_offset, kernel_emit_nullifier_write_offset, kernel_emit_unencrypted_log_write_offset, kernel_kernel_in_offset, kernel_kernel_out_offset, kernel_l1_to_l2_msg_exists_write_offset, kernel_note_hash_exist_write_offset, kernel_nullifier_exists_write_offset, kernel_nullifier_non_exists_write_offset, kernel_q_public_input_kernel_add_to_table, kernel_q_public_input_kernel_out_add_to_table, kernel_side_effect_counter, kernel_sload_write_offset, kernel_sstore_write_offset, main_abs_da_rem_gas_hi, main_abs_da_rem_gas_lo, main_abs_l2_rem_gas_hi, main_abs_l2_rem_gas_lo, main_alu_in_tag, main_bin_op_id, main_call_ptr, main_da_gas_op_cost, main_da_gas_remaining, main_da_out_of_gas, main_ia, main_ib, main_ic, main_id, main_id_zero, main_ind_addr_a, main_ind_addr_b, main_ind_addr_c, main_ind_addr_d, main_internal_return_ptr, main_inv, main_l2_gas_op_cost, main_l2_gas_remaining, main_l2_out_of_gas, main_mem_addr_a, main_mem_addr_b, main_mem_addr_c, main_mem_addr_d, main_op_err, main_opcode_val, main_pc, main_r_in_tag, main_rwa, main_rwb, main_rwc, main_rwd, main_sel_alu, main_sel_bin, main_sel_calldata, main_sel_gas_accounting_active, main_sel_last, main_sel_mem_op_a, main_sel_mem_op_activate_gas, main_sel_mem_op_b, main_sel_mem_op_c, main_sel_mem_op_d, main_sel_mov_ia_to_ic, main_sel_mov_ib_to_ic, main_sel_op_add, main_sel_op_address, main_sel_op_and, main_sel_op_block_number, main_sel_op_calldata_copy, main_sel_op_cast, main_sel_op_chain_id, main_sel_op_cmov, main_sel_op_coinbase, main_sel_op_dagasleft, main_sel_op_div, main_sel_op_emit_l2_to_l1_msg, main_sel_op_emit_note_hash, main_sel_op_emit_nullifier, main_sel_op_emit_unencrypted_log, main_sel_op_eq, main_sel_op_external_call, main_sel_op_external_return, main_sel_op_fdiv, main_sel_op_fee_per_da_gas, main_sel_op_fee_per_l2_gas, main_sel_op_function_selector, main_sel_op_get_contract_instance, main_sel_op_halt, main_sel_op_internal_call, main_sel_op_internal_return, main_sel_op_jump, main_sel_op_jumpi, main_sel_op_keccak, main_sel_op_l1_to_l2_msg_exists, main_sel_op_l2gasleft, main_sel_op_lt, main_sel_op_lte, main_sel_op_mov, main_sel_op_mul, main_sel_op_not, main_sel_op_note_hash_exists, main_sel_op_nullifier_exists, main_sel_op_or, main_sel_op_pedersen, main_sel_op_poseidon2, main_sel_op_radix_le, main_sel_op_sender, main_sel_op_sha256, main_sel_op_shl, main_sel_op_shr, main_sel_op_sload, main_sel_op_sstore, main_sel_op_storage_address, main_sel_op_sub, main_sel_op_timestamp, main_sel_op_transaction_fee, main_sel_op_version, main_sel_op_xor, main_sel_q_kernel_lookup, main_sel_q_kernel_output_lookup, main_sel_resolve_ind_addr_a, main_sel_resolve_ind_addr_b, main_sel_resolve_ind_addr_c, main_sel_resolve_ind_addr_d, main_sel_returndata, main_sel_rng_16, main_sel_rng_8, main_sel_slice_gadget, main_space_id, main_tag_err, main_w_in_tag, mem_addr, mem_clk, mem_diff_hi, mem_diff_lo, mem_diff_mid, mem_glob_addr, mem_last, mem_lastAccess, mem_one_min_inv, mem_r_in_tag, mem_rw, mem_sel_mem, mem_sel_mov_ia_to_ic, mem_sel_mov_ib_to_ic, mem_sel_op_a, mem_sel_op_b, mem_sel_op_c, mem_sel_op_cmov, mem_sel_op_d, mem_sel_op_slice, mem_sel_resolve_ind_addr_a, mem_sel_resolve_ind_addr_b, mem_sel_resolve_ind_addr_c, mem_sel_resolve_ind_addr_d, mem_sel_rng_chk, mem_skip_check_tag, mem_space_id, mem_tag, mem_tag_err, mem_tsp, mem_val, mem_w_in_tag, pedersen_clk, pedersen_input, pedersen_output, pedersen_sel_pedersen, poseidon2_clk, poseidon2_input, poseidon2_output, poseidon2_sel_poseidon_perm, powers_power_of_2, sha256_clk, sha256_input, sha256_output, sha256_sel_sha256_compression, sha256_state, slice_addr, slice_clk, slice_cnt, slice_col_offset, slice_one_min_inv, slice_sel_cd_cpy, slice_sel_mem_active, slice_sel_return, slice_sel_start, slice_space_id, slice_val, lookup_byte_lengths_counts, lookup_byte_operations_counts, lookup_cd_value_counts, lookup_ret_value_counts, lookup_opcode_gas_counts, range_check_l2_gas_hi_counts, range_check_l2_gas_lo_counts, range_check_da_gas_hi_counts, range_check_da_gas_lo_counts, kernel_output_lookup_counts, lookup_into_kernel_counts, incl_main_tag_err_counts, incl_mem_tag_err_counts, lookup_mem_rng_chk_lo_counts, lookup_mem_rng_chk_mid_counts, lookup_mem_rng_chk_hi_counts, lookup_pow_2_0_counts, lookup_pow_2_1_counts, lookup_u8_0_counts, lookup_u8_1_counts, lookup_u16_0_counts, lookup_u16_1_counts, lookup_u16_2_counts, lookup_u16_3_counts, lookup_u16_4_counts, lookup_u16_5_counts, lookup_u16_6_counts, lookup_u16_7_counts, lookup_u16_8_counts, lookup_u16_9_counts, lookup_u16_10_counts, lookup_u16_11_counts, lookup_u16_12_counts, lookup_u16_13_counts, lookup_u16_14_counts, lookup_div_u16_0_counts, lookup_div_u16_1_counts, lookup_div_u16_2_counts, lookup_div_u16_3_counts, lookup_div_u16_4_counts, lookup_div_u16_5_counts, lookup_div_u16_6_counts, lookup_div_u16_7_counts -#define DERIVED_WITNESS_ENTITIES perm_slice_mem, perm_main_alu, perm_main_bin, perm_main_conv, perm_main_pos2_perm, perm_main_pedersen, perm_main_slice, perm_main_mem_a, perm_main_mem_b, perm_main_mem_c, perm_main_mem_d, perm_main_mem_ind_addr_a, perm_main_mem_ind_addr_b, perm_main_mem_ind_addr_c, perm_main_mem_ind_addr_d, lookup_byte_lengths, lookup_byte_operations, lookup_cd_value, lookup_ret_value, lookup_opcode_gas, range_check_l2_gas_hi, range_check_l2_gas_lo, range_check_da_gas_hi, range_check_da_gas_lo, kernel_output_lookup, lookup_into_kernel, incl_main_tag_err, incl_mem_tag_err, lookup_mem_rng_chk_lo, lookup_mem_rng_chk_mid, lookup_mem_rng_chk_hi, lookup_pow_2_0, lookup_pow_2_1, lookup_u8_0, lookup_u8_1, lookup_u16_0, lookup_u16_1, lookup_u16_2, lookup_u16_3, lookup_u16_4, lookup_u16_5, lookup_u16_6, lookup_u16_7, lookup_u16_8, lookup_u16_9, lookup_u16_10, lookup_u16_11, lookup_u16_12, lookup_u16_13, lookup_u16_14, lookup_div_u16_0, lookup_div_u16_1, lookup_div_u16_2, lookup_div_u16_3, lookup_div_u16_4, lookup_div_u16_5, lookup_div_u16_6, lookup_div_u16_7 -#define SHIFTED_ENTITIES alu_a_hi_shift, alu_a_lo_shift, alu_b_hi_shift, alu_b_lo_shift, alu_cmp_rng_ctr_shift, alu_div_u16_r0_shift, alu_div_u16_r1_shift, alu_div_u16_r2_shift, alu_div_u16_r3_shift, alu_div_u16_r4_shift, alu_div_u16_r5_shift, alu_div_u16_r6_shift, alu_div_u16_r7_shift, alu_op_add_shift, alu_op_cast_prev_shift, alu_op_cast_shift, alu_op_div_shift, alu_op_mul_shift, alu_op_shl_shift, alu_op_shr_shift, alu_op_sub_shift, alu_p_sub_a_hi_shift, alu_p_sub_a_lo_shift, alu_p_sub_b_hi_shift, alu_p_sub_b_lo_shift, alu_sel_alu_shift, alu_sel_cmp_shift, alu_sel_div_rng_chk_shift, alu_sel_rng_chk_lookup_shift, alu_sel_rng_chk_shift, alu_u16_r0_shift, alu_u16_r1_shift, alu_u16_r2_shift, alu_u16_r3_shift, alu_u16_r4_shift, alu_u16_r5_shift, alu_u16_r6_shift, alu_u8_r0_shift, alu_u8_r1_shift, binary_acc_ia_shift, binary_acc_ib_shift, binary_acc_ic_shift, binary_mem_tag_ctr_shift, binary_op_id_shift, kernel_emit_l2_to_l1_msg_write_offset_shift, kernel_emit_note_hash_write_offset_shift, kernel_emit_nullifier_write_offset_shift, kernel_emit_unencrypted_log_write_offset_shift, kernel_l1_to_l2_msg_exists_write_offset_shift, kernel_note_hash_exist_write_offset_shift, kernel_nullifier_exists_write_offset_shift, kernel_nullifier_non_exists_write_offset_shift, kernel_side_effect_counter_shift, kernel_sload_write_offset_shift, kernel_sstore_write_offset_shift, main_da_gas_remaining_shift, main_internal_return_ptr_shift, main_l2_gas_remaining_shift, main_pc_shift, mem_glob_addr_shift, mem_rw_shift, mem_sel_mem_shift, mem_tag_shift, mem_tsp_shift, mem_val_shift, slice_addr_shift, slice_clk_shift, slice_cnt_shift, slice_col_offset_shift, slice_sel_cd_cpy_shift, slice_sel_mem_active_shift, slice_sel_return_shift, slice_sel_start_shift, slice_space_id_shift -#define TO_BE_SHIFTED(e) e.alu_a_hi, e.alu_a_lo, e.alu_b_hi, e.alu_b_lo, e.alu_cmp_rng_ctr, e.alu_div_u16_r0, e.alu_div_u16_r1, e.alu_div_u16_r2, e.alu_div_u16_r3, e.alu_div_u16_r4, e.alu_div_u16_r5, e.alu_div_u16_r6, e.alu_div_u16_r7, e.alu_op_add, e.alu_op_cast_prev, e.alu_op_cast, e.alu_op_div, e.alu_op_mul, e.alu_op_shl, e.alu_op_shr, e.alu_op_sub, e.alu_p_sub_a_hi, e.alu_p_sub_a_lo, e.alu_p_sub_b_hi, e.alu_p_sub_b_lo, e.alu_sel_alu, e.alu_sel_cmp, e.alu_sel_div_rng_chk, e.alu_sel_rng_chk_lookup, e.alu_sel_rng_chk, e.alu_u16_r0, e.alu_u16_r1, e.alu_u16_r2, e.alu_u16_r3, e.alu_u16_r4, e.alu_u16_r5, e.alu_u16_r6, e.alu_u8_r0, e.alu_u8_r1, e.binary_acc_ia, e.binary_acc_ib, e.binary_acc_ic, e.binary_mem_tag_ctr, e.binary_op_id, e.kernel_emit_l2_to_l1_msg_write_offset, e.kernel_emit_note_hash_write_offset, e.kernel_emit_nullifier_write_offset, e.kernel_emit_unencrypted_log_write_offset, e.kernel_l1_to_l2_msg_exists_write_offset, e.kernel_note_hash_exist_write_offset, e.kernel_nullifier_exists_write_offset, e.kernel_nullifier_non_exists_write_offset, e.kernel_side_effect_counter, e.kernel_sload_write_offset, e.kernel_sstore_write_offset, e.main_da_gas_remaining, e.main_internal_return_ptr, e.main_l2_gas_remaining, e.main_pc, e.mem_glob_addr, e.mem_rw, e.mem_sel_mem, e.mem_tag, e.mem_tsp, e.mem_val, e.slice_addr, e.slice_clk, e.slice_cnt, e.slice_col_offset, e.slice_sel_cd_cpy, e.slice_sel_mem_active, e.slice_sel_return, e.slice_sel_start, e.slice_space_id +#define WIRE_ENTITIES kernel_kernel_inputs, kernel_kernel_value_out, kernel_kernel_side_effect_out, kernel_kernel_metadata_out, main_calldata, main_returndata, alu_a_hi, alu_a_lo, alu_b_hi, alu_b_lo, alu_borrow, alu_cf, alu_clk, alu_cmp_rng_ctr, alu_div_u16_r0, alu_div_u16_r1, alu_div_u16_r2, alu_div_u16_r3, alu_div_u16_r4, alu_div_u16_r5, alu_div_u16_r6, alu_div_u16_r7, alu_divisor_hi, alu_divisor_lo, alu_ff_tag, alu_ia, alu_ib, alu_ic, alu_in_tag, alu_op_add, alu_op_cast, alu_op_cast_prev, alu_op_div, alu_op_div_a_lt_b, alu_op_div_std, alu_op_eq, alu_op_eq_diff_inv, alu_op_lt, alu_op_lte, alu_op_mul, alu_op_not, alu_op_shl, alu_op_shr, alu_op_sub, alu_p_a_borrow, alu_p_b_borrow, alu_p_sub_a_hi, alu_p_sub_a_lo, alu_p_sub_b_hi, alu_p_sub_b_lo, alu_partial_prod_hi, alu_partial_prod_lo, alu_quotient_hi, alu_quotient_lo, alu_remainder, alu_res_hi, alu_res_lo, alu_sel_alu, alu_sel_cmp, alu_sel_div_rng_chk, alu_sel_rng_chk, alu_sel_rng_chk_lookup, alu_sel_shift_which, alu_shift_lt_bit_len, alu_t_sub_s_bits, alu_two_pow_s, alu_two_pow_t_sub_s, alu_u128_tag, alu_u16_r0, alu_u16_r1, alu_u16_r10, alu_u16_r11, alu_u16_r12, alu_u16_r13, alu_u16_r14, alu_u16_r2, alu_u16_r3, alu_u16_r4, alu_u16_r5, alu_u16_r6, alu_u16_r7, alu_u16_r8, alu_u16_r9, alu_u16_tag, alu_u32_tag, alu_u64_tag, alu_u8_r0, alu_u8_r1, alu_u8_tag, binary_acc_ia, binary_acc_ib, binary_acc_ic, binary_clk, binary_ia_bytes, binary_ib_bytes, binary_ic_bytes, binary_in_tag, binary_mem_tag_ctr, binary_mem_tag_ctr_inv, binary_op_id, binary_sel_bin, binary_start, byte_lookup_sel_bin, byte_lookup_table_byte_lengths, byte_lookup_table_in_tags, byte_lookup_table_input_a, byte_lookup_table_input_b, byte_lookup_table_op_id, byte_lookup_table_output, conversion_clk, conversion_input, conversion_num_limbs, conversion_radix, conversion_sel_to_radix_le, gas_da_gas_fixed_table, gas_l2_gas_fixed_table, gas_sel_gas_cost, keccakf1600_clk, keccakf1600_input, keccakf1600_output, keccakf1600_sel_keccakf1600, kernel_emit_l2_to_l1_msg_write_offset, kernel_emit_note_hash_write_offset, kernel_emit_nullifier_write_offset, kernel_emit_unencrypted_log_write_offset, kernel_kernel_in_offset, kernel_kernel_out_offset, kernel_l1_to_l2_msg_exists_write_offset, kernel_note_hash_exist_write_offset, kernel_nullifier_exists_write_offset, kernel_nullifier_non_exists_write_offset, kernel_q_public_input_kernel_add_to_table, kernel_q_public_input_kernel_out_add_to_table, kernel_side_effect_counter, kernel_sload_write_offset, kernel_sstore_write_offset, main_abs_da_rem_gas_hi, main_abs_da_rem_gas_lo, main_abs_l2_rem_gas_hi, main_abs_l2_rem_gas_lo, main_alu_in_tag, main_bin_op_id, main_call_ptr, main_da_gas_op_cost, main_da_gas_remaining, main_da_out_of_gas, main_ia, main_ib, main_ic, main_id, main_id_zero, main_ind_addr_a, main_ind_addr_b, main_ind_addr_c, main_ind_addr_d, main_internal_return_ptr, main_inv, main_l2_gas_op_cost, main_l2_gas_remaining, main_l2_out_of_gas, main_mem_addr_a, main_mem_addr_b, main_mem_addr_c, main_mem_addr_d, main_op_err, main_opcode_val, main_pc, main_r_in_tag, main_rwa, main_rwb, main_rwc, main_rwd, main_sel_alu, main_sel_bin, main_sel_calldata, main_sel_gas_accounting_active, main_sel_last, main_sel_mem_op_a, main_sel_mem_op_activate_gas, main_sel_mem_op_b, main_sel_mem_op_c, main_sel_mem_op_d, main_sel_mov_ia_to_ic, main_sel_mov_ib_to_ic, main_sel_op_add, main_sel_op_address, main_sel_op_and, main_sel_op_block_number, main_sel_op_calldata_copy, main_sel_op_cast, main_sel_op_chain_id, main_sel_op_cmov, main_sel_op_coinbase, main_sel_op_dagasleft, main_sel_op_div, main_sel_op_emit_l2_to_l1_msg, main_sel_op_emit_note_hash, main_sel_op_emit_nullifier, main_sel_op_emit_unencrypted_log, main_sel_op_eq, main_sel_op_external_call, main_sel_op_external_return, main_sel_op_fdiv, main_sel_op_fee_per_da_gas, main_sel_op_fee_per_l2_gas, main_sel_op_function_selector, main_sel_op_get_contract_instance, main_sel_op_halt, main_sel_op_internal_call, main_sel_op_internal_return, main_sel_op_jump, main_sel_op_jumpi, main_sel_op_keccak, main_sel_op_l1_to_l2_msg_exists, main_sel_op_l2gasleft, main_sel_op_lt, main_sel_op_lte, main_sel_op_mov, main_sel_op_mul, main_sel_op_not, main_sel_op_note_hash_exists, main_sel_op_nullifier_exists, main_sel_op_or, main_sel_op_pedersen, main_sel_op_poseidon2, main_sel_op_radix_le, main_sel_op_sender, main_sel_op_sha256, main_sel_op_shl, main_sel_op_shr, main_sel_op_sload, main_sel_op_sstore, main_sel_op_storage_address, main_sel_op_sub, main_sel_op_timestamp, main_sel_op_transaction_fee, main_sel_op_version, main_sel_op_xor, main_sel_q_kernel_lookup, main_sel_q_kernel_output_lookup, main_sel_resolve_ind_addr_a, main_sel_resolve_ind_addr_b, main_sel_resolve_ind_addr_c, main_sel_resolve_ind_addr_d, main_sel_returndata, main_sel_rng_16, main_sel_rng_8, main_sel_slice_gadget, main_space_id, main_tag_err, main_w_in_tag, mem_addr, mem_clk, mem_diff_hi, mem_diff_lo, mem_diff_mid, mem_glob_addr, mem_last, mem_lastAccess, mem_one_min_inv, mem_r_in_tag, mem_rw, mem_sel_mem, mem_sel_mov_ia_to_ic, mem_sel_mov_ib_to_ic, mem_sel_op_a, mem_sel_op_b, mem_sel_op_c, mem_sel_op_cmov, mem_sel_op_d, mem_sel_op_gadget_a, mem_sel_op_gadget_b, mem_sel_op_gadget_c, mem_sel_op_gadget_d, mem_sel_op_slice, mem_sel_resolve_ind_addr_a, mem_sel_resolve_ind_addr_b, mem_sel_resolve_ind_addr_c, mem_sel_resolve_ind_addr_d, mem_sel_rng_chk, mem_skip_check_tag, mem_space_id, mem_tag, mem_tag_err, mem_tsp, mem_val, mem_w_in_tag, pedersen_clk, pedersen_input, pedersen_output, pedersen_sel_pedersen, poseidon2_B_10_0, poseidon2_B_10_1, poseidon2_B_10_2, poseidon2_B_10_3, poseidon2_B_11_0, poseidon2_B_11_1, poseidon2_B_11_2, poseidon2_B_11_3, poseidon2_B_12_0, poseidon2_B_12_1, poseidon2_B_12_2, poseidon2_B_12_3, poseidon2_B_13_0, poseidon2_B_13_1, poseidon2_B_13_2, poseidon2_B_13_3, poseidon2_B_14_0, poseidon2_B_14_1, poseidon2_B_14_2, poseidon2_B_14_3, poseidon2_B_15_0, poseidon2_B_15_1, poseidon2_B_15_2, poseidon2_B_15_3, poseidon2_B_16_0, poseidon2_B_16_1, poseidon2_B_16_2, poseidon2_B_16_3, poseidon2_B_17_0, poseidon2_B_17_1, poseidon2_B_17_2, poseidon2_B_17_3, poseidon2_B_18_0, poseidon2_B_18_1, poseidon2_B_18_2, poseidon2_B_18_3, poseidon2_B_19_0, poseidon2_B_19_1, poseidon2_B_19_2, poseidon2_B_19_3, poseidon2_B_20_0, poseidon2_B_20_1, poseidon2_B_20_2, poseidon2_B_20_3, poseidon2_B_21_0, poseidon2_B_21_1, poseidon2_B_21_2, poseidon2_B_21_3, poseidon2_B_22_0, poseidon2_B_22_1, poseidon2_B_22_2, poseidon2_B_22_3, poseidon2_B_23_0, poseidon2_B_23_1, poseidon2_B_23_2, poseidon2_B_23_3, poseidon2_B_24_0, poseidon2_B_24_1, poseidon2_B_24_2, poseidon2_B_24_3, poseidon2_B_25_0, poseidon2_B_25_1, poseidon2_B_25_2, poseidon2_B_25_3, poseidon2_B_26_0, poseidon2_B_26_1, poseidon2_B_26_2, poseidon2_B_26_3, poseidon2_B_27_0, poseidon2_B_27_1, poseidon2_B_27_2, poseidon2_B_27_3, poseidon2_B_28_0, poseidon2_B_28_1, poseidon2_B_28_2, poseidon2_B_28_3, poseidon2_B_29_0, poseidon2_B_29_1, poseidon2_B_29_2, poseidon2_B_29_3, poseidon2_B_30_0, poseidon2_B_30_1, poseidon2_B_30_2, poseidon2_B_30_3, poseidon2_B_31_0, poseidon2_B_31_1, poseidon2_B_31_2, poseidon2_B_31_3, poseidon2_B_32_0, poseidon2_B_32_1, poseidon2_B_32_2, poseidon2_B_32_3, poseidon2_B_33_0, poseidon2_B_33_1, poseidon2_B_33_2, poseidon2_B_33_3, poseidon2_B_34_0, poseidon2_B_34_1, poseidon2_B_34_2, poseidon2_B_34_3, poseidon2_B_35_0, poseidon2_B_35_1, poseidon2_B_35_2, poseidon2_B_35_3, poseidon2_B_36_0, poseidon2_B_36_1, poseidon2_B_36_2, poseidon2_B_36_3, poseidon2_B_37_0, poseidon2_B_37_1, poseidon2_B_37_2, poseidon2_B_37_3, poseidon2_B_38_0, poseidon2_B_38_1, poseidon2_B_38_2, poseidon2_B_38_3, poseidon2_B_39_0, poseidon2_B_39_1, poseidon2_B_39_2, poseidon2_B_39_3, poseidon2_B_40_0, poseidon2_B_40_1, poseidon2_B_40_2, poseidon2_B_40_3, poseidon2_B_41_0, poseidon2_B_41_1, poseidon2_B_41_2, poseidon2_B_41_3, poseidon2_B_42_0, poseidon2_B_42_1, poseidon2_B_42_2, poseidon2_B_42_3, poseidon2_B_43_0, poseidon2_B_43_1, poseidon2_B_43_2, poseidon2_B_43_3, poseidon2_B_44_0, poseidon2_B_44_1, poseidon2_B_44_2, poseidon2_B_44_3, poseidon2_B_45_0, poseidon2_B_45_1, poseidon2_B_45_2, poseidon2_B_45_3, poseidon2_B_46_0, poseidon2_B_46_1, poseidon2_B_46_2, poseidon2_B_46_3, poseidon2_B_47_0, poseidon2_B_47_1, poseidon2_B_47_2, poseidon2_B_47_3, poseidon2_B_48_0, poseidon2_B_48_1, poseidon2_B_48_2, poseidon2_B_48_3, poseidon2_B_49_0, poseidon2_B_49_1, poseidon2_B_49_2, poseidon2_B_49_3, poseidon2_B_4_0, poseidon2_B_4_1, poseidon2_B_4_2, poseidon2_B_4_3, poseidon2_B_50_0, poseidon2_B_50_1, poseidon2_B_50_2, poseidon2_B_50_3, poseidon2_B_51_0, poseidon2_B_51_1, poseidon2_B_51_2, poseidon2_B_51_3, poseidon2_B_52_0, poseidon2_B_52_1, poseidon2_B_52_2, poseidon2_B_52_3, poseidon2_B_53_0, poseidon2_B_53_1, poseidon2_B_53_2, poseidon2_B_53_3, poseidon2_B_54_0, poseidon2_B_54_1, poseidon2_B_54_2, poseidon2_B_54_3, poseidon2_B_55_0, poseidon2_B_55_1, poseidon2_B_55_2, poseidon2_B_55_3, poseidon2_B_56_0, poseidon2_B_56_1, poseidon2_B_56_2, poseidon2_B_56_3, poseidon2_B_57_0, poseidon2_B_57_1, poseidon2_B_57_2, poseidon2_B_57_3, poseidon2_B_58_0, poseidon2_B_58_1, poseidon2_B_58_2, poseidon2_B_58_3, poseidon2_B_59_0, poseidon2_B_59_1, poseidon2_B_59_2, poseidon2_B_59_3, poseidon2_B_5_0, poseidon2_B_5_1, poseidon2_B_5_2, poseidon2_B_5_3, poseidon2_B_6_0, poseidon2_B_6_1, poseidon2_B_6_2, poseidon2_B_6_3, poseidon2_B_7_0, poseidon2_B_7_1, poseidon2_B_7_2, poseidon2_B_7_3, poseidon2_B_8_0, poseidon2_B_8_1, poseidon2_B_8_2, poseidon2_B_8_3, poseidon2_B_9_0, poseidon2_B_9_1, poseidon2_B_9_2, poseidon2_B_9_3, poseidon2_EXT_LAYER_4, poseidon2_EXT_LAYER_5, poseidon2_EXT_LAYER_6, poseidon2_EXT_LAYER_7, poseidon2_T_0_4, poseidon2_T_0_5, poseidon2_T_0_6, poseidon2_T_0_7, poseidon2_T_1_4, poseidon2_T_1_5, poseidon2_T_1_6, poseidon2_T_1_7, poseidon2_T_2_4, poseidon2_T_2_5, poseidon2_T_2_6, poseidon2_T_2_7, poseidon2_T_3_4, poseidon2_T_3_5, poseidon2_T_3_6, poseidon2_T_3_7, poseidon2_T_60_4, poseidon2_T_60_5, poseidon2_T_60_6, poseidon2_T_60_7, poseidon2_T_61_4, poseidon2_T_61_5, poseidon2_T_61_6, poseidon2_T_61_7, poseidon2_T_62_4, poseidon2_T_62_5, poseidon2_T_62_6, poseidon2_T_62_7, poseidon2_T_63_4, poseidon2_T_63_5, poseidon2_T_63_6, poseidon2_T_63_7, poseidon2_a_0, poseidon2_a_1, poseidon2_a_2, poseidon2_a_3, poseidon2_b_0, poseidon2_b_1, poseidon2_b_2, poseidon2_b_3, poseidon2_clk, poseidon2_in_tag, poseidon2_input_addr, poseidon2_mem_addr_a, poseidon2_mem_addr_b, poseidon2_mem_addr_c, poseidon2_mem_addr_d, poseidon2_mem_op, poseidon2_output_addr, poseidon2_read_line, poseidon2_sel_poseidon_perm, poseidon2_write_line, powers_power_of_2, sha256_clk, sha256_input, sha256_output, sha256_sel_sha256_compression, sha256_state, slice_addr, slice_clk, slice_cnt, slice_col_offset, slice_one_min_inv, slice_sel_cd_cpy, slice_sel_mem_active, slice_sel_return, slice_sel_start, slice_space_id, slice_val, lookup_byte_lengths_counts, lookup_byte_operations_counts, lookup_cd_value_counts, lookup_ret_value_counts, lookup_opcode_gas_counts, range_check_l2_gas_hi_counts, range_check_l2_gas_lo_counts, range_check_da_gas_hi_counts, range_check_da_gas_lo_counts, kernel_output_lookup_counts, lookup_into_kernel_counts, incl_main_tag_err_counts, incl_mem_tag_err_counts, lookup_mem_rng_chk_lo_counts, lookup_mem_rng_chk_mid_counts, lookup_mem_rng_chk_hi_counts, lookup_pow_2_0_counts, lookup_pow_2_1_counts, lookup_u8_0_counts, lookup_u8_1_counts, lookup_u16_0_counts, lookup_u16_1_counts, lookup_u16_2_counts, lookup_u16_3_counts, lookup_u16_4_counts, lookup_u16_5_counts, lookup_u16_6_counts, lookup_u16_7_counts, lookup_u16_8_counts, lookup_u16_9_counts, lookup_u16_10_counts, lookup_u16_11_counts, lookup_u16_12_counts, lookup_u16_13_counts, lookup_u16_14_counts, lookup_div_u16_0_counts, lookup_div_u16_1_counts, lookup_div_u16_2_counts, lookup_div_u16_3_counts, lookup_div_u16_4_counts, lookup_div_u16_5_counts, lookup_div_u16_6_counts, lookup_div_u16_7_counts +#define DERIVED_WITNESS_ENTITIES perm_pos_mem_a, perm_pos_mem_b, perm_pos_mem_c, perm_pos_mem_d, perm_slice_mem, perm_main_alu, perm_main_bin, perm_main_conv, perm_main_pos2_perm, perm_main_pedersen, perm_main_slice, perm_main_mem_a, perm_main_mem_b, perm_main_mem_c, perm_main_mem_d, perm_main_mem_ind_addr_a, perm_main_mem_ind_addr_b, perm_main_mem_ind_addr_c, perm_main_mem_ind_addr_d, lookup_byte_lengths, lookup_byte_operations, lookup_cd_value, lookup_ret_value, lookup_opcode_gas, range_check_l2_gas_hi, range_check_l2_gas_lo, range_check_da_gas_hi, range_check_da_gas_lo, kernel_output_lookup, lookup_into_kernel, incl_main_tag_err, incl_mem_tag_err, lookup_mem_rng_chk_lo, lookup_mem_rng_chk_mid, lookup_mem_rng_chk_hi, lookup_pow_2_0, lookup_pow_2_1, lookup_u8_0, lookup_u8_1, lookup_u16_0, lookup_u16_1, lookup_u16_2, lookup_u16_3, lookup_u16_4, lookup_u16_5, lookup_u16_6, lookup_u16_7, lookup_u16_8, lookup_u16_9, lookup_u16_10, lookup_u16_11, lookup_u16_12, lookup_u16_13, lookup_u16_14, lookup_div_u16_0, lookup_div_u16_1, lookup_div_u16_2, lookup_div_u16_3, lookup_div_u16_4, lookup_div_u16_5, lookup_div_u16_6, lookup_div_u16_7 +#define SHIFTED_ENTITIES alu_a_hi_shift, alu_a_lo_shift, alu_b_hi_shift, alu_b_lo_shift, alu_cmp_rng_ctr_shift, alu_div_u16_r0_shift, alu_div_u16_r1_shift, alu_div_u16_r2_shift, alu_div_u16_r3_shift, alu_div_u16_r4_shift, alu_div_u16_r5_shift, alu_div_u16_r6_shift, alu_div_u16_r7_shift, alu_op_add_shift, alu_op_cast_prev_shift, alu_op_cast_shift, alu_op_div_shift, alu_op_mul_shift, alu_op_shl_shift, alu_op_shr_shift, alu_op_sub_shift, alu_p_sub_a_hi_shift, alu_p_sub_a_lo_shift, alu_p_sub_b_hi_shift, alu_p_sub_b_lo_shift, alu_sel_alu_shift, alu_sel_cmp_shift, alu_sel_div_rng_chk_shift, alu_sel_rng_chk_lookup_shift, alu_sel_rng_chk_shift, alu_u16_r0_shift, alu_u16_r1_shift, alu_u16_r2_shift, alu_u16_r3_shift, alu_u16_r4_shift, alu_u16_r5_shift, alu_u16_r6_shift, alu_u8_r0_shift, alu_u8_r1_shift, binary_acc_ia_shift, binary_acc_ib_shift, binary_acc_ic_shift, binary_mem_tag_ctr_shift, binary_op_id_shift, kernel_emit_l2_to_l1_msg_write_offset_shift, kernel_emit_note_hash_write_offset_shift, kernel_emit_nullifier_write_offset_shift, kernel_emit_unencrypted_log_write_offset_shift, kernel_l1_to_l2_msg_exists_write_offset_shift, kernel_note_hash_exist_write_offset_shift, kernel_nullifier_exists_write_offset_shift, kernel_nullifier_non_exists_write_offset_shift, kernel_side_effect_counter_shift, kernel_sload_write_offset_shift, kernel_sstore_write_offset_shift, main_da_gas_remaining_shift, main_internal_return_ptr_shift, main_l2_gas_remaining_shift, main_pc_shift, mem_glob_addr_shift, mem_rw_shift, mem_sel_mem_shift, mem_tag_shift, mem_tsp_shift, mem_val_shift, poseidon2_a_0_shift, poseidon2_a_1_shift, poseidon2_a_2_shift, poseidon2_a_3_shift, poseidon2_sel_poseidon_perm_shift, poseidon2_write_line_shift, slice_addr_shift, slice_clk_shift, slice_cnt_shift, slice_col_offset_shift, slice_sel_cd_cpy_shift, slice_sel_mem_active_shift, slice_sel_return_shift, slice_sel_start_shift, slice_space_id_shift +#define TO_BE_SHIFTED(e) e.alu_a_hi, e.alu_a_lo, e.alu_b_hi, e.alu_b_lo, e.alu_cmp_rng_ctr, e.alu_div_u16_r0, e.alu_div_u16_r1, e.alu_div_u16_r2, e.alu_div_u16_r3, e.alu_div_u16_r4, e.alu_div_u16_r5, e.alu_div_u16_r6, e.alu_div_u16_r7, e.alu_op_add, e.alu_op_cast_prev, e.alu_op_cast, e.alu_op_div, e.alu_op_mul, e.alu_op_shl, e.alu_op_shr, e.alu_op_sub, e.alu_p_sub_a_hi, e.alu_p_sub_a_lo, e.alu_p_sub_b_hi, e.alu_p_sub_b_lo, e.alu_sel_alu, e.alu_sel_cmp, e.alu_sel_div_rng_chk, e.alu_sel_rng_chk_lookup, e.alu_sel_rng_chk, e.alu_u16_r0, e.alu_u16_r1, e.alu_u16_r2, e.alu_u16_r3, e.alu_u16_r4, e.alu_u16_r5, e.alu_u16_r6, e.alu_u8_r0, e.alu_u8_r1, e.binary_acc_ia, e.binary_acc_ib, e.binary_acc_ic, e.binary_mem_tag_ctr, e.binary_op_id, e.kernel_emit_l2_to_l1_msg_write_offset, e.kernel_emit_note_hash_write_offset, e.kernel_emit_nullifier_write_offset, e.kernel_emit_unencrypted_log_write_offset, e.kernel_l1_to_l2_msg_exists_write_offset, e.kernel_note_hash_exist_write_offset, e.kernel_nullifier_exists_write_offset, e.kernel_nullifier_non_exists_write_offset, e.kernel_side_effect_counter, e.kernel_sload_write_offset, e.kernel_sstore_write_offset, e.main_da_gas_remaining, e.main_internal_return_ptr, e.main_l2_gas_remaining, e.main_pc, e.mem_glob_addr, e.mem_rw, e.mem_sel_mem, e.mem_tag, e.mem_tsp, e.mem_val, e.poseidon2_a_0, e.poseidon2_a_1, e.poseidon2_a_2, e.poseidon2_a_3, e.poseidon2_sel_poseidon_perm, e.poseidon2_write_line, e.slice_addr, e.slice_clk, e.slice_cnt, e.slice_col_offset, e.slice_sel_cd_cpy, e.slice_sel_mem_active, e.slice_sel_return, e.slice_sel_start, e.slice_space_id #define ALL_ENTITIES PRECOMPUTED_ENTITIES, WIRE_ENTITIES, DERIVED_WITNESS_ENTITIES, SHIFTED_ENTITIES // clang-format on @@ -121,35 +125,11 @@ class AvmFlavor { using RelationSeparator = AvmFlavorSettings::RelationSeparator; static constexpr size_t NUM_PRECOMPUTED_ENTITIES = 2; -<<<<<<< HEAD - static constexpr size_t NUM_WITNESS_ENTITIES = 409; + static constexpr size_t NUM_WITNESS_ENTITIES = 693; static constexpr size_t NUM_WIRES = NUM_WITNESS_ENTITIES + NUM_PRECOMPUTED_ENTITIES; // We have two copies of the witness entities, so we subtract the number of fixed ones (they have no shift), one for // the unshifted and one for the shifted - static constexpr size_t NUM_ALL_ENTITIES = 485; -======= -<<<<<<< HEAD - static constexpr size_t NUM_WITNESS_ENTITIES = 385; - static constexpr size_t NUM_WIRES = NUM_WITNESS_ENTITIES + NUM_PRECOMPUTED_ENTITIES; - // We have two copies of the witness entities, so we subtract the number of fixed ones (they have no shift), one for - // the unshifted and one for the shifted - static constexpr size_t NUM_ALL_ENTITIES = 452; -======= -<<<<<<< HEAD - static constexpr size_t NUM_WITNESS_ENTITIES = 384; - static constexpr size_t NUM_WIRES = NUM_WITNESS_ENTITIES + NUM_PRECOMPUTED_ENTITIES; - // We have two copies of the witness entities, so we subtract the number of fixed ones (they have no shift), one for - // the unshifted and one for the shifted - static constexpr size_t NUM_ALL_ENTITIES = 451; -======= - static constexpr size_t NUM_WITNESS_ENTITIES = 391; - static constexpr size_t NUM_WIRES = NUM_WITNESS_ENTITIES + NUM_PRECOMPUTED_ENTITIES; - // We have two copies of the witness entities, so we subtract the number of fixed ones (they have no shift), one for - // the unshifted and one for the shifted - static constexpr size_t NUM_ALL_ENTITIES = 458; ->>>>>>> 91347fba1 (feat(avm): poseidon2 constraints) ->>>>>>> dfd3ca77d (feat(avm): poseidon2 constraints) ->>>>>>> 804a62263 (feat(avm): poseidon2 constraints) + static constexpr size_t NUM_ALL_ENTITIES = 775; using MainRelations = std::tuple< // Relations @@ -169,6 +149,10 @@ class AvmFlavor { using LookupRelations = std::tuple< // Lookups + perm_pos_mem_a_relation, + perm_pos_mem_b_relation, + perm_pos_mem_c_relation, + perm_pos_mem_d_relation, perm_slice_mem_relation, perm_main_alu_relation, perm_main_bin_relation, @@ -261,1116 +245,12 @@ class AvmFlavor { template class WireEntities { public: -<<<<<<< HEAD DEFINE_FLAVOR_MEMBERS(DataType, WIRE_ENTITIES) -======= - DEFINE_FLAVOR_MEMBERS(DataType, - kernel_kernel_inputs, - kernel_kernel_value_out, - kernel_kernel_side_effect_out, - kernel_kernel_metadata_out, - main_calldata, - alu_a_hi, - alu_a_lo, - alu_b_hi, - alu_b_lo, - alu_borrow, - alu_cf, - alu_clk, - alu_cmp_rng_ctr, - alu_div_u16_r0, - alu_div_u16_r1, - alu_div_u16_r2, - alu_div_u16_r3, - alu_div_u16_r4, - alu_div_u16_r5, - alu_div_u16_r6, - alu_div_u16_r7, - alu_divisor_hi, - alu_divisor_lo, - alu_ff_tag, - alu_ia, - alu_ib, - alu_ic, - alu_in_tag, - alu_op_add, - alu_op_cast, - alu_op_cast_prev, - alu_op_div, - alu_op_div_a_lt_b, - alu_op_div_std, - alu_op_eq, - alu_op_eq_diff_inv, - alu_op_lt, - alu_op_lte, - alu_op_mul, - alu_op_not, - alu_op_shl, - alu_op_shr, - alu_op_sub, - alu_p_a_borrow, - alu_p_b_borrow, - alu_p_sub_a_hi, - alu_p_sub_a_lo, - alu_p_sub_b_hi, - alu_p_sub_b_lo, - alu_partial_prod_hi, - alu_partial_prod_lo, - alu_quotient_hi, - alu_quotient_lo, - alu_remainder, - alu_res_hi, - alu_res_lo, - alu_sel_alu, - alu_sel_cmp, - alu_sel_div_rng_chk, - alu_sel_rng_chk, - alu_sel_rng_chk_lookup, - alu_sel_shift_which, - alu_shift_lt_bit_len, - alu_t_sub_s_bits, - alu_two_pow_s, - alu_two_pow_t_sub_s, - alu_u128_tag, - alu_u16_r0, - alu_u16_r1, - alu_u16_r10, - alu_u16_r11, - alu_u16_r12, - alu_u16_r13, - alu_u16_r14, - alu_u16_r2, - alu_u16_r3, - alu_u16_r4, - alu_u16_r5, - alu_u16_r6, - alu_u16_r7, - alu_u16_r8, - alu_u16_r9, - alu_u16_tag, - alu_u32_tag, - alu_u64_tag, - alu_u8_r0, - alu_u8_r1, - alu_u8_tag, - binary_acc_ia, - binary_acc_ib, - binary_acc_ic, - binary_clk, - binary_ia_bytes, - binary_ib_bytes, - binary_ic_bytes, - binary_in_tag, - binary_mem_tag_ctr, - binary_mem_tag_ctr_inv, - binary_op_id, - binary_sel_bin, - binary_start, - byte_lookup_sel_bin, - byte_lookup_table_byte_lengths, - byte_lookup_table_in_tags, - byte_lookup_table_input_a, - byte_lookup_table_input_b, - byte_lookup_table_op_id, - byte_lookup_table_output, - conversion_clk, - conversion_input, - conversion_num_limbs, - conversion_radix, - conversion_sel_to_radix_le, - gas_da_gas_fixed_table, - gas_l2_gas_fixed_table, - gas_sel_gas_cost, - keccakf1600_clk, - keccakf1600_input, - keccakf1600_output, - keccakf1600_sel_keccakf1600, - kernel_emit_l2_to_l1_msg_write_offset, - kernel_emit_note_hash_write_offset, - kernel_emit_nullifier_write_offset, - kernel_emit_unencrypted_log_write_offset, - kernel_kernel_in_offset, - kernel_kernel_out_offset, - kernel_l1_to_l2_msg_exists_write_offset, - kernel_note_hash_exist_write_offset, - kernel_nullifier_exists_write_offset, - kernel_nullifier_non_exists_write_offset, - kernel_q_public_input_kernel_add_to_table, - kernel_q_public_input_kernel_out_add_to_table, - kernel_side_effect_counter, - kernel_sload_write_offset, - kernel_sstore_write_offset, - main_abs_da_rem_gas_hi, - main_abs_da_rem_gas_lo, - main_abs_l2_rem_gas_hi, - main_abs_l2_rem_gas_lo, - main_alu_in_tag, - main_bin_op_id, - main_call_ptr, - main_da_gas_op_cost, - main_da_gas_remaining, - main_da_out_of_gas, - main_ia, - main_ib, - main_ic, - main_id, - main_id_zero, - main_ind_addr_a, - main_ind_addr_b, - main_ind_addr_c, - main_ind_addr_d, - main_internal_return_ptr, - main_inv, - main_l2_gas_op_cost, - main_l2_gas_remaining, - main_l2_out_of_gas, - main_mem_addr_a, - main_mem_addr_b, - main_mem_addr_c, - main_mem_addr_d, - main_op_err, - main_opcode_val, - main_pc, - main_r_in_tag, - main_rwa, - main_rwb, - main_rwc, - main_rwd, - main_sel_alu, - main_sel_bin, - main_sel_gas_accounting_active, - main_sel_last, - main_sel_mem_op_a, - main_sel_mem_op_activate_gas, - main_sel_mem_op_b, - main_sel_mem_op_c, - main_sel_mem_op_d, - main_sel_mov_ia_to_ic, - main_sel_mov_ib_to_ic, - main_sel_op_add, - main_sel_op_address, - main_sel_op_and, - main_sel_op_block_number, - main_sel_op_cast, - main_sel_op_chain_id, - main_sel_op_cmov, - main_sel_op_coinbase, - main_sel_op_dagasleft, - main_sel_op_div, - main_sel_op_emit_l2_to_l1_msg, - main_sel_op_emit_note_hash, - main_sel_op_emit_nullifier, - main_sel_op_emit_unencrypted_log, - main_sel_op_eq, - main_sel_op_external_call, - main_sel_op_fdiv, - main_sel_op_fee_per_da_gas, - main_sel_op_fee_per_l2_gas, - main_sel_op_function_selector, - main_sel_op_get_contract_instance, - main_sel_op_halt, - main_sel_op_internal_call, - main_sel_op_internal_return, - main_sel_op_jump, - main_sel_op_jumpi, - main_sel_op_keccak, - main_sel_op_l1_to_l2_msg_exists, - main_sel_op_l2gasleft, - main_sel_op_lt, - main_sel_op_lte, - main_sel_op_mov, - main_sel_op_mul, - main_sel_op_not, - main_sel_op_note_hash_exists, - main_sel_op_nullifier_exists, - main_sel_op_or, - main_sel_op_pedersen, - main_sel_op_poseidon2, - main_sel_op_radix_le, - main_sel_op_sender, - main_sel_op_sha256, - main_sel_op_shl, - main_sel_op_shr, - main_sel_op_sload, - main_sel_op_sstore, - main_sel_op_storage_address, - main_sel_op_sub, - main_sel_op_timestamp, - main_sel_op_transaction_fee, - main_sel_op_version, - main_sel_op_xor, - main_sel_q_kernel_lookup, - main_sel_q_kernel_output_lookup, - main_sel_resolve_ind_addr_a, - main_sel_resolve_ind_addr_b, - main_sel_resolve_ind_addr_c, - main_sel_resolve_ind_addr_d, - main_sel_rng_16, - main_sel_rng_8, - main_space_id, - main_tag_err, - main_w_in_tag, - mem_addr, - mem_clk, - mem_diff_hi, - mem_diff_lo, - mem_diff_mid, - mem_glob_addr, - mem_last, - mem_lastAccess, - mem_one_min_inv, - mem_r_in_tag, - mem_rw, - mem_sel_mem, - mem_sel_mov_ia_to_ic, - mem_sel_mov_ib_to_ic, - mem_sel_op_a, - mem_sel_op_b, - mem_sel_op_c, - mem_sel_op_cmov, - mem_sel_op_d, - mem_sel_resolve_ind_addr_a, - mem_sel_resolve_ind_addr_b, - mem_sel_resolve_ind_addr_c, - mem_sel_resolve_ind_addr_d, - mem_sel_rng_chk, - mem_skip_check_tag, - mem_space_id, - mem_tag, - mem_tag_err, - mem_tsp, - mem_val, - mem_w_in_tag, - pedersen_clk, - pedersen_input, - pedersen_output, - pedersen_sel_pedersen, - poseidon2_a_0, - poseidon2_a_1, - poseidon2_a_2, - poseidon2_a_3, - poseidon2_b_0, - poseidon2_b_1, - poseidon2_b_2, - poseidon2_b_3, - poseidon2_clk, - poseidon2_input, - poseidon2_output, - poseidon2_sel_poseidon_perm, - powers_power_of_2, - sha256_clk, - sha256_input, - sha256_output, - sha256_sel_sha256_compression, - sha256_state, - lookup_byte_lengths_counts, - lookup_byte_operations_counts, - lookup_opcode_gas_counts, - range_check_l2_gas_hi_counts, - range_check_l2_gas_lo_counts, - range_check_da_gas_hi_counts, - range_check_da_gas_lo_counts, - kernel_output_lookup_counts, - lookup_into_kernel_counts, - incl_main_tag_err_counts, - incl_mem_tag_err_counts, - lookup_mem_rng_chk_lo_counts, - lookup_mem_rng_chk_mid_counts, - lookup_mem_rng_chk_hi_counts, - lookup_pow_2_0_counts, - lookup_pow_2_1_counts, - lookup_u8_0_counts, - lookup_u8_1_counts, - lookup_u16_0_counts, - lookup_u16_1_counts, - lookup_u16_2_counts, - lookup_u16_3_counts, - lookup_u16_4_counts, - lookup_u16_5_counts, - lookup_u16_6_counts, - lookup_u16_7_counts, - lookup_u16_8_counts, - lookup_u16_9_counts, - lookup_u16_10_counts, - lookup_u16_11_counts, - lookup_u16_12_counts, - lookup_u16_13_counts, - lookup_u16_14_counts, - lookup_div_u16_0_counts, - lookup_div_u16_1_counts, - lookup_div_u16_2_counts, - lookup_div_u16_3_counts, - lookup_div_u16_4_counts, - lookup_div_u16_5_counts, - lookup_div_u16_6_counts, - lookup_div_u16_7_counts) -<<<<<<< HEAD -======= - - RefVector get_wires() - { - return { kernel_kernel_inputs, - kernel_kernel_value_out, - kernel_kernel_side_effect_out, - kernel_kernel_metadata_out, - main_calldata, - alu_a_hi, - alu_a_lo, - alu_b_hi, - alu_b_lo, - alu_borrow, - alu_cf, - alu_clk, - alu_cmp_rng_ctr, - alu_div_u16_r0, - alu_div_u16_r1, - alu_div_u16_r2, - alu_div_u16_r3, - alu_div_u16_r4, - alu_div_u16_r5, - alu_div_u16_r6, - alu_div_u16_r7, - alu_divisor_hi, - alu_divisor_lo, - alu_ff_tag, - alu_ia, - alu_ib, - alu_ic, - alu_in_tag, - alu_op_add, - alu_op_cast, - alu_op_cast_prev, - alu_op_div, - alu_op_div_a_lt_b, - alu_op_div_std, - alu_op_eq, - alu_op_eq_diff_inv, - alu_op_lt, - alu_op_lte, - alu_op_mul, - alu_op_not, - alu_op_shl, - alu_op_shr, - alu_op_sub, - alu_p_a_borrow, - alu_p_b_borrow, - alu_p_sub_a_hi, - alu_p_sub_a_lo, - alu_p_sub_b_hi, - alu_p_sub_b_lo, - alu_partial_prod_hi, - alu_partial_prod_lo, - alu_quotient_hi, - alu_quotient_lo, - alu_remainder, - alu_res_hi, - alu_res_lo, - alu_sel_alu, - alu_sel_cmp, - alu_sel_div_rng_chk, - alu_sel_rng_chk, - alu_sel_rng_chk_lookup, - alu_sel_shift_which, - alu_shift_lt_bit_len, - alu_t_sub_s_bits, - alu_two_pow_s, - alu_two_pow_t_sub_s, - alu_u128_tag, - alu_u16_r0, - alu_u16_r1, - alu_u16_r10, - alu_u16_r11, - alu_u16_r12, - alu_u16_r13, - alu_u16_r14, - alu_u16_r2, - alu_u16_r3, - alu_u16_r4, - alu_u16_r5, - alu_u16_r6, - alu_u16_r7, - alu_u16_r8, - alu_u16_r9, - alu_u16_tag, - alu_u32_tag, - alu_u64_tag, - alu_u8_r0, - alu_u8_r1, - alu_u8_tag, - binary_acc_ia, - binary_acc_ib, - binary_acc_ic, - binary_clk, - binary_ia_bytes, - binary_ib_bytes, - binary_ic_bytes, - binary_in_tag, - binary_mem_tag_ctr, - binary_mem_tag_ctr_inv, - binary_op_id, - binary_sel_bin, - binary_start, - byte_lookup_sel_bin, - byte_lookup_table_byte_lengths, - byte_lookup_table_in_tags, - byte_lookup_table_input_a, - byte_lookup_table_input_b, - byte_lookup_table_op_id, - byte_lookup_table_output, - conversion_clk, - conversion_input, - conversion_num_limbs, - conversion_radix, - conversion_sel_to_radix_le, - gas_da_gas_fixed_table, - gas_l2_gas_fixed_table, - gas_sel_gas_cost, - keccakf1600_clk, - keccakf1600_input, - keccakf1600_output, - keccakf1600_sel_keccakf1600, - kernel_emit_l2_to_l1_msg_write_offset, - kernel_emit_note_hash_write_offset, - kernel_emit_nullifier_write_offset, - kernel_emit_unencrypted_log_write_offset, - kernel_kernel_in_offset, - kernel_kernel_out_offset, - kernel_l1_to_l2_msg_exists_write_offset, - kernel_note_hash_exist_write_offset, - kernel_nullifier_exists_write_offset, - kernel_nullifier_non_exists_write_offset, - kernel_q_public_input_kernel_add_to_table, - kernel_q_public_input_kernel_out_add_to_table, - kernel_side_effect_counter, - kernel_sload_write_offset, - kernel_sstore_write_offset, - main_abs_da_rem_gas_hi, - main_abs_da_rem_gas_lo, - main_abs_l2_rem_gas_hi, - main_abs_l2_rem_gas_lo, - main_alu_in_tag, - main_bin_op_id, - main_call_ptr, - main_da_gas_op_cost, - main_da_gas_remaining, - main_da_out_of_gas, - main_ia, - main_ib, - main_ic, - main_id, - main_id_zero, - main_ind_addr_a, - main_ind_addr_b, - main_ind_addr_c, - main_ind_addr_d, - main_internal_return_ptr, - main_inv, - main_l2_gas_op_cost, - main_l2_gas_remaining, - main_l2_out_of_gas, - main_mem_addr_a, - main_mem_addr_b, - main_mem_addr_c, - main_mem_addr_d, - main_op_err, - main_opcode_val, - main_pc, - main_r_in_tag, - main_rwa, - main_rwb, - main_rwc, - main_rwd, - main_sel_alu, - main_sel_bin, - main_sel_gas_accounting_active, - main_sel_last, - main_sel_mem_op_a, - main_sel_mem_op_activate_gas, - main_sel_mem_op_b, - main_sel_mem_op_c, - main_sel_mem_op_d, - main_sel_mov_ia_to_ic, - main_sel_mov_ib_to_ic, - main_sel_op_add, - main_sel_op_address, - main_sel_op_and, - main_sel_op_block_number, - main_sel_op_cast, - main_sel_op_chain_id, - main_sel_op_cmov, - main_sel_op_coinbase, - main_sel_op_dagasleft, - main_sel_op_div, - main_sel_op_emit_l2_to_l1_msg, - main_sel_op_emit_note_hash, - main_sel_op_emit_nullifier, - main_sel_op_emit_unencrypted_log, - main_sel_op_eq, - main_sel_op_external_call, - main_sel_op_fdiv, - main_sel_op_fee_per_da_gas, - main_sel_op_fee_per_l2_gas, - main_sel_op_function_selector, - main_sel_op_get_contract_instance, - main_sel_op_halt, - main_sel_op_internal_call, - main_sel_op_internal_return, - main_sel_op_jump, - main_sel_op_jumpi, - main_sel_op_keccak, - main_sel_op_l1_to_l2_msg_exists, - main_sel_op_l2gasleft, - main_sel_op_lt, - main_sel_op_lte, - main_sel_op_mov, - main_sel_op_mul, - main_sel_op_not, - main_sel_op_note_hash_exists, - main_sel_op_nullifier_exists, - main_sel_op_or, - main_sel_op_pedersen, - main_sel_op_poseidon2, - main_sel_op_radix_le, - main_sel_op_sender, - main_sel_op_sha256, - main_sel_op_shl, - main_sel_op_shr, - main_sel_op_sload, - main_sel_op_sstore, - main_sel_op_storage_address, - main_sel_op_sub, - main_sel_op_timestamp, - main_sel_op_transaction_fee, - main_sel_op_version, - main_sel_op_xor, - main_sel_q_kernel_lookup, - main_sel_q_kernel_output_lookup, - main_sel_resolve_ind_addr_a, - main_sel_resolve_ind_addr_b, - main_sel_resolve_ind_addr_c, - main_sel_resolve_ind_addr_d, - main_sel_rng_16, - main_sel_rng_8, - main_space_id, - main_tag_err, - main_w_in_tag, - mem_addr, - mem_clk, - mem_diff_hi, - mem_diff_lo, - mem_diff_mid, - mem_glob_addr, - mem_last, - mem_lastAccess, - mem_one_min_inv, - mem_r_in_tag, - mem_rw, - mem_sel_mem, - mem_sel_mov_ia_to_ic, - mem_sel_mov_ib_to_ic, - mem_sel_op_a, - mem_sel_op_b, - mem_sel_op_c, - mem_sel_op_cmov, - mem_sel_op_d, - mem_sel_resolve_ind_addr_a, - mem_sel_resolve_ind_addr_b, - mem_sel_resolve_ind_addr_c, - mem_sel_resolve_ind_addr_d, - mem_sel_rng_chk, - mem_skip_check_tag, - mem_space_id, - mem_tag, - mem_tag_err, - mem_tsp, - mem_val, - mem_w_in_tag, - pedersen_clk, - pedersen_input, - pedersen_output, - pedersen_sel_pedersen, - poseidon2_a_0, - poseidon2_a_1, - poseidon2_a_2, - poseidon2_a_3, - poseidon2_b_0, - poseidon2_b_1, - poseidon2_b_2, - poseidon2_b_3, - poseidon2_clk, - poseidon2_input, - poseidon2_output, - poseidon2_sel_poseidon_perm, - powers_power_of_2, - sha256_clk, - sha256_input, - sha256_output, - sha256_sel_sha256_compression, - sha256_state, - perm_main_alu, - perm_main_bin, - perm_main_conv, - perm_main_pos2_perm, - perm_main_pedersen, - perm_main_mem_a, - perm_main_mem_b, - perm_main_mem_c, - perm_main_mem_d, - perm_main_mem_ind_addr_a, - perm_main_mem_ind_addr_b, - perm_main_mem_ind_addr_c, - perm_main_mem_ind_addr_d, - lookup_byte_lengths, - lookup_byte_operations, - lookup_opcode_gas, - range_check_l2_gas_hi, - range_check_l2_gas_lo, - range_check_da_gas_hi, - range_check_da_gas_lo, - kernel_output_lookup, - lookup_into_kernel, - incl_main_tag_err, - incl_mem_tag_err, - lookup_mem_rng_chk_lo, - lookup_mem_rng_chk_mid, - lookup_mem_rng_chk_hi, - lookup_pow_2_0, - lookup_pow_2_1, - lookup_u8_0, - lookup_u8_1, - lookup_u16_0, - lookup_u16_1, - lookup_u16_2, - lookup_u16_3, - lookup_u16_4, - lookup_u16_5, - lookup_u16_6, - lookup_u16_7, - lookup_u16_8, - lookup_u16_9, - lookup_u16_10, - lookup_u16_11, - lookup_u16_12, - lookup_u16_13, - lookup_u16_14, - lookup_div_u16_0, - lookup_div_u16_1, - lookup_div_u16_2, - lookup_div_u16_3, - lookup_div_u16_4, - lookup_div_u16_5, - lookup_div_u16_6, - lookup_div_u16_7, - lookup_byte_lengths_counts, - lookup_byte_operations_counts, - lookup_opcode_gas_counts, - range_check_l2_gas_hi_counts, - range_check_l2_gas_lo_counts, - range_check_da_gas_hi_counts, - range_check_da_gas_lo_counts, - kernel_output_lookup_counts, - lookup_into_kernel_counts, - incl_main_tag_err_counts, - incl_mem_tag_err_counts, - lookup_mem_rng_chk_lo_counts, - lookup_mem_rng_chk_mid_counts, - lookup_mem_rng_chk_hi_counts, - lookup_pow_2_0_counts, - lookup_pow_2_1_counts, - lookup_u8_0_counts, - lookup_u8_1_counts, - lookup_u16_0_counts, - lookup_u16_1_counts, - lookup_u16_2_counts, - lookup_u16_3_counts, - lookup_u16_4_counts, - lookup_u16_5_counts, - lookup_u16_6_counts, - lookup_u16_7_counts, - lookup_u16_8_counts, - lookup_u16_9_counts, - lookup_u16_10_counts, - lookup_u16_11_counts, - lookup_u16_12_counts, - lookup_u16_13_counts, - lookup_u16_14_counts, - lookup_div_u16_0_counts, - lookup_div_u16_1_counts, - lookup_div_u16_2_counts, - lookup_div_u16_3_counts, - lookup_div_u16_4_counts, - lookup_div_u16_5_counts, - lookup_div_u16_6_counts, - lookup_div_u16_7_counts }; - }; ->>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) ->>>>>>> 804a62263 (feat(avm): poseidon2 constraints) }; template class DerivedWitnessEntities { public: -<<<<<<< HEAD DEFINE_FLAVOR_MEMBERS(DataType, DERIVED_WITNESS_ENTITIES) -======= - DEFINE_FLAVOR_MEMBERS(DataType, -<<<<<<< HEAD -======= - main_clk, - main_sel_first, - kernel_kernel_inputs, - kernel_kernel_value_out, - kernel_kernel_side_effect_out, - kernel_kernel_metadata_out, - main_calldata, - alu_a_hi, - alu_a_lo, - alu_b_hi, - alu_b_lo, - alu_borrow, - alu_cf, - alu_clk, - alu_cmp_rng_ctr, - alu_div_u16_r0, - alu_div_u16_r1, - alu_div_u16_r2, - alu_div_u16_r3, - alu_div_u16_r4, - alu_div_u16_r5, - alu_div_u16_r6, - alu_div_u16_r7, - alu_divisor_hi, - alu_divisor_lo, - alu_ff_tag, - alu_ia, - alu_ib, - alu_ic, - alu_in_tag, - alu_op_add, - alu_op_cast, - alu_op_cast_prev, - alu_op_div, - alu_op_div_a_lt_b, - alu_op_div_std, - alu_op_eq, - alu_op_eq_diff_inv, - alu_op_lt, - alu_op_lte, - alu_op_mul, - alu_op_not, - alu_op_shl, - alu_op_shr, - alu_op_sub, - alu_p_a_borrow, - alu_p_b_borrow, - alu_p_sub_a_hi, - alu_p_sub_a_lo, - alu_p_sub_b_hi, - alu_p_sub_b_lo, - alu_partial_prod_hi, - alu_partial_prod_lo, - alu_quotient_hi, - alu_quotient_lo, - alu_remainder, - alu_res_hi, - alu_res_lo, - alu_sel_alu, - alu_sel_cmp, - alu_sel_div_rng_chk, - alu_sel_rng_chk, - alu_sel_rng_chk_lookup, - alu_sel_shift_which, - alu_shift_lt_bit_len, - alu_t_sub_s_bits, - alu_two_pow_s, - alu_two_pow_t_sub_s, - alu_u128_tag, - alu_u16_r0, - alu_u16_r1, - alu_u16_r10, - alu_u16_r11, - alu_u16_r12, - alu_u16_r13, - alu_u16_r14, - alu_u16_r2, - alu_u16_r3, - alu_u16_r4, - alu_u16_r5, - alu_u16_r6, - alu_u16_r7, - alu_u16_r8, - alu_u16_r9, - alu_u16_tag, - alu_u32_tag, - alu_u64_tag, - alu_u8_r0, - alu_u8_r1, - alu_u8_tag, - binary_acc_ia, - binary_acc_ib, - binary_acc_ic, - binary_clk, - binary_ia_bytes, - binary_ib_bytes, - binary_ic_bytes, - binary_in_tag, - binary_mem_tag_ctr, - binary_mem_tag_ctr_inv, - binary_op_id, - binary_sel_bin, - binary_start, - byte_lookup_sel_bin, - byte_lookup_table_byte_lengths, - byte_lookup_table_in_tags, - byte_lookup_table_input_a, - byte_lookup_table_input_b, - byte_lookup_table_op_id, - byte_lookup_table_output, - conversion_clk, - conversion_input, - conversion_num_limbs, - conversion_radix, - conversion_sel_to_radix_le, - gas_da_gas_fixed_table, - gas_l2_gas_fixed_table, - gas_sel_gas_cost, - keccakf1600_clk, - keccakf1600_input, - keccakf1600_output, - keccakf1600_sel_keccakf1600, - kernel_emit_l2_to_l1_msg_write_offset, - kernel_emit_note_hash_write_offset, - kernel_emit_nullifier_write_offset, - kernel_emit_unencrypted_log_write_offset, - kernel_kernel_in_offset, - kernel_kernel_out_offset, - kernel_l1_to_l2_msg_exists_write_offset, - kernel_note_hash_exist_write_offset, - kernel_nullifier_exists_write_offset, - kernel_nullifier_non_exists_write_offset, - kernel_q_public_input_kernel_add_to_table, - kernel_q_public_input_kernel_out_add_to_table, - kernel_side_effect_counter, - kernel_sload_write_offset, - kernel_sstore_write_offset, - main_abs_da_rem_gas_hi, - main_abs_da_rem_gas_lo, - main_abs_l2_rem_gas_hi, - main_abs_l2_rem_gas_lo, - main_alu_in_tag, - main_bin_op_id, - main_call_ptr, - main_da_gas_op_cost, - main_da_gas_remaining, - main_da_out_of_gas, - main_ia, - main_ib, - main_ic, - main_id, - main_id_zero, - main_ind_addr_a, - main_ind_addr_b, - main_ind_addr_c, - main_ind_addr_d, - main_internal_return_ptr, - main_inv, - main_l2_gas_op_cost, - main_l2_gas_remaining, - main_l2_out_of_gas, - main_mem_addr_a, - main_mem_addr_b, - main_mem_addr_c, - main_mem_addr_d, - main_op_err, - main_opcode_val, - main_pc, - main_r_in_tag, - main_rwa, - main_rwb, - main_rwc, - main_rwd, - main_sel_alu, - main_sel_bin, - main_sel_gas_accounting_active, - main_sel_last, - main_sel_mem_op_a, - main_sel_mem_op_activate_gas, - main_sel_mem_op_b, - main_sel_mem_op_c, - main_sel_mem_op_d, - main_sel_mov_ia_to_ic, - main_sel_mov_ib_to_ic, - main_sel_op_add, - main_sel_op_address, - main_sel_op_and, - main_sel_op_block_number, - main_sel_op_cast, - main_sel_op_chain_id, - main_sel_op_cmov, - main_sel_op_coinbase, - main_sel_op_dagasleft, - main_sel_op_div, - main_sel_op_emit_l2_to_l1_msg, - main_sel_op_emit_note_hash, - main_sel_op_emit_nullifier, - main_sel_op_emit_unencrypted_log, - main_sel_op_eq, - main_sel_op_external_call, - main_sel_op_fdiv, - main_sel_op_fee_per_da_gas, - main_sel_op_fee_per_l2_gas, - main_sel_op_function_selector, - main_sel_op_get_contract_instance, - main_sel_op_halt, - main_sel_op_internal_call, - main_sel_op_internal_return, - main_sel_op_jump, - main_sel_op_jumpi, - main_sel_op_keccak, - main_sel_op_l1_to_l2_msg_exists, - main_sel_op_l2gasleft, - main_sel_op_lt, - main_sel_op_lte, - main_sel_op_mov, - main_sel_op_mul, - main_sel_op_not, - main_sel_op_note_hash_exists, - main_sel_op_nullifier_exists, - main_sel_op_or, - main_sel_op_pedersen, - main_sel_op_poseidon2, - main_sel_op_radix_le, - main_sel_op_sender, - main_sel_op_sha256, - main_sel_op_shl, - main_sel_op_shr, - main_sel_op_sload, - main_sel_op_sstore, - main_sel_op_storage_address, - main_sel_op_sub, - main_sel_op_timestamp, - main_sel_op_transaction_fee, - main_sel_op_version, - main_sel_op_xor, - main_sel_q_kernel_lookup, - main_sel_q_kernel_output_lookup, - main_sel_resolve_ind_addr_a, - main_sel_resolve_ind_addr_b, - main_sel_resolve_ind_addr_c, - main_sel_resolve_ind_addr_d, - main_sel_rng_16, - main_sel_rng_8, - main_space_id, - main_tag_err, - main_w_in_tag, - mem_addr, - mem_clk, - mem_diff_hi, - mem_diff_lo, - mem_diff_mid, - mem_glob_addr, - mem_last, - mem_lastAccess, - mem_one_min_inv, - mem_r_in_tag, - mem_rw, - mem_sel_mem, - mem_sel_mov_ia_to_ic, - mem_sel_mov_ib_to_ic, - mem_sel_op_a, - mem_sel_op_b, - mem_sel_op_c, - mem_sel_op_cmov, - mem_sel_op_d, - mem_sel_resolve_ind_addr_a, - mem_sel_resolve_ind_addr_b, - mem_sel_resolve_ind_addr_c, - mem_sel_resolve_ind_addr_d, - mem_sel_rng_chk, - mem_skip_check_tag, - mem_space_id, - mem_tag, - mem_tag_err, - mem_tsp, - mem_val, - mem_w_in_tag, - pedersen_clk, - pedersen_input, - pedersen_output, - pedersen_sel_pedersen, - poseidon2_a_0, - poseidon2_a_1, - poseidon2_a_2, - poseidon2_a_3, - poseidon2_b_0, - poseidon2_b_1, - poseidon2_b_2, - poseidon2_b_3, - poseidon2_clk, - poseidon2_input, - poseidon2_output, - poseidon2_sel_poseidon_perm, - powers_power_of_2, - sha256_clk, - sha256_input, - sha256_output, - sha256_sel_sha256_compression, - sha256_state, ->>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) - perm_main_alu, - perm_main_bin, - perm_main_conv, - perm_main_pos2_perm, - perm_main_pedersen, - perm_main_mem_a, - perm_main_mem_b, - perm_main_mem_c, - perm_main_mem_d, - perm_main_mem_ind_addr_a, - perm_main_mem_ind_addr_b, - perm_main_mem_ind_addr_c, - perm_main_mem_ind_addr_d, - lookup_byte_lengths, - lookup_byte_operations, - lookup_opcode_gas, - range_check_l2_gas_hi, - range_check_l2_gas_lo, - range_check_da_gas_hi, - range_check_da_gas_lo, - kernel_output_lookup, - lookup_into_kernel, - incl_main_tag_err, - incl_mem_tag_err, - lookup_mem_rng_chk_lo, - lookup_mem_rng_chk_mid, - lookup_mem_rng_chk_hi, - lookup_pow_2_0, - lookup_pow_2_1, - lookup_u8_0, - lookup_u8_1, - lookup_u16_0, - lookup_u16_1, - lookup_u16_2, - lookup_u16_3, - lookup_u16_4, - lookup_u16_5, - lookup_u16_6, - lookup_u16_7, - lookup_u16_8, - lookup_u16_9, - lookup_u16_10, - lookup_u16_11, - lookup_u16_12, - lookup_u16_13, - lookup_u16_14, - lookup_div_u16_0, - lookup_div_u16_1, - lookup_div_u16_2, - lookup_div_u16_3, - lookup_div_u16_4, - lookup_div_u16_5, - lookup_div_u16_6, - lookup_div_u16_7) ->>>>>>> 804a62263 (feat(avm): poseidon2 constraints) }; template class ShiftedEntities { @@ -1401,1009 +281,11 @@ class AvmFlavor { auto get_unshifted() { -<<<<<<< HEAD return concatenate(PrecomputedEntities::get_all(), WitnessEntities::get_all()); } auto get_to_be_shifted() { return AvmFlavor::get_to_be_shifted(*this); } auto get_shifted() { return ShiftedEntities::get_all(); } auto get_precomputed() { return PrecomputedEntities::get_all(); } -======= - return { main_clk, - main_sel_first, - kernel_kernel_inputs, - kernel_kernel_value_out, - kernel_kernel_side_effect_out, - kernel_kernel_metadata_out, - main_calldata, - alu_a_hi, - alu_a_lo, - alu_b_hi, - alu_b_lo, - alu_borrow, - alu_cf, - alu_clk, - alu_cmp_rng_ctr, - alu_div_u16_r0, - alu_div_u16_r1, - alu_div_u16_r2, - alu_div_u16_r3, - alu_div_u16_r4, - alu_div_u16_r5, - alu_div_u16_r6, - alu_div_u16_r7, - alu_divisor_hi, - alu_divisor_lo, - alu_ff_tag, - alu_ia, - alu_ib, - alu_ic, - alu_in_tag, - alu_op_add, - alu_op_cast, - alu_op_cast_prev, - alu_op_div, - alu_op_div_a_lt_b, - alu_op_div_std, - alu_op_eq, - alu_op_eq_diff_inv, - alu_op_lt, - alu_op_lte, - alu_op_mul, - alu_op_not, - alu_op_shl, - alu_op_shr, - alu_op_sub, - alu_p_a_borrow, - alu_p_b_borrow, - alu_p_sub_a_hi, - alu_p_sub_a_lo, - alu_p_sub_b_hi, - alu_p_sub_b_lo, - alu_partial_prod_hi, - alu_partial_prod_lo, - alu_quotient_hi, - alu_quotient_lo, - alu_remainder, - alu_res_hi, - alu_res_lo, - alu_sel_alu, - alu_sel_cmp, - alu_sel_div_rng_chk, - alu_sel_rng_chk, - alu_sel_rng_chk_lookup, - alu_sel_shift_which, - alu_shift_lt_bit_len, - alu_t_sub_s_bits, - alu_two_pow_s, - alu_two_pow_t_sub_s, - alu_u128_tag, - alu_u16_r0, - alu_u16_r1, - alu_u16_r10, - alu_u16_r11, - alu_u16_r12, - alu_u16_r13, - alu_u16_r14, - alu_u16_r2, - alu_u16_r3, - alu_u16_r4, - alu_u16_r5, - alu_u16_r6, - alu_u16_r7, - alu_u16_r8, - alu_u16_r9, - alu_u16_tag, - alu_u32_tag, - alu_u64_tag, - alu_u8_r0, - alu_u8_r1, - alu_u8_tag, - binary_acc_ia, - binary_acc_ib, - binary_acc_ic, - binary_clk, - binary_ia_bytes, - binary_ib_bytes, - binary_ic_bytes, - binary_in_tag, - binary_mem_tag_ctr, - binary_mem_tag_ctr_inv, - binary_op_id, - binary_sel_bin, - binary_start, - byte_lookup_sel_bin, - byte_lookup_table_byte_lengths, - byte_lookup_table_in_tags, - byte_lookup_table_input_a, - byte_lookup_table_input_b, - byte_lookup_table_op_id, - byte_lookup_table_output, - conversion_clk, - conversion_input, - conversion_num_limbs, - conversion_radix, - conversion_sel_to_radix_le, - gas_da_gas_fixed_table, - gas_l2_gas_fixed_table, - gas_sel_gas_cost, - keccakf1600_clk, - keccakf1600_input, - keccakf1600_output, - keccakf1600_sel_keccakf1600, - kernel_emit_l2_to_l1_msg_write_offset, - kernel_emit_note_hash_write_offset, - kernel_emit_nullifier_write_offset, - kernel_emit_unencrypted_log_write_offset, - kernel_kernel_in_offset, - kernel_kernel_out_offset, - kernel_l1_to_l2_msg_exists_write_offset, - kernel_note_hash_exist_write_offset, - kernel_nullifier_exists_write_offset, - kernel_nullifier_non_exists_write_offset, - kernel_q_public_input_kernel_add_to_table, - kernel_q_public_input_kernel_out_add_to_table, - kernel_side_effect_counter, - kernel_sload_write_offset, - kernel_sstore_write_offset, - main_abs_da_rem_gas_hi, - main_abs_da_rem_gas_lo, - main_abs_l2_rem_gas_hi, - main_abs_l2_rem_gas_lo, - main_alu_in_tag, - main_bin_op_id, - main_call_ptr, - main_da_gas_op_cost, - main_da_gas_remaining, - main_da_out_of_gas, - main_ia, - main_ib, - main_ic, - main_id, - main_id_zero, - main_ind_addr_a, - main_ind_addr_b, - main_ind_addr_c, - main_ind_addr_d, - main_internal_return_ptr, - main_inv, - main_l2_gas_op_cost, - main_l2_gas_remaining, - main_l2_out_of_gas, - main_mem_addr_a, - main_mem_addr_b, - main_mem_addr_c, - main_mem_addr_d, - main_op_err, - main_opcode_val, - main_pc, - main_r_in_tag, - main_rwa, - main_rwb, - main_rwc, - main_rwd, - main_sel_alu, - main_sel_bin, - main_sel_gas_accounting_active, - main_sel_last, - main_sel_mem_op_a, - main_sel_mem_op_activate_gas, - main_sel_mem_op_b, - main_sel_mem_op_c, - main_sel_mem_op_d, - main_sel_mov_ia_to_ic, - main_sel_mov_ib_to_ic, - main_sel_op_add, - main_sel_op_address, - main_sel_op_and, - main_sel_op_block_number, - main_sel_op_cast, - main_sel_op_chain_id, - main_sel_op_cmov, - main_sel_op_coinbase, - main_sel_op_dagasleft, - main_sel_op_div, - main_sel_op_emit_l2_to_l1_msg, - main_sel_op_emit_note_hash, - main_sel_op_emit_nullifier, - main_sel_op_emit_unencrypted_log, - main_sel_op_eq, - main_sel_op_external_call, - main_sel_op_fdiv, - main_sel_op_fee_per_da_gas, - main_sel_op_fee_per_l2_gas, - main_sel_op_function_selector, - main_sel_op_get_contract_instance, - main_sel_op_halt, - main_sel_op_internal_call, - main_sel_op_internal_return, - main_sel_op_jump, - main_sel_op_jumpi, - main_sel_op_keccak, - main_sel_op_l1_to_l2_msg_exists, - main_sel_op_l2gasleft, - main_sel_op_lt, - main_sel_op_lte, - main_sel_op_mov, - main_sel_op_mul, - main_sel_op_not, - main_sel_op_note_hash_exists, - main_sel_op_nullifier_exists, - main_sel_op_or, - main_sel_op_pedersen, - main_sel_op_poseidon2, - main_sel_op_radix_le, - main_sel_op_sender, - main_sel_op_sha256, - main_sel_op_shl, - main_sel_op_shr, - main_sel_op_sload, - main_sel_op_sstore, - main_sel_op_storage_address, - main_sel_op_sub, - main_sel_op_timestamp, - main_sel_op_transaction_fee, - main_sel_op_version, - main_sel_op_xor, - main_sel_q_kernel_lookup, - main_sel_q_kernel_output_lookup, - main_sel_resolve_ind_addr_a, - main_sel_resolve_ind_addr_b, - main_sel_resolve_ind_addr_c, - main_sel_resolve_ind_addr_d, - main_sel_rng_16, - main_sel_rng_8, - main_space_id, - main_tag_err, - main_w_in_tag, - mem_addr, - mem_clk, - mem_diff_hi, - mem_diff_lo, - mem_diff_mid, - mem_glob_addr, - mem_last, - mem_lastAccess, - mem_one_min_inv, - mem_r_in_tag, - mem_rw, - mem_sel_mem, - mem_sel_mov_ia_to_ic, - mem_sel_mov_ib_to_ic, - mem_sel_op_a, - mem_sel_op_b, - mem_sel_op_c, - mem_sel_op_cmov, - mem_sel_op_d, - mem_sel_resolve_ind_addr_a, - mem_sel_resolve_ind_addr_b, - mem_sel_resolve_ind_addr_c, - mem_sel_resolve_ind_addr_d, - mem_sel_rng_chk, - mem_skip_check_tag, - mem_space_id, - mem_tag, - mem_tag_err, - mem_tsp, - mem_val, - mem_w_in_tag, - pedersen_clk, - pedersen_input, - pedersen_output, - pedersen_sel_pedersen, - poseidon2_a_0, - poseidon2_a_1, - poseidon2_a_2, - poseidon2_a_3, - poseidon2_b_0, - poseidon2_b_1, - poseidon2_b_2, - poseidon2_b_3, - poseidon2_clk, - poseidon2_input, - poseidon2_output, - poseidon2_sel_poseidon_perm, - powers_power_of_2, - sha256_clk, - sha256_input, - sha256_output, - sha256_sel_sha256_compression, - sha256_state, - perm_main_alu, - perm_main_bin, - perm_main_conv, - perm_main_pos2_perm, - perm_main_pedersen, - perm_main_mem_a, - perm_main_mem_b, - perm_main_mem_c, - perm_main_mem_d, - perm_main_mem_ind_addr_a, - perm_main_mem_ind_addr_b, - perm_main_mem_ind_addr_c, - perm_main_mem_ind_addr_d, - lookup_byte_lengths, - lookup_byte_operations, - lookup_opcode_gas, - range_check_l2_gas_hi, - range_check_l2_gas_lo, - range_check_da_gas_hi, - range_check_da_gas_lo, - kernel_output_lookup, - lookup_into_kernel, - incl_main_tag_err, - incl_mem_tag_err, - lookup_mem_rng_chk_lo, - lookup_mem_rng_chk_mid, - lookup_mem_rng_chk_hi, - lookup_pow_2_0, - lookup_pow_2_1, - lookup_u8_0, - lookup_u8_1, - lookup_u16_0, - lookup_u16_1, - lookup_u16_2, - lookup_u16_3, - lookup_u16_4, - lookup_u16_5, - lookup_u16_6, - lookup_u16_7, - lookup_u16_8, - lookup_u16_9, - lookup_u16_10, - lookup_u16_11, - lookup_u16_12, - lookup_u16_13, - lookup_u16_14, - lookup_div_u16_0, - lookup_div_u16_1, - lookup_div_u16_2, - lookup_div_u16_3, - lookup_div_u16_4, - lookup_div_u16_5, - lookup_div_u16_6, - lookup_div_u16_7, - lookup_byte_lengths_counts, - lookup_byte_operations_counts, - lookup_opcode_gas_counts, - range_check_l2_gas_hi_counts, - range_check_l2_gas_lo_counts, - range_check_da_gas_hi_counts, - range_check_da_gas_lo_counts, - kernel_output_lookup_counts, - lookup_into_kernel_counts, - incl_main_tag_err_counts, - incl_mem_tag_err_counts, - lookup_mem_rng_chk_lo_counts, - lookup_mem_rng_chk_mid_counts, - lookup_mem_rng_chk_hi_counts, - lookup_pow_2_0_counts, - lookup_pow_2_1_counts, - lookup_u8_0_counts, - lookup_u8_1_counts, - lookup_u16_0_counts, - lookup_u16_1_counts, - lookup_u16_2_counts, - lookup_u16_3_counts, - lookup_u16_4_counts, - lookup_u16_5_counts, - lookup_u16_6_counts, - lookup_u16_7_counts, - lookup_u16_8_counts, - lookup_u16_9_counts, - lookup_u16_10_counts, - lookup_u16_11_counts, - lookup_u16_12_counts, - lookup_u16_13_counts, - lookup_u16_14_counts, - lookup_div_u16_0_counts, - lookup_div_u16_1_counts, - lookup_div_u16_2_counts, - lookup_div_u16_3_counts, - lookup_div_u16_4_counts, - lookup_div_u16_5_counts, - lookup_div_u16_6_counts, - lookup_div_u16_7_counts, - alu_a_hi_shift, - alu_a_lo_shift, - alu_b_hi_shift, - alu_b_lo_shift, - alu_cmp_rng_ctr_shift, - alu_div_u16_r0_shift, - alu_div_u16_r1_shift, - alu_div_u16_r2_shift, - alu_div_u16_r3_shift, - alu_div_u16_r4_shift, - alu_div_u16_r5_shift, - alu_div_u16_r6_shift, - alu_div_u16_r7_shift, - alu_op_add_shift, - alu_op_cast_prev_shift, - alu_op_cast_shift, - alu_op_div_shift, - alu_op_mul_shift, - alu_op_shl_shift, - alu_op_shr_shift, - alu_op_sub_shift, - alu_p_sub_a_hi_shift, - alu_p_sub_a_lo_shift, - alu_p_sub_b_hi_shift, - alu_p_sub_b_lo_shift, - alu_sel_alu_shift, - alu_sel_cmp_shift, - alu_sel_div_rng_chk_shift, - alu_sel_rng_chk_lookup_shift, - alu_sel_rng_chk_shift, - alu_u16_r0_shift, - alu_u16_r1_shift, - alu_u16_r2_shift, - alu_u16_r3_shift, - alu_u16_r4_shift, - alu_u16_r5_shift, - alu_u16_r6_shift, - alu_u8_r0_shift, - alu_u8_r1_shift, - binary_acc_ia_shift, - binary_acc_ib_shift, - binary_acc_ic_shift, - binary_mem_tag_ctr_shift, - binary_op_id_shift, - kernel_emit_l2_to_l1_msg_write_offset_shift, - kernel_emit_note_hash_write_offset_shift, - kernel_emit_nullifier_write_offset_shift, - kernel_emit_unencrypted_log_write_offset_shift, - kernel_l1_to_l2_msg_exists_write_offset_shift, - kernel_note_hash_exist_write_offset_shift, - kernel_nullifier_exists_write_offset_shift, - kernel_nullifier_non_exists_write_offset_shift, - kernel_side_effect_counter_shift, - kernel_sload_write_offset_shift, - kernel_sstore_write_offset_shift, - main_da_gas_remaining_shift, - main_internal_return_ptr_shift, - main_l2_gas_remaining_shift, - main_pc_shift, - mem_glob_addr_shift, - mem_rw_shift, - mem_sel_mem_shift, - mem_tag_shift, - mem_tsp_shift, - mem_val_shift }; - }; - RefVector get_unshifted() - { - return { main_clk, - main_sel_first, - kernel_kernel_inputs, - kernel_kernel_value_out, - kernel_kernel_side_effect_out, - kernel_kernel_metadata_out, - main_calldata, - alu_a_hi, - alu_a_lo, - alu_b_hi, - alu_b_lo, - alu_borrow, - alu_cf, - alu_clk, - alu_cmp_rng_ctr, - alu_div_u16_r0, - alu_div_u16_r1, - alu_div_u16_r2, - alu_div_u16_r3, - alu_div_u16_r4, - alu_div_u16_r5, - alu_div_u16_r6, - alu_div_u16_r7, - alu_divisor_hi, - alu_divisor_lo, - alu_ff_tag, - alu_ia, - alu_ib, - alu_ic, - alu_in_tag, - alu_op_add, - alu_op_cast, - alu_op_cast_prev, - alu_op_div, - alu_op_div_a_lt_b, - alu_op_div_std, - alu_op_eq, - alu_op_eq_diff_inv, - alu_op_lt, - alu_op_lte, - alu_op_mul, - alu_op_not, - alu_op_shl, - alu_op_shr, - alu_op_sub, - alu_p_a_borrow, - alu_p_b_borrow, - alu_p_sub_a_hi, - alu_p_sub_a_lo, - alu_p_sub_b_hi, - alu_p_sub_b_lo, - alu_partial_prod_hi, - alu_partial_prod_lo, - alu_quotient_hi, - alu_quotient_lo, - alu_remainder, - alu_res_hi, - alu_res_lo, - alu_sel_alu, - alu_sel_cmp, - alu_sel_div_rng_chk, - alu_sel_rng_chk, - alu_sel_rng_chk_lookup, - alu_sel_shift_which, - alu_shift_lt_bit_len, - alu_t_sub_s_bits, - alu_two_pow_s, - alu_two_pow_t_sub_s, - alu_u128_tag, - alu_u16_r0, - alu_u16_r1, - alu_u16_r10, - alu_u16_r11, - alu_u16_r12, - alu_u16_r13, - alu_u16_r14, - alu_u16_r2, - alu_u16_r3, - alu_u16_r4, - alu_u16_r5, - alu_u16_r6, - alu_u16_r7, - alu_u16_r8, - alu_u16_r9, - alu_u16_tag, - alu_u32_tag, - alu_u64_tag, - alu_u8_r0, - alu_u8_r1, - alu_u8_tag, - binary_acc_ia, - binary_acc_ib, - binary_acc_ic, - binary_clk, - binary_ia_bytes, - binary_ib_bytes, - binary_ic_bytes, - binary_in_tag, - binary_mem_tag_ctr, - binary_mem_tag_ctr_inv, - binary_op_id, - binary_sel_bin, - binary_start, - byte_lookup_sel_bin, - byte_lookup_table_byte_lengths, - byte_lookup_table_in_tags, - byte_lookup_table_input_a, - byte_lookup_table_input_b, - byte_lookup_table_op_id, - byte_lookup_table_output, - conversion_clk, - conversion_input, - conversion_num_limbs, - conversion_radix, - conversion_sel_to_radix_le, - gas_da_gas_fixed_table, - gas_l2_gas_fixed_table, - gas_sel_gas_cost, - keccakf1600_clk, - keccakf1600_input, - keccakf1600_output, - keccakf1600_sel_keccakf1600, - kernel_emit_l2_to_l1_msg_write_offset, - kernel_emit_note_hash_write_offset, - kernel_emit_nullifier_write_offset, - kernel_emit_unencrypted_log_write_offset, - kernel_kernel_in_offset, - kernel_kernel_out_offset, - kernel_l1_to_l2_msg_exists_write_offset, - kernel_note_hash_exist_write_offset, - kernel_nullifier_exists_write_offset, - kernel_nullifier_non_exists_write_offset, - kernel_q_public_input_kernel_add_to_table, - kernel_q_public_input_kernel_out_add_to_table, - kernel_side_effect_counter, - kernel_sload_write_offset, - kernel_sstore_write_offset, - main_abs_da_rem_gas_hi, - main_abs_da_rem_gas_lo, - main_abs_l2_rem_gas_hi, - main_abs_l2_rem_gas_lo, - main_alu_in_tag, - main_bin_op_id, - main_call_ptr, - main_da_gas_op_cost, - main_da_gas_remaining, - main_da_out_of_gas, - main_ia, - main_ib, - main_ic, - main_id, - main_id_zero, - main_ind_addr_a, - main_ind_addr_b, - main_ind_addr_c, - main_ind_addr_d, - main_internal_return_ptr, - main_inv, - main_l2_gas_op_cost, - main_l2_gas_remaining, - main_l2_out_of_gas, - main_mem_addr_a, - main_mem_addr_b, - main_mem_addr_c, - main_mem_addr_d, - main_op_err, - main_opcode_val, - main_pc, - main_r_in_tag, - main_rwa, - main_rwb, - main_rwc, - main_rwd, - main_sel_alu, - main_sel_bin, - main_sel_gas_accounting_active, - main_sel_last, - main_sel_mem_op_a, - main_sel_mem_op_activate_gas, - main_sel_mem_op_b, - main_sel_mem_op_c, - main_sel_mem_op_d, - main_sel_mov_ia_to_ic, - main_sel_mov_ib_to_ic, - main_sel_op_add, - main_sel_op_address, - main_sel_op_and, - main_sel_op_block_number, - main_sel_op_cast, - main_sel_op_chain_id, - main_sel_op_cmov, - main_sel_op_coinbase, - main_sel_op_dagasleft, - main_sel_op_div, - main_sel_op_emit_l2_to_l1_msg, - main_sel_op_emit_note_hash, - main_sel_op_emit_nullifier, - main_sel_op_emit_unencrypted_log, - main_sel_op_eq, - main_sel_op_external_call, - main_sel_op_fdiv, - main_sel_op_fee_per_da_gas, - main_sel_op_fee_per_l2_gas, - main_sel_op_function_selector, - main_sel_op_get_contract_instance, - main_sel_op_halt, - main_sel_op_internal_call, - main_sel_op_internal_return, - main_sel_op_jump, - main_sel_op_jumpi, - main_sel_op_keccak, - main_sel_op_l1_to_l2_msg_exists, - main_sel_op_l2gasleft, - main_sel_op_lt, - main_sel_op_lte, - main_sel_op_mov, - main_sel_op_mul, - main_sel_op_not, - main_sel_op_note_hash_exists, - main_sel_op_nullifier_exists, - main_sel_op_or, - main_sel_op_pedersen, - main_sel_op_poseidon2, - main_sel_op_radix_le, - main_sel_op_sender, - main_sel_op_sha256, - main_sel_op_shl, - main_sel_op_shr, - main_sel_op_sload, - main_sel_op_sstore, - main_sel_op_storage_address, - main_sel_op_sub, - main_sel_op_timestamp, - main_sel_op_transaction_fee, - main_sel_op_version, - main_sel_op_xor, - main_sel_q_kernel_lookup, - main_sel_q_kernel_output_lookup, - main_sel_resolve_ind_addr_a, - main_sel_resolve_ind_addr_b, - main_sel_resolve_ind_addr_c, - main_sel_resolve_ind_addr_d, - main_sel_rng_16, - main_sel_rng_8, - main_space_id, - main_tag_err, - main_w_in_tag, - mem_addr, - mem_clk, - mem_diff_hi, - mem_diff_lo, - mem_diff_mid, - mem_glob_addr, - mem_last, - mem_lastAccess, - mem_one_min_inv, - mem_r_in_tag, - mem_rw, - mem_sel_mem, - mem_sel_mov_ia_to_ic, - mem_sel_mov_ib_to_ic, - mem_sel_op_a, - mem_sel_op_b, - mem_sel_op_c, - mem_sel_op_cmov, - mem_sel_op_d, - mem_sel_resolve_ind_addr_a, - mem_sel_resolve_ind_addr_b, - mem_sel_resolve_ind_addr_c, - mem_sel_resolve_ind_addr_d, - mem_sel_rng_chk, - mem_skip_check_tag, - mem_space_id, - mem_tag, - mem_tag_err, - mem_tsp, - mem_val, - mem_w_in_tag, - pedersen_clk, - pedersen_input, - pedersen_output, - pedersen_sel_pedersen, - poseidon2_a_0, - poseidon2_a_1, - poseidon2_a_2, - poseidon2_a_3, - poseidon2_b_0, - poseidon2_b_1, - poseidon2_b_2, - poseidon2_b_3, - poseidon2_clk, - poseidon2_input, - poseidon2_output, - poseidon2_sel_poseidon_perm, - powers_power_of_2, - sha256_clk, - sha256_input, - sha256_output, - sha256_sel_sha256_compression, - sha256_state, - perm_main_alu, - perm_main_bin, - perm_main_conv, - perm_main_pos2_perm, - perm_main_pedersen, - perm_main_mem_a, - perm_main_mem_b, - perm_main_mem_c, - perm_main_mem_d, - perm_main_mem_ind_addr_a, - perm_main_mem_ind_addr_b, - perm_main_mem_ind_addr_c, - perm_main_mem_ind_addr_d, - lookup_byte_lengths, - lookup_byte_operations, - lookup_opcode_gas, - range_check_l2_gas_hi, - range_check_l2_gas_lo, - range_check_da_gas_hi, - range_check_da_gas_lo, - kernel_output_lookup, - lookup_into_kernel, - incl_main_tag_err, - incl_mem_tag_err, - lookup_mem_rng_chk_lo, - lookup_mem_rng_chk_mid, - lookup_mem_rng_chk_hi, - lookup_pow_2_0, - lookup_pow_2_1, - lookup_u8_0, - lookup_u8_1, - lookup_u16_0, - lookup_u16_1, - lookup_u16_2, - lookup_u16_3, - lookup_u16_4, - lookup_u16_5, - lookup_u16_6, - lookup_u16_7, - lookup_u16_8, - lookup_u16_9, - lookup_u16_10, - lookup_u16_11, - lookup_u16_12, - lookup_u16_13, - lookup_u16_14, - lookup_div_u16_0, - lookup_div_u16_1, - lookup_div_u16_2, - lookup_div_u16_3, - lookup_div_u16_4, - lookup_div_u16_5, - lookup_div_u16_6, - lookup_div_u16_7, - lookup_byte_lengths_counts, - lookup_byte_operations_counts, - lookup_opcode_gas_counts, - range_check_l2_gas_hi_counts, - range_check_l2_gas_lo_counts, - range_check_da_gas_hi_counts, - range_check_da_gas_lo_counts, - kernel_output_lookup_counts, - lookup_into_kernel_counts, - incl_main_tag_err_counts, - incl_mem_tag_err_counts, - lookup_mem_rng_chk_lo_counts, - lookup_mem_rng_chk_mid_counts, - lookup_mem_rng_chk_hi_counts, - lookup_pow_2_0_counts, - lookup_pow_2_1_counts, - lookup_u8_0_counts, - lookup_u8_1_counts, - lookup_u16_0_counts, - lookup_u16_1_counts, - lookup_u16_2_counts, - lookup_u16_3_counts, - lookup_u16_4_counts, - lookup_u16_5_counts, - lookup_u16_6_counts, - lookup_u16_7_counts, - lookup_u16_8_counts, - lookup_u16_9_counts, - lookup_u16_10_counts, - lookup_u16_11_counts, - lookup_u16_12_counts, - lookup_u16_13_counts, - lookup_u16_14_counts, - lookup_div_u16_0_counts, - lookup_div_u16_1_counts, - lookup_div_u16_2_counts, - lookup_div_u16_3_counts, - lookup_div_u16_4_counts, - lookup_div_u16_5_counts, - lookup_div_u16_6_counts, - lookup_div_u16_7_counts }; - }; - RefVector get_to_be_shifted() - { - return { alu_a_hi, - alu_a_lo, - alu_b_hi, - alu_b_lo, - alu_cmp_rng_ctr, - alu_div_u16_r0, - alu_div_u16_r1, - alu_div_u16_r2, - alu_div_u16_r3, - alu_div_u16_r4, - alu_div_u16_r5, - alu_div_u16_r6, - alu_div_u16_r7, - alu_op_add, - alu_op_cast_prev, - alu_op_cast, - alu_op_div, - alu_op_mul, - alu_op_shl, - alu_op_shr, - alu_op_sub, - alu_p_sub_a_hi, - alu_p_sub_a_lo, - alu_p_sub_b_hi, - alu_p_sub_b_lo, - alu_sel_alu, - alu_sel_cmp, - alu_sel_div_rng_chk, - alu_sel_rng_chk_lookup, - alu_sel_rng_chk, - alu_u16_r0, - alu_u16_r1, - alu_u16_r2, - alu_u16_r3, - alu_u16_r4, - alu_u16_r5, - alu_u16_r6, - alu_u8_r0, - alu_u8_r1, - binary_acc_ia, - binary_acc_ib, - binary_acc_ic, - binary_mem_tag_ctr, - binary_op_id, - kernel_emit_l2_to_l1_msg_write_offset, - kernel_emit_note_hash_write_offset, - kernel_emit_nullifier_write_offset, - kernel_emit_unencrypted_log_write_offset, - kernel_l1_to_l2_msg_exists_write_offset, - kernel_note_hash_exist_write_offset, - kernel_nullifier_exists_write_offset, - kernel_nullifier_non_exists_write_offset, - kernel_side_effect_counter, - kernel_sload_write_offset, - kernel_sstore_write_offset, - main_da_gas_remaining, - main_internal_return_ptr, - main_l2_gas_remaining, - main_pc, - mem_glob_addr, - mem_rw, - mem_sel_mem, - mem_tag, - mem_tsp, - mem_val }; - }; - RefVector get_shifted() - { - return { alu_a_hi_shift, - alu_a_lo_shift, - alu_b_hi_shift, - alu_b_lo_shift, - alu_cmp_rng_ctr_shift, - alu_div_u16_r0_shift, - alu_div_u16_r1_shift, - alu_div_u16_r2_shift, - alu_div_u16_r3_shift, - alu_div_u16_r4_shift, - alu_div_u16_r5_shift, - alu_div_u16_r6_shift, - alu_div_u16_r7_shift, - alu_op_add_shift, - alu_op_cast_prev_shift, - alu_op_cast_shift, - alu_op_div_shift, - alu_op_mul_shift, - alu_op_shl_shift, - alu_op_shr_shift, - alu_op_sub_shift, - alu_p_sub_a_hi_shift, - alu_p_sub_a_lo_shift, - alu_p_sub_b_hi_shift, - alu_p_sub_b_lo_shift, - alu_sel_alu_shift, - alu_sel_cmp_shift, - alu_sel_div_rng_chk_shift, - alu_sel_rng_chk_lookup_shift, - alu_sel_rng_chk_shift, - alu_u16_r0_shift, - alu_u16_r1_shift, - alu_u16_r2_shift, - alu_u16_r3_shift, - alu_u16_r4_shift, - alu_u16_r5_shift, - alu_u16_r6_shift, - alu_u8_r0_shift, - alu_u8_r1_shift, - binary_acc_ia_shift, - binary_acc_ib_shift, - binary_acc_ic_shift, - binary_mem_tag_ctr_shift, - binary_op_id_shift, - kernel_emit_l2_to_l1_msg_write_offset_shift, - kernel_emit_note_hash_write_offset_shift, - kernel_emit_nullifier_write_offset_shift, - kernel_emit_unencrypted_log_write_offset_shift, - kernel_l1_to_l2_msg_exists_write_offset_shift, - kernel_note_hash_exist_write_offset_shift, - kernel_nullifier_exists_write_offset_shift, - kernel_nullifier_non_exists_write_offset_shift, - kernel_side_effect_counter_shift, - kernel_sload_write_offset_shift, - kernel_sstore_write_offset_shift, - main_da_gas_remaining_shift, - main_internal_return_ptr_shift, - main_l2_gas_remaining_shift, - main_pc_shift, - mem_glob_addr_shift, - mem_rw_shift, - mem_sel_mem_shift, - mem_tag_shift, - mem_tsp_shift, - mem_val_shift }; - }; ->>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) }; public: @@ -2431,7 +313,7 @@ class AvmFlavor { DEFINE_FLAVOR_MEMBERS(DataType, ALL_ENTITIES) - AllConstRefValues(const RefArray& il) + AllConstRefValues(const RefArray& il) : main_clk(il[0]) , main_sel_first(il[1]) , kernel_kernel_inputs(il[2]) @@ -2704,219 +586,509 @@ class AvmFlavor { , mem_sel_op_c(il[269]) , mem_sel_op_cmov(il[270]) , mem_sel_op_d(il[271]) - , mem_sel_op_slice(il[272]) - , mem_sel_resolve_ind_addr_a(il[273]) - , mem_sel_resolve_ind_addr_b(il[274]) - , mem_sel_resolve_ind_addr_c(il[275]) - , mem_sel_resolve_ind_addr_d(il[276]) - , mem_sel_rng_chk(il[277]) - , mem_skip_check_tag(il[278]) - , mem_space_id(il[279]) - , mem_tag(il[280]) - , mem_tag_err(il[281]) - , mem_tsp(il[282]) - , mem_val(il[283]) - , mem_w_in_tag(il[284]) - , pedersen_clk(il[285]) - , pedersen_input(il[286]) - , pedersen_output(il[287]) - , pedersen_sel_pedersen(il[288]) - , poseidon2_clk(il[289]) - , poseidon2_input(il[290]) - , poseidon2_output(il[291]) - , poseidon2_sel_poseidon_perm(il[292]) - , powers_power_of_2(il[293]) - , sha256_clk(il[294]) - , sha256_input(il[295]) - , sha256_output(il[296]) - , sha256_sel_sha256_compression(il[297]) - , sha256_state(il[298]) - , slice_addr(il[299]) - , slice_clk(il[300]) - , slice_cnt(il[301]) - , slice_col_offset(il[302]) - , slice_one_min_inv(il[303]) - , slice_sel_cd_cpy(il[304]) - , slice_sel_mem_active(il[305]) - , slice_sel_return(il[306]) - , slice_sel_start(il[307]) - , slice_space_id(il[308]) - , slice_val(il[309]) - , lookup_byte_lengths_counts(il[310]) - , lookup_byte_operations_counts(il[311]) - , lookup_cd_value_counts(il[312]) - , lookup_ret_value_counts(il[313]) - , lookup_opcode_gas_counts(il[314]) - , range_check_l2_gas_hi_counts(il[315]) - , range_check_l2_gas_lo_counts(il[316]) - , range_check_da_gas_hi_counts(il[317]) - , range_check_da_gas_lo_counts(il[318]) - , kernel_output_lookup_counts(il[319]) - , lookup_into_kernel_counts(il[320]) - , incl_main_tag_err_counts(il[321]) - , incl_mem_tag_err_counts(il[322]) - , lookup_mem_rng_chk_lo_counts(il[323]) - , lookup_mem_rng_chk_mid_counts(il[324]) - , lookup_mem_rng_chk_hi_counts(il[325]) - , lookup_pow_2_0_counts(il[326]) - , lookup_pow_2_1_counts(il[327]) - , lookup_u8_0_counts(il[328]) - , lookup_u8_1_counts(il[329]) - , lookup_u16_0_counts(il[330]) - , lookup_u16_1_counts(il[331]) - , lookup_u16_2_counts(il[332]) - , lookup_u16_3_counts(il[333]) - , lookup_u16_4_counts(il[334]) - , lookup_u16_5_counts(il[335]) - , lookup_u16_6_counts(il[336]) - , lookup_u16_7_counts(il[337]) - , lookup_u16_8_counts(il[338]) - , lookup_u16_9_counts(il[339]) - , lookup_u16_10_counts(il[340]) - , lookup_u16_11_counts(il[341]) - , lookup_u16_12_counts(il[342]) - , lookup_u16_13_counts(il[343]) - , lookup_u16_14_counts(il[344]) - , lookup_div_u16_0_counts(il[345]) - , lookup_div_u16_1_counts(il[346]) - , lookup_div_u16_2_counts(il[347]) - , lookup_div_u16_3_counts(il[348]) - , lookup_div_u16_4_counts(il[349]) - , lookup_div_u16_5_counts(il[350]) - , lookup_div_u16_6_counts(il[351]) - , lookup_div_u16_7_counts(il[352]) - , perm_slice_mem(il[353]) - , perm_main_alu(il[354]) - , perm_main_bin(il[355]) - , perm_main_conv(il[356]) - , perm_main_pos2_perm(il[357]) - , perm_main_pedersen(il[358]) - , perm_main_slice(il[359]) - , perm_main_mem_a(il[360]) - , perm_main_mem_b(il[361]) - , perm_main_mem_c(il[362]) - , perm_main_mem_d(il[363]) - , perm_main_mem_ind_addr_a(il[364]) - , perm_main_mem_ind_addr_b(il[365]) - , perm_main_mem_ind_addr_c(il[366]) - , perm_main_mem_ind_addr_d(il[367]) - , lookup_byte_lengths(il[368]) - , lookup_byte_operations(il[369]) - , lookup_cd_value(il[370]) - , lookup_ret_value(il[371]) - , lookup_opcode_gas(il[372]) - , range_check_l2_gas_hi(il[373]) - , range_check_l2_gas_lo(il[374]) - , range_check_da_gas_hi(il[375]) - , range_check_da_gas_lo(il[376]) - , kernel_output_lookup(il[377]) - , lookup_into_kernel(il[378]) - , incl_main_tag_err(il[379]) - , incl_mem_tag_err(il[380]) - , lookup_mem_rng_chk_lo(il[381]) - , lookup_mem_rng_chk_mid(il[382]) - , lookup_mem_rng_chk_hi(il[383]) - , lookup_pow_2_0(il[384]) - , lookup_pow_2_1(il[385]) - , lookup_u8_0(il[386]) - , lookup_u8_1(il[387]) - , lookup_u16_0(il[388]) - , lookup_u16_1(il[389]) - , lookup_u16_2(il[390]) - , lookup_u16_3(il[391]) - , lookup_u16_4(il[392]) - , lookup_u16_5(il[393]) - , lookup_u16_6(il[394]) - , lookup_u16_7(il[395]) - , lookup_u16_8(il[396]) - , lookup_u16_9(il[397]) - , lookup_u16_10(il[398]) - , lookup_u16_11(il[399]) - , lookup_u16_12(il[400]) - , lookup_u16_13(il[401]) - , lookup_u16_14(il[402]) - , lookup_div_u16_0(il[403]) - , lookup_div_u16_1(il[404]) - , lookup_div_u16_2(il[405]) - , lookup_div_u16_3(il[406]) - , lookup_div_u16_4(il[407]) - , lookup_div_u16_5(il[408]) - , lookup_div_u16_6(il[409]) - , lookup_div_u16_7(il[410]) - , alu_a_hi_shift(il[411]) - , alu_a_lo_shift(il[412]) - , alu_b_hi_shift(il[413]) - , alu_b_lo_shift(il[414]) - , alu_cmp_rng_ctr_shift(il[415]) - , alu_div_u16_r0_shift(il[416]) - , alu_div_u16_r1_shift(il[417]) - , alu_div_u16_r2_shift(il[418]) - , alu_div_u16_r3_shift(il[419]) - , alu_div_u16_r4_shift(il[420]) - , alu_div_u16_r5_shift(il[421]) - , alu_div_u16_r6_shift(il[422]) - , alu_div_u16_r7_shift(il[423]) - , alu_op_add_shift(il[424]) - , alu_op_cast_prev_shift(il[425]) - , alu_op_cast_shift(il[426]) - , alu_op_div_shift(il[427]) - , alu_op_mul_shift(il[428]) - , alu_op_shl_shift(il[429]) - , alu_op_shr_shift(il[430]) - , alu_op_sub_shift(il[431]) - , alu_p_sub_a_hi_shift(il[432]) - , alu_p_sub_a_lo_shift(il[433]) - , alu_p_sub_b_hi_shift(il[434]) - , alu_p_sub_b_lo_shift(il[435]) - , alu_sel_alu_shift(il[436]) - , alu_sel_cmp_shift(il[437]) - , alu_sel_div_rng_chk_shift(il[438]) - , alu_sel_rng_chk_lookup_shift(il[439]) - , alu_sel_rng_chk_shift(il[440]) - , alu_u16_r0_shift(il[441]) - , alu_u16_r1_shift(il[442]) - , alu_u16_r2_shift(il[443]) - , alu_u16_r3_shift(il[444]) - , alu_u16_r4_shift(il[445]) - , alu_u16_r5_shift(il[446]) - , alu_u16_r6_shift(il[447]) - , alu_u8_r0_shift(il[448]) - , alu_u8_r1_shift(il[449]) - , binary_acc_ia_shift(il[450]) - , binary_acc_ib_shift(il[451]) - , binary_acc_ic_shift(il[452]) - , binary_mem_tag_ctr_shift(il[453]) - , binary_op_id_shift(il[454]) - , kernel_emit_l2_to_l1_msg_write_offset_shift(il[455]) - , kernel_emit_note_hash_write_offset_shift(il[456]) - , kernel_emit_nullifier_write_offset_shift(il[457]) - , kernel_emit_unencrypted_log_write_offset_shift(il[458]) - , kernel_l1_to_l2_msg_exists_write_offset_shift(il[459]) - , kernel_note_hash_exist_write_offset_shift(il[460]) - , kernel_nullifier_exists_write_offset_shift(il[461]) - , kernel_nullifier_non_exists_write_offset_shift(il[462]) - , kernel_side_effect_counter_shift(il[463]) - , kernel_sload_write_offset_shift(il[464]) - , kernel_sstore_write_offset_shift(il[465]) - , main_da_gas_remaining_shift(il[466]) - , main_internal_return_ptr_shift(il[467]) - , main_l2_gas_remaining_shift(il[468]) - , main_pc_shift(il[469]) - , mem_glob_addr_shift(il[470]) - , mem_rw_shift(il[471]) - , mem_sel_mem_shift(il[472]) - , mem_tag_shift(il[473]) - , mem_tsp_shift(il[474]) - , mem_val_shift(il[475]) - , slice_addr_shift(il[476]) - , slice_clk_shift(il[477]) - , slice_cnt_shift(il[478]) - , slice_col_offset_shift(il[479]) - , slice_sel_cd_cpy_shift(il[480]) - , slice_sel_mem_active_shift(il[481]) - , slice_sel_return_shift(il[482]) - , slice_sel_start_shift(il[483]) - , slice_space_id_shift(il[484]) + , mem_sel_op_gadget_a(il[272]) + , mem_sel_op_gadget_b(il[273]) + , mem_sel_op_gadget_c(il[274]) + , mem_sel_op_gadget_d(il[275]) + , mem_sel_op_slice(il[276]) + , mem_sel_resolve_ind_addr_a(il[277]) + , mem_sel_resolve_ind_addr_b(il[278]) + , mem_sel_resolve_ind_addr_c(il[279]) + , mem_sel_resolve_ind_addr_d(il[280]) + , mem_sel_rng_chk(il[281]) + , mem_skip_check_tag(il[282]) + , mem_space_id(il[283]) + , mem_tag(il[284]) + , mem_tag_err(il[285]) + , mem_tsp(il[286]) + , mem_val(il[287]) + , mem_w_in_tag(il[288]) + , pedersen_clk(il[289]) + , pedersen_input(il[290]) + , pedersen_output(il[291]) + , pedersen_sel_pedersen(il[292]) + , poseidon2_B_10_0(il[293]) + , poseidon2_B_10_1(il[294]) + , poseidon2_B_10_2(il[295]) + , poseidon2_B_10_3(il[296]) + , poseidon2_B_11_0(il[297]) + , poseidon2_B_11_1(il[298]) + , poseidon2_B_11_2(il[299]) + , poseidon2_B_11_3(il[300]) + , poseidon2_B_12_0(il[301]) + , poseidon2_B_12_1(il[302]) + , poseidon2_B_12_2(il[303]) + , poseidon2_B_12_3(il[304]) + , poseidon2_B_13_0(il[305]) + , poseidon2_B_13_1(il[306]) + , poseidon2_B_13_2(il[307]) + , poseidon2_B_13_3(il[308]) + , poseidon2_B_14_0(il[309]) + , poseidon2_B_14_1(il[310]) + , poseidon2_B_14_2(il[311]) + , poseidon2_B_14_3(il[312]) + , poseidon2_B_15_0(il[313]) + , poseidon2_B_15_1(il[314]) + , poseidon2_B_15_2(il[315]) + , poseidon2_B_15_3(il[316]) + , poseidon2_B_16_0(il[317]) + , poseidon2_B_16_1(il[318]) + , poseidon2_B_16_2(il[319]) + , poseidon2_B_16_3(il[320]) + , poseidon2_B_17_0(il[321]) + , poseidon2_B_17_1(il[322]) + , poseidon2_B_17_2(il[323]) + , poseidon2_B_17_3(il[324]) + , poseidon2_B_18_0(il[325]) + , poseidon2_B_18_1(il[326]) + , poseidon2_B_18_2(il[327]) + , poseidon2_B_18_3(il[328]) + , poseidon2_B_19_0(il[329]) + , poseidon2_B_19_1(il[330]) + , poseidon2_B_19_2(il[331]) + , poseidon2_B_19_3(il[332]) + , poseidon2_B_20_0(il[333]) + , poseidon2_B_20_1(il[334]) + , poseidon2_B_20_2(il[335]) + , poseidon2_B_20_3(il[336]) + , poseidon2_B_21_0(il[337]) + , poseidon2_B_21_1(il[338]) + , poseidon2_B_21_2(il[339]) + , poseidon2_B_21_3(il[340]) + , poseidon2_B_22_0(il[341]) + , poseidon2_B_22_1(il[342]) + , poseidon2_B_22_2(il[343]) + , poseidon2_B_22_3(il[344]) + , poseidon2_B_23_0(il[345]) + , poseidon2_B_23_1(il[346]) + , poseidon2_B_23_2(il[347]) + , poseidon2_B_23_3(il[348]) + , poseidon2_B_24_0(il[349]) + , poseidon2_B_24_1(il[350]) + , poseidon2_B_24_2(il[351]) + , poseidon2_B_24_3(il[352]) + , poseidon2_B_25_0(il[353]) + , poseidon2_B_25_1(il[354]) + , poseidon2_B_25_2(il[355]) + , poseidon2_B_25_3(il[356]) + , poseidon2_B_26_0(il[357]) + , poseidon2_B_26_1(il[358]) + , poseidon2_B_26_2(il[359]) + , poseidon2_B_26_3(il[360]) + , poseidon2_B_27_0(il[361]) + , poseidon2_B_27_1(il[362]) + , poseidon2_B_27_2(il[363]) + , poseidon2_B_27_3(il[364]) + , poseidon2_B_28_0(il[365]) + , poseidon2_B_28_1(il[366]) + , poseidon2_B_28_2(il[367]) + , poseidon2_B_28_3(il[368]) + , poseidon2_B_29_0(il[369]) + , poseidon2_B_29_1(il[370]) + , poseidon2_B_29_2(il[371]) + , poseidon2_B_29_3(il[372]) + , poseidon2_B_30_0(il[373]) + , poseidon2_B_30_1(il[374]) + , poseidon2_B_30_2(il[375]) + , poseidon2_B_30_3(il[376]) + , poseidon2_B_31_0(il[377]) + , poseidon2_B_31_1(il[378]) + , poseidon2_B_31_2(il[379]) + , poseidon2_B_31_3(il[380]) + , poseidon2_B_32_0(il[381]) + , poseidon2_B_32_1(il[382]) + , poseidon2_B_32_2(il[383]) + , poseidon2_B_32_3(il[384]) + , poseidon2_B_33_0(il[385]) + , poseidon2_B_33_1(il[386]) + , poseidon2_B_33_2(il[387]) + , poseidon2_B_33_3(il[388]) + , poseidon2_B_34_0(il[389]) + , poseidon2_B_34_1(il[390]) + , poseidon2_B_34_2(il[391]) + , poseidon2_B_34_3(il[392]) + , poseidon2_B_35_0(il[393]) + , poseidon2_B_35_1(il[394]) + , poseidon2_B_35_2(il[395]) + , poseidon2_B_35_3(il[396]) + , poseidon2_B_36_0(il[397]) + , poseidon2_B_36_1(il[398]) + , poseidon2_B_36_2(il[399]) + , poseidon2_B_36_3(il[400]) + , poseidon2_B_37_0(il[401]) + , poseidon2_B_37_1(il[402]) + , poseidon2_B_37_2(il[403]) + , poseidon2_B_37_3(il[404]) + , poseidon2_B_38_0(il[405]) + , poseidon2_B_38_1(il[406]) + , poseidon2_B_38_2(il[407]) + , poseidon2_B_38_3(il[408]) + , poseidon2_B_39_0(il[409]) + , poseidon2_B_39_1(il[410]) + , poseidon2_B_39_2(il[411]) + , poseidon2_B_39_3(il[412]) + , poseidon2_B_40_0(il[413]) + , poseidon2_B_40_1(il[414]) + , poseidon2_B_40_2(il[415]) + , poseidon2_B_40_3(il[416]) + , poseidon2_B_41_0(il[417]) + , poseidon2_B_41_1(il[418]) + , poseidon2_B_41_2(il[419]) + , poseidon2_B_41_3(il[420]) + , poseidon2_B_42_0(il[421]) + , poseidon2_B_42_1(il[422]) + , poseidon2_B_42_2(il[423]) + , poseidon2_B_42_3(il[424]) + , poseidon2_B_43_0(il[425]) + , poseidon2_B_43_1(il[426]) + , poseidon2_B_43_2(il[427]) + , poseidon2_B_43_3(il[428]) + , poseidon2_B_44_0(il[429]) + , poseidon2_B_44_1(il[430]) + , poseidon2_B_44_2(il[431]) + , poseidon2_B_44_3(il[432]) + , poseidon2_B_45_0(il[433]) + , poseidon2_B_45_1(il[434]) + , poseidon2_B_45_2(il[435]) + , poseidon2_B_45_3(il[436]) + , poseidon2_B_46_0(il[437]) + , poseidon2_B_46_1(il[438]) + , poseidon2_B_46_2(il[439]) + , poseidon2_B_46_3(il[440]) + , poseidon2_B_47_0(il[441]) + , poseidon2_B_47_1(il[442]) + , poseidon2_B_47_2(il[443]) + , poseidon2_B_47_3(il[444]) + , poseidon2_B_48_0(il[445]) + , poseidon2_B_48_1(il[446]) + , poseidon2_B_48_2(il[447]) + , poseidon2_B_48_3(il[448]) + , poseidon2_B_49_0(il[449]) + , poseidon2_B_49_1(il[450]) + , poseidon2_B_49_2(il[451]) + , poseidon2_B_49_3(il[452]) + , poseidon2_B_4_0(il[453]) + , poseidon2_B_4_1(il[454]) + , poseidon2_B_4_2(il[455]) + , poseidon2_B_4_3(il[456]) + , poseidon2_B_50_0(il[457]) + , poseidon2_B_50_1(il[458]) + , poseidon2_B_50_2(il[459]) + , poseidon2_B_50_3(il[460]) + , poseidon2_B_51_0(il[461]) + , poseidon2_B_51_1(il[462]) + , poseidon2_B_51_2(il[463]) + , poseidon2_B_51_3(il[464]) + , poseidon2_B_52_0(il[465]) + , poseidon2_B_52_1(il[466]) + , poseidon2_B_52_2(il[467]) + , poseidon2_B_52_3(il[468]) + , poseidon2_B_53_0(il[469]) + , poseidon2_B_53_1(il[470]) + , poseidon2_B_53_2(il[471]) + , poseidon2_B_53_3(il[472]) + , poseidon2_B_54_0(il[473]) + , poseidon2_B_54_1(il[474]) + , poseidon2_B_54_2(il[475]) + , poseidon2_B_54_3(il[476]) + , poseidon2_B_55_0(il[477]) + , poseidon2_B_55_1(il[478]) + , poseidon2_B_55_2(il[479]) + , poseidon2_B_55_3(il[480]) + , poseidon2_B_56_0(il[481]) + , poseidon2_B_56_1(il[482]) + , poseidon2_B_56_2(il[483]) + , poseidon2_B_56_3(il[484]) + , poseidon2_B_57_0(il[485]) + , poseidon2_B_57_1(il[486]) + , poseidon2_B_57_2(il[487]) + , poseidon2_B_57_3(il[488]) + , poseidon2_B_58_0(il[489]) + , poseidon2_B_58_1(il[490]) + , poseidon2_B_58_2(il[491]) + , poseidon2_B_58_3(il[492]) + , poseidon2_B_59_0(il[493]) + , poseidon2_B_59_1(il[494]) + , poseidon2_B_59_2(il[495]) + , poseidon2_B_59_3(il[496]) + , poseidon2_B_5_0(il[497]) + , poseidon2_B_5_1(il[498]) + , poseidon2_B_5_2(il[499]) + , poseidon2_B_5_3(il[500]) + , poseidon2_B_6_0(il[501]) + , poseidon2_B_6_1(il[502]) + , poseidon2_B_6_2(il[503]) + , poseidon2_B_6_3(il[504]) + , poseidon2_B_7_0(il[505]) + , poseidon2_B_7_1(il[506]) + , poseidon2_B_7_2(il[507]) + , poseidon2_B_7_3(il[508]) + , poseidon2_B_8_0(il[509]) + , poseidon2_B_8_1(il[510]) + , poseidon2_B_8_2(il[511]) + , poseidon2_B_8_3(il[512]) + , poseidon2_B_9_0(il[513]) + , poseidon2_B_9_1(il[514]) + , poseidon2_B_9_2(il[515]) + , poseidon2_B_9_3(il[516]) + , poseidon2_EXT_LAYER_4(il[517]) + , poseidon2_EXT_LAYER_5(il[518]) + , poseidon2_EXT_LAYER_6(il[519]) + , poseidon2_EXT_LAYER_7(il[520]) + , poseidon2_T_0_4(il[521]) + , poseidon2_T_0_5(il[522]) + , poseidon2_T_0_6(il[523]) + , poseidon2_T_0_7(il[524]) + , poseidon2_T_1_4(il[525]) + , poseidon2_T_1_5(il[526]) + , poseidon2_T_1_6(il[527]) + , poseidon2_T_1_7(il[528]) + , poseidon2_T_2_4(il[529]) + , poseidon2_T_2_5(il[530]) + , poseidon2_T_2_6(il[531]) + , poseidon2_T_2_7(il[532]) + , poseidon2_T_3_4(il[533]) + , poseidon2_T_3_5(il[534]) + , poseidon2_T_3_6(il[535]) + , poseidon2_T_3_7(il[536]) + , poseidon2_T_60_4(il[537]) + , poseidon2_T_60_5(il[538]) + , poseidon2_T_60_6(il[539]) + , poseidon2_T_60_7(il[540]) + , poseidon2_T_61_4(il[541]) + , poseidon2_T_61_5(il[542]) + , poseidon2_T_61_6(il[543]) + , poseidon2_T_61_7(il[544]) + , poseidon2_T_62_4(il[545]) + , poseidon2_T_62_5(il[546]) + , poseidon2_T_62_6(il[547]) + , poseidon2_T_62_7(il[548]) + , poseidon2_T_63_4(il[549]) + , poseidon2_T_63_5(il[550]) + , poseidon2_T_63_6(il[551]) + , poseidon2_T_63_7(il[552]) + , poseidon2_a_0(il[553]) + , poseidon2_a_1(il[554]) + , poseidon2_a_2(il[555]) + , poseidon2_a_3(il[556]) + , poseidon2_b_0(il[557]) + , poseidon2_b_1(il[558]) + , poseidon2_b_2(il[559]) + , poseidon2_b_3(il[560]) + , poseidon2_clk(il[561]) + , poseidon2_in_tag(il[562]) + , poseidon2_input_addr(il[563]) + , poseidon2_mem_addr_a(il[564]) + , poseidon2_mem_addr_b(il[565]) + , poseidon2_mem_addr_c(il[566]) + , poseidon2_mem_addr_d(il[567]) + , poseidon2_mem_op(il[568]) + , poseidon2_output_addr(il[569]) + , poseidon2_read_line(il[570]) + , poseidon2_sel_poseidon_perm(il[571]) + , poseidon2_write_line(il[572]) + , powers_power_of_2(il[573]) + , sha256_clk(il[574]) + , sha256_input(il[575]) + , sha256_output(il[576]) + , sha256_sel_sha256_compression(il[577]) + , sha256_state(il[578]) + , slice_addr(il[579]) + , slice_clk(il[580]) + , slice_cnt(il[581]) + , slice_col_offset(il[582]) + , slice_one_min_inv(il[583]) + , slice_sel_cd_cpy(il[584]) + , slice_sel_mem_active(il[585]) + , slice_sel_return(il[586]) + , slice_sel_start(il[587]) + , slice_space_id(il[588]) + , slice_val(il[589]) + , lookup_byte_lengths_counts(il[590]) + , lookup_byte_operations_counts(il[591]) + , lookup_cd_value_counts(il[592]) + , lookup_ret_value_counts(il[593]) + , lookup_opcode_gas_counts(il[594]) + , range_check_l2_gas_hi_counts(il[595]) + , range_check_l2_gas_lo_counts(il[596]) + , range_check_da_gas_hi_counts(il[597]) + , range_check_da_gas_lo_counts(il[598]) + , kernel_output_lookup_counts(il[599]) + , lookup_into_kernel_counts(il[600]) + , incl_main_tag_err_counts(il[601]) + , incl_mem_tag_err_counts(il[602]) + , lookup_mem_rng_chk_lo_counts(il[603]) + , lookup_mem_rng_chk_mid_counts(il[604]) + , lookup_mem_rng_chk_hi_counts(il[605]) + , lookup_pow_2_0_counts(il[606]) + , lookup_pow_2_1_counts(il[607]) + , lookup_u8_0_counts(il[608]) + , lookup_u8_1_counts(il[609]) + , lookup_u16_0_counts(il[610]) + , lookup_u16_1_counts(il[611]) + , lookup_u16_2_counts(il[612]) + , lookup_u16_3_counts(il[613]) + , lookup_u16_4_counts(il[614]) + , lookup_u16_5_counts(il[615]) + , lookup_u16_6_counts(il[616]) + , lookup_u16_7_counts(il[617]) + , lookup_u16_8_counts(il[618]) + , lookup_u16_9_counts(il[619]) + , lookup_u16_10_counts(il[620]) + , lookup_u16_11_counts(il[621]) + , lookup_u16_12_counts(il[622]) + , lookup_u16_13_counts(il[623]) + , lookup_u16_14_counts(il[624]) + , lookup_div_u16_0_counts(il[625]) + , lookup_div_u16_1_counts(il[626]) + , lookup_div_u16_2_counts(il[627]) + , lookup_div_u16_3_counts(il[628]) + , lookup_div_u16_4_counts(il[629]) + , lookup_div_u16_5_counts(il[630]) + , lookup_div_u16_6_counts(il[631]) + , lookup_div_u16_7_counts(il[632]) + , perm_pos_mem_a(il[633]) + , perm_pos_mem_b(il[634]) + , perm_pos_mem_c(il[635]) + , perm_pos_mem_d(il[636]) + , perm_slice_mem(il[637]) + , perm_main_alu(il[638]) + , perm_main_bin(il[639]) + , perm_main_conv(il[640]) + , perm_main_pos2_perm(il[641]) + , perm_main_pedersen(il[642]) + , perm_main_slice(il[643]) + , perm_main_mem_a(il[644]) + , perm_main_mem_b(il[645]) + , perm_main_mem_c(il[646]) + , perm_main_mem_d(il[647]) + , perm_main_mem_ind_addr_a(il[648]) + , perm_main_mem_ind_addr_b(il[649]) + , perm_main_mem_ind_addr_c(il[650]) + , perm_main_mem_ind_addr_d(il[651]) + , lookup_byte_lengths(il[652]) + , lookup_byte_operations(il[653]) + , lookup_cd_value(il[654]) + , lookup_ret_value(il[655]) + , lookup_opcode_gas(il[656]) + , range_check_l2_gas_hi(il[657]) + , range_check_l2_gas_lo(il[658]) + , range_check_da_gas_hi(il[659]) + , range_check_da_gas_lo(il[660]) + , kernel_output_lookup(il[661]) + , lookup_into_kernel(il[662]) + , incl_main_tag_err(il[663]) + , incl_mem_tag_err(il[664]) + , lookup_mem_rng_chk_lo(il[665]) + , lookup_mem_rng_chk_mid(il[666]) + , lookup_mem_rng_chk_hi(il[667]) + , lookup_pow_2_0(il[668]) + , lookup_pow_2_1(il[669]) + , lookup_u8_0(il[670]) + , lookup_u8_1(il[671]) + , lookup_u16_0(il[672]) + , lookup_u16_1(il[673]) + , lookup_u16_2(il[674]) + , lookup_u16_3(il[675]) + , lookup_u16_4(il[676]) + , lookup_u16_5(il[677]) + , lookup_u16_6(il[678]) + , lookup_u16_7(il[679]) + , lookup_u16_8(il[680]) + , lookup_u16_9(il[681]) + , lookup_u16_10(il[682]) + , lookup_u16_11(il[683]) + , lookup_u16_12(il[684]) + , lookup_u16_13(il[685]) + , lookup_u16_14(il[686]) + , lookup_div_u16_0(il[687]) + , lookup_div_u16_1(il[688]) + , lookup_div_u16_2(il[689]) + , lookup_div_u16_3(il[690]) + , lookup_div_u16_4(il[691]) + , lookup_div_u16_5(il[692]) + , lookup_div_u16_6(il[693]) + , lookup_div_u16_7(il[694]) + , alu_a_hi_shift(il[695]) + , alu_a_lo_shift(il[696]) + , alu_b_hi_shift(il[697]) + , alu_b_lo_shift(il[698]) + , alu_cmp_rng_ctr_shift(il[699]) + , alu_div_u16_r0_shift(il[700]) + , alu_div_u16_r1_shift(il[701]) + , alu_div_u16_r2_shift(il[702]) + , alu_div_u16_r3_shift(il[703]) + , alu_div_u16_r4_shift(il[704]) + , alu_div_u16_r5_shift(il[705]) + , alu_div_u16_r6_shift(il[706]) + , alu_div_u16_r7_shift(il[707]) + , alu_op_add_shift(il[708]) + , alu_op_cast_prev_shift(il[709]) + , alu_op_cast_shift(il[710]) + , alu_op_div_shift(il[711]) + , alu_op_mul_shift(il[712]) + , alu_op_shl_shift(il[713]) + , alu_op_shr_shift(il[714]) + , alu_op_sub_shift(il[715]) + , alu_p_sub_a_hi_shift(il[716]) + , alu_p_sub_a_lo_shift(il[717]) + , alu_p_sub_b_hi_shift(il[718]) + , alu_p_sub_b_lo_shift(il[719]) + , alu_sel_alu_shift(il[720]) + , alu_sel_cmp_shift(il[721]) + , alu_sel_div_rng_chk_shift(il[722]) + , alu_sel_rng_chk_lookup_shift(il[723]) + , alu_sel_rng_chk_shift(il[724]) + , alu_u16_r0_shift(il[725]) + , alu_u16_r1_shift(il[726]) + , alu_u16_r2_shift(il[727]) + , alu_u16_r3_shift(il[728]) + , alu_u16_r4_shift(il[729]) + , alu_u16_r5_shift(il[730]) + , alu_u16_r6_shift(il[731]) + , alu_u8_r0_shift(il[732]) + , alu_u8_r1_shift(il[733]) + , binary_acc_ia_shift(il[734]) + , binary_acc_ib_shift(il[735]) + , binary_acc_ic_shift(il[736]) + , binary_mem_tag_ctr_shift(il[737]) + , binary_op_id_shift(il[738]) + , kernel_emit_l2_to_l1_msg_write_offset_shift(il[739]) + , kernel_emit_note_hash_write_offset_shift(il[740]) + , kernel_emit_nullifier_write_offset_shift(il[741]) + , kernel_emit_unencrypted_log_write_offset_shift(il[742]) + , kernel_l1_to_l2_msg_exists_write_offset_shift(il[743]) + , kernel_note_hash_exist_write_offset_shift(il[744]) + , kernel_nullifier_exists_write_offset_shift(il[745]) + , kernel_nullifier_non_exists_write_offset_shift(il[746]) + , kernel_side_effect_counter_shift(il[747]) + , kernel_sload_write_offset_shift(il[748]) + , kernel_sstore_write_offset_shift(il[749]) + , main_da_gas_remaining_shift(il[750]) + , main_internal_return_ptr_shift(il[751]) + , main_l2_gas_remaining_shift(il[752]) + , main_pc_shift(il[753]) + , mem_glob_addr_shift(il[754]) + , mem_rw_shift(il[755]) + , mem_sel_mem_shift(il[756]) + , mem_tag_shift(il[757]) + , mem_tsp_shift(il[758]) + , mem_val_shift(il[759]) + , poseidon2_a_0_shift(il[760]) + , poseidon2_a_1_shift(il[761]) + , poseidon2_a_2_shift(il[762]) + , poseidon2_a_3_shift(il[763]) + , poseidon2_sel_poseidon_perm_shift(il[764]) + , poseidon2_write_line_shift(il[765]) + , slice_addr_shift(il[766]) + , slice_clk_shift(il[767]) + , slice_cnt_shift(il[768]) + , slice_col_offset_shift(il[769]) + , slice_sel_cd_cpy_shift(il[770]) + , slice_sel_mem_active_shift(il[771]) + , slice_sel_return_shift(il[772]) + , slice_sel_start_shift(il[773]) + , slice_space_id_shift(il[774]) {} }; @@ -3224,6 +1396,10 @@ class AvmFlavor { mem_sel_op_c[row_idx], mem_sel_op_cmov[row_idx], mem_sel_op_d[row_idx], + mem_sel_op_gadget_a[row_idx], + mem_sel_op_gadget_b[row_idx], + mem_sel_op_gadget_c[row_idx], + mem_sel_op_gadget_d[row_idx], mem_sel_op_slice[row_idx], mem_sel_resolve_ind_addr_a[row_idx], mem_sel_resolve_ind_addr_b[row_idx], @@ -3241,10 +1417,286 @@ class AvmFlavor { pedersen_input[row_idx], pedersen_output[row_idx], pedersen_sel_pedersen[row_idx], + poseidon2_B_10_0[row_idx], + poseidon2_B_10_1[row_idx], + poseidon2_B_10_2[row_idx], + poseidon2_B_10_3[row_idx], + poseidon2_B_11_0[row_idx], + poseidon2_B_11_1[row_idx], + poseidon2_B_11_2[row_idx], + poseidon2_B_11_3[row_idx], + poseidon2_B_12_0[row_idx], + poseidon2_B_12_1[row_idx], + poseidon2_B_12_2[row_idx], + poseidon2_B_12_3[row_idx], + poseidon2_B_13_0[row_idx], + poseidon2_B_13_1[row_idx], + poseidon2_B_13_2[row_idx], + poseidon2_B_13_3[row_idx], + poseidon2_B_14_0[row_idx], + poseidon2_B_14_1[row_idx], + poseidon2_B_14_2[row_idx], + poseidon2_B_14_3[row_idx], + poseidon2_B_15_0[row_idx], + poseidon2_B_15_1[row_idx], + poseidon2_B_15_2[row_idx], + poseidon2_B_15_3[row_idx], + poseidon2_B_16_0[row_idx], + poseidon2_B_16_1[row_idx], + poseidon2_B_16_2[row_idx], + poseidon2_B_16_3[row_idx], + poseidon2_B_17_0[row_idx], + poseidon2_B_17_1[row_idx], + poseidon2_B_17_2[row_idx], + poseidon2_B_17_3[row_idx], + poseidon2_B_18_0[row_idx], + poseidon2_B_18_1[row_idx], + poseidon2_B_18_2[row_idx], + poseidon2_B_18_3[row_idx], + poseidon2_B_19_0[row_idx], + poseidon2_B_19_1[row_idx], + poseidon2_B_19_2[row_idx], + poseidon2_B_19_3[row_idx], + poseidon2_B_20_0[row_idx], + poseidon2_B_20_1[row_idx], + poseidon2_B_20_2[row_idx], + poseidon2_B_20_3[row_idx], + poseidon2_B_21_0[row_idx], + poseidon2_B_21_1[row_idx], + poseidon2_B_21_2[row_idx], + poseidon2_B_21_3[row_idx], + poseidon2_B_22_0[row_idx], + poseidon2_B_22_1[row_idx], + poseidon2_B_22_2[row_idx], + poseidon2_B_22_3[row_idx], + poseidon2_B_23_0[row_idx], + poseidon2_B_23_1[row_idx], + poseidon2_B_23_2[row_idx], + poseidon2_B_23_3[row_idx], + poseidon2_B_24_0[row_idx], + poseidon2_B_24_1[row_idx], + poseidon2_B_24_2[row_idx], + poseidon2_B_24_3[row_idx], + poseidon2_B_25_0[row_idx], + poseidon2_B_25_1[row_idx], + poseidon2_B_25_2[row_idx], + poseidon2_B_25_3[row_idx], + poseidon2_B_26_0[row_idx], + poseidon2_B_26_1[row_idx], + poseidon2_B_26_2[row_idx], + poseidon2_B_26_3[row_idx], + poseidon2_B_27_0[row_idx], + poseidon2_B_27_1[row_idx], + poseidon2_B_27_2[row_idx], + poseidon2_B_27_3[row_idx], + poseidon2_B_28_0[row_idx], + poseidon2_B_28_1[row_idx], + poseidon2_B_28_2[row_idx], + poseidon2_B_28_3[row_idx], + poseidon2_B_29_0[row_idx], + poseidon2_B_29_1[row_idx], + poseidon2_B_29_2[row_idx], + poseidon2_B_29_3[row_idx], + poseidon2_B_30_0[row_idx], + poseidon2_B_30_1[row_idx], + poseidon2_B_30_2[row_idx], + poseidon2_B_30_3[row_idx], + poseidon2_B_31_0[row_idx], + poseidon2_B_31_1[row_idx], + poseidon2_B_31_2[row_idx], + poseidon2_B_31_3[row_idx], + poseidon2_B_32_0[row_idx], + poseidon2_B_32_1[row_idx], + poseidon2_B_32_2[row_idx], + poseidon2_B_32_3[row_idx], + poseidon2_B_33_0[row_idx], + poseidon2_B_33_1[row_idx], + poseidon2_B_33_2[row_idx], + poseidon2_B_33_3[row_idx], + poseidon2_B_34_0[row_idx], + poseidon2_B_34_1[row_idx], + poseidon2_B_34_2[row_idx], + poseidon2_B_34_3[row_idx], + poseidon2_B_35_0[row_idx], + poseidon2_B_35_1[row_idx], + poseidon2_B_35_2[row_idx], + poseidon2_B_35_3[row_idx], + poseidon2_B_36_0[row_idx], + poseidon2_B_36_1[row_idx], + poseidon2_B_36_2[row_idx], + poseidon2_B_36_3[row_idx], + poseidon2_B_37_0[row_idx], + poseidon2_B_37_1[row_idx], + poseidon2_B_37_2[row_idx], + poseidon2_B_37_3[row_idx], + poseidon2_B_38_0[row_idx], + poseidon2_B_38_1[row_idx], + poseidon2_B_38_2[row_idx], + poseidon2_B_38_3[row_idx], + poseidon2_B_39_0[row_idx], + poseidon2_B_39_1[row_idx], + poseidon2_B_39_2[row_idx], + poseidon2_B_39_3[row_idx], + poseidon2_B_40_0[row_idx], + poseidon2_B_40_1[row_idx], + poseidon2_B_40_2[row_idx], + poseidon2_B_40_3[row_idx], + poseidon2_B_41_0[row_idx], + poseidon2_B_41_1[row_idx], + poseidon2_B_41_2[row_idx], + poseidon2_B_41_3[row_idx], + poseidon2_B_42_0[row_idx], + poseidon2_B_42_1[row_idx], + poseidon2_B_42_2[row_idx], + poseidon2_B_42_3[row_idx], + poseidon2_B_43_0[row_idx], + poseidon2_B_43_1[row_idx], + poseidon2_B_43_2[row_idx], + poseidon2_B_43_3[row_idx], + poseidon2_B_44_0[row_idx], + poseidon2_B_44_1[row_idx], + poseidon2_B_44_2[row_idx], + poseidon2_B_44_3[row_idx], + poseidon2_B_45_0[row_idx], + poseidon2_B_45_1[row_idx], + poseidon2_B_45_2[row_idx], + poseidon2_B_45_3[row_idx], + poseidon2_B_46_0[row_idx], + poseidon2_B_46_1[row_idx], + poseidon2_B_46_2[row_idx], + poseidon2_B_46_3[row_idx], + poseidon2_B_47_0[row_idx], + poseidon2_B_47_1[row_idx], + poseidon2_B_47_2[row_idx], + poseidon2_B_47_3[row_idx], + poseidon2_B_48_0[row_idx], + poseidon2_B_48_1[row_idx], + poseidon2_B_48_2[row_idx], + poseidon2_B_48_3[row_idx], + poseidon2_B_49_0[row_idx], + poseidon2_B_49_1[row_idx], + poseidon2_B_49_2[row_idx], + poseidon2_B_49_3[row_idx], + poseidon2_B_4_0[row_idx], + poseidon2_B_4_1[row_idx], + poseidon2_B_4_2[row_idx], + poseidon2_B_4_3[row_idx], + poseidon2_B_50_0[row_idx], + poseidon2_B_50_1[row_idx], + poseidon2_B_50_2[row_idx], + poseidon2_B_50_3[row_idx], + poseidon2_B_51_0[row_idx], + poseidon2_B_51_1[row_idx], + poseidon2_B_51_2[row_idx], + poseidon2_B_51_3[row_idx], + poseidon2_B_52_0[row_idx], + poseidon2_B_52_1[row_idx], + poseidon2_B_52_2[row_idx], + poseidon2_B_52_3[row_idx], + poseidon2_B_53_0[row_idx], + poseidon2_B_53_1[row_idx], + poseidon2_B_53_2[row_idx], + poseidon2_B_53_3[row_idx], + poseidon2_B_54_0[row_idx], + poseidon2_B_54_1[row_idx], + poseidon2_B_54_2[row_idx], + poseidon2_B_54_3[row_idx], + poseidon2_B_55_0[row_idx], + poseidon2_B_55_1[row_idx], + poseidon2_B_55_2[row_idx], + poseidon2_B_55_3[row_idx], + poseidon2_B_56_0[row_idx], + poseidon2_B_56_1[row_idx], + poseidon2_B_56_2[row_idx], + poseidon2_B_56_3[row_idx], + poseidon2_B_57_0[row_idx], + poseidon2_B_57_1[row_idx], + poseidon2_B_57_2[row_idx], + poseidon2_B_57_3[row_idx], + poseidon2_B_58_0[row_idx], + poseidon2_B_58_1[row_idx], + poseidon2_B_58_2[row_idx], + poseidon2_B_58_3[row_idx], + poseidon2_B_59_0[row_idx], + poseidon2_B_59_1[row_idx], + poseidon2_B_59_2[row_idx], + poseidon2_B_59_3[row_idx], + poseidon2_B_5_0[row_idx], + poseidon2_B_5_1[row_idx], + poseidon2_B_5_2[row_idx], + poseidon2_B_5_3[row_idx], + poseidon2_B_6_0[row_idx], + poseidon2_B_6_1[row_idx], + poseidon2_B_6_2[row_idx], + poseidon2_B_6_3[row_idx], + poseidon2_B_7_0[row_idx], + poseidon2_B_7_1[row_idx], + poseidon2_B_7_2[row_idx], + poseidon2_B_7_3[row_idx], + poseidon2_B_8_0[row_idx], + poseidon2_B_8_1[row_idx], + poseidon2_B_8_2[row_idx], + poseidon2_B_8_3[row_idx], + poseidon2_B_9_0[row_idx], + poseidon2_B_9_1[row_idx], + poseidon2_B_9_2[row_idx], + poseidon2_B_9_3[row_idx], + poseidon2_EXT_LAYER_4[row_idx], + poseidon2_EXT_LAYER_5[row_idx], + poseidon2_EXT_LAYER_6[row_idx], + poseidon2_EXT_LAYER_7[row_idx], + poseidon2_T_0_4[row_idx], + poseidon2_T_0_5[row_idx], + poseidon2_T_0_6[row_idx], + poseidon2_T_0_7[row_idx], + poseidon2_T_1_4[row_idx], + poseidon2_T_1_5[row_idx], + poseidon2_T_1_6[row_idx], + poseidon2_T_1_7[row_idx], + poseidon2_T_2_4[row_idx], + poseidon2_T_2_5[row_idx], + poseidon2_T_2_6[row_idx], + poseidon2_T_2_7[row_idx], + poseidon2_T_3_4[row_idx], + poseidon2_T_3_5[row_idx], + poseidon2_T_3_6[row_idx], + poseidon2_T_3_7[row_idx], + poseidon2_T_60_4[row_idx], + poseidon2_T_60_5[row_idx], + poseidon2_T_60_6[row_idx], + poseidon2_T_60_7[row_idx], + poseidon2_T_61_4[row_idx], + poseidon2_T_61_5[row_idx], + poseidon2_T_61_6[row_idx], + poseidon2_T_61_7[row_idx], + poseidon2_T_62_4[row_idx], + poseidon2_T_62_5[row_idx], + poseidon2_T_62_6[row_idx], + poseidon2_T_62_7[row_idx], + poseidon2_T_63_4[row_idx], + poseidon2_T_63_5[row_idx], + poseidon2_T_63_6[row_idx], + poseidon2_T_63_7[row_idx], + poseidon2_a_0[row_idx], + poseidon2_a_1[row_idx], + poseidon2_a_2[row_idx], + poseidon2_a_3[row_idx], + poseidon2_b_0[row_idx], + poseidon2_b_1[row_idx], + poseidon2_b_2[row_idx], + poseidon2_b_3[row_idx], poseidon2_clk[row_idx], - poseidon2_input[row_idx], - poseidon2_output[row_idx], + poseidon2_in_tag[row_idx], + poseidon2_input_addr[row_idx], + poseidon2_mem_addr_a[row_idx], + poseidon2_mem_addr_b[row_idx], + poseidon2_mem_addr_c[row_idx], + poseidon2_mem_addr_d[row_idx], + poseidon2_mem_op[row_idx], + poseidon2_output_addr[row_idx], + poseidon2_read_line[row_idx], poseidon2_sel_poseidon_perm[row_idx], + poseidon2_write_line[row_idx], powers_power_of_2[row_idx], sha256_clk[row_idx], sha256_input[row_idx], @@ -3305,6 +1757,10 @@ class AvmFlavor { lookup_div_u16_5_counts[row_idx], lookup_div_u16_6_counts[row_idx], lookup_div_u16_7_counts[row_idx], + perm_pos_mem_a[row_idx], + perm_pos_mem_b[row_idx], + perm_pos_mem_c[row_idx], + perm_pos_mem_d[row_idx], perm_slice_mem[row_idx], perm_main_alu[row_idx], perm_main_bin[row_idx], @@ -3428,6 +1884,12 @@ class AvmFlavor { mem_tag_shift[row_idx], mem_tsp_shift[row_idx], mem_val_shift[row_idx], + poseidon2_a_0_shift[row_idx], + poseidon2_a_1_shift[row_idx], + poseidon2_a_2_shift[row_idx], + poseidon2_a_3_shift[row_idx], + poseidon2_sel_poseidon_perm_shift[row_idx], + poseidon2_write_line_shift[row_idx], slice_addr_shift[row_idx], slice_clk_shift[row_idx], slice_cnt_shift[row_idx], @@ -3756,6 +2218,10 @@ class AvmFlavor { Base::mem_sel_op_c = "MEM_SEL_OP_C"; Base::mem_sel_op_cmov = "MEM_SEL_OP_CMOV"; Base::mem_sel_op_d = "MEM_SEL_OP_D"; + Base::mem_sel_op_gadget_a = "MEM_SEL_OP_GADGET_A"; + Base::mem_sel_op_gadget_b = "MEM_SEL_OP_GADGET_B"; + Base::mem_sel_op_gadget_c = "MEM_SEL_OP_GADGET_C"; + Base::mem_sel_op_gadget_d = "MEM_SEL_OP_GADGET_D"; Base::mem_sel_op_slice = "MEM_SEL_OP_SLICE"; Base::mem_sel_resolve_ind_addr_a = "MEM_SEL_RESOLVE_IND_ADDR_A"; Base::mem_sel_resolve_ind_addr_b = "MEM_SEL_RESOLVE_IND_ADDR_B"; @@ -3773,6 +2239,266 @@ class AvmFlavor { Base::pedersen_input = "PEDERSEN_INPUT"; Base::pedersen_output = "PEDERSEN_OUTPUT"; Base::pedersen_sel_pedersen = "PEDERSEN_SEL_PEDERSEN"; + Base::poseidon2_B_10_0 = "POSEIDON2_B_10_0"; + Base::poseidon2_B_10_1 = "POSEIDON2_B_10_1"; + Base::poseidon2_B_10_2 = "POSEIDON2_B_10_2"; + Base::poseidon2_B_10_3 = "POSEIDON2_B_10_3"; + Base::poseidon2_B_11_0 = "POSEIDON2_B_11_0"; + Base::poseidon2_B_11_1 = "POSEIDON2_B_11_1"; + Base::poseidon2_B_11_2 = "POSEIDON2_B_11_2"; + Base::poseidon2_B_11_3 = "POSEIDON2_B_11_3"; + Base::poseidon2_B_12_0 = "POSEIDON2_B_12_0"; + Base::poseidon2_B_12_1 = "POSEIDON2_B_12_1"; + Base::poseidon2_B_12_2 = "POSEIDON2_B_12_2"; + Base::poseidon2_B_12_3 = "POSEIDON2_B_12_3"; + Base::poseidon2_B_13_0 = "POSEIDON2_B_13_0"; + Base::poseidon2_B_13_1 = "POSEIDON2_B_13_1"; + Base::poseidon2_B_13_2 = "POSEIDON2_B_13_2"; + Base::poseidon2_B_13_3 = "POSEIDON2_B_13_3"; + Base::poseidon2_B_14_0 = "POSEIDON2_B_14_0"; + Base::poseidon2_B_14_1 = "POSEIDON2_B_14_1"; + Base::poseidon2_B_14_2 = "POSEIDON2_B_14_2"; + Base::poseidon2_B_14_3 = "POSEIDON2_B_14_3"; + Base::poseidon2_B_15_0 = "POSEIDON2_B_15_0"; + Base::poseidon2_B_15_1 = "POSEIDON2_B_15_1"; + Base::poseidon2_B_15_2 = "POSEIDON2_B_15_2"; + Base::poseidon2_B_15_3 = "POSEIDON2_B_15_3"; + Base::poseidon2_B_16_0 = "POSEIDON2_B_16_0"; + Base::poseidon2_B_16_1 = "POSEIDON2_B_16_1"; + Base::poseidon2_B_16_2 = "POSEIDON2_B_16_2"; + Base::poseidon2_B_16_3 = "POSEIDON2_B_16_3"; + Base::poseidon2_B_17_0 = "POSEIDON2_B_17_0"; + Base::poseidon2_B_17_1 = "POSEIDON2_B_17_1"; + Base::poseidon2_B_17_2 = "POSEIDON2_B_17_2"; + Base::poseidon2_B_17_3 = "POSEIDON2_B_17_3"; + Base::poseidon2_B_18_0 = "POSEIDON2_B_18_0"; + Base::poseidon2_B_18_1 = "POSEIDON2_B_18_1"; + Base::poseidon2_B_18_2 = "POSEIDON2_B_18_2"; + Base::poseidon2_B_18_3 = "POSEIDON2_B_18_3"; + Base::poseidon2_B_19_0 = "POSEIDON2_B_19_0"; + Base::poseidon2_B_19_1 = "POSEIDON2_B_19_1"; + Base::poseidon2_B_19_2 = "POSEIDON2_B_19_2"; + Base::poseidon2_B_19_3 = "POSEIDON2_B_19_3"; + Base::poseidon2_B_20_0 = "POSEIDON2_B_20_0"; + Base::poseidon2_B_20_1 = "POSEIDON2_B_20_1"; + Base::poseidon2_B_20_2 = "POSEIDON2_B_20_2"; + Base::poseidon2_B_20_3 = "POSEIDON2_B_20_3"; + Base::poseidon2_B_21_0 = "POSEIDON2_B_21_0"; + Base::poseidon2_B_21_1 = "POSEIDON2_B_21_1"; + Base::poseidon2_B_21_2 = "POSEIDON2_B_21_2"; + Base::poseidon2_B_21_3 = "POSEIDON2_B_21_3"; + Base::poseidon2_B_22_0 = "POSEIDON2_B_22_0"; + Base::poseidon2_B_22_1 = "POSEIDON2_B_22_1"; + Base::poseidon2_B_22_2 = "POSEIDON2_B_22_2"; + Base::poseidon2_B_22_3 = "POSEIDON2_B_22_3"; + Base::poseidon2_B_23_0 = "POSEIDON2_B_23_0"; + Base::poseidon2_B_23_1 = "POSEIDON2_B_23_1"; + Base::poseidon2_B_23_2 = "POSEIDON2_B_23_2"; + Base::poseidon2_B_23_3 = "POSEIDON2_B_23_3"; + Base::poseidon2_B_24_0 = "POSEIDON2_B_24_0"; + Base::poseidon2_B_24_1 = "POSEIDON2_B_24_1"; + Base::poseidon2_B_24_2 = "POSEIDON2_B_24_2"; + Base::poseidon2_B_24_3 = "POSEIDON2_B_24_3"; + Base::poseidon2_B_25_0 = "POSEIDON2_B_25_0"; + Base::poseidon2_B_25_1 = "POSEIDON2_B_25_1"; + Base::poseidon2_B_25_2 = "POSEIDON2_B_25_2"; + Base::poseidon2_B_25_3 = "POSEIDON2_B_25_3"; + Base::poseidon2_B_26_0 = "POSEIDON2_B_26_0"; + Base::poseidon2_B_26_1 = "POSEIDON2_B_26_1"; + Base::poseidon2_B_26_2 = "POSEIDON2_B_26_2"; + Base::poseidon2_B_26_3 = "POSEIDON2_B_26_3"; + Base::poseidon2_B_27_0 = "POSEIDON2_B_27_0"; + Base::poseidon2_B_27_1 = "POSEIDON2_B_27_1"; + Base::poseidon2_B_27_2 = "POSEIDON2_B_27_2"; + Base::poseidon2_B_27_3 = "POSEIDON2_B_27_3"; + Base::poseidon2_B_28_0 = "POSEIDON2_B_28_0"; + Base::poseidon2_B_28_1 = "POSEIDON2_B_28_1"; + Base::poseidon2_B_28_2 = "POSEIDON2_B_28_2"; + Base::poseidon2_B_28_3 = "POSEIDON2_B_28_3"; + Base::poseidon2_B_29_0 = "POSEIDON2_B_29_0"; + Base::poseidon2_B_29_1 = "POSEIDON2_B_29_1"; + Base::poseidon2_B_29_2 = "POSEIDON2_B_29_2"; + Base::poseidon2_B_29_3 = "POSEIDON2_B_29_3"; + Base::poseidon2_B_30_0 = "POSEIDON2_B_30_0"; + Base::poseidon2_B_30_1 = "POSEIDON2_B_30_1"; + Base::poseidon2_B_30_2 = "POSEIDON2_B_30_2"; + Base::poseidon2_B_30_3 = "POSEIDON2_B_30_3"; + Base::poseidon2_B_31_0 = "POSEIDON2_B_31_0"; + Base::poseidon2_B_31_1 = "POSEIDON2_B_31_1"; + Base::poseidon2_B_31_2 = "POSEIDON2_B_31_2"; + Base::poseidon2_B_31_3 = "POSEIDON2_B_31_3"; + Base::poseidon2_B_32_0 = "POSEIDON2_B_32_0"; + Base::poseidon2_B_32_1 = "POSEIDON2_B_32_1"; + Base::poseidon2_B_32_2 = "POSEIDON2_B_32_2"; + Base::poseidon2_B_32_3 = "POSEIDON2_B_32_3"; + Base::poseidon2_B_33_0 = "POSEIDON2_B_33_0"; + Base::poseidon2_B_33_1 = "POSEIDON2_B_33_1"; + Base::poseidon2_B_33_2 = "POSEIDON2_B_33_2"; + Base::poseidon2_B_33_3 = "POSEIDON2_B_33_3"; + Base::poseidon2_B_34_0 = "POSEIDON2_B_34_0"; + Base::poseidon2_B_34_1 = "POSEIDON2_B_34_1"; + Base::poseidon2_B_34_2 = "POSEIDON2_B_34_2"; + Base::poseidon2_B_34_3 = "POSEIDON2_B_34_3"; + Base::poseidon2_B_35_0 = "POSEIDON2_B_35_0"; + Base::poseidon2_B_35_1 = "POSEIDON2_B_35_1"; + Base::poseidon2_B_35_2 = "POSEIDON2_B_35_2"; + Base::poseidon2_B_35_3 = "POSEIDON2_B_35_3"; + Base::poseidon2_B_36_0 = "POSEIDON2_B_36_0"; + Base::poseidon2_B_36_1 = "POSEIDON2_B_36_1"; + Base::poseidon2_B_36_2 = "POSEIDON2_B_36_2"; + Base::poseidon2_B_36_3 = "POSEIDON2_B_36_3"; + Base::poseidon2_B_37_0 = "POSEIDON2_B_37_0"; + Base::poseidon2_B_37_1 = "POSEIDON2_B_37_1"; + Base::poseidon2_B_37_2 = "POSEIDON2_B_37_2"; + Base::poseidon2_B_37_3 = "POSEIDON2_B_37_3"; + Base::poseidon2_B_38_0 = "POSEIDON2_B_38_0"; + Base::poseidon2_B_38_1 = "POSEIDON2_B_38_1"; + Base::poseidon2_B_38_2 = "POSEIDON2_B_38_2"; + Base::poseidon2_B_38_3 = "POSEIDON2_B_38_3"; + Base::poseidon2_B_39_0 = "POSEIDON2_B_39_0"; + Base::poseidon2_B_39_1 = "POSEIDON2_B_39_1"; + Base::poseidon2_B_39_2 = "POSEIDON2_B_39_2"; + Base::poseidon2_B_39_3 = "POSEIDON2_B_39_3"; + Base::poseidon2_B_40_0 = "POSEIDON2_B_40_0"; + Base::poseidon2_B_40_1 = "POSEIDON2_B_40_1"; + Base::poseidon2_B_40_2 = "POSEIDON2_B_40_2"; + Base::poseidon2_B_40_3 = "POSEIDON2_B_40_3"; + Base::poseidon2_B_41_0 = "POSEIDON2_B_41_0"; + Base::poseidon2_B_41_1 = "POSEIDON2_B_41_1"; + Base::poseidon2_B_41_2 = "POSEIDON2_B_41_2"; + Base::poseidon2_B_41_3 = "POSEIDON2_B_41_3"; + Base::poseidon2_B_42_0 = "POSEIDON2_B_42_0"; + Base::poseidon2_B_42_1 = "POSEIDON2_B_42_1"; + Base::poseidon2_B_42_2 = "POSEIDON2_B_42_2"; + Base::poseidon2_B_42_3 = "POSEIDON2_B_42_3"; + Base::poseidon2_B_43_0 = "POSEIDON2_B_43_0"; + Base::poseidon2_B_43_1 = "POSEIDON2_B_43_1"; + Base::poseidon2_B_43_2 = "POSEIDON2_B_43_2"; + Base::poseidon2_B_43_3 = "POSEIDON2_B_43_3"; + Base::poseidon2_B_44_0 = "POSEIDON2_B_44_0"; + Base::poseidon2_B_44_1 = "POSEIDON2_B_44_1"; + Base::poseidon2_B_44_2 = "POSEIDON2_B_44_2"; + Base::poseidon2_B_44_3 = "POSEIDON2_B_44_3"; + Base::poseidon2_B_45_0 = "POSEIDON2_B_45_0"; + Base::poseidon2_B_45_1 = "POSEIDON2_B_45_1"; + Base::poseidon2_B_45_2 = "POSEIDON2_B_45_2"; + Base::poseidon2_B_45_3 = "POSEIDON2_B_45_3"; + Base::poseidon2_B_46_0 = "POSEIDON2_B_46_0"; + Base::poseidon2_B_46_1 = "POSEIDON2_B_46_1"; + Base::poseidon2_B_46_2 = "POSEIDON2_B_46_2"; + Base::poseidon2_B_46_3 = "POSEIDON2_B_46_3"; + Base::poseidon2_B_47_0 = "POSEIDON2_B_47_0"; + Base::poseidon2_B_47_1 = "POSEIDON2_B_47_1"; + Base::poseidon2_B_47_2 = "POSEIDON2_B_47_2"; + Base::poseidon2_B_47_3 = "POSEIDON2_B_47_3"; + Base::poseidon2_B_48_0 = "POSEIDON2_B_48_0"; + Base::poseidon2_B_48_1 = "POSEIDON2_B_48_1"; + Base::poseidon2_B_48_2 = "POSEIDON2_B_48_2"; + Base::poseidon2_B_48_3 = "POSEIDON2_B_48_3"; + Base::poseidon2_B_49_0 = "POSEIDON2_B_49_0"; + Base::poseidon2_B_49_1 = "POSEIDON2_B_49_1"; + Base::poseidon2_B_49_2 = "POSEIDON2_B_49_2"; + Base::poseidon2_B_49_3 = "POSEIDON2_B_49_3"; + Base::poseidon2_B_4_0 = "POSEIDON2_B_4_0"; + Base::poseidon2_B_4_1 = "POSEIDON2_B_4_1"; + Base::poseidon2_B_4_2 = "POSEIDON2_B_4_2"; + Base::poseidon2_B_4_3 = "POSEIDON2_B_4_3"; + Base::poseidon2_B_50_0 = "POSEIDON2_B_50_0"; + Base::poseidon2_B_50_1 = "POSEIDON2_B_50_1"; + Base::poseidon2_B_50_2 = "POSEIDON2_B_50_2"; + Base::poseidon2_B_50_3 = "POSEIDON2_B_50_3"; + Base::poseidon2_B_51_0 = "POSEIDON2_B_51_0"; + Base::poseidon2_B_51_1 = "POSEIDON2_B_51_1"; + Base::poseidon2_B_51_2 = "POSEIDON2_B_51_2"; + Base::poseidon2_B_51_3 = "POSEIDON2_B_51_3"; + Base::poseidon2_B_52_0 = "POSEIDON2_B_52_0"; + Base::poseidon2_B_52_1 = "POSEIDON2_B_52_1"; + Base::poseidon2_B_52_2 = "POSEIDON2_B_52_2"; + Base::poseidon2_B_52_3 = "POSEIDON2_B_52_3"; + Base::poseidon2_B_53_0 = "POSEIDON2_B_53_0"; + Base::poseidon2_B_53_1 = "POSEIDON2_B_53_1"; + Base::poseidon2_B_53_2 = "POSEIDON2_B_53_2"; + Base::poseidon2_B_53_3 = "POSEIDON2_B_53_3"; + Base::poseidon2_B_54_0 = "POSEIDON2_B_54_0"; + Base::poseidon2_B_54_1 = "POSEIDON2_B_54_1"; + Base::poseidon2_B_54_2 = "POSEIDON2_B_54_2"; + Base::poseidon2_B_54_3 = "POSEIDON2_B_54_3"; + Base::poseidon2_B_55_0 = "POSEIDON2_B_55_0"; + Base::poseidon2_B_55_1 = "POSEIDON2_B_55_1"; + Base::poseidon2_B_55_2 = "POSEIDON2_B_55_2"; + Base::poseidon2_B_55_3 = "POSEIDON2_B_55_3"; + Base::poseidon2_B_56_0 = "POSEIDON2_B_56_0"; + Base::poseidon2_B_56_1 = "POSEIDON2_B_56_1"; + Base::poseidon2_B_56_2 = "POSEIDON2_B_56_2"; + Base::poseidon2_B_56_3 = "POSEIDON2_B_56_3"; + Base::poseidon2_B_57_0 = "POSEIDON2_B_57_0"; + Base::poseidon2_B_57_1 = "POSEIDON2_B_57_1"; + Base::poseidon2_B_57_2 = "POSEIDON2_B_57_2"; + Base::poseidon2_B_57_3 = "POSEIDON2_B_57_3"; + Base::poseidon2_B_58_0 = "POSEIDON2_B_58_0"; + Base::poseidon2_B_58_1 = "POSEIDON2_B_58_1"; + Base::poseidon2_B_58_2 = "POSEIDON2_B_58_2"; + Base::poseidon2_B_58_3 = "POSEIDON2_B_58_3"; + Base::poseidon2_B_59_0 = "POSEIDON2_B_59_0"; + Base::poseidon2_B_59_1 = "POSEIDON2_B_59_1"; + Base::poseidon2_B_59_2 = "POSEIDON2_B_59_2"; + Base::poseidon2_B_59_3 = "POSEIDON2_B_59_3"; + Base::poseidon2_B_5_0 = "POSEIDON2_B_5_0"; + Base::poseidon2_B_5_1 = "POSEIDON2_B_5_1"; + Base::poseidon2_B_5_2 = "POSEIDON2_B_5_2"; + Base::poseidon2_B_5_3 = "POSEIDON2_B_5_3"; + Base::poseidon2_B_6_0 = "POSEIDON2_B_6_0"; + Base::poseidon2_B_6_1 = "POSEIDON2_B_6_1"; + Base::poseidon2_B_6_2 = "POSEIDON2_B_6_2"; + Base::poseidon2_B_6_3 = "POSEIDON2_B_6_3"; + Base::poseidon2_B_7_0 = "POSEIDON2_B_7_0"; + Base::poseidon2_B_7_1 = "POSEIDON2_B_7_1"; + Base::poseidon2_B_7_2 = "POSEIDON2_B_7_2"; + Base::poseidon2_B_7_3 = "POSEIDON2_B_7_3"; + Base::poseidon2_B_8_0 = "POSEIDON2_B_8_0"; + Base::poseidon2_B_8_1 = "POSEIDON2_B_8_1"; + Base::poseidon2_B_8_2 = "POSEIDON2_B_8_2"; + Base::poseidon2_B_8_3 = "POSEIDON2_B_8_3"; + Base::poseidon2_B_9_0 = "POSEIDON2_B_9_0"; + Base::poseidon2_B_9_1 = "POSEIDON2_B_9_1"; + Base::poseidon2_B_9_2 = "POSEIDON2_B_9_2"; + Base::poseidon2_B_9_3 = "POSEIDON2_B_9_3"; + Base::poseidon2_EXT_LAYER_4 = "POSEIDON2_EXT_LAYER_4"; + Base::poseidon2_EXT_LAYER_5 = "POSEIDON2_EXT_LAYER_5"; + Base::poseidon2_EXT_LAYER_6 = "POSEIDON2_EXT_LAYER_6"; + Base::poseidon2_EXT_LAYER_7 = "POSEIDON2_EXT_LAYER_7"; + Base::poseidon2_T_0_4 = "POSEIDON2_T_0_4"; + Base::poseidon2_T_0_5 = "POSEIDON2_T_0_5"; + Base::poseidon2_T_0_6 = "POSEIDON2_T_0_6"; + Base::poseidon2_T_0_7 = "POSEIDON2_T_0_7"; + Base::poseidon2_T_1_4 = "POSEIDON2_T_1_4"; + Base::poseidon2_T_1_5 = "POSEIDON2_T_1_5"; + Base::poseidon2_T_1_6 = "POSEIDON2_T_1_6"; + Base::poseidon2_T_1_7 = "POSEIDON2_T_1_7"; + Base::poseidon2_T_2_4 = "POSEIDON2_T_2_4"; + Base::poseidon2_T_2_5 = "POSEIDON2_T_2_5"; + Base::poseidon2_T_2_6 = "POSEIDON2_T_2_6"; + Base::poseidon2_T_2_7 = "POSEIDON2_T_2_7"; + Base::poseidon2_T_3_4 = "POSEIDON2_T_3_4"; + Base::poseidon2_T_3_5 = "POSEIDON2_T_3_5"; + Base::poseidon2_T_3_6 = "POSEIDON2_T_3_6"; + Base::poseidon2_T_3_7 = "POSEIDON2_T_3_7"; + Base::poseidon2_T_60_4 = "POSEIDON2_T_60_4"; + Base::poseidon2_T_60_5 = "POSEIDON2_T_60_5"; + Base::poseidon2_T_60_6 = "POSEIDON2_T_60_6"; + Base::poseidon2_T_60_7 = "POSEIDON2_T_60_7"; + Base::poseidon2_T_61_4 = "POSEIDON2_T_61_4"; + Base::poseidon2_T_61_5 = "POSEIDON2_T_61_5"; + Base::poseidon2_T_61_6 = "POSEIDON2_T_61_6"; + Base::poseidon2_T_61_7 = "POSEIDON2_T_61_7"; + Base::poseidon2_T_62_4 = "POSEIDON2_T_62_4"; + Base::poseidon2_T_62_5 = "POSEIDON2_T_62_5"; + Base::poseidon2_T_62_6 = "POSEIDON2_T_62_6"; + Base::poseidon2_T_62_7 = "POSEIDON2_T_62_7"; + Base::poseidon2_T_63_4 = "POSEIDON2_T_63_4"; + Base::poseidon2_T_63_5 = "POSEIDON2_T_63_5"; + Base::poseidon2_T_63_6 = "POSEIDON2_T_63_6"; + Base::poseidon2_T_63_7 = "POSEIDON2_T_63_7"; Base::poseidon2_a_0 = "POSEIDON2_A_0"; Base::poseidon2_a_1 = "POSEIDON2_A_1"; Base::poseidon2_a_2 = "POSEIDON2_A_2"; @@ -3782,9 +2508,17 @@ class AvmFlavor { Base::poseidon2_b_2 = "POSEIDON2_B_2"; Base::poseidon2_b_3 = "POSEIDON2_B_3"; Base::poseidon2_clk = "POSEIDON2_CLK"; - Base::poseidon2_input = "POSEIDON2_INPUT"; - Base::poseidon2_output = "POSEIDON2_OUTPUT"; + Base::poseidon2_in_tag = "POSEIDON2_IN_TAG"; + Base::poseidon2_input_addr = "POSEIDON2_INPUT_ADDR"; + Base::poseidon2_mem_addr_a = "POSEIDON2_MEM_ADDR_A"; + Base::poseidon2_mem_addr_b = "POSEIDON2_MEM_ADDR_B"; + Base::poseidon2_mem_addr_c = "POSEIDON2_MEM_ADDR_C"; + Base::poseidon2_mem_addr_d = "POSEIDON2_MEM_ADDR_D"; + Base::poseidon2_mem_op = "POSEIDON2_MEM_OP"; + Base::poseidon2_output_addr = "POSEIDON2_OUTPUT_ADDR"; + Base::poseidon2_read_line = "POSEIDON2_READ_LINE"; Base::poseidon2_sel_poseidon_perm = "POSEIDON2_SEL_POSEIDON_PERM"; + Base::poseidon2_write_line = "POSEIDON2_WRITE_LINE"; Base::powers_power_of_2 = "POWERS_POWER_OF_2"; Base::sha256_clk = "SHA256_CLK"; Base::sha256_input = "SHA256_INPUT"; @@ -3802,6 +2536,10 @@ class AvmFlavor { Base::slice_sel_start = "SLICE_SEL_START"; Base::slice_space_id = "SLICE_SPACE_ID"; Base::slice_val = "SLICE_VAL"; + Base::perm_pos_mem_a = "PERM_POS_MEM_A"; + Base::perm_pos_mem_b = "PERM_POS_MEM_B"; + Base::perm_pos_mem_c = "PERM_POS_MEM_C"; + Base::perm_pos_mem_d = "PERM_POS_MEM_D"; Base::perm_slice_mem = "PERM_SLICE_MEM"; Base::perm_main_alu = "PERM_MAIN_ALU"; Base::perm_main_bin = "PERM_MAIN_BIN"; @@ -3922,403 +2660,7 @@ class AvmFlavor { public: uint32_t circuit_size; -<<<<<<< HEAD std::array commitments; -======= - Commitment kernel_kernel_inputs; - Commitment kernel_kernel_value_out; - Commitment kernel_kernel_side_effect_out; - Commitment kernel_kernel_metadata_out; - Commitment main_calldata; - Commitment alu_a_hi; - Commitment alu_a_lo; - Commitment alu_b_hi; - Commitment alu_b_lo; - Commitment alu_borrow; - Commitment alu_cf; - Commitment alu_clk; - Commitment alu_cmp_rng_ctr; - Commitment alu_div_u16_r0; - Commitment alu_div_u16_r1; - Commitment alu_div_u16_r2; - Commitment alu_div_u16_r3; - Commitment alu_div_u16_r4; - Commitment alu_div_u16_r5; - Commitment alu_div_u16_r6; - Commitment alu_div_u16_r7; - Commitment alu_divisor_hi; - Commitment alu_divisor_lo; - Commitment alu_ff_tag; - Commitment alu_ia; - Commitment alu_ib; - Commitment alu_ic; - Commitment alu_in_tag; - Commitment alu_op_add; - Commitment alu_op_cast; - Commitment alu_op_cast_prev; - Commitment alu_op_div; - Commitment alu_op_div_a_lt_b; - Commitment alu_op_div_std; - Commitment alu_op_eq; - Commitment alu_op_eq_diff_inv; - Commitment alu_op_lt; - Commitment alu_op_lte; - Commitment alu_op_mul; - Commitment alu_op_not; - Commitment alu_op_shl; - Commitment alu_op_shr; - Commitment alu_op_sub; - Commitment alu_p_a_borrow; - Commitment alu_p_b_borrow; - Commitment alu_p_sub_a_hi; - Commitment alu_p_sub_a_lo; - Commitment alu_p_sub_b_hi; - Commitment alu_p_sub_b_lo; - Commitment alu_partial_prod_hi; - Commitment alu_partial_prod_lo; - Commitment alu_quotient_hi; - Commitment alu_quotient_lo; - Commitment alu_remainder; - Commitment alu_res_hi; - Commitment alu_res_lo; - Commitment alu_sel_alu; - Commitment alu_sel_cmp; - Commitment alu_sel_div_rng_chk; - Commitment alu_sel_rng_chk; - Commitment alu_sel_rng_chk_lookup; - Commitment alu_sel_shift_which; - Commitment alu_shift_lt_bit_len; - Commitment alu_t_sub_s_bits; - Commitment alu_two_pow_s; - Commitment alu_two_pow_t_sub_s; - Commitment alu_u128_tag; - Commitment alu_u16_r0; - Commitment alu_u16_r1; - Commitment alu_u16_r10; - Commitment alu_u16_r11; - Commitment alu_u16_r12; - Commitment alu_u16_r13; - Commitment alu_u16_r14; - Commitment alu_u16_r2; - Commitment alu_u16_r3; - Commitment alu_u16_r4; - Commitment alu_u16_r5; - Commitment alu_u16_r6; - Commitment alu_u16_r7; - Commitment alu_u16_r8; - Commitment alu_u16_r9; - Commitment alu_u16_tag; - Commitment alu_u32_tag; - Commitment alu_u64_tag; - Commitment alu_u8_r0; - Commitment alu_u8_r1; - Commitment alu_u8_tag; - Commitment binary_acc_ia; - Commitment binary_acc_ib; - Commitment binary_acc_ic; - Commitment binary_clk; - Commitment binary_ia_bytes; - Commitment binary_ib_bytes; - Commitment binary_ic_bytes; - Commitment binary_in_tag; - Commitment binary_mem_tag_ctr; - Commitment binary_mem_tag_ctr_inv; - Commitment binary_op_id; - Commitment binary_sel_bin; - Commitment binary_start; - Commitment byte_lookup_sel_bin; - Commitment byte_lookup_table_byte_lengths; - Commitment byte_lookup_table_in_tags; - Commitment byte_lookup_table_input_a; - Commitment byte_lookup_table_input_b; - Commitment byte_lookup_table_op_id; - Commitment byte_lookup_table_output; - Commitment conversion_clk; - Commitment conversion_input; - Commitment conversion_num_limbs; - Commitment conversion_radix; - Commitment conversion_sel_to_radix_le; - Commitment gas_da_gas_fixed_table; - Commitment gas_l2_gas_fixed_table; - Commitment gas_sel_gas_cost; - Commitment keccakf1600_clk; - Commitment keccakf1600_input; - Commitment keccakf1600_output; - Commitment keccakf1600_sel_keccakf1600; - Commitment kernel_emit_l2_to_l1_msg_write_offset; - Commitment kernel_emit_note_hash_write_offset; - Commitment kernel_emit_nullifier_write_offset; - Commitment kernel_emit_unencrypted_log_write_offset; - Commitment kernel_kernel_in_offset; - Commitment kernel_kernel_out_offset; - Commitment kernel_l1_to_l2_msg_exists_write_offset; - Commitment kernel_note_hash_exist_write_offset; - Commitment kernel_nullifier_exists_write_offset; - Commitment kernel_nullifier_non_exists_write_offset; - Commitment kernel_q_public_input_kernel_add_to_table; - Commitment kernel_q_public_input_kernel_out_add_to_table; - Commitment kernel_side_effect_counter; - Commitment kernel_sload_write_offset; - Commitment kernel_sstore_write_offset; - Commitment main_abs_da_rem_gas_hi; - Commitment main_abs_da_rem_gas_lo; - Commitment main_abs_l2_rem_gas_hi; - Commitment main_abs_l2_rem_gas_lo; - Commitment main_alu_in_tag; - Commitment main_bin_op_id; - Commitment main_call_ptr; - Commitment main_da_gas_op_cost; - Commitment main_da_gas_remaining; - Commitment main_da_out_of_gas; - Commitment main_ia; - Commitment main_ib; - Commitment main_ic; - Commitment main_id; - Commitment main_id_zero; - Commitment main_ind_addr_a; - Commitment main_ind_addr_b; - Commitment main_ind_addr_c; - Commitment main_ind_addr_d; - Commitment main_internal_return_ptr; - Commitment main_inv; - Commitment main_l2_gas_op_cost; - Commitment main_l2_gas_remaining; - Commitment main_l2_out_of_gas; - Commitment main_mem_addr_a; - Commitment main_mem_addr_b; - Commitment main_mem_addr_c; - Commitment main_mem_addr_d; - Commitment main_op_err; - Commitment main_opcode_val; - Commitment main_pc; - Commitment main_r_in_tag; - Commitment main_rwa; - Commitment main_rwb; - Commitment main_rwc; - Commitment main_rwd; - Commitment main_sel_alu; - Commitment main_sel_bin; - Commitment main_sel_gas_accounting_active; - Commitment main_sel_last; - Commitment main_sel_mem_op_a; - Commitment main_sel_mem_op_activate_gas; - Commitment main_sel_mem_op_b; - Commitment main_sel_mem_op_c; - Commitment main_sel_mem_op_d; - Commitment main_sel_mov_ia_to_ic; - Commitment main_sel_mov_ib_to_ic; - Commitment main_sel_op_add; - Commitment main_sel_op_address; - Commitment main_sel_op_and; - Commitment main_sel_op_block_number; - Commitment main_sel_op_cast; - Commitment main_sel_op_chain_id; - Commitment main_sel_op_cmov; - Commitment main_sel_op_coinbase; - Commitment main_sel_op_dagasleft; - Commitment main_sel_op_div; - Commitment main_sel_op_emit_l2_to_l1_msg; - Commitment main_sel_op_emit_note_hash; - Commitment main_sel_op_emit_nullifier; - Commitment main_sel_op_emit_unencrypted_log; - Commitment main_sel_op_eq; - Commitment main_sel_op_external_call; - Commitment main_sel_op_fdiv; - Commitment main_sel_op_fee_per_da_gas; - Commitment main_sel_op_fee_per_l2_gas; - Commitment main_sel_op_function_selector; - Commitment main_sel_op_get_contract_instance; - Commitment main_sel_op_halt; - Commitment main_sel_op_internal_call; - Commitment main_sel_op_internal_return; - Commitment main_sel_op_jump; - Commitment main_sel_op_jumpi; - Commitment main_sel_op_keccak; - Commitment main_sel_op_l1_to_l2_msg_exists; - Commitment main_sel_op_l2gasleft; - Commitment main_sel_op_lt; - Commitment main_sel_op_lte; - Commitment main_sel_op_mov; - Commitment main_sel_op_mul; - Commitment main_sel_op_not; - Commitment main_sel_op_note_hash_exists; - Commitment main_sel_op_nullifier_exists; - Commitment main_sel_op_or; - Commitment main_sel_op_pedersen; - Commitment main_sel_op_poseidon2; - Commitment main_sel_op_radix_le; - Commitment main_sel_op_sender; - Commitment main_sel_op_sha256; - Commitment main_sel_op_shl; - Commitment main_sel_op_shr; - Commitment main_sel_op_sload; - Commitment main_sel_op_sstore; - Commitment main_sel_op_storage_address; - Commitment main_sel_op_sub; - Commitment main_sel_op_timestamp; - Commitment main_sel_op_transaction_fee; - Commitment main_sel_op_version; - Commitment main_sel_op_xor; - Commitment main_sel_q_kernel_lookup; - Commitment main_sel_q_kernel_output_lookup; - Commitment main_sel_resolve_ind_addr_a; - Commitment main_sel_resolve_ind_addr_b; - Commitment main_sel_resolve_ind_addr_c; - Commitment main_sel_resolve_ind_addr_d; - Commitment main_sel_rng_16; - Commitment main_sel_rng_8; - Commitment main_space_id; - Commitment main_tag_err; - Commitment main_w_in_tag; - Commitment mem_addr; - Commitment mem_clk; - Commitment mem_diff_hi; - Commitment mem_diff_lo; - Commitment mem_diff_mid; - Commitment mem_glob_addr; - Commitment mem_last; - Commitment mem_lastAccess; - Commitment mem_one_min_inv; - Commitment mem_r_in_tag; - Commitment mem_rw; - Commitment mem_sel_mem; - Commitment mem_sel_mov_ia_to_ic; - Commitment mem_sel_mov_ib_to_ic; - Commitment mem_sel_op_a; - Commitment mem_sel_op_b; - Commitment mem_sel_op_c; - Commitment mem_sel_op_cmov; - Commitment mem_sel_op_d; - Commitment mem_sel_resolve_ind_addr_a; - Commitment mem_sel_resolve_ind_addr_b; - Commitment mem_sel_resolve_ind_addr_c; - Commitment mem_sel_resolve_ind_addr_d; - Commitment mem_sel_rng_chk; - Commitment mem_skip_check_tag; - Commitment mem_space_id; - Commitment mem_tag; - Commitment mem_tag_err; - Commitment mem_tsp; - Commitment mem_val; - Commitment mem_w_in_tag; - Commitment pedersen_clk; - Commitment pedersen_input; - Commitment pedersen_output; - Commitment pedersen_sel_pedersen; - Commitment poseidon2_a_0; - Commitment poseidon2_a_1; - Commitment poseidon2_a_2; - Commitment poseidon2_a_3; - Commitment poseidon2_b_0; - Commitment poseidon2_b_1; - Commitment poseidon2_b_2; - Commitment poseidon2_b_3; - Commitment poseidon2_clk; - Commitment poseidon2_input; - Commitment poseidon2_output; - Commitment poseidon2_sel_poseidon_perm; - Commitment powers_power_of_2; - Commitment sha256_clk; - Commitment sha256_input; - Commitment sha256_output; - Commitment sha256_sel_sha256_compression; - Commitment sha256_state; - Commitment perm_main_alu; - Commitment perm_main_bin; - Commitment perm_main_conv; - Commitment perm_main_pos2_perm; - Commitment perm_main_pedersen; - Commitment perm_main_mem_a; - Commitment perm_main_mem_b; - Commitment perm_main_mem_c; - Commitment perm_main_mem_d; - Commitment perm_main_mem_ind_addr_a; - Commitment perm_main_mem_ind_addr_b; - Commitment perm_main_mem_ind_addr_c; - Commitment perm_main_mem_ind_addr_d; - Commitment lookup_byte_lengths; - Commitment lookup_byte_operations; - Commitment lookup_opcode_gas; - Commitment range_check_l2_gas_hi; - Commitment range_check_l2_gas_lo; - Commitment range_check_da_gas_hi; - Commitment range_check_da_gas_lo; - Commitment kernel_output_lookup; - Commitment lookup_into_kernel; - Commitment incl_main_tag_err; - Commitment incl_mem_tag_err; - Commitment lookup_mem_rng_chk_lo; - Commitment lookup_mem_rng_chk_mid; - Commitment lookup_mem_rng_chk_hi; - Commitment lookup_pow_2_0; - Commitment lookup_pow_2_1; - Commitment lookup_u8_0; - Commitment lookup_u8_1; - Commitment lookup_u16_0; - Commitment lookup_u16_1; - Commitment lookup_u16_2; - Commitment lookup_u16_3; - Commitment lookup_u16_4; - Commitment lookup_u16_5; - Commitment lookup_u16_6; - Commitment lookup_u16_7; - Commitment lookup_u16_8; - Commitment lookup_u16_9; - Commitment lookup_u16_10; - Commitment lookup_u16_11; - Commitment lookup_u16_12; - Commitment lookup_u16_13; - Commitment lookup_u16_14; - Commitment lookup_div_u16_0; - Commitment lookup_div_u16_1; - Commitment lookup_div_u16_2; - Commitment lookup_div_u16_3; - Commitment lookup_div_u16_4; - Commitment lookup_div_u16_5; - Commitment lookup_div_u16_6; - Commitment lookup_div_u16_7; - Commitment lookup_byte_lengths_counts; - Commitment lookup_byte_operations_counts; - Commitment lookup_opcode_gas_counts; - Commitment range_check_l2_gas_hi_counts; - Commitment range_check_l2_gas_lo_counts; - Commitment range_check_da_gas_hi_counts; - Commitment range_check_da_gas_lo_counts; - Commitment kernel_output_lookup_counts; - Commitment lookup_into_kernel_counts; - Commitment incl_main_tag_err_counts; - Commitment incl_mem_tag_err_counts; - Commitment lookup_mem_rng_chk_lo_counts; - Commitment lookup_mem_rng_chk_mid_counts; - Commitment lookup_mem_rng_chk_hi_counts; - Commitment lookup_pow_2_0_counts; - Commitment lookup_pow_2_1_counts; - Commitment lookup_u8_0_counts; - Commitment lookup_u8_1_counts; - Commitment lookup_u16_0_counts; - Commitment lookup_u16_1_counts; - Commitment lookup_u16_2_counts; - Commitment lookup_u16_3_counts; - Commitment lookup_u16_4_counts; - Commitment lookup_u16_5_counts; - Commitment lookup_u16_6_counts; - Commitment lookup_u16_7_counts; - Commitment lookup_u16_8_counts; - Commitment lookup_u16_9_counts; - Commitment lookup_u16_10_counts; - Commitment lookup_u16_11_counts; - Commitment lookup_u16_12_counts; - Commitment lookup_u16_13_counts; - Commitment lookup_u16_14_counts; - Commitment lookup_div_u16_0_counts; - Commitment lookup_div_u16_1_counts; - Commitment lookup_div_u16_2_counts; - Commitment lookup_div_u16_3_counts; - Commitment lookup_div_u16_4_counts; - Commitment lookup_div_u16_5_counts; - Commitment lookup_div_u16_6_counts; - Commitment lookup_div_u16_7_counts; ->>>>>>> 520b7216c (feat(avm): poseidon2 constraints) std::vector> sumcheck_univariates; std::array sumcheck_evaluations; @@ -4338,418 +2680,9 @@ class AvmFlavor { circuit_size = deserialize_from_buffer(proof_data, num_frs_read); size_t log_n = numeric::get_msb(circuit_size); -<<<<<<< HEAD for (auto& commitment : commitments) { commitment = deserialize_from_buffer(proof_data, num_frs_read); } -======= - kernel_kernel_inputs = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_kernel_value_out = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_kernel_side_effect_out = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_kernel_metadata_out = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_calldata = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_a_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_a_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_b_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_b_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_borrow = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_cf = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_cmp_rng_ctr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_div_u16_r0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_div_u16_r1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_div_u16_r2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_div_u16_r3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_div_u16_r4 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_div_u16_r5 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_div_u16_r6 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_div_u16_r7 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_divisor_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_divisor_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_ff_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_ia = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_ib = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_add = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_cast = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_cast_prev = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_div = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_div_a_lt_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_div_std = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_eq = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_eq_diff_inv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_lt = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_lte = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_mul = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_not = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_shl = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_shr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_op_sub = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_p_a_borrow = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_p_b_borrow = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_p_sub_a_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_p_sub_a_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_p_sub_b_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_p_sub_b_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_partial_prod_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_partial_prod_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_quotient_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_quotient_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_remainder = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_res_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_res_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_sel_alu = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_sel_cmp = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_sel_div_rng_chk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_sel_rng_chk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_sel_rng_chk_lookup = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_sel_shift_which = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_shift_lt_bit_len = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_t_sub_s_bits = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_two_pow_s = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_two_pow_t_sub_s = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u128_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r10 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r11 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r12 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r13 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r14 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r4 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r5 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r6 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r7 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r8 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_r9 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u16_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u32_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u64_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u8_r0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u8_r1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - alu_u8_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_acc_ia = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_acc_ib = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_acc_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_ia_bytes = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_ib_bytes = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_ic_bytes = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_mem_tag_ctr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_mem_tag_ctr_inv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_op_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_sel_bin = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - binary_start = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - byte_lookup_sel_bin = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - byte_lookup_table_byte_lengths = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - byte_lookup_table_in_tags = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - byte_lookup_table_input_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - byte_lookup_table_input_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - byte_lookup_table_op_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - byte_lookup_table_output = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - conversion_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - conversion_input = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - conversion_num_limbs = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - conversion_radix = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - conversion_sel_to_radix_le = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - gas_da_gas_fixed_table = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - gas_l2_gas_fixed_table = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - gas_sel_gas_cost = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - keccakf1600_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - keccakf1600_input = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - keccakf1600_output = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - keccakf1600_sel_keccakf1600 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_emit_l2_to_l1_msg_write_offset = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_emit_note_hash_write_offset = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_emit_nullifier_write_offset = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_emit_unencrypted_log_write_offset = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_kernel_in_offset = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_kernel_out_offset = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_l1_to_l2_msg_exists_write_offset = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_note_hash_exist_write_offset = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_nullifier_exists_write_offset = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_nullifier_non_exists_write_offset = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_q_public_input_kernel_add_to_table = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_q_public_input_kernel_out_add_to_table = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_side_effect_counter = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_sload_write_offset = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_sstore_write_offset = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_abs_da_rem_gas_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_abs_da_rem_gas_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_abs_l2_rem_gas_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_abs_l2_rem_gas_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_alu_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_bin_op_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_call_ptr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_da_gas_op_cost = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_da_gas_remaining = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_da_out_of_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_ia = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_ib = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_id_zero = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_ind_addr_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_ind_addr_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_ind_addr_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_ind_addr_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_internal_return_ptr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_inv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_l2_gas_op_cost = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_l2_gas_remaining = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_l2_out_of_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_mem_addr_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_mem_addr_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_mem_addr_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_mem_addr_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_op_err = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_opcode_val = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_pc = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_r_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_rwa = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_rwb = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_rwc = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_rwd = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_alu = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_bin = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_gas_accounting_active = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_last = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_mem_op_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_mem_op_activate_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_mem_op_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_mem_op_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_mem_op_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_mov_ia_to_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_mov_ib_to_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_add = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_address = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_and = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_block_number = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_cast = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_chain_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_cmov = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_coinbase = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_dagasleft = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_div = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_emit_l2_to_l1_msg = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_emit_note_hash = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_emit_nullifier = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_emit_unencrypted_log = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_eq = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_external_call = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_fdiv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_fee_per_da_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_fee_per_l2_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_function_selector = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_get_contract_instance = - deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_halt = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_internal_call = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_internal_return = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_jump = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_jumpi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_keccak = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_l1_to_l2_msg_exists = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_l2gasleft = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_lt = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_lte = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_mov = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_mul = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_not = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_note_hash_exists = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_nullifier_exists = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_or = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_pedersen = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_poseidon2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_radix_le = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_sender = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_sha256 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_shl = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_shr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_sload = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_sstore = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_storage_address = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_sub = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_timestamp = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_transaction_fee = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_version = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_op_xor = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_q_kernel_lookup = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_q_kernel_output_lookup = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_resolve_ind_addr_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_resolve_ind_addr_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_resolve_ind_addr_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_resolve_ind_addr_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_rng_16 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_sel_rng_8 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_space_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_tag_err = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - main_w_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_addr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_diff_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_diff_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_diff_mid = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_glob_addr = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_last = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_lastAccess = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_one_min_inv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_r_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_rw = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_mem = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_mov_ia_to_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_mov_ib_to_ic = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_op_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_op_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_op_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_op_cmov = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_op_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_resolve_ind_addr_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_resolve_ind_addr_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_resolve_ind_addr_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_resolve_ind_addr_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_sel_rng_chk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_skip_check_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_space_id = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_tag_err = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_tsp = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_val = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - mem_w_in_tag = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - pedersen_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - pedersen_input = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - pedersen_output = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - pedersen_sel_pedersen = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_a_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_a_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_a_2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_a_3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_b_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_b_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_b_2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_b_3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_input = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_output = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - poseidon2_sel_poseidon_perm = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - powers_power_of_2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - sha256_clk = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - sha256_input = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - sha256_output = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - sha256_sel_sha256_compression = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - sha256_state = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_alu = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_bin = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_conv = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_pos2_perm = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_pedersen = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_mem_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_mem_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_mem_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_mem_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_mem_ind_addr_a = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_mem_ind_addr_b = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_mem_ind_addr_c = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - perm_main_mem_ind_addr_d = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_byte_lengths = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_byte_operations = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_opcode_gas = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - range_check_l2_gas_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - range_check_l2_gas_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - range_check_da_gas_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - range_check_da_gas_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_output_lookup = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_into_kernel = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - incl_main_tag_err = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - incl_mem_tag_err = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_mem_rng_chk_lo = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_mem_rng_chk_mid = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_mem_rng_chk_hi = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_pow_2_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_pow_2_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u8_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u8_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_4 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_5 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_6 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_7 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_8 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_9 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_10 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_11 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_12 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_13 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_14 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_0 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_1 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_2 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_3 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_4 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_5 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_6 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_7 = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_byte_lengths_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_byte_operations_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_opcode_gas_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - range_check_l2_gas_hi_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - range_check_l2_gas_lo_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - range_check_da_gas_hi_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - range_check_da_gas_lo_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - kernel_output_lookup_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_into_kernel_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - incl_main_tag_err_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - incl_mem_tag_err_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_mem_rng_chk_lo_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_mem_rng_chk_mid_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_mem_rng_chk_hi_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_pow_2_0_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_pow_2_1_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u8_0_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u8_1_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_0_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_1_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_2_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_3_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_4_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_5_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_6_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_7_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_8_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_9_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_10_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_11_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_12_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_13_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_u16_14_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_0_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_1_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_2_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_3_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_4_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_5_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_6_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - lookup_div_u16_7_counts = deserialize_from_buffer(Transcript::proof_data, num_frs_read); - ->>>>>>> 520b7216c (feat(avm): poseidon2 constraints) for (size_t i = 0; i < log_n; ++i) { sumcheck_univariates.emplace_back( deserialize_from_buffer>(Transcript::proof_data, @@ -4772,406 +2705,9 @@ class AvmFlavor { serialize_to_buffer(circuit_size, Transcript::proof_data); -<<<<<<< HEAD for (const auto& commitment : commitments) { serialize_to_buffer(commitment, Transcript::proof_data); } -======= - serialize_to_buffer(kernel_kernel_inputs, Transcript::proof_data); - serialize_to_buffer(kernel_kernel_value_out, Transcript::proof_data); - serialize_to_buffer(kernel_kernel_side_effect_out, Transcript::proof_data); - serialize_to_buffer(kernel_kernel_metadata_out, Transcript::proof_data); - serialize_to_buffer(main_calldata, Transcript::proof_data); - serialize_to_buffer(alu_a_hi, Transcript::proof_data); - serialize_to_buffer(alu_a_lo, Transcript::proof_data); - serialize_to_buffer(alu_b_hi, Transcript::proof_data); - serialize_to_buffer(alu_b_lo, Transcript::proof_data); - serialize_to_buffer(alu_borrow, Transcript::proof_data); - serialize_to_buffer(alu_cf, Transcript::proof_data); - serialize_to_buffer(alu_clk, Transcript::proof_data); - serialize_to_buffer(alu_cmp_rng_ctr, Transcript::proof_data); - serialize_to_buffer(alu_div_u16_r0, Transcript::proof_data); - serialize_to_buffer(alu_div_u16_r1, Transcript::proof_data); - serialize_to_buffer(alu_div_u16_r2, Transcript::proof_data); - serialize_to_buffer(alu_div_u16_r3, Transcript::proof_data); - serialize_to_buffer(alu_div_u16_r4, Transcript::proof_data); - serialize_to_buffer(alu_div_u16_r5, Transcript::proof_data); - serialize_to_buffer(alu_div_u16_r6, Transcript::proof_data); - serialize_to_buffer(alu_div_u16_r7, Transcript::proof_data); - serialize_to_buffer(alu_divisor_hi, Transcript::proof_data); - serialize_to_buffer(alu_divisor_lo, Transcript::proof_data); - serialize_to_buffer(alu_ff_tag, Transcript::proof_data); - serialize_to_buffer(alu_ia, Transcript::proof_data); - serialize_to_buffer(alu_ib, Transcript::proof_data); - serialize_to_buffer(alu_ic, Transcript::proof_data); - serialize_to_buffer(alu_in_tag, Transcript::proof_data); - serialize_to_buffer(alu_op_add, Transcript::proof_data); - serialize_to_buffer(alu_op_cast, Transcript::proof_data); - serialize_to_buffer(alu_op_cast_prev, Transcript::proof_data); - serialize_to_buffer(alu_op_div, Transcript::proof_data); - serialize_to_buffer(alu_op_div_a_lt_b, Transcript::proof_data); - serialize_to_buffer(alu_op_div_std, Transcript::proof_data); - serialize_to_buffer(alu_op_eq, Transcript::proof_data); - serialize_to_buffer(alu_op_eq_diff_inv, Transcript::proof_data); - serialize_to_buffer(alu_op_lt, Transcript::proof_data); - serialize_to_buffer(alu_op_lte, Transcript::proof_data); - serialize_to_buffer(alu_op_mul, Transcript::proof_data); - serialize_to_buffer(alu_op_not, Transcript::proof_data); - serialize_to_buffer(alu_op_shl, Transcript::proof_data); - serialize_to_buffer(alu_op_shr, Transcript::proof_data); - serialize_to_buffer(alu_op_sub, Transcript::proof_data); - serialize_to_buffer(alu_p_a_borrow, Transcript::proof_data); - serialize_to_buffer(alu_p_b_borrow, Transcript::proof_data); - serialize_to_buffer(alu_p_sub_a_hi, Transcript::proof_data); - serialize_to_buffer(alu_p_sub_a_lo, Transcript::proof_data); - serialize_to_buffer(alu_p_sub_b_hi, Transcript::proof_data); - serialize_to_buffer(alu_p_sub_b_lo, Transcript::proof_data); - serialize_to_buffer(alu_partial_prod_hi, Transcript::proof_data); - serialize_to_buffer(alu_partial_prod_lo, Transcript::proof_data); - serialize_to_buffer(alu_quotient_hi, Transcript::proof_data); - serialize_to_buffer(alu_quotient_lo, Transcript::proof_data); - serialize_to_buffer(alu_remainder, Transcript::proof_data); - serialize_to_buffer(alu_res_hi, Transcript::proof_data); - serialize_to_buffer(alu_res_lo, Transcript::proof_data); - serialize_to_buffer(alu_sel_alu, Transcript::proof_data); - serialize_to_buffer(alu_sel_cmp, Transcript::proof_data); - serialize_to_buffer(alu_sel_div_rng_chk, Transcript::proof_data); - serialize_to_buffer(alu_sel_rng_chk, Transcript::proof_data); - serialize_to_buffer(alu_sel_rng_chk_lookup, Transcript::proof_data); - serialize_to_buffer(alu_sel_shift_which, Transcript::proof_data); - serialize_to_buffer(alu_shift_lt_bit_len, Transcript::proof_data); - serialize_to_buffer(alu_t_sub_s_bits, Transcript::proof_data); - serialize_to_buffer(alu_two_pow_s, Transcript::proof_data); - serialize_to_buffer(alu_two_pow_t_sub_s, Transcript::proof_data); - serialize_to_buffer(alu_u128_tag, Transcript::proof_data); - serialize_to_buffer(alu_u16_r0, Transcript::proof_data); - serialize_to_buffer(alu_u16_r1, Transcript::proof_data); - serialize_to_buffer(alu_u16_r10, Transcript::proof_data); - serialize_to_buffer(alu_u16_r11, Transcript::proof_data); - serialize_to_buffer(alu_u16_r12, Transcript::proof_data); - serialize_to_buffer(alu_u16_r13, Transcript::proof_data); - serialize_to_buffer(alu_u16_r14, Transcript::proof_data); - serialize_to_buffer(alu_u16_r2, Transcript::proof_data); - serialize_to_buffer(alu_u16_r3, Transcript::proof_data); - serialize_to_buffer(alu_u16_r4, Transcript::proof_data); - serialize_to_buffer(alu_u16_r5, Transcript::proof_data); - serialize_to_buffer(alu_u16_r6, Transcript::proof_data); - serialize_to_buffer(alu_u16_r7, Transcript::proof_data); - serialize_to_buffer(alu_u16_r8, Transcript::proof_data); - serialize_to_buffer(alu_u16_r9, Transcript::proof_data); - serialize_to_buffer(alu_u16_tag, Transcript::proof_data); - serialize_to_buffer(alu_u32_tag, Transcript::proof_data); - serialize_to_buffer(alu_u64_tag, Transcript::proof_data); - serialize_to_buffer(alu_u8_r0, Transcript::proof_data); - serialize_to_buffer(alu_u8_r1, Transcript::proof_data); - serialize_to_buffer(alu_u8_tag, Transcript::proof_data); - serialize_to_buffer(binary_acc_ia, Transcript::proof_data); - serialize_to_buffer(binary_acc_ib, Transcript::proof_data); - serialize_to_buffer(binary_acc_ic, Transcript::proof_data); - serialize_to_buffer(binary_clk, Transcript::proof_data); - serialize_to_buffer(binary_ia_bytes, Transcript::proof_data); - serialize_to_buffer(binary_ib_bytes, Transcript::proof_data); - serialize_to_buffer(binary_ic_bytes, Transcript::proof_data); - serialize_to_buffer(binary_in_tag, Transcript::proof_data); - serialize_to_buffer(binary_mem_tag_ctr, Transcript::proof_data); - serialize_to_buffer(binary_mem_tag_ctr_inv, Transcript::proof_data); - serialize_to_buffer(binary_op_id, Transcript::proof_data); - serialize_to_buffer(binary_sel_bin, Transcript::proof_data); - serialize_to_buffer(binary_start, Transcript::proof_data); - serialize_to_buffer(byte_lookup_sel_bin, Transcript::proof_data); - serialize_to_buffer(byte_lookup_table_byte_lengths, Transcript::proof_data); - serialize_to_buffer(byte_lookup_table_in_tags, Transcript::proof_data); - serialize_to_buffer(byte_lookup_table_input_a, Transcript::proof_data); - serialize_to_buffer(byte_lookup_table_input_b, Transcript::proof_data); - serialize_to_buffer(byte_lookup_table_op_id, Transcript::proof_data); - serialize_to_buffer(byte_lookup_table_output, Transcript::proof_data); - serialize_to_buffer(conversion_clk, Transcript::proof_data); - serialize_to_buffer(conversion_input, Transcript::proof_data); - serialize_to_buffer(conversion_num_limbs, Transcript::proof_data); - serialize_to_buffer(conversion_radix, Transcript::proof_data); - serialize_to_buffer(conversion_sel_to_radix_le, Transcript::proof_data); - serialize_to_buffer(gas_da_gas_fixed_table, Transcript::proof_data); - serialize_to_buffer(gas_l2_gas_fixed_table, Transcript::proof_data); - serialize_to_buffer(gas_sel_gas_cost, Transcript::proof_data); - serialize_to_buffer(keccakf1600_clk, Transcript::proof_data); - serialize_to_buffer(keccakf1600_input, Transcript::proof_data); - serialize_to_buffer(keccakf1600_output, Transcript::proof_data); - serialize_to_buffer(keccakf1600_sel_keccakf1600, Transcript::proof_data); - serialize_to_buffer(kernel_emit_l2_to_l1_msg_write_offset, Transcript::proof_data); - serialize_to_buffer(kernel_emit_note_hash_write_offset, Transcript::proof_data); - serialize_to_buffer(kernel_emit_nullifier_write_offset, Transcript::proof_data); - serialize_to_buffer(kernel_emit_unencrypted_log_write_offset, Transcript::proof_data); - serialize_to_buffer(kernel_kernel_in_offset, Transcript::proof_data); - serialize_to_buffer(kernel_kernel_out_offset, Transcript::proof_data); - serialize_to_buffer(kernel_l1_to_l2_msg_exists_write_offset, Transcript::proof_data); - serialize_to_buffer(kernel_note_hash_exist_write_offset, Transcript::proof_data); - serialize_to_buffer(kernel_nullifier_exists_write_offset, Transcript::proof_data); - serialize_to_buffer(kernel_nullifier_non_exists_write_offset, Transcript::proof_data); - serialize_to_buffer(kernel_q_public_input_kernel_add_to_table, Transcript::proof_data); - serialize_to_buffer(kernel_q_public_input_kernel_out_add_to_table, Transcript::proof_data); - serialize_to_buffer(kernel_side_effect_counter, Transcript::proof_data); - serialize_to_buffer(kernel_sload_write_offset, Transcript::proof_data); - serialize_to_buffer(kernel_sstore_write_offset, Transcript::proof_data); - serialize_to_buffer(main_abs_da_rem_gas_hi, Transcript::proof_data); - serialize_to_buffer(main_abs_da_rem_gas_lo, Transcript::proof_data); - serialize_to_buffer(main_abs_l2_rem_gas_hi, Transcript::proof_data); - serialize_to_buffer(main_abs_l2_rem_gas_lo, Transcript::proof_data); - serialize_to_buffer(main_alu_in_tag, Transcript::proof_data); - serialize_to_buffer(main_bin_op_id, Transcript::proof_data); - serialize_to_buffer(main_call_ptr, Transcript::proof_data); - serialize_to_buffer(main_da_gas_op_cost, Transcript::proof_data); - serialize_to_buffer(main_da_gas_remaining, Transcript::proof_data); - serialize_to_buffer(main_da_out_of_gas, Transcript::proof_data); - serialize_to_buffer(main_ia, Transcript::proof_data); - serialize_to_buffer(main_ib, Transcript::proof_data); - serialize_to_buffer(main_ic, Transcript::proof_data); - serialize_to_buffer(main_id, Transcript::proof_data); - serialize_to_buffer(main_id_zero, Transcript::proof_data); - serialize_to_buffer(main_ind_addr_a, Transcript::proof_data); - serialize_to_buffer(main_ind_addr_b, Transcript::proof_data); - serialize_to_buffer(main_ind_addr_c, Transcript::proof_data); - serialize_to_buffer(main_ind_addr_d, Transcript::proof_data); - serialize_to_buffer(main_internal_return_ptr, Transcript::proof_data); - serialize_to_buffer(main_inv, Transcript::proof_data); - serialize_to_buffer(main_l2_gas_op_cost, Transcript::proof_data); - serialize_to_buffer(main_l2_gas_remaining, Transcript::proof_data); - serialize_to_buffer(main_l2_out_of_gas, Transcript::proof_data); - serialize_to_buffer(main_mem_addr_a, Transcript::proof_data); - serialize_to_buffer(main_mem_addr_b, Transcript::proof_data); - serialize_to_buffer(main_mem_addr_c, Transcript::proof_data); - serialize_to_buffer(main_mem_addr_d, Transcript::proof_data); - serialize_to_buffer(main_op_err, Transcript::proof_data); - serialize_to_buffer(main_opcode_val, Transcript::proof_data); - serialize_to_buffer(main_pc, Transcript::proof_data); - serialize_to_buffer(main_r_in_tag, Transcript::proof_data); - serialize_to_buffer(main_rwa, Transcript::proof_data); - serialize_to_buffer(main_rwb, Transcript::proof_data); - serialize_to_buffer(main_rwc, Transcript::proof_data); - serialize_to_buffer(main_rwd, Transcript::proof_data); - serialize_to_buffer(main_sel_alu, Transcript::proof_data); - serialize_to_buffer(main_sel_bin, Transcript::proof_data); - serialize_to_buffer(main_sel_gas_accounting_active, Transcript::proof_data); - serialize_to_buffer(main_sel_last, Transcript::proof_data); - serialize_to_buffer(main_sel_mem_op_a, Transcript::proof_data); - serialize_to_buffer(main_sel_mem_op_activate_gas, Transcript::proof_data); - serialize_to_buffer(main_sel_mem_op_b, Transcript::proof_data); - serialize_to_buffer(main_sel_mem_op_c, Transcript::proof_data); - serialize_to_buffer(main_sel_mem_op_d, Transcript::proof_data); - serialize_to_buffer(main_sel_mov_ia_to_ic, Transcript::proof_data); - serialize_to_buffer(main_sel_mov_ib_to_ic, Transcript::proof_data); - serialize_to_buffer(main_sel_op_add, Transcript::proof_data); - serialize_to_buffer(main_sel_op_address, Transcript::proof_data); - serialize_to_buffer(main_sel_op_and, Transcript::proof_data); - serialize_to_buffer(main_sel_op_block_number, Transcript::proof_data); - serialize_to_buffer(main_sel_op_cast, Transcript::proof_data); - serialize_to_buffer(main_sel_op_chain_id, Transcript::proof_data); - serialize_to_buffer(main_sel_op_cmov, Transcript::proof_data); - serialize_to_buffer(main_sel_op_coinbase, Transcript::proof_data); - serialize_to_buffer(main_sel_op_dagasleft, Transcript::proof_data); - serialize_to_buffer(main_sel_op_div, Transcript::proof_data); - serialize_to_buffer(main_sel_op_emit_l2_to_l1_msg, Transcript::proof_data); - serialize_to_buffer(main_sel_op_emit_note_hash, Transcript::proof_data); - serialize_to_buffer(main_sel_op_emit_nullifier, Transcript::proof_data); - serialize_to_buffer(main_sel_op_emit_unencrypted_log, Transcript::proof_data); - serialize_to_buffer(main_sel_op_eq, Transcript::proof_data); - serialize_to_buffer(main_sel_op_external_call, Transcript::proof_data); - serialize_to_buffer(main_sel_op_fdiv, Transcript::proof_data); - serialize_to_buffer(main_sel_op_fee_per_da_gas, Transcript::proof_data); - serialize_to_buffer(main_sel_op_fee_per_l2_gas, Transcript::proof_data); - serialize_to_buffer(main_sel_op_function_selector, Transcript::proof_data); - serialize_to_buffer(main_sel_op_get_contract_instance, Transcript::proof_data); - serialize_to_buffer(main_sel_op_halt, Transcript::proof_data); - serialize_to_buffer(main_sel_op_internal_call, Transcript::proof_data); - serialize_to_buffer(main_sel_op_internal_return, Transcript::proof_data); - serialize_to_buffer(main_sel_op_jump, Transcript::proof_data); - serialize_to_buffer(main_sel_op_jumpi, Transcript::proof_data); - serialize_to_buffer(main_sel_op_keccak, Transcript::proof_data); - serialize_to_buffer(main_sel_op_l1_to_l2_msg_exists, Transcript::proof_data); - serialize_to_buffer(main_sel_op_l2gasleft, Transcript::proof_data); - serialize_to_buffer(main_sel_op_lt, Transcript::proof_data); - serialize_to_buffer(main_sel_op_lte, Transcript::proof_data); - serialize_to_buffer(main_sel_op_mov, Transcript::proof_data); - serialize_to_buffer(main_sel_op_mul, Transcript::proof_data); - serialize_to_buffer(main_sel_op_not, Transcript::proof_data); - serialize_to_buffer(main_sel_op_note_hash_exists, Transcript::proof_data); - serialize_to_buffer(main_sel_op_nullifier_exists, Transcript::proof_data); - serialize_to_buffer(main_sel_op_or, Transcript::proof_data); - serialize_to_buffer(main_sel_op_pedersen, Transcript::proof_data); - serialize_to_buffer(main_sel_op_poseidon2, Transcript::proof_data); - serialize_to_buffer(main_sel_op_radix_le, Transcript::proof_data); - serialize_to_buffer(main_sel_op_sender, Transcript::proof_data); - serialize_to_buffer(main_sel_op_sha256, Transcript::proof_data); - serialize_to_buffer(main_sel_op_shl, Transcript::proof_data); - serialize_to_buffer(main_sel_op_shr, Transcript::proof_data); - serialize_to_buffer(main_sel_op_sload, Transcript::proof_data); - serialize_to_buffer(main_sel_op_sstore, Transcript::proof_data); - serialize_to_buffer(main_sel_op_storage_address, Transcript::proof_data); - serialize_to_buffer(main_sel_op_sub, Transcript::proof_data); - serialize_to_buffer(main_sel_op_timestamp, Transcript::proof_data); - serialize_to_buffer(main_sel_op_transaction_fee, Transcript::proof_data); - serialize_to_buffer(main_sel_op_version, Transcript::proof_data); - serialize_to_buffer(main_sel_op_xor, Transcript::proof_data); - serialize_to_buffer(main_sel_q_kernel_lookup, Transcript::proof_data); - serialize_to_buffer(main_sel_q_kernel_output_lookup, Transcript::proof_data); - serialize_to_buffer(main_sel_resolve_ind_addr_a, Transcript::proof_data); - serialize_to_buffer(main_sel_resolve_ind_addr_b, Transcript::proof_data); - serialize_to_buffer(main_sel_resolve_ind_addr_c, Transcript::proof_data); - serialize_to_buffer(main_sel_resolve_ind_addr_d, Transcript::proof_data); - serialize_to_buffer(main_sel_rng_16, Transcript::proof_data); - serialize_to_buffer(main_sel_rng_8, Transcript::proof_data); - serialize_to_buffer(main_space_id, Transcript::proof_data); - serialize_to_buffer(main_tag_err, Transcript::proof_data); - serialize_to_buffer(main_w_in_tag, Transcript::proof_data); - serialize_to_buffer(mem_addr, Transcript::proof_data); - serialize_to_buffer(mem_clk, Transcript::proof_data); - serialize_to_buffer(mem_diff_hi, Transcript::proof_data); - serialize_to_buffer(mem_diff_lo, Transcript::proof_data); - serialize_to_buffer(mem_diff_mid, Transcript::proof_data); - serialize_to_buffer(mem_glob_addr, Transcript::proof_data); - serialize_to_buffer(mem_last, Transcript::proof_data); - serialize_to_buffer(mem_lastAccess, Transcript::proof_data); - serialize_to_buffer(mem_one_min_inv, Transcript::proof_data); - serialize_to_buffer(mem_r_in_tag, Transcript::proof_data); - serialize_to_buffer(mem_rw, Transcript::proof_data); - serialize_to_buffer(mem_sel_mem, Transcript::proof_data); - serialize_to_buffer(mem_sel_mov_ia_to_ic, Transcript::proof_data); - serialize_to_buffer(mem_sel_mov_ib_to_ic, Transcript::proof_data); - serialize_to_buffer(mem_sel_op_a, Transcript::proof_data); - serialize_to_buffer(mem_sel_op_b, Transcript::proof_data); - serialize_to_buffer(mem_sel_op_c, Transcript::proof_data); - serialize_to_buffer(mem_sel_op_cmov, Transcript::proof_data); - serialize_to_buffer(mem_sel_op_d, Transcript::proof_data); - serialize_to_buffer(mem_sel_resolve_ind_addr_a, Transcript::proof_data); - serialize_to_buffer(mem_sel_resolve_ind_addr_b, Transcript::proof_data); - serialize_to_buffer(mem_sel_resolve_ind_addr_c, Transcript::proof_data); - serialize_to_buffer(mem_sel_resolve_ind_addr_d, Transcript::proof_data); - serialize_to_buffer(mem_sel_rng_chk, Transcript::proof_data); - serialize_to_buffer(mem_skip_check_tag, Transcript::proof_data); - serialize_to_buffer(mem_space_id, Transcript::proof_data); - serialize_to_buffer(mem_tag, Transcript::proof_data); - serialize_to_buffer(mem_tag_err, Transcript::proof_data); - serialize_to_buffer(mem_tsp, Transcript::proof_data); - serialize_to_buffer(mem_val, Transcript::proof_data); - serialize_to_buffer(mem_w_in_tag, Transcript::proof_data); - serialize_to_buffer(pedersen_clk, Transcript::proof_data); - serialize_to_buffer(pedersen_input, Transcript::proof_data); - serialize_to_buffer(pedersen_output, Transcript::proof_data); - serialize_to_buffer(pedersen_sel_pedersen, Transcript::proof_data); - serialize_to_buffer(poseidon2_a_0, Transcript::proof_data); - serialize_to_buffer(poseidon2_a_1, Transcript::proof_data); - serialize_to_buffer(poseidon2_a_2, Transcript::proof_data); - serialize_to_buffer(poseidon2_a_3, Transcript::proof_data); - serialize_to_buffer(poseidon2_b_0, Transcript::proof_data); - serialize_to_buffer(poseidon2_b_1, Transcript::proof_data); - serialize_to_buffer(poseidon2_b_2, Transcript::proof_data); - serialize_to_buffer(poseidon2_b_3, Transcript::proof_data); - serialize_to_buffer(poseidon2_clk, Transcript::proof_data); - serialize_to_buffer(poseidon2_input, Transcript::proof_data); - serialize_to_buffer(poseidon2_output, Transcript::proof_data); - serialize_to_buffer(poseidon2_sel_poseidon_perm, Transcript::proof_data); - serialize_to_buffer(powers_power_of_2, Transcript::proof_data); - serialize_to_buffer(sha256_clk, Transcript::proof_data); - serialize_to_buffer(sha256_input, Transcript::proof_data); - serialize_to_buffer(sha256_output, Transcript::proof_data); - serialize_to_buffer(sha256_sel_sha256_compression, Transcript::proof_data); - serialize_to_buffer(sha256_state, Transcript::proof_data); - serialize_to_buffer(perm_main_alu, Transcript::proof_data); - serialize_to_buffer(perm_main_bin, Transcript::proof_data); - serialize_to_buffer(perm_main_conv, Transcript::proof_data); - serialize_to_buffer(perm_main_pos2_perm, Transcript::proof_data); - serialize_to_buffer(perm_main_pedersen, Transcript::proof_data); - serialize_to_buffer(perm_main_mem_a, Transcript::proof_data); - serialize_to_buffer(perm_main_mem_b, Transcript::proof_data); - serialize_to_buffer(perm_main_mem_c, Transcript::proof_data); - serialize_to_buffer(perm_main_mem_d, Transcript::proof_data); - serialize_to_buffer(perm_main_mem_ind_addr_a, Transcript::proof_data); - serialize_to_buffer(perm_main_mem_ind_addr_b, Transcript::proof_data); - serialize_to_buffer(perm_main_mem_ind_addr_c, Transcript::proof_data); - serialize_to_buffer(perm_main_mem_ind_addr_d, Transcript::proof_data); - serialize_to_buffer(lookup_byte_lengths, Transcript::proof_data); - serialize_to_buffer(lookup_byte_operations, Transcript::proof_data); - serialize_to_buffer(lookup_opcode_gas, Transcript::proof_data); - serialize_to_buffer(range_check_l2_gas_hi, Transcript::proof_data); - serialize_to_buffer(range_check_l2_gas_lo, Transcript::proof_data); - serialize_to_buffer(range_check_da_gas_hi, Transcript::proof_data); - serialize_to_buffer(range_check_da_gas_lo, Transcript::proof_data); - serialize_to_buffer(kernel_output_lookup, Transcript::proof_data); - serialize_to_buffer(lookup_into_kernel, Transcript::proof_data); - serialize_to_buffer(incl_main_tag_err, Transcript::proof_data); - serialize_to_buffer(incl_mem_tag_err, Transcript::proof_data); - serialize_to_buffer(lookup_mem_rng_chk_lo, Transcript::proof_data); - serialize_to_buffer(lookup_mem_rng_chk_mid, Transcript::proof_data); - serialize_to_buffer(lookup_mem_rng_chk_hi, Transcript::proof_data); - serialize_to_buffer(lookup_pow_2_0, Transcript::proof_data); - serialize_to_buffer(lookup_pow_2_1, Transcript::proof_data); - serialize_to_buffer(lookup_u8_0, Transcript::proof_data); - serialize_to_buffer(lookup_u8_1, Transcript::proof_data); - serialize_to_buffer(lookup_u16_0, Transcript::proof_data); - serialize_to_buffer(lookup_u16_1, Transcript::proof_data); - serialize_to_buffer(lookup_u16_2, Transcript::proof_data); - serialize_to_buffer(lookup_u16_3, Transcript::proof_data); - serialize_to_buffer(lookup_u16_4, Transcript::proof_data); - serialize_to_buffer(lookup_u16_5, Transcript::proof_data); - serialize_to_buffer(lookup_u16_6, Transcript::proof_data); - serialize_to_buffer(lookup_u16_7, Transcript::proof_data); - serialize_to_buffer(lookup_u16_8, Transcript::proof_data); - serialize_to_buffer(lookup_u16_9, Transcript::proof_data); - serialize_to_buffer(lookup_u16_10, Transcript::proof_data); - serialize_to_buffer(lookup_u16_11, Transcript::proof_data); - serialize_to_buffer(lookup_u16_12, Transcript::proof_data); - serialize_to_buffer(lookup_u16_13, Transcript::proof_data); - serialize_to_buffer(lookup_u16_14, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_0, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_1, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_2, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_3, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_4, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_5, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_6, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_7, Transcript::proof_data); - serialize_to_buffer(lookup_byte_lengths_counts, Transcript::proof_data); - serialize_to_buffer(lookup_byte_operations_counts, Transcript::proof_data); - serialize_to_buffer(lookup_opcode_gas_counts, Transcript::proof_data); - serialize_to_buffer(range_check_l2_gas_hi_counts, Transcript::proof_data); - serialize_to_buffer(range_check_l2_gas_lo_counts, Transcript::proof_data); - serialize_to_buffer(range_check_da_gas_hi_counts, Transcript::proof_data); - serialize_to_buffer(range_check_da_gas_lo_counts, Transcript::proof_data); - serialize_to_buffer(kernel_output_lookup_counts, Transcript::proof_data); - serialize_to_buffer(lookup_into_kernel_counts, Transcript::proof_data); - serialize_to_buffer(incl_main_tag_err_counts, Transcript::proof_data); - serialize_to_buffer(incl_mem_tag_err_counts, Transcript::proof_data); - serialize_to_buffer(lookup_mem_rng_chk_lo_counts, Transcript::proof_data); - serialize_to_buffer(lookup_mem_rng_chk_mid_counts, Transcript::proof_data); - serialize_to_buffer(lookup_mem_rng_chk_hi_counts, Transcript::proof_data); - serialize_to_buffer(lookup_pow_2_0_counts, Transcript::proof_data); - serialize_to_buffer(lookup_pow_2_1_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u8_0_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u8_1_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_0_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_1_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_2_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_3_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_4_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_5_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_6_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_7_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_8_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_9_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_10_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_11_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_12_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_13_counts, Transcript::proof_data); - serialize_to_buffer(lookup_u16_14_counts, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_0_counts, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_1_counts, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_2_counts, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_3_counts, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_4_counts, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_5_counts, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_6_counts, Transcript::proof_data); - serialize_to_buffer(lookup_div_u16_7_counts, Transcript::proof_data); - ->>>>>>> 520b7216c (feat(avm): poseidon2 constraints) for (size_t i = 0; i < log_n; ++i) { serialize_to_buffer(sumcheck_univariates[i], Transcript::proof_data); } diff --git a/barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp b/barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp index 6060b0407140..71f1b08f9cff 100644 --- a/barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp @@ -70,557 +70,19 @@ bool AvmVerifier::verify_proof(const HonkProof& proof, const std::vectortemplate receive_from_prover(label); } -======= - commitments.kernel_kernel_inputs = - transcript->template receive_from_prover(commitment_labels.kernel_kernel_inputs); - commitments.kernel_kernel_value_out = - transcript->template receive_from_prover(commitment_labels.kernel_kernel_value_out); - commitments.kernel_kernel_side_effect_out = - transcript->template receive_from_prover(commitment_labels.kernel_kernel_side_effect_out); - commitments.kernel_kernel_metadata_out = - transcript->template receive_from_prover(commitment_labels.kernel_kernel_metadata_out); - commitments.main_calldata = transcript->template receive_from_prover(commitment_labels.main_calldata); - commitments.alu_a_hi = transcript->template receive_from_prover(commitment_labels.alu_a_hi); - commitments.alu_a_lo = transcript->template receive_from_prover(commitment_labels.alu_a_lo); - commitments.alu_b_hi = transcript->template receive_from_prover(commitment_labels.alu_b_hi); - commitments.alu_b_lo = transcript->template receive_from_prover(commitment_labels.alu_b_lo); - commitments.alu_borrow = transcript->template receive_from_prover(commitment_labels.alu_borrow); - commitments.alu_cf = transcript->template receive_from_prover(commitment_labels.alu_cf); - commitments.alu_clk = transcript->template receive_from_prover(commitment_labels.alu_clk); - commitments.alu_cmp_rng_ctr = - transcript->template receive_from_prover(commitment_labels.alu_cmp_rng_ctr); - commitments.alu_div_u16_r0 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r0); - commitments.alu_div_u16_r1 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r1); - commitments.alu_div_u16_r2 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r2); - commitments.alu_div_u16_r3 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r3); - commitments.alu_div_u16_r4 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r4); - commitments.alu_div_u16_r5 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r5); - commitments.alu_div_u16_r6 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r6); - commitments.alu_div_u16_r7 = transcript->template receive_from_prover(commitment_labels.alu_div_u16_r7); - commitments.alu_divisor_hi = transcript->template receive_from_prover(commitment_labels.alu_divisor_hi); - commitments.alu_divisor_lo = transcript->template receive_from_prover(commitment_labels.alu_divisor_lo); - commitments.alu_ff_tag = transcript->template receive_from_prover(commitment_labels.alu_ff_tag); - commitments.alu_ia = transcript->template receive_from_prover(commitment_labels.alu_ia); - commitments.alu_ib = transcript->template receive_from_prover(commitment_labels.alu_ib); - commitments.alu_ic = transcript->template receive_from_prover(commitment_labels.alu_ic); - commitments.alu_in_tag = transcript->template receive_from_prover(commitment_labels.alu_in_tag); - commitments.alu_op_add = transcript->template receive_from_prover(commitment_labels.alu_op_add); - commitments.alu_op_cast = transcript->template receive_from_prover(commitment_labels.alu_op_cast); - commitments.alu_op_cast_prev = - transcript->template receive_from_prover(commitment_labels.alu_op_cast_prev); - commitments.alu_op_div = transcript->template receive_from_prover(commitment_labels.alu_op_div); - commitments.alu_op_div_a_lt_b = - transcript->template receive_from_prover(commitment_labels.alu_op_div_a_lt_b); - commitments.alu_op_div_std = transcript->template receive_from_prover(commitment_labels.alu_op_div_std); - commitments.alu_op_eq = transcript->template receive_from_prover(commitment_labels.alu_op_eq); - commitments.alu_op_eq_diff_inv = - transcript->template receive_from_prover(commitment_labels.alu_op_eq_diff_inv); - commitments.alu_op_lt = transcript->template receive_from_prover(commitment_labels.alu_op_lt); - commitments.alu_op_lte = transcript->template receive_from_prover(commitment_labels.alu_op_lte); - commitments.alu_op_mul = transcript->template receive_from_prover(commitment_labels.alu_op_mul); - commitments.alu_op_not = transcript->template receive_from_prover(commitment_labels.alu_op_not); - commitments.alu_op_shl = transcript->template receive_from_prover(commitment_labels.alu_op_shl); - commitments.alu_op_shr = transcript->template receive_from_prover(commitment_labels.alu_op_shr); - commitments.alu_op_sub = transcript->template receive_from_prover(commitment_labels.alu_op_sub); - commitments.alu_p_a_borrow = transcript->template receive_from_prover(commitment_labels.alu_p_a_borrow); - commitments.alu_p_b_borrow = transcript->template receive_from_prover(commitment_labels.alu_p_b_borrow); - commitments.alu_p_sub_a_hi = transcript->template receive_from_prover(commitment_labels.alu_p_sub_a_hi); - commitments.alu_p_sub_a_lo = transcript->template receive_from_prover(commitment_labels.alu_p_sub_a_lo); - commitments.alu_p_sub_b_hi = transcript->template receive_from_prover(commitment_labels.alu_p_sub_b_hi); - commitments.alu_p_sub_b_lo = transcript->template receive_from_prover(commitment_labels.alu_p_sub_b_lo); - commitments.alu_partial_prod_hi = - transcript->template receive_from_prover(commitment_labels.alu_partial_prod_hi); - commitments.alu_partial_prod_lo = - transcript->template receive_from_prover(commitment_labels.alu_partial_prod_lo); - commitments.alu_quotient_hi = - transcript->template receive_from_prover(commitment_labels.alu_quotient_hi); - commitments.alu_quotient_lo = - transcript->template receive_from_prover(commitment_labels.alu_quotient_lo); - commitments.alu_remainder = transcript->template receive_from_prover(commitment_labels.alu_remainder); - commitments.alu_res_hi = transcript->template receive_from_prover(commitment_labels.alu_res_hi); - commitments.alu_res_lo = transcript->template receive_from_prover(commitment_labels.alu_res_lo); - commitments.alu_sel_alu = transcript->template receive_from_prover(commitment_labels.alu_sel_alu); - commitments.alu_sel_cmp = transcript->template receive_from_prover(commitment_labels.alu_sel_cmp); - commitments.alu_sel_div_rng_chk = - transcript->template receive_from_prover(commitment_labels.alu_sel_div_rng_chk); - commitments.alu_sel_rng_chk = - transcript->template receive_from_prover(commitment_labels.alu_sel_rng_chk); - commitments.alu_sel_rng_chk_lookup = - transcript->template receive_from_prover(commitment_labels.alu_sel_rng_chk_lookup); - commitments.alu_sel_shift_which = - transcript->template receive_from_prover(commitment_labels.alu_sel_shift_which); - commitments.alu_shift_lt_bit_len = - transcript->template receive_from_prover(commitment_labels.alu_shift_lt_bit_len); - commitments.alu_t_sub_s_bits = - transcript->template receive_from_prover(commitment_labels.alu_t_sub_s_bits); - commitments.alu_two_pow_s = transcript->template receive_from_prover(commitment_labels.alu_two_pow_s); - commitments.alu_two_pow_t_sub_s = - transcript->template receive_from_prover(commitment_labels.alu_two_pow_t_sub_s); - commitments.alu_u128_tag = transcript->template receive_from_prover(commitment_labels.alu_u128_tag); - commitments.alu_u16_r0 = transcript->template receive_from_prover(commitment_labels.alu_u16_r0); - commitments.alu_u16_r1 = transcript->template receive_from_prover(commitment_labels.alu_u16_r1); - commitments.alu_u16_r10 = transcript->template receive_from_prover(commitment_labels.alu_u16_r10); - commitments.alu_u16_r11 = transcript->template receive_from_prover(commitment_labels.alu_u16_r11); - commitments.alu_u16_r12 = transcript->template receive_from_prover(commitment_labels.alu_u16_r12); - commitments.alu_u16_r13 = transcript->template receive_from_prover(commitment_labels.alu_u16_r13); - commitments.alu_u16_r14 = transcript->template receive_from_prover(commitment_labels.alu_u16_r14); - commitments.alu_u16_r2 = transcript->template receive_from_prover(commitment_labels.alu_u16_r2); - commitments.alu_u16_r3 = transcript->template receive_from_prover(commitment_labels.alu_u16_r3); - commitments.alu_u16_r4 = transcript->template receive_from_prover(commitment_labels.alu_u16_r4); - commitments.alu_u16_r5 = transcript->template receive_from_prover(commitment_labels.alu_u16_r5); - commitments.alu_u16_r6 = transcript->template receive_from_prover(commitment_labels.alu_u16_r6); - commitments.alu_u16_r7 = transcript->template receive_from_prover(commitment_labels.alu_u16_r7); - commitments.alu_u16_r8 = transcript->template receive_from_prover(commitment_labels.alu_u16_r8); - commitments.alu_u16_r9 = transcript->template receive_from_prover(commitment_labels.alu_u16_r9); - commitments.alu_u16_tag = transcript->template receive_from_prover(commitment_labels.alu_u16_tag); - commitments.alu_u32_tag = transcript->template receive_from_prover(commitment_labels.alu_u32_tag); - commitments.alu_u64_tag = transcript->template receive_from_prover(commitment_labels.alu_u64_tag); - commitments.alu_u8_r0 = transcript->template receive_from_prover(commitment_labels.alu_u8_r0); - commitments.alu_u8_r1 = transcript->template receive_from_prover(commitment_labels.alu_u8_r1); - commitments.alu_u8_tag = transcript->template receive_from_prover(commitment_labels.alu_u8_tag); - commitments.binary_acc_ia = transcript->template receive_from_prover(commitment_labels.binary_acc_ia); - commitments.binary_acc_ib = transcript->template receive_from_prover(commitment_labels.binary_acc_ib); - commitments.binary_acc_ic = transcript->template receive_from_prover(commitment_labels.binary_acc_ic); - commitments.binary_clk = transcript->template receive_from_prover(commitment_labels.binary_clk); - commitments.binary_ia_bytes = - transcript->template receive_from_prover(commitment_labels.binary_ia_bytes); - commitments.binary_ib_bytes = - transcript->template receive_from_prover(commitment_labels.binary_ib_bytes); - commitments.binary_ic_bytes = - transcript->template receive_from_prover(commitment_labels.binary_ic_bytes); - commitments.binary_in_tag = transcript->template receive_from_prover(commitment_labels.binary_in_tag); - commitments.binary_mem_tag_ctr = - transcript->template receive_from_prover(commitment_labels.binary_mem_tag_ctr); - commitments.binary_mem_tag_ctr_inv = - transcript->template receive_from_prover(commitment_labels.binary_mem_tag_ctr_inv); - commitments.binary_op_id = transcript->template receive_from_prover(commitment_labels.binary_op_id); - commitments.binary_sel_bin = transcript->template receive_from_prover(commitment_labels.binary_sel_bin); - commitments.binary_start = transcript->template receive_from_prover(commitment_labels.binary_start); - commitments.byte_lookup_sel_bin = - transcript->template receive_from_prover(commitment_labels.byte_lookup_sel_bin); - commitments.byte_lookup_table_byte_lengths = - transcript->template receive_from_prover(commitment_labels.byte_lookup_table_byte_lengths); - commitments.byte_lookup_table_in_tags = - transcript->template receive_from_prover(commitment_labels.byte_lookup_table_in_tags); - commitments.byte_lookup_table_input_a = - transcript->template receive_from_prover(commitment_labels.byte_lookup_table_input_a); - commitments.byte_lookup_table_input_b = - transcript->template receive_from_prover(commitment_labels.byte_lookup_table_input_b); - commitments.byte_lookup_table_op_id = - transcript->template receive_from_prover(commitment_labels.byte_lookup_table_op_id); - commitments.byte_lookup_table_output = - transcript->template receive_from_prover(commitment_labels.byte_lookup_table_output); - commitments.conversion_clk = transcript->template receive_from_prover(commitment_labels.conversion_clk); - commitments.conversion_input = - transcript->template receive_from_prover(commitment_labels.conversion_input); - commitments.conversion_num_limbs = - transcript->template receive_from_prover(commitment_labels.conversion_num_limbs); - commitments.conversion_radix = - transcript->template receive_from_prover(commitment_labels.conversion_radix); - commitments.conversion_sel_to_radix_le = - transcript->template receive_from_prover(commitment_labels.conversion_sel_to_radix_le); - commitments.gas_da_gas_fixed_table = - transcript->template receive_from_prover(commitment_labels.gas_da_gas_fixed_table); - commitments.gas_l2_gas_fixed_table = - transcript->template receive_from_prover(commitment_labels.gas_l2_gas_fixed_table); - commitments.gas_sel_gas_cost = - transcript->template receive_from_prover(commitment_labels.gas_sel_gas_cost); - commitments.keccakf1600_clk = - transcript->template receive_from_prover(commitment_labels.keccakf1600_clk); - commitments.keccakf1600_input = - transcript->template receive_from_prover(commitment_labels.keccakf1600_input); - commitments.keccakf1600_output = - transcript->template receive_from_prover(commitment_labels.keccakf1600_output); - commitments.keccakf1600_sel_keccakf1600 = - transcript->template receive_from_prover(commitment_labels.keccakf1600_sel_keccakf1600); - commitments.kernel_emit_l2_to_l1_msg_write_offset = - transcript->template receive_from_prover(commitment_labels.kernel_emit_l2_to_l1_msg_write_offset); - commitments.kernel_emit_note_hash_write_offset = - transcript->template receive_from_prover(commitment_labels.kernel_emit_note_hash_write_offset); - commitments.kernel_emit_nullifier_write_offset = - transcript->template receive_from_prover(commitment_labels.kernel_emit_nullifier_write_offset); - commitments.kernel_emit_unencrypted_log_write_offset = transcript->template receive_from_prover( - commitment_labels.kernel_emit_unencrypted_log_write_offset); - commitments.kernel_kernel_in_offset = - transcript->template receive_from_prover(commitment_labels.kernel_kernel_in_offset); - commitments.kernel_kernel_out_offset = - transcript->template receive_from_prover(commitment_labels.kernel_kernel_out_offset); - commitments.kernel_l1_to_l2_msg_exists_write_offset = - transcript->template receive_from_prover(commitment_labels.kernel_l1_to_l2_msg_exists_write_offset); - commitments.kernel_note_hash_exist_write_offset = - transcript->template receive_from_prover(commitment_labels.kernel_note_hash_exist_write_offset); - commitments.kernel_nullifier_exists_write_offset = - transcript->template receive_from_prover(commitment_labels.kernel_nullifier_exists_write_offset); - commitments.kernel_nullifier_non_exists_write_offset = transcript->template receive_from_prover( - commitment_labels.kernel_nullifier_non_exists_write_offset); - commitments.kernel_q_public_input_kernel_add_to_table = transcript->template receive_from_prover( - commitment_labels.kernel_q_public_input_kernel_add_to_table); - commitments.kernel_q_public_input_kernel_out_add_to_table = transcript->template receive_from_prover( - commitment_labels.kernel_q_public_input_kernel_out_add_to_table); - commitments.kernel_side_effect_counter = - transcript->template receive_from_prover(commitment_labels.kernel_side_effect_counter); - commitments.kernel_sload_write_offset = - transcript->template receive_from_prover(commitment_labels.kernel_sload_write_offset); - commitments.kernel_sstore_write_offset = - transcript->template receive_from_prover(commitment_labels.kernel_sstore_write_offset); - commitments.main_abs_da_rem_gas_hi = - transcript->template receive_from_prover(commitment_labels.main_abs_da_rem_gas_hi); - commitments.main_abs_da_rem_gas_lo = - transcript->template receive_from_prover(commitment_labels.main_abs_da_rem_gas_lo); - commitments.main_abs_l2_rem_gas_hi = - transcript->template receive_from_prover(commitment_labels.main_abs_l2_rem_gas_hi); - commitments.main_abs_l2_rem_gas_lo = - transcript->template receive_from_prover(commitment_labels.main_abs_l2_rem_gas_lo); - commitments.main_alu_in_tag = - transcript->template receive_from_prover(commitment_labels.main_alu_in_tag); - commitments.main_bin_op_id = transcript->template receive_from_prover(commitment_labels.main_bin_op_id); - commitments.main_call_ptr = transcript->template receive_from_prover(commitment_labels.main_call_ptr); - commitments.main_da_gas_op_cost = - transcript->template receive_from_prover(commitment_labels.main_da_gas_op_cost); - commitments.main_da_gas_remaining = - transcript->template receive_from_prover(commitment_labels.main_da_gas_remaining); - commitments.main_da_out_of_gas = - transcript->template receive_from_prover(commitment_labels.main_da_out_of_gas); - commitments.main_ia = transcript->template receive_from_prover(commitment_labels.main_ia); - commitments.main_ib = transcript->template receive_from_prover(commitment_labels.main_ib); - commitments.main_ic = transcript->template receive_from_prover(commitment_labels.main_ic); - commitments.main_id = transcript->template receive_from_prover(commitment_labels.main_id); - commitments.main_id_zero = transcript->template receive_from_prover(commitment_labels.main_id_zero); - commitments.main_ind_addr_a = - transcript->template receive_from_prover(commitment_labels.main_ind_addr_a); - commitments.main_ind_addr_b = - transcript->template receive_from_prover(commitment_labels.main_ind_addr_b); - commitments.main_ind_addr_c = - transcript->template receive_from_prover(commitment_labels.main_ind_addr_c); - commitments.main_ind_addr_d = - transcript->template receive_from_prover(commitment_labels.main_ind_addr_d); - commitments.main_internal_return_ptr = - transcript->template receive_from_prover(commitment_labels.main_internal_return_ptr); - commitments.main_inv = transcript->template receive_from_prover(commitment_labels.main_inv); - commitments.main_l2_gas_op_cost = - transcript->template receive_from_prover(commitment_labels.main_l2_gas_op_cost); - commitments.main_l2_gas_remaining = - transcript->template receive_from_prover(commitment_labels.main_l2_gas_remaining); - commitments.main_l2_out_of_gas = - transcript->template receive_from_prover(commitment_labels.main_l2_out_of_gas); - commitments.main_mem_addr_a = - transcript->template receive_from_prover(commitment_labels.main_mem_addr_a); - commitments.main_mem_addr_b = - transcript->template receive_from_prover(commitment_labels.main_mem_addr_b); - commitments.main_mem_addr_c = - transcript->template receive_from_prover(commitment_labels.main_mem_addr_c); - commitments.main_mem_addr_d = - transcript->template receive_from_prover(commitment_labels.main_mem_addr_d); - commitments.main_op_err = transcript->template receive_from_prover(commitment_labels.main_op_err); - commitments.main_opcode_val = - transcript->template receive_from_prover(commitment_labels.main_opcode_val); - commitments.main_pc = transcript->template receive_from_prover(commitment_labels.main_pc); - commitments.main_r_in_tag = transcript->template receive_from_prover(commitment_labels.main_r_in_tag); - commitments.main_rwa = transcript->template receive_from_prover(commitment_labels.main_rwa); - commitments.main_rwb = transcript->template receive_from_prover(commitment_labels.main_rwb); - commitments.main_rwc = transcript->template receive_from_prover(commitment_labels.main_rwc); - commitments.main_rwd = transcript->template receive_from_prover(commitment_labels.main_rwd); - commitments.main_sel_alu = transcript->template receive_from_prover(commitment_labels.main_sel_alu); - commitments.main_sel_bin = transcript->template receive_from_prover(commitment_labels.main_sel_bin); - commitments.main_sel_gas_accounting_active = - transcript->template receive_from_prover(commitment_labels.main_sel_gas_accounting_active); - commitments.main_sel_last = transcript->template receive_from_prover(commitment_labels.main_sel_last); - commitments.main_sel_mem_op_a = - transcript->template receive_from_prover(commitment_labels.main_sel_mem_op_a); - commitments.main_sel_mem_op_activate_gas = - transcript->template receive_from_prover(commitment_labels.main_sel_mem_op_activate_gas); - commitments.main_sel_mem_op_b = - transcript->template receive_from_prover(commitment_labels.main_sel_mem_op_b); - commitments.main_sel_mem_op_c = - transcript->template receive_from_prover(commitment_labels.main_sel_mem_op_c); - commitments.main_sel_mem_op_d = - transcript->template receive_from_prover(commitment_labels.main_sel_mem_op_d); - commitments.main_sel_mov_ia_to_ic = - transcript->template receive_from_prover(commitment_labels.main_sel_mov_ia_to_ic); - commitments.main_sel_mov_ib_to_ic = - transcript->template receive_from_prover(commitment_labels.main_sel_mov_ib_to_ic); - commitments.main_sel_op_add = - transcript->template receive_from_prover(commitment_labels.main_sel_op_add); - commitments.main_sel_op_address = - transcript->template receive_from_prover(commitment_labels.main_sel_op_address); - commitments.main_sel_op_and = - transcript->template receive_from_prover(commitment_labels.main_sel_op_and); - commitments.main_sel_op_block_number = - transcript->template receive_from_prover(commitment_labels.main_sel_op_block_number); - commitments.main_sel_op_cast = - transcript->template receive_from_prover(commitment_labels.main_sel_op_cast); - commitments.main_sel_op_chain_id = - transcript->template receive_from_prover(commitment_labels.main_sel_op_chain_id); - commitments.main_sel_op_cmov = - transcript->template receive_from_prover(commitment_labels.main_sel_op_cmov); - commitments.main_sel_op_coinbase = - transcript->template receive_from_prover(commitment_labels.main_sel_op_coinbase); - commitments.main_sel_op_dagasleft = - transcript->template receive_from_prover(commitment_labels.main_sel_op_dagasleft); - commitments.main_sel_op_div = - transcript->template receive_from_prover(commitment_labels.main_sel_op_div); - commitments.main_sel_op_emit_l2_to_l1_msg = - transcript->template receive_from_prover(commitment_labels.main_sel_op_emit_l2_to_l1_msg); - commitments.main_sel_op_emit_note_hash = - transcript->template receive_from_prover(commitment_labels.main_sel_op_emit_note_hash); - commitments.main_sel_op_emit_nullifier = - transcript->template receive_from_prover(commitment_labels.main_sel_op_emit_nullifier); - commitments.main_sel_op_emit_unencrypted_log = - transcript->template receive_from_prover(commitment_labels.main_sel_op_emit_unencrypted_log); - commitments.main_sel_op_eq = transcript->template receive_from_prover(commitment_labels.main_sel_op_eq); - commitments.main_sel_op_external_call = - transcript->template receive_from_prover(commitment_labels.main_sel_op_external_call); - commitments.main_sel_op_fdiv = - transcript->template receive_from_prover(commitment_labels.main_sel_op_fdiv); - commitments.main_sel_op_fee_per_da_gas = - transcript->template receive_from_prover(commitment_labels.main_sel_op_fee_per_da_gas); - commitments.main_sel_op_fee_per_l2_gas = - transcript->template receive_from_prover(commitment_labels.main_sel_op_fee_per_l2_gas); - commitments.main_sel_op_function_selector = - transcript->template receive_from_prover(commitment_labels.main_sel_op_function_selector); - commitments.main_sel_op_get_contract_instance = - transcript->template receive_from_prover(commitment_labels.main_sel_op_get_contract_instance); - commitments.main_sel_op_halt = - transcript->template receive_from_prover(commitment_labels.main_sel_op_halt); - commitments.main_sel_op_internal_call = - transcript->template receive_from_prover(commitment_labels.main_sel_op_internal_call); - commitments.main_sel_op_internal_return = - transcript->template receive_from_prover(commitment_labels.main_sel_op_internal_return); - commitments.main_sel_op_jump = - transcript->template receive_from_prover(commitment_labels.main_sel_op_jump); - commitments.main_sel_op_jumpi = - transcript->template receive_from_prover(commitment_labels.main_sel_op_jumpi); - commitments.main_sel_op_keccak = - transcript->template receive_from_prover(commitment_labels.main_sel_op_keccak); - commitments.main_sel_op_l1_to_l2_msg_exists = - transcript->template receive_from_prover(commitment_labels.main_sel_op_l1_to_l2_msg_exists); - commitments.main_sel_op_l2gasleft = - transcript->template receive_from_prover(commitment_labels.main_sel_op_l2gasleft); - commitments.main_sel_op_lt = transcript->template receive_from_prover(commitment_labels.main_sel_op_lt); - commitments.main_sel_op_lte = - transcript->template receive_from_prover(commitment_labels.main_sel_op_lte); - commitments.main_sel_op_mov = - transcript->template receive_from_prover(commitment_labels.main_sel_op_mov); - commitments.main_sel_op_mul = - transcript->template receive_from_prover(commitment_labels.main_sel_op_mul); - commitments.main_sel_op_not = - transcript->template receive_from_prover(commitment_labels.main_sel_op_not); - commitments.main_sel_op_note_hash_exists = - transcript->template receive_from_prover(commitment_labels.main_sel_op_note_hash_exists); - commitments.main_sel_op_nullifier_exists = - transcript->template receive_from_prover(commitment_labels.main_sel_op_nullifier_exists); - commitments.main_sel_op_or = transcript->template receive_from_prover(commitment_labels.main_sel_op_or); - commitments.main_sel_op_pedersen = - transcript->template receive_from_prover(commitment_labels.main_sel_op_pedersen); - commitments.main_sel_op_poseidon2 = - transcript->template receive_from_prover(commitment_labels.main_sel_op_poseidon2); - commitments.main_sel_op_radix_le = - transcript->template receive_from_prover(commitment_labels.main_sel_op_radix_le); - commitments.main_sel_op_sender = - transcript->template receive_from_prover(commitment_labels.main_sel_op_sender); - commitments.main_sel_op_sha256 = - transcript->template receive_from_prover(commitment_labels.main_sel_op_sha256); - commitments.main_sel_op_shl = - transcript->template receive_from_prover(commitment_labels.main_sel_op_shl); - commitments.main_sel_op_shr = - transcript->template receive_from_prover(commitment_labels.main_sel_op_shr); - commitments.main_sel_op_sload = - transcript->template receive_from_prover(commitment_labels.main_sel_op_sload); - commitments.main_sel_op_sstore = - transcript->template receive_from_prover(commitment_labels.main_sel_op_sstore); - commitments.main_sel_op_storage_address = - transcript->template receive_from_prover(commitment_labels.main_sel_op_storage_address); - commitments.main_sel_op_sub = - transcript->template receive_from_prover(commitment_labels.main_sel_op_sub); - commitments.main_sel_op_timestamp = - transcript->template receive_from_prover(commitment_labels.main_sel_op_timestamp); - commitments.main_sel_op_transaction_fee = - transcript->template receive_from_prover(commitment_labels.main_sel_op_transaction_fee); - commitments.main_sel_op_version = - transcript->template receive_from_prover(commitment_labels.main_sel_op_version); - commitments.main_sel_op_xor = - transcript->template receive_from_prover(commitment_labels.main_sel_op_xor); - commitments.main_sel_q_kernel_lookup = - transcript->template receive_from_prover(commitment_labels.main_sel_q_kernel_lookup); - commitments.main_sel_q_kernel_output_lookup = - transcript->template receive_from_prover(commitment_labels.main_sel_q_kernel_output_lookup); - commitments.main_sel_resolve_ind_addr_a = - transcript->template receive_from_prover(commitment_labels.main_sel_resolve_ind_addr_a); - commitments.main_sel_resolve_ind_addr_b = - transcript->template receive_from_prover(commitment_labels.main_sel_resolve_ind_addr_b); - commitments.main_sel_resolve_ind_addr_c = - transcript->template receive_from_prover(commitment_labels.main_sel_resolve_ind_addr_c); - commitments.main_sel_resolve_ind_addr_d = - transcript->template receive_from_prover(commitment_labels.main_sel_resolve_ind_addr_d); - commitments.main_sel_rng_16 = - transcript->template receive_from_prover(commitment_labels.main_sel_rng_16); - commitments.main_sel_rng_8 = transcript->template receive_from_prover(commitment_labels.main_sel_rng_8); - commitments.main_space_id = transcript->template receive_from_prover(commitment_labels.main_space_id); - commitments.main_tag_err = transcript->template receive_from_prover(commitment_labels.main_tag_err); - commitments.main_w_in_tag = transcript->template receive_from_prover(commitment_labels.main_w_in_tag); - commitments.mem_addr = transcript->template receive_from_prover(commitment_labels.mem_addr); - commitments.mem_clk = transcript->template receive_from_prover(commitment_labels.mem_clk); - commitments.mem_diff_hi = transcript->template receive_from_prover(commitment_labels.mem_diff_hi); - commitments.mem_diff_lo = transcript->template receive_from_prover(commitment_labels.mem_diff_lo); - commitments.mem_diff_mid = transcript->template receive_from_prover(commitment_labels.mem_diff_mid); - commitments.mem_glob_addr = transcript->template receive_from_prover(commitment_labels.mem_glob_addr); - commitments.mem_last = transcript->template receive_from_prover(commitment_labels.mem_last); - commitments.mem_lastAccess = transcript->template receive_from_prover(commitment_labels.mem_lastAccess); - commitments.mem_one_min_inv = - transcript->template receive_from_prover(commitment_labels.mem_one_min_inv); - commitments.mem_r_in_tag = transcript->template receive_from_prover(commitment_labels.mem_r_in_tag); - commitments.mem_rw = transcript->template receive_from_prover(commitment_labels.mem_rw); - commitments.mem_sel_mem = transcript->template receive_from_prover(commitment_labels.mem_sel_mem); - commitments.mem_sel_mov_ia_to_ic = - transcript->template receive_from_prover(commitment_labels.mem_sel_mov_ia_to_ic); - commitments.mem_sel_mov_ib_to_ic = - transcript->template receive_from_prover(commitment_labels.mem_sel_mov_ib_to_ic); - commitments.mem_sel_op_a = transcript->template receive_from_prover(commitment_labels.mem_sel_op_a); - commitments.mem_sel_op_b = transcript->template receive_from_prover(commitment_labels.mem_sel_op_b); - commitments.mem_sel_op_c = transcript->template receive_from_prover(commitment_labels.mem_sel_op_c); - commitments.mem_sel_op_cmov = - transcript->template receive_from_prover(commitment_labels.mem_sel_op_cmov); - commitments.mem_sel_op_d = transcript->template receive_from_prover(commitment_labels.mem_sel_op_d); - commitments.mem_sel_resolve_ind_addr_a = - transcript->template receive_from_prover(commitment_labels.mem_sel_resolve_ind_addr_a); - commitments.mem_sel_resolve_ind_addr_b = - transcript->template receive_from_prover(commitment_labels.mem_sel_resolve_ind_addr_b); - commitments.mem_sel_resolve_ind_addr_c = - transcript->template receive_from_prover(commitment_labels.mem_sel_resolve_ind_addr_c); - commitments.mem_sel_resolve_ind_addr_d = - transcript->template receive_from_prover(commitment_labels.mem_sel_resolve_ind_addr_d); - commitments.mem_sel_rng_chk = - transcript->template receive_from_prover(commitment_labels.mem_sel_rng_chk); - commitments.mem_skip_check_tag = - transcript->template receive_from_prover(commitment_labels.mem_skip_check_tag); - commitments.mem_space_id = transcript->template receive_from_prover(commitment_labels.mem_space_id); - commitments.mem_tag = transcript->template receive_from_prover(commitment_labels.mem_tag); - commitments.mem_tag_err = transcript->template receive_from_prover(commitment_labels.mem_tag_err); - commitments.mem_tsp = transcript->template receive_from_prover(commitment_labels.mem_tsp); - commitments.mem_val = transcript->template receive_from_prover(commitment_labels.mem_val); - commitments.mem_w_in_tag = transcript->template receive_from_prover(commitment_labels.mem_w_in_tag); - commitments.pedersen_clk = transcript->template receive_from_prover(commitment_labels.pedersen_clk); - commitments.pedersen_input = transcript->template receive_from_prover(commitment_labels.pedersen_input); - commitments.pedersen_output = - transcript->template receive_from_prover(commitment_labels.pedersen_output); - commitments.pedersen_sel_pedersen = - transcript->template receive_from_prover(commitment_labels.pedersen_sel_pedersen); - commitments.poseidon2_a_0 = transcript->template receive_from_prover(commitment_labels.poseidon2_a_0); - commitments.poseidon2_a_1 = transcript->template receive_from_prover(commitment_labels.poseidon2_a_1); - commitments.poseidon2_a_2 = transcript->template receive_from_prover(commitment_labels.poseidon2_a_2); - commitments.poseidon2_a_3 = transcript->template receive_from_prover(commitment_labels.poseidon2_a_3); - commitments.poseidon2_b_0 = transcript->template receive_from_prover(commitment_labels.poseidon2_b_0); - commitments.poseidon2_b_1 = transcript->template receive_from_prover(commitment_labels.poseidon2_b_1); - commitments.poseidon2_b_2 = transcript->template receive_from_prover(commitment_labels.poseidon2_b_2); - commitments.poseidon2_b_3 = transcript->template receive_from_prover(commitment_labels.poseidon2_b_3); - commitments.poseidon2_clk = transcript->template receive_from_prover(commitment_labels.poseidon2_clk); - commitments.poseidon2_input = - transcript->template receive_from_prover(commitment_labels.poseidon2_input); - commitments.poseidon2_output = - transcript->template receive_from_prover(commitment_labels.poseidon2_output); - commitments.poseidon2_sel_poseidon_perm = - transcript->template receive_from_prover(commitment_labels.poseidon2_sel_poseidon_perm); - commitments.powers_power_of_2 = - transcript->template receive_from_prover(commitment_labels.powers_power_of_2); - commitments.sha256_clk = transcript->template receive_from_prover(commitment_labels.sha256_clk); - commitments.sha256_input = transcript->template receive_from_prover(commitment_labels.sha256_input); - commitments.sha256_output = transcript->template receive_from_prover(commitment_labels.sha256_output); - commitments.sha256_sel_sha256_compression = - transcript->template receive_from_prover(commitment_labels.sha256_sel_sha256_compression); - commitments.sha256_state = transcript->template receive_from_prover(commitment_labels.sha256_state); - commitments.lookup_byte_lengths_counts = - transcript->template receive_from_prover(commitment_labels.lookup_byte_lengths_counts); - commitments.lookup_byte_operations_counts = - transcript->template receive_from_prover(commitment_labels.lookup_byte_operations_counts); - commitments.lookup_opcode_gas_counts = - transcript->template receive_from_prover(commitment_labels.lookup_opcode_gas_counts); - commitments.range_check_l2_gas_hi_counts = - transcript->template receive_from_prover(commitment_labels.range_check_l2_gas_hi_counts); - commitments.range_check_l2_gas_lo_counts = - transcript->template receive_from_prover(commitment_labels.range_check_l2_gas_lo_counts); - commitments.range_check_da_gas_hi_counts = - transcript->template receive_from_prover(commitment_labels.range_check_da_gas_hi_counts); - commitments.range_check_da_gas_lo_counts = - transcript->template receive_from_prover(commitment_labels.range_check_da_gas_lo_counts); - commitments.kernel_output_lookup_counts = - transcript->template receive_from_prover(commitment_labels.kernel_output_lookup_counts); - commitments.lookup_into_kernel_counts = - transcript->template receive_from_prover(commitment_labels.lookup_into_kernel_counts); - commitments.incl_main_tag_err_counts = - transcript->template receive_from_prover(commitment_labels.incl_main_tag_err_counts); - commitments.incl_mem_tag_err_counts = - transcript->template receive_from_prover(commitment_labels.incl_mem_tag_err_counts); - commitments.lookup_mem_rng_chk_lo_counts = - transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_lo_counts); - commitments.lookup_mem_rng_chk_mid_counts = - transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_mid_counts); - commitments.lookup_mem_rng_chk_hi_counts = - transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_hi_counts); - commitments.lookup_pow_2_0_counts = - transcript->template receive_from_prover(commitment_labels.lookup_pow_2_0_counts); - commitments.lookup_pow_2_1_counts = - transcript->template receive_from_prover(commitment_labels.lookup_pow_2_1_counts); - commitments.lookup_u8_0_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u8_0_counts); - commitments.lookup_u8_1_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u8_1_counts); - commitments.lookup_u16_0_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_0_counts); - commitments.lookup_u16_1_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_1_counts); - commitments.lookup_u16_2_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_2_counts); - commitments.lookup_u16_3_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_3_counts); - commitments.lookup_u16_4_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_4_counts); - commitments.lookup_u16_5_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_5_counts); - commitments.lookup_u16_6_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_6_counts); - commitments.lookup_u16_7_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_7_counts); - commitments.lookup_u16_8_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_8_counts); - commitments.lookup_u16_9_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_9_counts); - commitments.lookup_u16_10_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_10_counts); - commitments.lookup_u16_11_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_11_counts); - commitments.lookup_u16_12_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_12_counts); - commitments.lookup_u16_13_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_13_counts); - commitments.lookup_u16_14_counts = - transcript->template receive_from_prover(commitment_labels.lookup_u16_14_counts); - commitments.lookup_div_u16_0_counts = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_0_counts); - commitments.lookup_div_u16_1_counts = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_1_counts); - commitments.lookup_div_u16_2_counts = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_2_counts); - commitments.lookup_div_u16_3_counts = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_3_counts); - commitments.lookup_div_u16_4_counts = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_4_counts); - commitments.lookup_div_u16_5_counts = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_5_counts); - commitments.lookup_div_u16_6_counts = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_6_counts); - commitments.lookup_div_u16_7_counts = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_7_counts); ->>>>>>> e28ed4281 (feat(avm): poseidon2 constraints) auto [beta, gamm] = transcript->template get_challenges("beta", "gamma"); relation_parameters.beta = beta; relation_parameters.gamma = gamm; // Get commitments to inverses + commitments.perm_pos_mem_a = transcript->template receive_from_prover(commitment_labels.perm_pos_mem_a); + commitments.perm_pos_mem_b = transcript->template receive_from_prover(commitment_labels.perm_pos_mem_b); + commitments.perm_pos_mem_c = transcript->template receive_from_prover(commitment_labels.perm_pos_mem_c); + commitments.perm_pos_mem_d = transcript->template receive_from_prover(commitment_labels.perm_pos_mem_d); commitments.perm_slice_mem = transcript->template receive_from_prover(commitment_labels.perm_slice_mem); commitments.perm_main_alu = transcript->template receive_from_prover(commitment_labels.perm_main_alu); commitments.perm_main_bin = transcript->template receive_from_prover(commitment_labels.perm_main_bin); From 076f4a246559400dbf457d4ac225219bdad4f2d7 Mon Sep 17 00:00:00 2001 From: IlyasRidhuan Date: Fri, 26 Jul 2024 09:21:17 +0000 Subject: [PATCH 4/4] single row mem ops --- .../cpp/pil/avm/gadgets/poseidon2.pil | 121 +- .../cpp/pil/avm/gadgets/poseidon2_params.pil | 2 +- barretenberg/cpp/pil/avm/main.pil | 1 + barretenberg/cpp/pil/avm/mem.pil | 33 +- .../relations/generated/avm/declare_views.hpp | 794 ----- .../generated/avm/perm_pos_mem_a.hpp | 72 - .../generated/avm/perm_pos_mem_b.hpp | 72 - .../generated/avm/perm_pos_mem_c.hpp | 72 - .../generated/avm/perm_pos_mem_d.hpp | 72 - .../vm/avm/generated/circuit_builder.cpp | 289 +- .../vm/avm/generated/circuit_builder.hpp | 4 +- .../barretenberg/vm/avm/generated/flavor.cpp | 1854 ++++++++--- .../barretenberg/vm/avm/generated/flavor.hpp | 28 +- .../vm/avm/generated/full_row.cpp | 82 +- .../vm/avm/generated/full_row.hpp | 43 +- .../vm/avm/generated/relations/mem.hpp | 118 +- .../relations/perm_pos_mem_read_a.hpp | 65 + .../relations/perm_pos_mem_read_b.hpp | 65 + .../relations/perm_pos_mem_read_c.hpp | 65 + .../relations/perm_pos_mem_read_d.hpp | 65 + .../relations/perm_pos_mem_write_a.hpp | 66 + .../relations/perm_pos_mem_write_b.hpp | 66 + .../relations/perm_pos_mem_write_c.hpp | 66 + .../relations/perm_pos_mem_write_d.hpp | 66 + .../vm/avm/generated/relations/poseidon2.hpp | 1161 ++++--- .../vm/avm/trace/gadgets/poseidon2.hpp | 76 +- .../barretenberg/vm/avm/trace/mem_trace.cpp | 2 +- .../barretenberg/vm/avm/trace/mem_trace.hpp | 2 +- .../src/barretenberg/vm/avm/trace/trace.cpp | 116 +- .../src/barretenberg/vm/avm/trace/trace.hpp | 4 +- .../vm/generated/avm_circuit_builder.hpp | 788 ----- .../barretenberg/vm/generated/avm_flavor.hpp | 2727 ----------------- .../vm/generated/avm_verifier.cpp | 248 -- .../srs_db/grumpkin/monomial/transcript00.dat | Bin 92 -> 0 bytes 34 files changed, 3119 insertions(+), 6186 deletions(-) delete mode 100644 barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp delete mode 100644 barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_a.hpp delete mode 100644 barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_b.hpp delete mode 100644 barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_c.hpp delete mode 100644 barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_d.hpp create mode 100644 barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_a.hpp create mode 100644 barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_b.hpp create mode 100644 barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_c.hpp create mode 100644 barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_d.hpp create mode 100644 barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_a.hpp create mode 100644 barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_b.hpp create mode 100644 barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_c.hpp create mode 100644 barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_d.hpp delete mode 100644 barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp delete mode 100644 barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp delete mode 100644 barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp delete mode 100644 barretenberg/srs_db/grumpkin/monomial/transcript00.dat diff --git a/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil b/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil index 96052ff38211..12e997465ad2 100644 --- a/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil +++ b/barretenberg/cpp/pil/avm/gadgets/poseidon2.pil @@ -1,3 +1,4 @@ +// Implementation based on https://eprint.iacr.org/2023/323.pdf include "poseidon2_params.pil"; namespace poseidon2(256); @@ -8,45 +9,32 @@ namespace poseidon2(256); pol commit sel_poseidon_perm; // Selector is boolean sel_poseidon_perm * (1 - sel_poseidon_perm) = 0; - // If poseidon_sel is set, it cannot be set on the next row - sel_poseidon_perm * sel_poseidon_perm' = 0; - - // Each poseidon2 invocation involves two rows, - // (1) A read line where 4 input values are loaded from memory - // (2) A write line where 4 output values are written to memory - pol commit read_line; - pol commit write_line; - // Line selectors are boolean values - read_line * (1 - read_line) = 0; - write_line * (1 - write_line) = 0; - // If poseidon_perm is selected, the current line is a read line and the next one is a write line - sel_poseidon_perm - read_line = 0; - sel_poseidon_perm - write_line' = 0; - - // Trivially on for all lines - pol commit mem_op; - mem_op = read_line + write_line; - // Read + Write must be mutual exclusive (todo: This should be enforceable by instruction decomposition) - mem_op * (1 - mem_op) = 0; - - // Constrain read and write tag to be FF - pol commit in_tag; - mem_op * (in_tag - 6) = 0; // The initial mem address for inputs or output pol commit input_addr; pol commit output_addr; // Address that is loaded by the gadget memory operations - pol commit mem_addr_a; - pol commit mem_addr_b; - pol commit mem_addr_c; - pol commit mem_addr_d; + pol commit mem_addr_read_a; + pol commit mem_addr_read_b; + pol commit mem_addr_read_c; + pol commit mem_addr_read_d; + // Address that is written by the gadget memory operations + pol commit mem_addr_write_a; + pol commit mem_addr_write_b; + pol commit mem_addr_write_c; + pol commit mem_addr_write_d; + // Accessed read / write addresses are contiguous blocks - mem_op * (mem_addr_a - (read_line * input_addr + write_line * output_addr)) = 0; - mem_op * (mem_addr_b - (read_line * input_addr + write_line * output_addr + 1)) = 0; - mem_op * (mem_addr_c - (read_line * input_addr + write_line * output_addr + 2)) = 0; - mem_op * (mem_addr_d - (read_line * input_addr + write_line * output_addr + 3)) = 0; + sel_poseidon_perm * (mem_addr_read_a - input_addr) = 0; + sel_poseidon_perm * (mem_addr_read_b - (input_addr + 1)) = 0; + sel_poseidon_perm * (mem_addr_read_c - (input_addr + 2)) = 0; + sel_poseidon_perm * (mem_addr_read_d - (input_addr + 3)) = 0; + + sel_poseidon_perm * (mem_addr_write_a - output_addr) = 0; + sel_poseidon_perm * (mem_addr_write_b - (output_addr + 1)) = 0; + sel_poseidon_perm * (mem_addr_write_c - (output_addr + 2)) = 0; + sel_poseidon_perm * (mem_addr_write_d - (output_addr + 3)) = 0; // The input values are represented by a_0, a_1, a_2, a_3 pol commit a_0; @@ -54,34 +42,55 @@ namespace poseidon2(256); pol commit a_2; pol commit a_3; + // Output values represented by b_0, b_1, b_2, b_3 + pol commit b_0; + pol commit b_1; + pol commit b_2; + pol commit b_3; - #[PERM_POS_MEM_A] - mem_op {clk, main.space_id, mem_addr_a, a_0, write_line, in_tag, in_tag} + // ==== READ MEM OPS ===== + #[PERM_POS_MEM_READ_A] + sel_poseidon_perm {clk, main.space_id, mem_addr_read_a, a_0, main.zeroes} is - mem.sel_op_gadget_a {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw, mem.r_in_tag, mem.w_in_tag}; + mem.sel_op_poseidon_read_a {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw}; - #[PERM_POS_MEM_B] - mem_op {clk, main.space_id, mem_addr_b, a_1, write_line, in_tag, in_tag} + #[PERM_POS_MEM_READ_B] + sel_poseidon_perm {clk, main.space_id, mem_addr_read_b, a_1, main.zeroes} is - mem.sel_op_gadget_b {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw, mem.r_in_tag, mem.w_in_tag}; + mem.sel_op_poseidon_read_b {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw}; - #[PERM_POS_MEM_C] - mem_op {clk, main.space_id, mem_addr_c, a_2, write_line, in_tag, in_tag} + #[PERM_POS_MEM_READ_C] + sel_poseidon_perm {clk, main.space_id, mem_addr_read_c, a_2, main.zeroes} is - mem.sel_op_gadget_c {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw, mem.r_in_tag, mem.w_in_tag}; + mem.sel_op_poseidon_read_c {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw}; - #[PERM_POS_MEM_D] - mem_op {clk, main.space_id, mem_addr_d, a_3, write_line, in_tag, in_tag} + #[PERM_POS_MEM_READ_D] + sel_poseidon_perm {clk, main.space_id, mem_addr_read_d, a_3, main.zeroes} is - mem.sel_op_gadget_d {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw, mem.r_in_tag, mem.w_in_tag}; + mem.sel_op_poseidon_read_d {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw}; - // Output values represented by b_0, b_1, b_2, b_3 - pol commit b_0; - pol commit b_1; - pol commit b_2; - pol commit b_3; + //// ==== WRITE MEM OPS ===== + #[PERM_POS_MEM_WRITE_A] + sel_poseidon_perm {clk, main.space_id, mem_addr_write_a, b_0, sel_poseidon_perm} + is + mem.sel_op_poseidon_write_a {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw}; + + #[PERM_POS_MEM_WRITE_B] + sel_poseidon_perm {clk, main.space_id, mem_addr_write_b, b_1, sel_poseidon_perm} + is + mem.sel_op_poseidon_write_b {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw}; + + #[PERM_POS_MEM_WRITE_C] + sel_poseidon_perm {clk, main.space_id, mem_addr_write_c, b_2, sel_poseidon_perm} + is + mem.sel_op_poseidon_write_c {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw}; + + #[PERM_POS_MEM_WRITE_D] + sel_poseidon_perm {clk, main.space_id, mem_addr_write_d, b_3, sel_poseidon_perm} + is + mem.sel_op_poseidon_write_d {mem.clk, mem.space_id, mem.addr, mem.val, mem.rw}; - // Intermediate helper values denoted by T_{id}; + // Intermediate helper values denoted by T_{id} - based on Appendix B of https://eprint.iacr.org/2023/323.pdf; // T_0 = a_0 + a_1; // T_1 = a_2 + a_3; // T_2 = 2 * a_1 + T_0; @@ -112,7 +121,7 @@ namespace poseidon2(256); ///////////////////////////////////////////////////// - // START FULL ROUND (4 ROUNDS) + // START FULL ROUNDS (4 ROUNDS) ///////////////////////////////////////////////////// // Round 1 (Full Round) // ARK (Add Round Constant) @@ -1687,7 +1696,7 @@ namespace poseidon2(256); sel_poseidon_perm * (B_59_3 - (poseidon2_params.MU_3 * A_59_3 + SUM_59)) = 0; ///////////////////////////////////////////////////// - // FINAL FULL ROUND (4 ROUNDS) + // FINAL FULL ROUNDS (4 ROUNDS) ///////////////////////////////////////////////////// // Round 61 (Full Round) // ARK (Add Round Constant) @@ -1805,7 +1814,7 @@ namespace poseidon2(256); // PERMUTATION END ///////////////////////////////////////////////////// // Check output against claimed output - sel_poseidon_perm * (a_0' - T_63_6) = 0; - sel_poseidon_perm * (a_1' - T_63_5) = 0; - sel_poseidon_perm * (a_2' - T_63_7) = 0; - sel_poseidon_perm * (a_3' - T_63_4) = 0; + sel_poseidon_perm * (b_0 - T_63_6) = 0; + sel_poseidon_perm * (b_1 - T_63_5) = 0; + sel_poseidon_perm * (b_2 - T_63_7) = 0; + sel_poseidon_perm * (b_3 - T_63_4) = 0; diff --git a/barretenberg/cpp/pil/avm/gadgets/poseidon2_params.pil b/barretenberg/cpp/pil/avm/gadgets/poseidon2_params.pil index 195363af7944..2bd73a08e6b1 100644 --- a/barretenberg/cpp/pil/avm/gadgets/poseidon2_params.pil +++ b/barretenberg/cpp/pil/avm/gadgets/poseidon2_params.pil @@ -1,4 +1,4 @@ - +// Values taken from barretenberg/crypto/poseidon2/poseidon2_params.hpp // Parameters for Poseidon for bn254. // 64 total rounds (8 full rounds and 56 partial rounds) diff --git a/barretenberg/cpp/pil/avm/main.pil b/barretenberg/cpp/pil/avm/main.pil index c209e491aae3..0f6b67549b7c 100644 --- a/barretenberg/cpp/pil/avm/main.pil +++ b/barretenberg/cpp/pil/avm/main.pil @@ -18,6 +18,7 @@ namespace main(256); pol constant clk(i) { i }; pol constant sel_first = [1] + [0]*; // Used mostly to toggle off the first row consisting // only in first element of shifted polynomials. + pol constant zeroes = [0]*; // Helper for if we need to use a constant zero column //===== PUBLIC COLUMNS========================================================= pol public calldata; diff --git a/barretenberg/cpp/pil/avm/mem.pil b/barretenberg/cpp/pil/avm/mem.pil index 262748f92bd8..8fb1a53b8a80 100644 --- a/barretenberg/cpp/pil/avm/mem.pil +++ b/barretenberg/cpp/pil/avm/mem.pil @@ -28,16 +28,22 @@ namespace mem(256); // We add a set of selectors for the gadgets, TODO: boolean check // TODO: Can we have a single set of sels for each gadget if we instead have a defined, homogenous MEMORY BUS that gadgets connect to - pol commit sel_op_gadget_a; - pol commit sel_op_gadget_b; - pol commit sel_op_gadget_c; - pol commit sel_op_gadget_d; + pol commit sel_op_poseidon_read_a; + pol commit sel_op_poseidon_read_b; + pol commit sel_op_poseidon_read_c; + pol commit sel_op_poseidon_read_d; + + pol commit sel_op_poseidon_write_a; + pol commit sel_op_poseidon_write_b; + pol commit sel_op_poseidon_write_c; + pol commit sel_op_poseidon_write_d; // For simplicity we group these as part of the SEL_DIRECT_MEM_OP_X - pol SEL_DIRECT_MEM_OP_A = sel_op_a + sel_op_gadget_a; - pol SEL_DIRECT_MEM_OP_B = sel_op_b + sel_op_gadget_b; - pol SEL_DIRECT_MEM_OP_C = sel_op_c + sel_op_gadget_c; - pol SEL_DIRECT_MEM_OP_D = sel_op_d + sel_op_gadget_d; + // These values will be mutually exclusive and enforced by the bytecode/instruction decomposition step + pol SEL_DIRECT_MEM_OP_A = sel_op_a + sel_op_poseidon_read_a + sel_op_poseidon_write_a; + pol SEL_DIRECT_MEM_OP_B = sel_op_b + sel_op_poseidon_read_b + sel_op_poseidon_write_b; + pol SEL_DIRECT_MEM_OP_C = sel_op_c + sel_op_poseidon_read_c + sel_op_poseidon_write_c; + pol SEL_DIRECT_MEM_OP_D = sel_op_d + sel_op_poseidon_read_d + sel_op_poseidon_write_d; // Indicator of the indirect register pertaining to the memory operation (foreign key to main.sel_resolve_ind_addr_XXX) pol commit sel_resolve_ind_addr_a; @@ -237,6 +243,17 @@ namespace mem(256); sel_op_slice * (w_in_tag - 6) = 0; // Only write elements of type FF sel_op_slice * (r_in_tag - 6) = 0; // Only read elements of type FF + //====== POSEIDON2 specific constraints ================================== + sel_op_poseidon_read_a * (w_in_tag - 6) = 0; // Only read elements of type FF + sel_op_poseidon_read_b * (w_in_tag - 6) = 0; // Only read elements of type FF + sel_op_poseidon_read_c * (w_in_tag - 6) = 0; // Only read elements of type FF + sel_op_poseidon_read_d * (w_in_tag - 6) = 0; // Only read elements of type FF + + sel_op_poseidon_write_a * (r_in_tag - 6) = 0; // Only write elements of type FF + sel_op_poseidon_write_b * (r_in_tag - 6) = 0; // Only write elements of type FF + sel_op_poseidon_write_c * (r_in_tag - 6) = 0; // Only write elements of type FF + sel_op_poseidon_write_d * (r_in_tag - 6) = 0; // Only write elements of type FF + //====== MOV/CMOV Opcode Tag Constraint ===================================== // The following constraint ensures that the r_in_tag is set to tag for // the load operation pertaining to Ia resp. Ib. diff --git a/barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp b/barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp deleted file mode 100644 index 964a48c6f6c5..000000000000 --- a/barretenberg/cpp/src/barretenberg/relations/generated/avm/declare_views.hpp +++ /dev/null @@ -1,794 +0,0 @@ -#pragma once - -#define Avm_DECLARE_VIEWS(index) \ - using Accumulator = typename std::tuple_element::type; \ - using View = typename Accumulator::View; \ - [[maybe_unused]] auto main_clk = View(new_term.main_clk); \ - [[maybe_unused]] auto main_sel_first = View(new_term.main_sel_first); \ - [[maybe_unused]] auto kernel_kernel_inputs = View(new_term.kernel_kernel_inputs); \ - [[maybe_unused]] auto kernel_kernel_value_out = View(new_term.kernel_kernel_value_out); \ - [[maybe_unused]] auto kernel_kernel_side_effect_out = View(new_term.kernel_kernel_side_effect_out); \ - [[maybe_unused]] auto kernel_kernel_metadata_out = View(new_term.kernel_kernel_metadata_out); \ - [[maybe_unused]] auto main_calldata = View(new_term.main_calldata); \ - [[maybe_unused]] auto main_returndata = View(new_term.main_returndata); \ - [[maybe_unused]] auto alu_a_hi = View(new_term.alu_a_hi); \ - [[maybe_unused]] auto alu_a_lo = View(new_term.alu_a_lo); \ - [[maybe_unused]] auto alu_b_hi = View(new_term.alu_b_hi); \ - [[maybe_unused]] auto alu_b_lo = View(new_term.alu_b_lo); \ - [[maybe_unused]] auto alu_borrow = View(new_term.alu_borrow); \ - [[maybe_unused]] auto alu_cf = View(new_term.alu_cf); \ - [[maybe_unused]] auto alu_clk = View(new_term.alu_clk); \ - [[maybe_unused]] auto alu_cmp_rng_ctr = View(new_term.alu_cmp_rng_ctr); \ - [[maybe_unused]] auto alu_div_u16_r0 = View(new_term.alu_div_u16_r0); \ - [[maybe_unused]] auto alu_div_u16_r1 = View(new_term.alu_div_u16_r1); \ - [[maybe_unused]] auto alu_div_u16_r2 = View(new_term.alu_div_u16_r2); \ - [[maybe_unused]] auto alu_div_u16_r3 = View(new_term.alu_div_u16_r3); \ - [[maybe_unused]] auto alu_div_u16_r4 = View(new_term.alu_div_u16_r4); \ - [[maybe_unused]] auto alu_div_u16_r5 = View(new_term.alu_div_u16_r5); \ - [[maybe_unused]] auto alu_div_u16_r6 = View(new_term.alu_div_u16_r6); \ - [[maybe_unused]] auto alu_div_u16_r7 = View(new_term.alu_div_u16_r7); \ - [[maybe_unused]] auto alu_divisor_hi = View(new_term.alu_divisor_hi); \ - [[maybe_unused]] auto alu_divisor_lo = View(new_term.alu_divisor_lo); \ - [[maybe_unused]] auto alu_ff_tag = View(new_term.alu_ff_tag); \ - [[maybe_unused]] auto alu_ia = View(new_term.alu_ia); \ - [[maybe_unused]] auto alu_ib = View(new_term.alu_ib); \ - [[maybe_unused]] auto alu_ic = View(new_term.alu_ic); \ - [[maybe_unused]] auto alu_in_tag = View(new_term.alu_in_tag); \ - [[maybe_unused]] auto alu_op_add = View(new_term.alu_op_add); \ - [[maybe_unused]] auto alu_op_cast = View(new_term.alu_op_cast); \ - [[maybe_unused]] auto alu_op_cast_prev = View(new_term.alu_op_cast_prev); \ - [[maybe_unused]] auto alu_op_div = View(new_term.alu_op_div); \ - [[maybe_unused]] auto alu_op_div_a_lt_b = View(new_term.alu_op_div_a_lt_b); \ - [[maybe_unused]] auto alu_op_div_std = View(new_term.alu_op_div_std); \ - [[maybe_unused]] auto alu_op_eq = View(new_term.alu_op_eq); \ - [[maybe_unused]] auto alu_op_eq_diff_inv = View(new_term.alu_op_eq_diff_inv); \ - [[maybe_unused]] auto alu_op_lt = View(new_term.alu_op_lt); \ - [[maybe_unused]] auto alu_op_lte = View(new_term.alu_op_lte); \ - [[maybe_unused]] auto alu_op_mul = View(new_term.alu_op_mul); \ - [[maybe_unused]] auto alu_op_not = View(new_term.alu_op_not); \ - [[maybe_unused]] auto alu_op_shl = View(new_term.alu_op_shl); \ - [[maybe_unused]] auto alu_op_shr = View(new_term.alu_op_shr); \ - [[maybe_unused]] auto alu_op_sub = View(new_term.alu_op_sub); \ - [[maybe_unused]] auto alu_p_a_borrow = View(new_term.alu_p_a_borrow); \ - [[maybe_unused]] auto alu_p_b_borrow = View(new_term.alu_p_b_borrow); \ - [[maybe_unused]] auto alu_p_sub_a_hi = View(new_term.alu_p_sub_a_hi); \ - [[maybe_unused]] auto alu_p_sub_a_lo = View(new_term.alu_p_sub_a_lo); \ - [[maybe_unused]] auto alu_p_sub_b_hi = View(new_term.alu_p_sub_b_hi); \ - [[maybe_unused]] auto alu_p_sub_b_lo = View(new_term.alu_p_sub_b_lo); \ - [[maybe_unused]] auto alu_partial_prod_hi = View(new_term.alu_partial_prod_hi); \ - [[maybe_unused]] auto alu_partial_prod_lo = View(new_term.alu_partial_prod_lo); \ - [[maybe_unused]] auto alu_quotient_hi = View(new_term.alu_quotient_hi); \ - [[maybe_unused]] auto alu_quotient_lo = View(new_term.alu_quotient_lo); \ - [[maybe_unused]] auto alu_remainder = View(new_term.alu_remainder); \ - [[maybe_unused]] auto alu_res_hi = View(new_term.alu_res_hi); \ - [[maybe_unused]] auto alu_res_lo = View(new_term.alu_res_lo); \ - [[maybe_unused]] auto alu_sel_alu = View(new_term.alu_sel_alu); \ - [[maybe_unused]] auto alu_sel_cmp = View(new_term.alu_sel_cmp); \ - [[maybe_unused]] auto alu_sel_div_rng_chk = View(new_term.alu_sel_div_rng_chk); \ - [[maybe_unused]] auto alu_sel_rng_chk = View(new_term.alu_sel_rng_chk); \ - [[maybe_unused]] auto alu_sel_rng_chk_lookup = View(new_term.alu_sel_rng_chk_lookup); \ - [[maybe_unused]] auto alu_sel_shift_which = View(new_term.alu_sel_shift_which); \ - [[maybe_unused]] auto alu_shift_lt_bit_len = View(new_term.alu_shift_lt_bit_len); \ - [[maybe_unused]] auto alu_t_sub_s_bits = View(new_term.alu_t_sub_s_bits); \ - [[maybe_unused]] auto alu_two_pow_s = View(new_term.alu_two_pow_s); \ - [[maybe_unused]] auto alu_two_pow_t_sub_s = View(new_term.alu_two_pow_t_sub_s); \ - [[maybe_unused]] auto alu_u128_tag = View(new_term.alu_u128_tag); \ - [[maybe_unused]] auto alu_u16_r0 = View(new_term.alu_u16_r0); \ - [[maybe_unused]] auto alu_u16_r1 = View(new_term.alu_u16_r1); \ - [[maybe_unused]] auto alu_u16_r10 = View(new_term.alu_u16_r10); \ - [[maybe_unused]] auto alu_u16_r11 = View(new_term.alu_u16_r11); \ - [[maybe_unused]] auto alu_u16_r12 = View(new_term.alu_u16_r12); \ - [[maybe_unused]] auto alu_u16_r13 = View(new_term.alu_u16_r13); \ - [[maybe_unused]] auto alu_u16_r14 = View(new_term.alu_u16_r14); \ - [[maybe_unused]] auto alu_u16_r2 = View(new_term.alu_u16_r2); \ - [[maybe_unused]] auto alu_u16_r3 = View(new_term.alu_u16_r3); \ - [[maybe_unused]] auto alu_u16_r4 = View(new_term.alu_u16_r4); \ - [[maybe_unused]] auto alu_u16_r5 = View(new_term.alu_u16_r5); \ - [[maybe_unused]] auto alu_u16_r6 = View(new_term.alu_u16_r6); \ - [[maybe_unused]] auto alu_u16_r7 = View(new_term.alu_u16_r7); \ - [[maybe_unused]] auto alu_u16_r8 = View(new_term.alu_u16_r8); \ - [[maybe_unused]] auto alu_u16_r9 = View(new_term.alu_u16_r9); \ - [[maybe_unused]] auto alu_u16_tag = View(new_term.alu_u16_tag); \ - [[maybe_unused]] auto alu_u32_tag = View(new_term.alu_u32_tag); \ - [[maybe_unused]] auto alu_u64_tag = View(new_term.alu_u64_tag); \ - [[maybe_unused]] auto alu_u8_r0 = View(new_term.alu_u8_r0); \ - [[maybe_unused]] auto alu_u8_r1 = View(new_term.alu_u8_r1); \ - [[maybe_unused]] auto alu_u8_tag = View(new_term.alu_u8_tag); \ - [[maybe_unused]] auto binary_acc_ia = View(new_term.binary_acc_ia); \ - [[maybe_unused]] auto binary_acc_ib = View(new_term.binary_acc_ib); \ - [[maybe_unused]] auto binary_acc_ic = View(new_term.binary_acc_ic); \ - [[maybe_unused]] auto binary_clk = View(new_term.binary_clk); \ - [[maybe_unused]] auto binary_ia_bytes = View(new_term.binary_ia_bytes); \ - [[maybe_unused]] auto binary_ib_bytes = View(new_term.binary_ib_bytes); \ - [[maybe_unused]] auto binary_ic_bytes = View(new_term.binary_ic_bytes); \ - [[maybe_unused]] auto binary_in_tag = View(new_term.binary_in_tag); \ - [[maybe_unused]] auto binary_mem_tag_ctr = View(new_term.binary_mem_tag_ctr); \ - [[maybe_unused]] auto binary_mem_tag_ctr_inv = View(new_term.binary_mem_tag_ctr_inv); \ - [[maybe_unused]] auto binary_op_id = View(new_term.binary_op_id); \ - [[maybe_unused]] auto binary_sel_bin = View(new_term.binary_sel_bin); \ - [[maybe_unused]] auto binary_start = View(new_term.binary_start); \ - [[maybe_unused]] auto byte_lookup_sel_bin = View(new_term.byte_lookup_sel_bin); \ - [[maybe_unused]] auto byte_lookup_table_byte_lengths = View(new_term.byte_lookup_table_byte_lengths); \ - [[maybe_unused]] auto byte_lookup_table_in_tags = View(new_term.byte_lookup_table_in_tags); \ - [[maybe_unused]] auto byte_lookup_table_input_a = View(new_term.byte_lookup_table_input_a); \ - [[maybe_unused]] auto byte_lookup_table_input_b = View(new_term.byte_lookup_table_input_b); \ - [[maybe_unused]] auto byte_lookup_table_op_id = View(new_term.byte_lookup_table_op_id); \ - [[maybe_unused]] auto byte_lookup_table_output = View(new_term.byte_lookup_table_output); \ - [[maybe_unused]] auto conversion_clk = View(new_term.conversion_clk); \ - [[maybe_unused]] auto conversion_input = View(new_term.conversion_input); \ - [[maybe_unused]] auto conversion_num_limbs = View(new_term.conversion_num_limbs); \ - [[maybe_unused]] auto conversion_radix = View(new_term.conversion_radix); \ - [[maybe_unused]] auto conversion_sel_to_radix_le = View(new_term.conversion_sel_to_radix_le); \ - [[maybe_unused]] auto gas_da_gas_fixed_table = View(new_term.gas_da_gas_fixed_table); \ - [[maybe_unused]] auto gas_l2_gas_fixed_table = View(new_term.gas_l2_gas_fixed_table); \ - [[maybe_unused]] auto gas_sel_gas_cost = View(new_term.gas_sel_gas_cost); \ - [[maybe_unused]] auto keccakf1600_clk = View(new_term.keccakf1600_clk); \ - [[maybe_unused]] auto keccakf1600_input = View(new_term.keccakf1600_input); \ - [[maybe_unused]] auto keccakf1600_output = View(new_term.keccakf1600_output); \ - [[maybe_unused]] auto keccakf1600_sel_keccakf1600 = View(new_term.keccakf1600_sel_keccakf1600); \ - [[maybe_unused]] auto kernel_emit_l2_to_l1_msg_write_offset = \ - View(new_term.kernel_emit_l2_to_l1_msg_write_offset); \ - [[maybe_unused]] auto kernel_emit_note_hash_write_offset = View(new_term.kernel_emit_note_hash_write_offset); \ - [[maybe_unused]] auto kernel_emit_nullifier_write_offset = View(new_term.kernel_emit_nullifier_write_offset); \ - [[maybe_unused]] auto kernel_emit_unencrypted_log_write_offset = \ - View(new_term.kernel_emit_unencrypted_log_write_offset); \ - [[maybe_unused]] auto kernel_kernel_in_offset = View(new_term.kernel_kernel_in_offset); \ - [[maybe_unused]] auto kernel_kernel_out_offset = View(new_term.kernel_kernel_out_offset); \ - [[maybe_unused]] auto kernel_l1_to_l2_msg_exists_write_offset = \ - View(new_term.kernel_l1_to_l2_msg_exists_write_offset); \ - [[maybe_unused]] auto kernel_note_hash_exist_write_offset = View(new_term.kernel_note_hash_exist_write_offset); \ - [[maybe_unused]] auto kernel_nullifier_exists_write_offset = View(new_term.kernel_nullifier_exists_write_offset); \ - [[maybe_unused]] auto kernel_nullifier_non_exists_write_offset = \ - View(new_term.kernel_nullifier_non_exists_write_offset); \ - [[maybe_unused]] auto kernel_q_public_input_kernel_add_to_table = \ - View(new_term.kernel_q_public_input_kernel_add_to_table); \ - [[maybe_unused]] auto kernel_q_public_input_kernel_out_add_to_table = \ - View(new_term.kernel_q_public_input_kernel_out_add_to_table); \ - [[maybe_unused]] auto kernel_side_effect_counter = View(new_term.kernel_side_effect_counter); \ - [[maybe_unused]] auto kernel_sload_write_offset = View(new_term.kernel_sload_write_offset); \ - [[maybe_unused]] auto kernel_sstore_write_offset = View(new_term.kernel_sstore_write_offset); \ - [[maybe_unused]] auto main_abs_da_rem_gas_hi = View(new_term.main_abs_da_rem_gas_hi); \ - [[maybe_unused]] auto main_abs_da_rem_gas_lo = View(new_term.main_abs_da_rem_gas_lo); \ - [[maybe_unused]] auto main_abs_l2_rem_gas_hi = View(new_term.main_abs_l2_rem_gas_hi); \ - [[maybe_unused]] auto main_abs_l2_rem_gas_lo = View(new_term.main_abs_l2_rem_gas_lo); \ - [[maybe_unused]] auto main_alu_in_tag = View(new_term.main_alu_in_tag); \ - [[maybe_unused]] auto main_bin_op_id = View(new_term.main_bin_op_id); \ - [[maybe_unused]] auto main_call_ptr = View(new_term.main_call_ptr); \ - [[maybe_unused]] auto main_da_gas_op_cost = View(new_term.main_da_gas_op_cost); \ - [[maybe_unused]] auto main_da_gas_remaining = View(new_term.main_da_gas_remaining); \ - [[maybe_unused]] auto main_da_out_of_gas = View(new_term.main_da_out_of_gas); \ - [[maybe_unused]] auto main_ia = View(new_term.main_ia); \ - [[maybe_unused]] auto main_ib = View(new_term.main_ib); \ - [[maybe_unused]] auto main_ic = View(new_term.main_ic); \ - [[maybe_unused]] auto main_id = View(new_term.main_id); \ - [[maybe_unused]] auto main_id_zero = View(new_term.main_id_zero); \ - [[maybe_unused]] auto main_ind_addr_a = View(new_term.main_ind_addr_a); \ - [[maybe_unused]] auto main_ind_addr_b = View(new_term.main_ind_addr_b); \ - [[maybe_unused]] auto main_ind_addr_c = View(new_term.main_ind_addr_c); \ - [[maybe_unused]] auto main_ind_addr_d = View(new_term.main_ind_addr_d); \ - [[maybe_unused]] auto main_internal_return_ptr = View(new_term.main_internal_return_ptr); \ - [[maybe_unused]] auto main_inv = View(new_term.main_inv); \ - [[maybe_unused]] auto main_l2_gas_op_cost = View(new_term.main_l2_gas_op_cost); \ - [[maybe_unused]] auto main_l2_gas_remaining = View(new_term.main_l2_gas_remaining); \ - [[maybe_unused]] auto main_l2_out_of_gas = View(new_term.main_l2_out_of_gas); \ - [[maybe_unused]] auto main_mem_addr_a = View(new_term.main_mem_addr_a); \ - [[maybe_unused]] auto main_mem_addr_b = View(new_term.main_mem_addr_b); \ - [[maybe_unused]] auto main_mem_addr_c = View(new_term.main_mem_addr_c); \ - [[maybe_unused]] auto main_mem_addr_d = View(new_term.main_mem_addr_d); \ - [[maybe_unused]] auto main_op_err = View(new_term.main_op_err); \ - [[maybe_unused]] auto main_opcode_val = View(new_term.main_opcode_val); \ - [[maybe_unused]] auto main_pc = View(new_term.main_pc); \ - [[maybe_unused]] auto main_r_in_tag = View(new_term.main_r_in_tag); \ - [[maybe_unused]] auto main_rwa = View(new_term.main_rwa); \ - [[maybe_unused]] auto main_rwb = View(new_term.main_rwb); \ - [[maybe_unused]] auto main_rwc = View(new_term.main_rwc); \ - [[maybe_unused]] auto main_rwd = View(new_term.main_rwd); \ - [[maybe_unused]] auto main_sel_alu = View(new_term.main_sel_alu); \ - [[maybe_unused]] auto main_sel_bin = View(new_term.main_sel_bin); \ - [[maybe_unused]] auto main_sel_calldata = View(new_term.main_sel_calldata); \ - [[maybe_unused]] auto main_sel_gas_accounting_active = View(new_term.main_sel_gas_accounting_active); \ - [[maybe_unused]] auto main_sel_last = View(new_term.main_sel_last); \ - [[maybe_unused]] auto main_sel_mem_op_a = View(new_term.main_sel_mem_op_a); \ - [[maybe_unused]] auto main_sel_mem_op_activate_gas = View(new_term.main_sel_mem_op_activate_gas); \ - [[maybe_unused]] auto main_sel_mem_op_b = View(new_term.main_sel_mem_op_b); \ - [[maybe_unused]] auto main_sel_mem_op_c = View(new_term.main_sel_mem_op_c); \ - [[maybe_unused]] auto main_sel_mem_op_d = View(new_term.main_sel_mem_op_d); \ - [[maybe_unused]] auto main_sel_mov_ia_to_ic = View(new_term.main_sel_mov_ia_to_ic); \ - [[maybe_unused]] auto main_sel_mov_ib_to_ic = View(new_term.main_sel_mov_ib_to_ic); \ - [[maybe_unused]] auto main_sel_op_add = View(new_term.main_sel_op_add); \ - [[maybe_unused]] auto main_sel_op_address = View(new_term.main_sel_op_address); \ - [[maybe_unused]] auto main_sel_op_and = View(new_term.main_sel_op_and); \ - [[maybe_unused]] auto main_sel_op_block_number = View(new_term.main_sel_op_block_number); \ - [[maybe_unused]] auto main_sel_op_calldata_copy = View(new_term.main_sel_op_calldata_copy); \ - [[maybe_unused]] auto main_sel_op_cast = View(new_term.main_sel_op_cast); \ - [[maybe_unused]] auto main_sel_op_chain_id = View(new_term.main_sel_op_chain_id); \ - [[maybe_unused]] auto main_sel_op_cmov = View(new_term.main_sel_op_cmov); \ - [[maybe_unused]] auto main_sel_op_coinbase = View(new_term.main_sel_op_coinbase); \ - [[maybe_unused]] auto main_sel_op_dagasleft = View(new_term.main_sel_op_dagasleft); \ - [[maybe_unused]] auto main_sel_op_div = View(new_term.main_sel_op_div); \ - [[maybe_unused]] auto main_sel_op_emit_l2_to_l1_msg = View(new_term.main_sel_op_emit_l2_to_l1_msg); \ - [[maybe_unused]] auto main_sel_op_emit_note_hash = View(new_term.main_sel_op_emit_note_hash); \ - [[maybe_unused]] auto main_sel_op_emit_nullifier = View(new_term.main_sel_op_emit_nullifier); \ - [[maybe_unused]] auto main_sel_op_emit_unencrypted_log = View(new_term.main_sel_op_emit_unencrypted_log); \ - [[maybe_unused]] auto main_sel_op_eq = View(new_term.main_sel_op_eq); \ - [[maybe_unused]] auto main_sel_op_external_call = View(new_term.main_sel_op_external_call); \ - [[maybe_unused]] auto main_sel_op_external_return = View(new_term.main_sel_op_external_return); \ - [[maybe_unused]] auto main_sel_op_fdiv = View(new_term.main_sel_op_fdiv); \ - [[maybe_unused]] auto main_sel_op_fee_per_da_gas = View(new_term.main_sel_op_fee_per_da_gas); \ - [[maybe_unused]] auto main_sel_op_fee_per_l2_gas = View(new_term.main_sel_op_fee_per_l2_gas); \ - [[maybe_unused]] auto main_sel_op_function_selector = View(new_term.main_sel_op_function_selector); \ - [[maybe_unused]] auto main_sel_op_get_contract_instance = View(new_term.main_sel_op_get_contract_instance); \ - [[maybe_unused]] auto main_sel_op_halt = View(new_term.main_sel_op_halt); \ - [[maybe_unused]] auto main_sel_op_internal_call = View(new_term.main_sel_op_internal_call); \ - [[maybe_unused]] auto main_sel_op_internal_return = View(new_term.main_sel_op_internal_return); \ - [[maybe_unused]] auto main_sel_op_jump = View(new_term.main_sel_op_jump); \ - [[maybe_unused]] auto main_sel_op_jumpi = View(new_term.main_sel_op_jumpi); \ - [[maybe_unused]] auto main_sel_op_keccak = View(new_term.main_sel_op_keccak); \ - [[maybe_unused]] auto main_sel_op_l1_to_l2_msg_exists = View(new_term.main_sel_op_l1_to_l2_msg_exists); \ - [[maybe_unused]] auto main_sel_op_l2gasleft = View(new_term.main_sel_op_l2gasleft); \ - [[maybe_unused]] auto main_sel_op_lt = View(new_term.main_sel_op_lt); \ - [[maybe_unused]] auto main_sel_op_lte = View(new_term.main_sel_op_lte); \ - [[maybe_unused]] auto main_sel_op_mov = View(new_term.main_sel_op_mov); \ - [[maybe_unused]] auto main_sel_op_mul = View(new_term.main_sel_op_mul); \ - [[maybe_unused]] auto main_sel_op_not = View(new_term.main_sel_op_not); \ - [[maybe_unused]] auto main_sel_op_note_hash_exists = View(new_term.main_sel_op_note_hash_exists); \ - [[maybe_unused]] auto main_sel_op_nullifier_exists = View(new_term.main_sel_op_nullifier_exists); \ - [[maybe_unused]] auto main_sel_op_or = View(new_term.main_sel_op_or); \ - [[maybe_unused]] auto main_sel_op_pedersen = View(new_term.main_sel_op_pedersen); \ - [[maybe_unused]] auto main_sel_op_poseidon2 = View(new_term.main_sel_op_poseidon2); \ - [[maybe_unused]] auto main_sel_op_radix_le = View(new_term.main_sel_op_radix_le); \ - [[maybe_unused]] auto main_sel_op_sender = View(new_term.main_sel_op_sender); \ - [[maybe_unused]] auto main_sel_op_sha256 = View(new_term.main_sel_op_sha256); \ - [[maybe_unused]] auto main_sel_op_shl = View(new_term.main_sel_op_shl); \ - [[maybe_unused]] auto main_sel_op_shr = View(new_term.main_sel_op_shr); \ - [[maybe_unused]] auto main_sel_op_sload = View(new_term.main_sel_op_sload); \ - [[maybe_unused]] auto main_sel_op_sstore = View(new_term.main_sel_op_sstore); \ - [[maybe_unused]] auto main_sel_op_storage_address = View(new_term.main_sel_op_storage_address); \ - [[maybe_unused]] auto main_sel_op_sub = View(new_term.main_sel_op_sub); \ - [[maybe_unused]] auto main_sel_op_timestamp = View(new_term.main_sel_op_timestamp); \ - [[maybe_unused]] auto main_sel_op_transaction_fee = View(new_term.main_sel_op_transaction_fee); \ - [[maybe_unused]] auto main_sel_op_version = View(new_term.main_sel_op_version); \ - [[maybe_unused]] auto main_sel_op_xor = View(new_term.main_sel_op_xor); \ - [[maybe_unused]] auto main_sel_q_kernel_lookup = View(new_term.main_sel_q_kernel_lookup); \ - [[maybe_unused]] auto main_sel_q_kernel_output_lookup = View(new_term.main_sel_q_kernel_output_lookup); \ - [[maybe_unused]] auto main_sel_resolve_ind_addr_a = View(new_term.main_sel_resolve_ind_addr_a); \ - [[maybe_unused]] auto main_sel_resolve_ind_addr_b = View(new_term.main_sel_resolve_ind_addr_b); \ - [[maybe_unused]] auto main_sel_resolve_ind_addr_c = View(new_term.main_sel_resolve_ind_addr_c); \ - [[maybe_unused]] auto main_sel_resolve_ind_addr_d = View(new_term.main_sel_resolve_ind_addr_d); \ - [[maybe_unused]] auto main_sel_returndata = View(new_term.main_sel_returndata); \ - [[maybe_unused]] auto main_sel_rng_16 = View(new_term.main_sel_rng_16); \ - [[maybe_unused]] auto main_sel_rng_8 = View(new_term.main_sel_rng_8); \ - [[maybe_unused]] auto main_sel_slice_gadget = View(new_term.main_sel_slice_gadget); \ - [[maybe_unused]] auto main_space_id = View(new_term.main_space_id); \ - [[maybe_unused]] auto main_tag_err = View(new_term.main_tag_err); \ - [[maybe_unused]] auto main_w_in_tag = View(new_term.main_w_in_tag); \ - [[maybe_unused]] auto mem_addr = View(new_term.mem_addr); \ - [[maybe_unused]] auto mem_clk = View(new_term.mem_clk); \ - [[maybe_unused]] auto mem_diff_hi = View(new_term.mem_diff_hi); \ - [[maybe_unused]] auto mem_diff_lo = View(new_term.mem_diff_lo); \ - [[maybe_unused]] auto mem_diff_mid = View(new_term.mem_diff_mid); \ - [[maybe_unused]] auto mem_glob_addr = View(new_term.mem_glob_addr); \ - [[maybe_unused]] auto mem_last = View(new_term.mem_last); \ - [[maybe_unused]] auto mem_lastAccess = View(new_term.mem_lastAccess); \ - [[maybe_unused]] auto mem_one_min_inv = View(new_term.mem_one_min_inv); \ - [[maybe_unused]] auto mem_r_in_tag = View(new_term.mem_r_in_tag); \ - [[maybe_unused]] auto mem_rw = View(new_term.mem_rw); \ - [[maybe_unused]] auto mem_sel_mem = View(new_term.mem_sel_mem); \ - [[maybe_unused]] auto mem_sel_mov_ia_to_ic = View(new_term.mem_sel_mov_ia_to_ic); \ - [[maybe_unused]] auto mem_sel_mov_ib_to_ic = View(new_term.mem_sel_mov_ib_to_ic); \ - [[maybe_unused]] auto mem_sel_op_a = View(new_term.mem_sel_op_a); \ - [[maybe_unused]] auto mem_sel_op_b = View(new_term.mem_sel_op_b); \ - [[maybe_unused]] auto mem_sel_op_c = View(new_term.mem_sel_op_c); \ - [[maybe_unused]] auto mem_sel_op_cmov = View(new_term.mem_sel_op_cmov); \ - [[maybe_unused]] auto mem_sel_op_d = View(new_term.mem_sel_op_d); \ - [[maybe_unused]] auto mem_sel_op_gadget_a = View(new_term.mem_sel_op_gadget_a); \ - [[maybe_unused]] auto mem_sel_op_gadget_b = View(new_term.mem_sel_op_gadget_b); \ - [[maybe_unused]] auto mem_sel_op_gadget_c = View(new_term.mem_sel_op_gadget_c); \ - [[maybe_unused]] auto mem_sel_op_gadget_d = View(new_term.mem_sel_op_gadget_d); \ - [[maybe_unused]] auto mem_sel_op_slice = View(new_term.mem_sel_op_slice); \ - [[maybe_unused]] auto mem_sel_resolve_ind_addr_a = View(new_term.mem_sel_resolve_ind_addr_a); \ - [[maybe_unused]] auto mem_sel_resolve_ind_addr_b = View(new_term.mem_sel_resolve_ind_addr_b); \ - [[maybe_unused]] auto mem_sel_resolve_ind_addr_c = View(new_term.mem_sel_resolve_ind_addr_c); \ - [[maybe_unused]] auto mem_sel_resolve_ind_addr_d = View(new_term.mem_sel_resolve_ind_addr_d); \ - [[maybe_unused]] auto mem_sel_rng_chk = View(new_term.mem_sel_rng_chk); \ - [[maybe_unused]] auto mem_skip_check_tag = View(new_term.mem_skip_check_tag); \ - [[maybe_unused]] auto mem_space_id = View(new_term.mem_space_id); \ - [[maybe_unused]] auto mem_tag = View(new_term.mem_tag); \ - [[maybe_unused]] auto mem_tag_err = View(new_term.mem_tag_err); \ - [[maybe_unused]] auto mem_tsp = View(new_term.mem_tsp); \ - [[maybe_unused]] auto mem_val = View(new_term.mem_val); \ - [[maybe_unused]] auto mem_w_in_tag = View(new_term.mem_w_in_tag); \ - [[maybe_unused]] auto pedersen_clk = View(new_term.pedersen_clk); \ - [[maybe_unused]] auto pedersen_input = View(new_term.pedersen_input); \ - [[maybe_unused]] auto pedersen_output = View(new_term.pedersen_output); \ - [[maybe_unused]] auto pedersen_sel_pedersen = View(new_term.pedersen_sel_pedersen); \ - [[maybe_unused]] auto poseidon2_B_10_0 = View(new_term.poseidon2_B_10_0); \ - [[maybe_unused]] auto poseidon2_B_10_1 = View(new_term.poseidon2_B_10_1); \ - [[maybe_unused]] auto poseidon2_B_10_2 = View(new_term.poseidon2_B_10_2); \ - [[maybe_unused]] auto poseidon2_B_10_3 = View(new_term.poseidon2_B_10_3); \ - [[maybe_unused]] auto poseidon2_B_11_0 = View(new_term.poseidon2_B_11_0); \ - [[maybe_unused]] auto poseidon2_B_11_1 = View(new_term.poseidon2_B_11_1); \ - [[maybe_unused]] auto poseidon2_B_11_2 = View(new_term.poseidon2_B_11_2); \ - [[maybe_unused]] auto poseidon2_B_11_3 = View(new_term.poseidon2_B_11_3); \ - [[maybe_unused]] auto poseidon2_B_12_0 = View(new_term.poseidon2_B_12_0); \ - [[maybe_unused]] auto poseidon2_B_12_1 = View(new_term.poseidon2_B_12_1); \ - [[maybe_unused]] auto poseidon2_B_12_2 = View(new_term.poseidon2_B_12_2); \ - [[maybe_unused]] auto poseidon2_B_12_3 = View(new_term.poseidon2_B_12_3); \ - [[maybe_unused]] auto poseidon2_B_13_0 = View(new_term.poseidon2_B_13_0); \ - [[maybe_unused]] auto poseidon2_B_13_1 = View(new_term.poseidon2_B_13_1); \ - [[maybe_unused]] auto poseidon2_B_13_2 = View(new_term.poseidon2_B_13_2); \ - [[maybe_unused]] auto poseidon2_B_13_3 = View(new_term.poseidon2_B_13_3); \ - [[maybe_unused]] auto poseidon2_B_14_0 = View(new_term.poseidon2_B_14_0); \ - [[maybe_unused]] auto poseidon2_B_14_1 = View(new_term.poseidon2_B_14_1); \ - [[maybe_unused]] auto poseidon2_B_14_2 = View(new_term.poseidon2_B_14_2); \ - [[maybe_unused]] auto poseidon2_B_14_3 = View(new_term.poseidon2_B_14_3); \ - [[maybe_unused]] auto poseidon2_B_15_0 = View(new_term.poseidon2_B_15_0); \ - [[maybe_unused]] auto poseidon2_B_15_1 = View(new_term.poseidon2_B_15_1); \ - [[maybe_unused]] auto poseidon2_B_15_2 = View(new_term.poseidon2_B_15_2); \ - [[maybe_unused]] auto poseidon2_B_15_3 = View(new_term.poseidon2_B_15_3); \ - [[maybe_unused]] auto poseidon2_B_16_0 = View(new_term.poseidon2_B_16_0); \ - [[maybe_unused]] auto poseidon2_B_16_1 = View(new_term.poseidon2_B_16_1); \ - [[maybe_unused]] auto poseidon2_B_16_2 = View(new_term.poseidon2_B_16_2); \ - [[maybe_unused]] auto poseidon2_B_16_3 = View(new_term.poseidon2_B_16_3); \ - [[maybe_unused]] auto poseidon2_B_17_0 = View(new_term.poseidon2_B_17_0); \ - [[maybe_unused]] auto poseidon2_B_17_1 = View(new_term.poseidon2_B_17_1); \ - [[maybe_unused]] auto poseidon2_B_17_2 = View(new_term.poseidon2_B_17_2); \ - [[maybe_unused]] auto poseidon2_B_17_3 = View(new_term.poseidon2_B_17_3); \ - [[maybe_unused]] auto poseidon2_B_18_0 = View(new_term.poseidon2_B_18_0); \ - [[maybe_unused]] auto poseidon2_B_18_1 = View(new_term.poseidon2_B_18_1); \ - [[maybe_unused]] auto poseidon2_B_18_2 = View(new_term.poseidon2_B_18_2); \ - [[maybe_unused]] auto poseidon2_B_18_3 = View(new_term.poseidon2_B_18_3); \ - [[maybe_unused]] auto poseidon2_B_19_0 = View(new_term.poseidon2_B_19_0); \ - [[maybe_unused]] auto poseidon2_B_19_1 = View(new_term.poseidon2_B_19_1); \ - [[maybe_unused]] auto poseidon2_B_19_2 = View(new_term.poseidon2_B_19_2); \ - [[maybe_unused]] auto poseidon2_B_19_3 = View(new_term.poseidon2_B_19_3); \ - [[maybe_unused]] auto poseidon2_B_20_0 = View(new_term.poseidon2_B_20_0); \ - [[maybe_unused]] auto poseidon2_B_20_1 = View(new_term.poseidon2_B_20_1); \ - [[maybe_unused]] auto poseidon2_B_20_2 = View(new_term.poseidon2_B_20_2); \ - [[maybe_unused]] auto poseidon2_B_20_3 = View(new_term.poseidon2_B_20_3); \ - [[maybe_unused]] auto poseidon2_B_21_0 = View(new_term.poseidon2_B_21_0); \ - [[maybe_unused]] auto poseidon2_B_21_1 = View(new_term.poseidon2_B_21_1); \ - [[maybe_unused]] auto poseidon2_B_21_2 = View(new_term.poseidon2_B_21_2); \ - [[maybe_unused]] auto poseidon2_B_21_3 = View(new_term.poseidon2_B_21_3); \ - [[maybe_unused]] auto poseidon2_B_22_0 = View(new_term.poseidon2_B_22_0); \ - [[maybe_unused]] auto poseidon2_B_22_1 = View(new_term.poseidon2_B_22_1); \ - [[maybe_unused]] auto poseidon2_B_22_2 = View(new_term.poseidon2_B_22_2); \ - [[maybe_unused]] auto poseidon2_B_22_3 = View(new_term.poseidon2_B_22_3); \ - [[maybe_unused]] auto poseidon2_B_23_0 = View(new_term.poseidon2_B_23_0); \ - [[maybe_unused]] auto poseidon2_B_23_1 = View(new_term.poseidon2_B_23_1); \ - [[maybe_unused]] auto poseidon2_B_23_2 = View(new_term.poseidon2_B_23_2); \ - [[maybe_unused]] auto poseidon2_B_23_3 = View(new_term.poseidon2_B_23_3); \ - [[maybe_unused]] auto poseidon2_B_24_0 = View(new_term.poseidon2_B_24_0); \ - [[maybe_unused]] auto poseidon2_B_24_1 = View(new_term.poseidon2_B_24_1); \ - [[maybe_unused]] auto poseidon2_B_24_2 = View(new_term.poseidon2_B_24_2); \ - [[maybe_unused]] auto poseidon2_B_24_3 = View(new_term.poseidon2_B_24_3); \ - [[maybe_unused]] auto poseidon2_B_25_0 = View(new_term.poseidon2_B_25_0); \ - [[maybe_unused]] auto poseidon2_B_25_1 = View(new_term.poseidon2_B_25_1); \ - [[maybe_unused]] auto poseidon2_B_25_2 = View(new_term.poseidon2_B_25_2); \ - [[maybe_unused]] auto poseidon2_B_25_3 = View(new_term.poseidon2_B_25_3); \ - [[maybe_unused]] auto poseidon2_B_26_0 = View(new_term.poseidon2_B_26_0); \ - [[maybe_unused]] auto poseidon2_B_26_1 = View(new_term.poseidon2_B_26_1); \ - [[maybe_unused]] auto poseidon2_B_26_2 = View(new_term.poseidon2_B_26_2); \ - [[maybe_unused]] auto poseidon2_B_26_3 = View(new_term.poseidon2_B_26_3); \ - [[maybe_unused]] auto poseidon2_B_27_0 = View(new_term.poseidon2_B_27_0); \ - [[maybe_unused]] auto poseidon2_B_27_1 = View(new_term.poseidon2_B_27_1); \ - [[maybe_unused]] auto poseidon2_B_27_2 = View(new_term.poseidon2_B_27_2); \ - [[maybe_unused]] auto poseidon2_B_27_3 = View(new_term.poseidon2_B_27_3); \ - [[maybe_unused]] auto poseidon2_B_28_0 = View(new_term.poseidon2_B_28_0); \ - [[maybe_unused]] auto poseidon2_B_28_1 = View(new_term.poseidon2_B_28_1); \ - [[maybe_unused]] auto poseidon2_B_28_2 = View(new_term.poseidon2_B_28_2); \ - [[maybe_unused]] auto poseidon2_B_28_3 = View(new_term.poseidon2_B_28_3); \ - [[maybe_unused]] auto poseidon2_B_29_0 = View(new_term.poseidon2_B_29_0); \ - [[maybe_unused]] auto poseidon2_B_29_1 = View(new_term.poseidon2_B_29_1); \ - [[maybe_unused]] auto poseidon2_B_29_2 = View(new_term.poseidon2_B_29_2); \ - [[maybe_unused]] auto poseidon2_B_29_3 = View(new_term.poseidon2_B_29_3); \ - [[maybe_unused]] auto poseidon2_B_30_0 = View(new_term.poseidon2_B_30_0); \ - [[maybe_unused]] auto poseidon2_B_30_1 = View(new_term.poseidon2_B_30_1); \ - [[maybe_unused]] auto poseidon2_B_30_2 = View(new_term.poseidon2_B_30_2); \ - [[maybe_unused]] auto poseidon2_B_30_3 = View(new_term.poseidon2_B_30_3); \ - [[maybe_unused]] auto poseidon2_B_31_0 = View(new_term.poseidon2_B_31_0); \ - [[maybe_unused]] auto poseidon2_B_31_1 = View(new_term.poseidon2_B_31_1); \ - [[maybe_unused]] auto poseidon2_B_31_2 = View(new_term.poseidon2_B_31_2); \ - [[maybe_unused]] auto poseidon2_B_31_3 = View(new_term.poseidon2_B_31_3); \ - [[maybe_unused]] auto poseidon2_B_32_0 = View(new_term.poseidon2_B_32_0); \ - [[maybe_unused]] auto poseidon2_B_32_1 = View(new_term.poseidon2_B_32_1); \ - [[maybe_unused]] auto poseidon2_B_32_2 = View(new_term.poseidon2_B_32_2); \ - [[maybe_unused]] auto poseidon2_B_32_3 = View(new_term.poseidon2_B_32_3); \ - [[maybe_unused]] auto poseidon2_B_33_0 = View(new_term.poseidon2_B_33_0); \ - [[maybe_unused]] auto poseidon2_B_33_1 = View(new_term.poseidon2_B_33_1); \ - [[maybe_unused]] auto poseidon2_B_33_2 = View(new_term.poseidon2_B_33_2); \ - [[maybe_unused]] auto poseidon2_B_33_3 = View(new_term.poseidon2_B_33_3); \ - [[maybe_unused]] auto poseidon2_B_34_0 = View(new_term.poseidon2_B_34_0); \ - [[maybe_unused]] auto poseidon2_B_34_1 = View(new_term.poseidon2_B_34_1); \ - [[maybe_unused]] auto poseidon2_B_34_2 = View(new_term.poseidon2_B_34_2); \ - [[maybe_unused]] auto poseidon2_B_34_3 = View(new_term.poseidon2_B_34_3); \ - [[maybe_unused]] auto poseidon2_B_35_0 = View(new_term.poseidon2_B_35_0); \ - [[maybe_unused]] auto poseidon2_B_35_1 = View(new_term.poseidon2_B_35_1); \ - [[maybe_unused]] auto poseidon2_B_35_2 = View(new_term.poseidon2_B_35_2); \ - [[maybe_unused]] auto poseidon2_B_35_3 = View(new_term.poseidon2_B_35_3); \ - [[maybe_unused]] auto poseidon2_B_36_0 = View(new_term.poseidon2_B_36_0); \ - [[maybe_unused]] auto poseidon2_B_36_1 = View(new_term.poseidon2_B_36_1); \ - [[maybe_unused]] auto poseidon2_B_36_2 = View(new_term.poseidon2_B_36_2); \ - [[maybe_unused]] auto poseidon2_B_36_3 = View(new_term.poseidon2_B_36_3); \ - [[maybe_unused]] auto poseidon2_B_37_0 = View(new_term.poseidon2_B_37_0); \ - [[maybe_unused]] auto poseidon2_B_37_1 = View(new_term.poseidon2_B_37_1); \ - [[maybe_unused]] auto poseidon2_B_37_2 = View(new_term.poseidon2_B_37_2); \ - [[maybe_unused]] auto poseidon2_B_37_3 = View(new_term.poseidon2_B_37_3); \ - [[maybe_unused]] auto poseidon2_B_38_0 = View(new_term.poseidon2_B_38_0); \ - [[maybe_unused]] auto poseidon2_B_38_1 = View(new_term.poseidon2_B_38_1); \ - [[maybe_unused]] auto poseidon2_B_38_2 = View(new_term.poseidon2_B_38_2); \ - [[maybe_unused]] auto poseidon2_B_38_3 = View(new_term.poseidon2_B_38_3); \ - [[maybe_unused]] auto poseidon2_B_39_0 = View(new_term.poseidon2_B_39_0); \ - [[maybe_unused]] auto poseidon2_B_39_1 = View(new_term.poseidon2_B_39_1); \ - [[maybe_unused]] auto poseidon2_B_39_2 = View(new_term.poseidon2_B_39_2); \ - [[maybe_unused]] auto poseidon2_B_39_3 = View(new_term.poseidon2_B_39_3); \ - [[maybe_unused]] auto poseidon2_B_40_0 = View(new_term.poseidon2_B_40_0); \ - [[maybe_unused]] auto poseidon2_B_40_1 = View(new_term.poseidon2_B_40_1); \ - [[maybe_unused]] auto poseidon2_B_40_2 = View(new_term.poseidon2_B_40_2); \ - [[maybe_unused]] auto poseidon2_B_40_3 = View(new_term.poseidon2_B_40_3); \ - [[maybe_unused]] auto poseidon2_B_41_0 = View(new_term.poseidon2_B_41_0); \ - [[maybe_unused]] auto poseidon2_B_41_1 = View(new_term.poseidon2_B_41_1); \ - [[maybe_unused]] auto poseidon2_B_41_2 = View(new_term.poseidon2_B_41_2); \ - [[maybe_unused]] auto poseidon2_B_41_3 = View(new_term.poseidon2_B_41_3); \ - [[maybe_unused]] auto poseidon2_B_42_0 = View(new_term.poseidon2_B_42_0); \ - [[maybe_unused]] auto poseidon2_B_42_1 = View(new_term.poseidon2_B_42_1); \ - [[maybe_unused]] auto poseidon2_B_42_2 = View(new_term.poseidon2_B_42_2); \ - [[maybe_unused]] auto poseidon2_B_42_3 = View(new_term.poseidon2_B_42_3); \ - [[maybe_unused]] auto poseidon2_B_43_0 = View(new_term.poseidon2_B_43_0); \ - [[maybe_unused]] auto poseidon2_B_43_1 = View(new_term.poseidon2_B_43_1); \ - [[maybe_unused]] auto poseidon2_B_43_2 = View(new_term.poseidon2_B_43_2); \ - [[maybe_unused]] auto poseidon2_B_43_3 = View(new_term.poseidon2_B_43_3); \ - [[maybe_unused]] auto poseidon2_B_44_0 = View(new_term.poseidon2_B_44_0); \ - [[maybe_unused]] auto poseidon2_B_44_1 = View(new_term.poseidon2_B_44_1); \ - [[maybe_unused]] auto poseidon2_B_44_2 = View(new_term.poseidon2_B_44_2); \ - [[maybe_unused]] auto poseidon2_B_44_3 = View(new_term.poseidon2_B_44_3); \ - [[maybe_unused]] auto poseidon2_B_45_0 = View(new_term.poseidon2_B_45_0); \ - [[maybe_unused]] auto poseidon2_B_45_1 = View(new_term.poseidon2_B_45_1); \ - [[maybe_unused]] auto poseidon2_B_45_2 = View(new_term.poseidon2_B_45_2); \ - [[maybe_unused]] auto poseidon2_B_45_3 = View(new_term.poseidon2_B_45_3); \ - [[maybe_unused]] auto poseidon2_B_46_0 = View(new_term.poseidon2_B_46_0); \ - [[maybe_unused]] auto poseidon2_B_46_1 = View(new_term.poseidon2_B_46_1); \ - [[maybe_unused]] auto poseidon2_B_46_2 = View(new_term.poseidon2_B_46_2); \ - [[maybe_unused]] auto poseidon2_B_46_3 = View(new_term.poseidon2_B_46_3); \ - [[maybe_unused]] auto poseidon2_B_47_0 = View(new_term.poseidon2_B_47_0); \ - [[maybe_unused]] auto poseidon2_B_47_1 = View(new_term.poseidon2_B_47_1); \ - [[maybe_unused]] auto poseidon2_B_47_2 = View(new_term.poseidon2_B_47_2); \ - [[maybe_unused]] auto poseidon2_B_47_3 = View(new_term.poseidon2_B_47_3); \ - [[maybe_unused]] auto poseidon2_B_48_0 = View(new_term.poseidon2_B_48_0); \ - [[maybe_unused]] auto poseidon2_B_48_1 = View(new_term.poseidon2_B_48_1); \ - [[maybe_unused]] auto poseidon2_B_48_2 = View(new_term.poseidon2_B_48_2); \ - [[maybe_unused]] auto poseidon2_B_48_3 = View(new_term.poseidon2_B_48_3); \ - [[maybe_unused]] auto poseidon2_B_49_0 = View(new_term.poseidon2_B_49_0); \ - [[maybe_unused]] auto poseidon2_B_49_1 = View(new_term.poseidon2_B_49_1); \ - [[maybe_unused]] auto poseidon2_B_49_2 = View(new_term.poseidon2_B_49_2); \ - [[maybe_unused]] auto poseidon2_B_49_3 = View(new_term.poseidon2_B_49_3); \ - [[maybe_unused]] auto poseidon2_B_4_0 = View(new_term.poseidon2_B_4_0); \ - [[maybe_unused]] auto poseidon2_B_4_1 = View(new_term.poseidon2_B_4_1); \ - [[maybe_unused]] auto poseidon2_B_4_2 = View(new_term.poseidon2_B_4_2); \ - [[maybe_unused]] auto poseidon2_B_4_3 = View(new_term.poseidon2_B_4_3); \ - [[maybe_unused]] auto poseidon2_B_50_0 = View(new_term.poseidon2_B_50_0); \ - [[maybe_unused]] auto poseidon2_B_50_1 = View(new_term.poseidon2_B_50_1); \ - [[maybe_unused]] auto poseidon2_B_50_2 = View(new_term.poseidon2_B_50_2); \ - [[maybe_unused]] auto poseidon2_B_50_3 = View(new_term.poseidon2_B_50_3); \ - [[maybe_unused]] auto poseidon2_B_51_0 = View(new_term.poseidon2_B_51_0); \ - [[maybe_unused]] auto poseidon2_B_51_1 = View(new_term.poseidon2_B_51_1); \ - [[maybe_unused]] auto poseidon2_B_51_2 = View(new_term.poseidon2_B_51_2); \ - [[maybe_unused]] auto poseidon2_B_51_3 = View(new_term.poseidon2_B_51_3); \ - [[maybe_unused]] auto poseidon2_B_52_0 = View(new_term.poseidon2_B_52_0); \ - [[maybe_unused]] auto poseidon2_B_52_1 = View(new_term.poseidon2_B_52_1); \ - [[maybe_unused]] auto poseidon2_B_52_2 = View(new_term.poseidon2_B_52_2); \ - [[maybe_unused]] auto poseidon2_B_52_3 = View(new_term.poseidon2_B_52_3); \ - [[maybe_unused]] auto poseidon2_B_53_0 = View(new_term.poseidon2_B_53_0); \ - [[maybe_unused]] auto poseidon2_B_53_1 = View(new_term.poseidon2_B_53_1); \ - [[maybe_unused]] auto poseidon2_B_53_2 = View(new_term.poseidon2_B_53_2); \ - [[maybe_unused]] auto poseidon2_B_53_3 = View(new_term.poseidon2_B_53_3); \ - [[maybe_unused]] auto poseidon2_B_54_0 = View(new_term.poseidon2_B_54_0); \ - [[maybe_unused]] auto poseidon2_B_54_1 = View(new_term.poseidon2_B_54_1); \ - [[maybe_unused]] auto poseidon2_B_54_2 = View(new_term.poseidon2_B_54_2); \ - [[maybe_unused]] auto poseidon2_B_54_3 = View(new_term.poseidon2_B_54_3); \ - [[maybe_unused]] auto poseidon2_B_55_0 = View(new_term.poseidon2_B_55_0); \ - [[maybe_unused]] auto poseidon2_B_55_1 = View(new_term.poseidon2_B_55_1); \ - [[maybe_unused]] auto poseidon2_B_55_2 = View(new_term.poseidon2_B_55_2); \ - [[maybe_unused]] auto poseidon2_B_55_3 = View(new_term.poseidon2_B_55_3); \ - [[maybe_unused]] auto poseidon2_B_56_0 = View(new_term.poseidon2_B_56_0); \ - [[maybe_unused]] auto poseidon2_B_56_1 = View(new_term.poseidon2_B_56_1); \ - [[maybe_unused]] auto poseidon2_B_56_2 = View(new_term.poseidon2_B_56_2); \ - [[maybe_unused]] auto poseidon2_B_56_3 = View(new_term.poseidon2_B_56_3); \ - [[maybe_unused]] auto poseidon2_B_57_0 = View(new_term.poseidon2_B_57_0); \ - [[maybe_unused]] auto poseidon2_B_57_1 = View(new_term.poseidon2_B_57_1); \ - [[maybe_unused]] auto poseidon2_B_57_2 = View(new_term.poseidon2_B_57_2); \ - [[maybe_unused]] auto poseidon2_B_57_3 = View(new_term.poseidon2_B_57_3); \ - [[maybe_unused]] auto poseidon2_B_58_0 = View(new_term.poseidon2_B_58_0); \ - [[maybe_unused]] auto poseidon2_B_58_1 = View(new_term.poseidon2_B_58_1); \ - [[maybe_unused]] auto poseidon2_B_58_2 = View(new_term.poseidon2_B_58_2); \ - [[maybe_unused]] auto poseidon2_B_58_3 = View(new_term.poseidon2_B_58_3); \ - [[maybe_unused]] auto poseidon2_B_59_0 = View(new_term.poseidon2_B_59_0); \ - [[maybe_unused]] auto poseidon2_B_59_1 = View(new_term.poseidon2_B_59_1); \ - [[maybe_unused]] auto poseidon2_B_59_2 = View(new_term.poseidon2_B_59_2); \ - [[maybe_unused]] auto poseidon2_B_59_3 = View(new_term.poseidon2_B_59_3); \ - [[maybe_unused]] auto poseidon2_B_5_0 = View(new_term.poseidon2_B_5_0); \ - [[maybe_unused]] auto poseidon2_B_5_1 = View(new_term.poseidon2_B_5_1); \ - [[maybe_unused]] auto poseidon2_B_5_2 = View(new_term.poseidon2_B_5_2); \ - [[maybe_unused]] auto poseidon2_B_5_3 = View(new_term.poseidon2_B_5_3); \ - [[maybe_unused]] auto poseidon2_B_6_0 = View(new_term.poseidon2_B_6_0); \ - [[maybe_unused]] auto poseidon2_B_6_1 = View(new_term.poseidon2_B_6_1); \ - [[maybe_unused]] auto poseidon2_B_6_2 = View(new_term.poseidon2_B_6_2); \ - [[maybe_unused]] auto poseidon2_B_6_3 = View(new_term.poseidon2_B_6_3); \ - [[maybe_unused]] auto poseidon2_B_7_0 = View(new_term.poseidon2_B_7_0); \ - [[maybe_unused]] auto poseidon2_B_7_1 = View(new_term.poseidon2_B_7_1); \ - [[maybe_unused]] auto poseidon2_B_7_2 = View(new_term.poseidon2_B_7_2); \ - [[maybe_unused]] auto poseidon2_B_7_3 = View(new_term.poseidon2_B_7_3); \ - [[maybe_unused]] auto poseidon2_B_8_0 = View(new_term.poseidon2_B_8_0); \ - [[maybe_unused]] auto poseidon2_B_8_1 = View(new_term.poseidon2_B_8_1); \ - [[maybe_unused]] auto poseidon2_B_8_2 = View(new_term.poseidon2_B_8_2); \ - [[maybe_unused]] auto poseidon2_B_8_3 = View(new_term.poseidon2_B_8_3); \ - [[maybe_unused]] auto poseidon2_B_9_0 = View(new_term.poseidon2_B_9_0); \ - [[maybe_unused]] auto poseidon2_B_9_1 = View(new_term.poseidon2_B_9_1); \ - [[maybe_unused]] auto poseidon2_B_9_2 = View(new_term.poseidon2_B_9_2); \ - [[maybe_unused]] auto poseidon2_B_9_3 = View(new_term.poseidon2_B_9_3); \ - [[maybe_unused]] auto poseidon2_EXT_LAYER_4 = View(new_term.poseidon2_EXT_LAYER_4); \ - [[maybe_unused]] auto poseidon2_EXT_LAYER_5 = View(new_term.poseidon2_EXT_LAYER_5); \ - [[maybe_unused]] auto poseidon2_EXT_LAYER_6 = View(new_term.poseidon2_EXT_LAYER_6); \ - [[maybe_unused]] auto poseidon2_EXT_LAYER_7 = View(new_term.poseidon2_EXT_LAYER_7); \ - [[maybe_unused]] auto poseidon2_T_0_4 = View(new_term.poseidon2_T_0_4); \ - [[maybe_unused]] auto poseidon2_T_0_5 = View(new_term.poseidon2_T_0_5); \ - [[maybe_unused]] auto poseidon2_T_0_6 = View(new_term.poseidon2_T_0_6); \ - [[maybe_unused]] auto poseidon2_T_0_7 = View(new_term.poseidon2_T_0_7); \ - [[maybe_unused]] auto poseidon2_T_1_4 = View(new_term.poseidon2_T_1_4); \ - [[maybe_unused]] auto poseidon2_T_1_5 = View(new_term.poseidon2_T_1_5); \ - [[maybe_unused]] auto poseidon2_T_1_6 = View(new_term.poseidon2_T_1_6); \ - [[maybe_unused]] auto poseidon2_T_1_7 = View(new_term.poseidon2_T_1_7); \ - [[maybe_unused]] auto poseidon2_T_2_4 = View(new_term.poseidon2_T_2_4); \ - [[maybe_unused]] auto poseidon2_T_2_5 = View(new_term.poseidon2_T_2_5); \ - [[maybe_unused]] auto poseidon2_T_2_6 = View(new_term.poseidon2_T_2_6); \ - [[maybe_unused]] auto poseidon2_T_2_7 = View(new_term.poseidon2_T_2_7); \ - [[maybe_unused]] auto poseidon2_T_3_4 = View(new_term.poseidon2_T_3_4); \ - [[maybe_unused]] auto poseidon2_T_3_5 = View(new_term.poseidon2_T_3_5); \ - [[maybe_unused]] auto poseidon2_T_3_6 = View(new_term.poseidon2_T_3_6); \ - [[maybe_unused]] auto poseidon2_T_3_7 = View(new_term.poseidon2_T_3_7); \ - [[maybe_unused]] auto poseidon2_T_60_4 = View(new_term.poseidon2_T_60_4); \ - [[maybe_unused]] auto poseidon2_T_60_5 = View(new_term.poseidon2_T_60_5); \ - [[maybe_unused]] auto poseidon2_T_60_6 = View(new_term.poseidon2_T_60_6); \ - [[maybe_unused]] auto poseidon2_T_60_7 = View(new_term.poseidon2_T_60_7); \ - [[maybe_unused]] auto poseidon2_T_61_4 = View(new_term.poseidon2_T_61_4); \ - [[maybe_unused]] auto poseidon2_T_61_5 = View(new_term.poseidon2_T_61_5); \ - [[maybe_unused]] auto poseidon2_T_61_6 = View(new_term.poseidon2_T_61_6); \ - [[maybe_unused]] auto poseidon2_T_61_7 = View(new_term.poseidon2_T_61_7); \ - [[maybe_unused]] auto poseidon2_T_62_4 = View(new_term.poseidon2_T_62_4); \ - [[maybe_unused]] auto poseidon2_T_62_5 = View(new_term.poseidon2_T_62_5); \ - [[maybe_unused]] auto poseidon2_T_62_6 = View(new_term.poseidon2_T_62_6); \ - [[maybe_unused]] auto poseidon2_T_62_7 = View(new_term.poseidon2_T_62_7); \ - [[maybe_unused]] auto poseidon2_T_63_4 = View(new_term.poseidon2_T_63_4); \ - [[maybe_unused]] auto poseidon2_T_63_5 = View(new_term.poseidon2_T_63_5); \ - [[maybe_unused]] auto poseidon2_T_63_6 = View(new_term.poseidon2_T_63_6); \ - [[maybe_unused]] auto poseidon2_T_63_7 = View(new_term.poseidon2_T_63_7); \ - [[maybe_unused]] auto poseidon2_a_0 = View(new_term.poseidon2_a_0); \ - [[maybe_unused]] auto poseidon2_a_1 = View(new_term.poseidon2_a_1); \ - [[maybe_unused]] auto poseidon2_a_2 = View(new_term.poseidon2_a_2); \ - [[maybe_unused]] auto poseidon2_a_3 = View(new_term.poseidon2_a_3); \ - [[maybe_unused]] auto poseidon2_b_0 = View(new_term.poseidon2_b_0); \ - [[maybe_unused]] auto poseidon2_b_1 = View(new_term.poseidon2_b_1); \ - [[maybe_unused]] auto poseidon2_b_2 = View(new_term.poseidon2_b_2); \ - [[maybe_unused]] auto poseidon2_b_3 = View(new_term.poseidon2_b_3); \ - [[maybe_unused]] auto poseidon2_clk = View(new_term.poseidon2_clk); \ - [[maybe_unused]] auto poseidon2_in_tag = View(new_term.poseidon2_in_tag); \ - [[maybe_unused]] auto poseidon2_input_addr = View(new_term.poseidon2_input_addr); \ - [[maybe_unused]] auto poseidon2_mem_addr_a = View(new_term.poseidon2_mem_addr_a); \ - [[maybe_unused]] auto poseidon2_mem_addr_b = View(new_term.poseidon2_mem_addr_b); \ - [[maybe_unused]] auto poseidon2_mem_addr_c = View(new_term.poseidon2_mem_addr_c); \ - [[maybe_unused]] auto poseidon2_mem_addr_d = View(new_term.poseidon2_mem_addr_d); \ - [[maybe_unused]] auto poseidon2_mem_op = View(new_term.poseidon2_mem_op); \ - [[maybe_unused]] auto poseidon2_output_addr = View(new_term.poseidon2_output_addr); \ - [[maybe_unused]] auto poseidon2_read_line = View(new_term.poseidon2_read_line); \ - [[maybe_unused]] auto poseidon2_sel_poseidon_perm = View(new_term.poseidon2_sel_poseidon_perm); \ - [[maybe_unused]] auto poseidon2_write_line = View(new_term.poseidon2_write_line); \ - [[maybe_unused]] auto powers_power_of_2 = View(new_term.powers_power_of_2); \ - [[maybe_unused]] auto sha256_clk = View(new_term.sha256_clk); \ - [[maybe_unused]] auto sha256_input = View(new_term.sha256_input); \ - [[maybe_unused]] auto sha256_output = View(new_term.sha256_output); \ - [[maybe_unused]] auto sha256_sel_sha256_compression = View(new_term.sha256_sel_sha256_compression); \ - [[maybe_unused]] auto sha256_state = View(new_term.sha256_state); \ - [[maybe_unused]] auto slice_addr = View(new_term.slice_addr); \ - [[maybe_unused]] auto slice_clk = View(new_term.slice_clk); \ - [[maybe_unused]] auto slice_cnt = View(new_term.slice_cnt); \ - [[maybe_unused]] auto slice_col_offset = View(new_term.slice_col_offset); \ - [[maybe_unused]] auto slice_one_min_inv = View(new_term.slice_one_min_inv); \ - [[maybe_unused]] auto slice_sel_cd_cpy = View(new_term.slice_sel_cd_cpy); \ - [[maybe_unused]] auto slice_sel_mem_active = View(new_term.slice_sel_mem_active); \ - [[maybe_unused]] auto slice_sel_return = View(new_term.slice_sel_return); \ - [[maybe_unused]] auto slice_sel_start = View(new_term.slice_sel_start); \ - [[maybe_unused]] auto slice_space_id = View(new_term.slice_space_id); \ - [[maybe_unused]] auto slice_val = View(new_term.slice_val); \ - [[maybe_unused]] auto perm_pos_mem_a = View(new_term.perm_pos_mem_a); \ - [[maybe_unused]] auto perm_pos_mem_b = View(new_term.perm_pos_mem_b); \ - [[maybe_unused]] auto perm_pos_mem_c = View(new_term.perm_pos_mem_c); \ - [[maybe_unused]] auto perm_pos_mem_d = View(new_term.perm_pos_mem_d); \ - [[maybe_unused]] auto perm_slice_mem = View(new_term.perm_slice_mem); \ - [[maybe_unused]] auto perm_main_alu = View(new_term.perm_main_alu); \ - [[maybe_unused]] auto perm_main_bin = View(new_term.perm_main_bin); \ - [[maybe_unused]] auto perm_main_conv = View(new_term.perm_main_conv); \ - [[maybe_unused]] auto perm_main_pos2_perm = View(new_term.perm_main_pos2_perm); \ - [[maybe_unused]] auto perm_main_pedersen = View(new_term.perm_main_pedersen); \ - [[maybe_unused]] auto perm_main_slice = View(new_term.perm_main_slice); \ - [[maybe_unused]] auto perm_main_mem_a = View(new_term.perm_main_mem_a); \ - [[maybe_unused]] auto perm_main_mem_b = View(new_term.perm_main_mem_b); \ - [[maybe_unused]] auto perm_main_mem_c = View(new_term.perm_main_mem_c); \ - [[maybe_unused]] auto perm_main_mem_d = View(new_term.perm_main_mem_d); \ - [[maybe_unused]] auto perm_main_mem_ind_addr_a = View(new_term.perm_main_mem_ind_addr_a); \ - [[maybe_unused]] auto perm_main_mem_ind_addr_b = View(new_term.perm_main_mem_ind_addr_b); \ - [[maybe_unused]] auto perm_main_mem_ind_addr_c = View(new_term.perm_main_mem_ind_addr_c); \ - [[maybe_unused]] auto perm_main_mem_ind_addr_d = View(new_term.perm_main_mem_ind_addr_d); \ - [[maybe_unused]] auto lookup_byte_lengths = View(new_term.lookup_byte_lengths); \ - [[maybe_unused]] auto lookup_byte_operations = View(new_term.lookup_byte_operations); \ - [[maybe_unused]] auto lookup_cd_value = View(new_term.lookup_cd_value); \ - [[maybe_unused]] auto lookup_ret_value = View(new_term.lookup_ret_value); \ - [[maybe_unused]] auto lookup_opcode_gas = View(new_term.lookup_opcode_gas); \ - [[maybe_unused]] auto range_check_l2_gas_hi = View(new_term.range_check_l2_gas_hi); \ - [[maybe_unused]] auto range_check_l2_gas_lo = View(new_term.range_check_l2_gas_lo); \ - [[maybe_unused]] auto range_check_da_gas_hi = View(new_term.range_check_da_gas_hi); \ - [[maybe_unused]] auto range_check_da_gas_lo = View(new_term.range_check_da_gas_lo); \ - [[maybe_unused]] auto kernel_output_lookup = View(new_term.kernel_output_lookup); \ - [[maybe_unused]] auto lookup_into_kernel = View(new_term.lookup_into_kernel); \ - [[maybe_unused]] auto incl_main_tag_err = View(new_term.incl_main_tag_err); \ - [[maybe_unused]] auto incl_mem_tag_err = View(new_term.incl_mem_tag_err); \ - [[maybe_unused]] auto lookup_mem_rng_chk_lo = View(new_term.lookup_mem_rng_chk_lo); \ - [[maybe_unused]] auto lookup_mem_rng_chk_mid = View(new_term.lookup_mem_rng_chk_mid); \ - [[maybe_unused]] auto lookup_mem_rng_chk_hi = View(new_term.lookup_mem_rng_chk_hi); \ - [[maybe_unused]] auto lookup_pow_2_0 = View(new_term.lookup_pow_2_0); \ - [[maybe_unused]] auto lookup_pow_2_1 = View(new_term.lookup_pow_2_1); \ - [[maybe_unused]] auto lookup_u8_0 = View(new_term.lookup_u8_0); \ - [[maybe_unused]] auto lookup_u8_1 = View(new_term.lookup_u8_1); \ - [[maybe_unused]] auto lookup_u16_0 = View(new_term.lookup_u16_0); \ - [[maybe_unused]] auto lookup_u16_1 = View(new_term.lookup_u16_1); \ - [[maybe_unused]] auto lookup_u16_2 = View(new_term.lookup_u16_2); \ - [[maybe_unused]] auto lookup_u16_3 = View(new_term.lookup_u16_3); \ - [[maybe_unused]] auto lookup_u16_4 = View(new_term.lookup_u16_4); \ - [[maybe_unused]] auto lookup_u16_5 = View(new_term.lookup_u16_5); \ - [[maybe_unused]] auto lookup_u16_6 = View(new_term.lookup_u16_6); \ - [[maybe_unused]] auto lookup_u16_7 = View(new_term.lookup_u16_7); \ - [[maybe_unused]] auto lookup_u16_8 = View(new_term.lookup_u16_8); \ - [[maybe_unused]] auto lookup_u16_9 = View(new_term.lookup_u16_9); \ - [[maybe_unused]] auto lookup_u16_10 = View(new_term.lookup_u16_10); \ - [[maybe_unused]] auto lookup_u16_11 = View(new_term.lookup_u16_11); \ - [[maybe_unused]] auto lookup_u16_12 = View(new_term.lookup_u16_12); \ - [[maybe_unused]] auto lookup_u16_13 = View(new_term.lookup_u16_13); \ - [[maybe_unused]] auto lookup_u16_14 = View(new_term.lookup_u16_14); \ - [[maybe_unused]] auto lookup_div_u16_0 = View(new_term.lookup_div_u16_0); \ - [[maybe_unused]] auto lookup_div_u16_1 = View(new_term.lookup_div_u16_1); \ - [[maybe_unused]] auto lookup_div_u16_2 = View(new_term.lookup_div_u16_2); \ - [[maybe_unused]] auto lookup_div_u16_3 = View(new_term.lookup_div_u16_3); \ - [[maybe_unused]] auto lookup_div_u16_4 = View(new_term.lookup_div_u16_4); \ - [[maybe_unused]] auto lookup_div_u16_5 = View(new_term.lookup_div_u16_5); \ - [[maybe_unused]] auto lookup_div_u16_6 = View(new_term.lookup_div_u16_6); \ - [[maybe_unused]] auto lookup_div_u16_7 = View(new_term.lookup_div_u16_7); \ - [[maybe_unused]] auto lookup_byte_lengths_counts = View(new_term.lookup_byte_lengths_counts); \ - [[maybe_unused]] auto lookup_byte_operations_counts = View(new_term.lookup_byte_operations_counts); \ - [[maybe_unused]] auto lookup_cd_value_counts = View(new_term.lookup_cd_value_counts); \ - [[maybe_unused]] auto lookup_ret_value_counts = View(new_term.lookup_ret_value_counts); \ - [[maybe_unused]] auto lookup_opcode_gas_counts = View(new_term.lookup_opcode_gas_counts); \ - [[maybe_unused]] auto range_check_l2_gas_hi_counts = View(new_term.range_check_l2_gas_hi_counts); \ - [[maybe_unused]] auto range_check_l2_gas_lo_counts = View(new_term.range_check_l2_gas_lo_counts); \ - [[maybe_unused]] auto range_check_da_gas_hi_counts = View(new_term.range_check_da_gas_hi_counts); \ - [[maybe_unused]] auto range_check_da_gas_lo_counts = View(new_term.range_check_da_gas_lo_counts); \ - [[maybe_unused]] auto kernel_output_lookup_counts = View(new_term.kernel_output_lookup_counts); \ - [[maybe_unused]] auto lookup_into_kernel_counts = View(new_term.lookup_into_kernel_counts); \ - [[maybe_unused]] auto incl_main_tag_err_counts = View(new_term.incl_main_tag_err_counts); \ - [[maybe_unused]] auto incl_mem_tag_err_counts = View(new_term.incl_mem_tag_err_counts); \ - [[maybe_unused]] auto lookup_mem_rng_chk_lo_counts = View(new_term.lookup_mem_rng_chk_lo_counts); \ - [[maybe_unused]] auto lookup_mem_rng_chk_mid_counts = View(new_term.lookup_mem_rng_chk_mid_counts); \ - [[maybe_unused]] auto lookup_mem_rng_chk_hi_counts = View(new_term.lookup_mem_rng_chk_hi_counts); \ - [[maybe_unused]] auto lookup_pow_2_0_counts = View(new_term.lookup_pow_2_0_counts); \ - [[maybe_unused]] auto lookup_pow_2_1_counts = View(new_term.lookup_pow_2_1_counts); \ - [[maybe_unused]] auto lookup_u8_0_counts = View(new_term.lookup_u8_0_counts); \ - [[maybe_unused]] auto lookup_u8_1_counts = View(new_term.lookup_u8_1_counts); \ - [[maybe_unused]] auto lookup_u16_0_counts = View(new_term.lookup_u16_0_counts); \ - [[maybe_unused]] auto lookup_u16_1_counts = View(new_term.lookup_u16_1_counts); \ - [[maybe_unused]] auto lookup_u16_2_counts = View(new_term.lookup_u16_2_counts); \ - [[maybe_unused]] auto lookup_u16_3_counts = View(new_term.lookup_u16_3_counts); \ - [[maybe_unused]] auto lookup_u16_4_counts = View(new_term.lookup_u16_4_counts); \ - [[maybe_unused]] auto lookup_u16_5_counts = View(new_term.lookup_u16_5_counts); \ - [[maybe_unused]] auto lookup_u16_6_counts = View(new_term.lookup_u16_6_counts); \ - [[maybe_unused]] auto lookup_u16_7_counts = View(new_term.lookup_u16_7_counts); \ - [[maybe_unused]] auto lookup_u16_8_counts = View(new_term.lookup_u16_8_counts); \ - [[maybe_unused]] auto lookup_u16_9_counts = View(new_term.lookup_u16_9_counts); \ - [[maybe_unused]] auto lookup_u16_10_counts = View(new_term.lookup_u16_10_counts); \ - [[maybe_unused]] auto lookup_u16_11_counts = View(new_term.lookup_u16_11_counts); \ - [[maybe_unused]] auto lookup_u16_12_counts = View(new_term.lookup_u16_12_counts); \ - [[maybe_unused]] auto lookup_u16_13_counts = View(new_term.lookup_u16_13_counts); \ - [[maybe_unused]] auto lookup_u16_14_counts = View(new_term.lookup_u16_14_counts); \ - [[maybe_unused]] auto lookup_div_u16_0_counts = View(new_term.lookup_div_u16_0_counts); \ - [[maybe_unused]] auto lookup_div_u16_1_counts = View(new_term.lookup_div_u16_1_counts); \ - [[maybe_unused]] auto lookup_div_u16_2_counts = View(new_term.lookup_div_u16_2_counts); \ - [[maybe_unused]] auto lookup_div_u16_3_counts = View(new_term.lookup_div_u16_3_counts); \ - [[maybe_unused]] auto lookup_div_u16_4_counts = View(new_term.lookup_div_u16_4_counts); \ - [[maybe_unused]] auto lookup_div_u16_5_counts = View(new_term.lookup_div_u16_5_counts); \ - [[maybe_unused]] auto lookup_div_u16_6_counts = View(new_term.lookup_div_u16_6_counts); \ - [[maybe_unused]] auto lookup_div_u16_7_counts = View(new_term.lookup_div_u16_7_counts); \ - [[maybe_unused]] auto alu_a_hi_shift = View(new_term.alu_a_hi_shift); \ - [[maybe_unused]] auto alu_a_lo_shift = View(new_term.alu_a_lo_shift); \ - [[maybe_unused]] auto alu_b_hi_shift = View(new_term.alu_b_hi_shift); \ - [[maybe_unused]] auto alu_b_lo_shift = View(new_term.alu_b_lo_shift); \ - [[maybe_unused]] auto alu_cmp_rng_ctr_shift = View(new_term.alu_cmp_rng_ctr_shift); \ - [[maybe_unused]] auto alu_div_u16_r0_shift = View(new_term.alu_div_u16_r0_shift); \ - [[maybe_unused]] auto alu_div_u16_r1_shift = View(new_term.alu_div_u16_r1_shift); \ - [[maybe_unused]] auto alu_div_u16_r2_shift = View(new_term.alu_div_u16_r2_shift); \ - [[maybe_unused]] auto alu_div_u16_r3_shift = View(new_term.alu_div_u16_r3_shift); \ - [[maybe_unused]] auto alu_div_u16_r4_shift = View(new_term.alu_div_u16_r4_shift); \ - [[maybe_unused]] auto alu_div_u16_r5_shift = View(new_term.alu_div_u16_r5_shift); \ - [[maybe_unused]] auto alu_div_u16_r6_shift = View(new_term.alu_div_u16_r6_shift); \ - [[maybe_unused]] auto alu_div_u16_r7_shift = View(new_term.alu_div_u16_r7_shift); \ - [[maybe_unused]] auto alu_op_add_shift = View(new_term.alu_op_add_shift); \ - [[maybe_unused]] auto alu_op_cast_prev_shift = View(new_term.alu_op_cast_prev_shift); \ - [[maybe_unused]] auto alu_op_cast_shift = View(new_term.alu_op_cast_shift); \ - [[maybe_unused]] auto alu_op_div_shift = View(new_term.alu_op_div_shift); \ - [[maybe_unused]] auto alu_op_mul_shift = View(new_term.alu_op_mul_shift); \ - [[maybe_unused]] auto alu_op_shl_shift = View(new_term.alu_op_shl_shift); \ - [[maybe_unused]] auto alu_op_shr_shift = View(new_term.alu_op_shr_shift); \ - [[maybe_unused]] auto alu_op_sub_shift = View(new_term.alu_op_sub_shift); \ - [[maybe_unused]] auto alu_p_sub_a_hi_shift = View(new_term.alu_p_sub_a_hi_shift); \ - [[maybe_unused]] auto alu_p_sub_a_lo_shift = View(new_term.alu_p_sub_a_lo_shift); \ - [[maybe_unused]] auto alu_p_sub_b_hi_shift = View(new_term.alu_p_sub_b_hi_shift); \ - [[maybe_unused]] auto alu_p_sub_b_lo_shift = View(new_term.alu_p_sub_b_lo_shift); \ - [[maybe_unused]] auto alu_sel_alu_shift = View(new_term.alu_sel_alu_shift); \ - [[maybe_unused]] auto alu_sel_cmp_shift = View(new_term.alu_sel_cmp_shift); \ - [[maybe_unused]] auto alu_sel_div_rng_chk_shift = View(new_term.alu_sel_div_rng_chk_shift); \ - [[maybe_unused]] auto alu_sel_rng_chk_lookup_shift = View(new_term.alu_sel_rng_chk_lookup_shift); \ - [[maybe_unused]] auto alu_sel_rng_chk_shift = View(new_term.alu_sel_rng_chk_shift); \ - [[maybe_unused]] auto alu_u16_r0_shift = View(new_term.alu_u16_r0_shift); \ - [[maybe_unused]] auto alu_u16_r1_shift = View(new_term.alu_u16_r1_shift); \ - [[maybe_unused]] auto alu_u16_r2_shift = View(new_term.alu_u16_r2_shift); \ - [[maybe_unused]] auto alu_u16_r3_shift = View(new_term.alu_u16_r3_shift); \ - [[maybe_unused]] auto alu_u16_r4_shift = View(new_term.alu_u16_r4_shift); \ - [[maybe_unused]] auto alu_u16_r5_shift = View(new_term.alu_u16_r5_shift); \ - [[maybe_unused]] auto alu_u16_r6_shift = View(new_term.alu_u16_r6_shift); \ - [[maybe_unused]] auto alu_u8_r0_shift = View(new_term.alu_u8_r0_shift); \ - [[maybe_unused]] auto alu_u8_r1_shift = View(new_term.alu_u8_r1_shift); \ - [[maybe_unused]] auto binary_acc_ia_shift = View(new_term.binary_acc_ia_shift); \ - [[maybe_unused]] auto binary_acc_ib_shift = View(new_term.binary_acc_ib_shift); \ - [[maybe_unused]] auto binary_acc_ic_shift = View(new_term.binary_acc_ic_shift); \ - [[maybe_unused]] auto binary_mem_tag_ctr_shift = View(new_term.binary_mem_tag_ctr_shift); \ - [[maybe_unused]] auto binary_op_id_shift = View(new_term.binary_op_id_shift); \ - [[maybe_unused]] auto kernel_emit_l2_to_l1_msg_write_offset_shift = \ - View(new_term.kernel_emit_l2_to_l1_msg_write_offset_shift); \ - [[maybe_unused]] auto kernel_emit_note_hash_write_offset_shift = \ - View(new_term.kernel_emit_note_hash_write_offset_shift); \ - [[maybe_unused]] auto kernel_emit_nullifier_write_offset_shift = \ - View(new_term.kernel_emit_nullifier_write_offset_shift); \ - [[maybe_unused]] auto kernel_emit_unencrypted_log_write_offset_shift = \ - View(new_term.kernel_emit_unencrypted_log_write_offset_shift); \ - [[maybe_unused]] auto kernel_l1_to_l2_msg_exists_write_offset_shift = \ - View(new_term.kernel_l1_to_l2_msg_exists_write_offset_shift); \ - [[maybe_unused]] auto kernel_note_hash_exist_write_offset_shift = \ - View(new_term.kernel_note_hash_exist_write_offset_shift); \ - [[maybe_unused]] auto kernel_nullifier_exists_write_offset_shift = \ - View(new_term.kernel_nullifier_exists_write_offset_shift); \ - [[maybe_unused]] auto kernel_nullifier_non_exists_write_offset_shift = \ - View(new_term.kernel_nullifier_non_exists_write_offset_shift); \ - [[maybe_unused]] auto kernel_side_effect_counter_shift = View(new_term.kernel_side_effect_counter_shift); \ - [[maybe_unused]] auto kernel_sload_write_offset_shift = View(new_term.kernel_sload_write_offset_shift); \ - [[maybe_unused]] auto kernel_sstore_write_offset_shift = View(new_term.kernel_sstore_write_offset_shift); \ - [[maybe_unused]] auto main_da_gas_remaining_shift = View(new_term.main_da_gas_remaining_shift); \ - [[maybe_unused]] auto main_internal_return_ptr_shift = View(new_term.main_internal_return_ptr_shift); \ - [[maybe_unused]] auto main_l2_gas_remaining_shift = View(new_term.main_l2_gas_remaining_shift); \ - [[maybe_unused]] auto main_pc_shift = View(new_term.main_pc_shift); \ - [[maybe_unused]] auto mem_glob_addr_shift = View(new_term.mem_glob_addr_shift); \ - [[maybe_unused]] auto mem_rw_shift = View(new_term.mem_rw_shift); \ - [[maybe_unused]] auto mem_sel_mem_shift = View(new_term.mem_sel_mem_shift); \ - [[maybe_unused]] auto mem_tag_shift = View(new_term.mem_tag_shift); \ - [[maybe_unused]] auto mem_tsp_shift = View(new_term.mem_tsp_shift); \ - [[maybe_unused]] auto mem_val_shift = View(new_term.mem_val_shift); \ - [[maybe_unused]] auto poseidon2_a_0_shift = View(new_term.poseidon2_a_0_shift); \ - [[maybe_unused]] auto poseidon2_a_1_shift = View(new_term.poseidon2_a_1_shift); \ - [[maybe_unused]] auto poseidon2_a_2_shift = View(new_term.poseidon2_a_2_shift); \ - [[maybe_unused]] auto poseidon2_a_3_shift = View(new_term.poseidon2_a_3_shift); \ - [[maybe_unused]] auto poseidon2_sel_poseidon_perm_shift = View(new_term.poseidon2_sel_poseidon_perm_shift); \ - [[maybe_unused]] auto poseidon2_write_line_shift = View(new_term.poseidon2_write_line_shift); \ - [[maybe_unused]] auto slice_addr_shift = View(new_term.slice_addr_shift); \ - [[maybe_unused]] auto slice_clk_shift = View(new_term.slice_clk_shift); \ - [[maybe_unused]] auto slice_cnt_shift = View(new_term.slice_cnt_shift); \ - [[maybe_unused]] auto slice_col_offset_shift = View(new_term.slice_col_offset_shift); \ - [[maybe_unused]] auto slice_sel_cd_cpy_shift = View(new_term.slice_sel_cd_cpy_shift); \ - [[maybe_unused]] auto slice_sel_mem_active_shift = View(new_term.slice_sel_mem_active_shift); \ - [[maybe_unused]] auto slice_sel_return_shift = View(new_term.slice_sel_return_shift); \ - [[maybe_unused]] auto slice_sel_start_shift = View(new_term.slice_sel_start_shift); \ - [[maybe_unused]] auto slice_space_id_shift = View(new_term.slice_space_id_shift); diff --git a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_a.hpp b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_a.hpp deleted file mode 100644 index 97f82c801940..000000000000 --- a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_a.hpp +++ /dev/null @@ -1,72 +0,0 @@ -#pragma once - -#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" - -#include -#include - -namespace bb { - -class perm_pos_mem_a_permutation_settings { - public: - // This constant defines how many columns are bundled together to form each set. - constexpr static size_t COLUMNS_PER_SET = 7; - - template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) - { - return (in.poseidon2_mem_op == 1 || in.mem_sel_op_gadget_a == 1); - } - - template static inline auto get_const_entities(const AllEntities& in) - { - return std::forward_as_tuple(in.perm_pos_mem_a, - in.poseidon2_mem_op, - in.poseidon2_mem_op, - in.mem_sel_op_gadget_a, - in.poseidon2_clk, - in.main_space_id, - in.poseidon2_mem_addr_a, - in.poseidon2_a_0, - in.poseidon2_write_line, - in.poseidon2_in_tag, - in.poseidon2_in_tag, - in.mem_clk, - in.mem_space_id, - in.mem_addr, - in.mem_val, - in.mem_rw, - in.mem_r_in_tag, - in.mem_w_in_tag); - } - - template static inline auto get_nonconst_entities(AllEntities& in) - { - return std::forward_as_tuple(in.perm_pos_mem_a, - in.poseidon2_mem_op, - in.poseidon2_mem_op, - in.mem_sel_op_gadget_a, - in.poseidon2_clk, - in.main_space_id, - in.poseidon2_mem_addr_a, - in.poseidon2_a_0, - in.poseidon2_write_line, - in.poseidon2_in_tag, - in.poseidon2_in_tag, - in.mem_clk, - in.mem_space_id, - in.mem_addr, - in.mem_val, - in.mem_rw, - in.mem_r_in_tag, - in.mem_w_in_tag); - } -}; - -template -class perm_pos_mem_a_relation : public GenericPermutationRelation { - public: - static constexpr const char* NAME = "PERM_POS_MEM_A"; -}; -template using perm_pos_mem_a = GenericPermutation; - -} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_b.hpp b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_b.hpp deleted file mode 100644 index ae1f5ee18af1..000000000000 --- a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_b.hpp +++ /dev/null @@ -1,72 +0,0 @@ -#pragma once - -#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" - -#include -#include - -namespace bb { - -class perm_pos_mem_b_permutation_settings { - public: - // This constant defines how many columns are bundled together to form each set. - constexpr static size_t COLUMNS_PER_SET = 7; - - template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) - { - return (in.poseidon2_mem_op == 1 || in.mem_sel_op_gadget_b == 1); - } - - template static inline auto get_const_entities(const AllEntities& in) - { - return std::forward_as_tuple(in.perm_pos_mem_b, - in.poseidon2_mem_op, - in.poseidon2_mem_op, - in.mem_sel_op_gadget_b, - in.poseidon2_clk, - in.main_space_id, - in.poseidon2_mem_addr_b, - in.poseidon2_a_1, - in.poseidon2_write_line, - in.poseidon2_in_tag, - in.poseidon2_in_tag, - in.mem_clk, - in.mem_space_id, - in.mem_addr, - in.mem_val, - in.mem_rw, - in.mem_r_in_tag, - in.mem_w_in_tag); - } - - template static inline auto get_nonconst_entities(AllEntities& in) - { - return std::forward_as_tuple(in.perm_pos_mem_b, - in.poseidon2_mem_op, - in.poseidon2_mem_op, - in.mem_sel_op_gadget_b, - in.poseidon2_clk, - in.main_space_id, - in.poseidon2_mem_addr_b, - in.poseidon2_a_1, - in.poseidon2_write_line, - in.poseidon2_in_tag, - in.poseidon2_in_tag, - in.mem_clk, - in.mem_space_id, - in.mem_addr, - in.mem_val, - in.mem_rw, - in.mem_r_in_tag, - in.mem_w_in_tag); - } -}; - -template -class perm_pos_mem_b_relation : public GenericPermutationRelation { - public: - static constexpr const char* NAME = "PERM_POS_MEM_B"; -}; -template using perm_pos_mem_b = GenericPermutation; - -} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_c.hpp b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_c.hpp deleted file mode 100644 index 056b285f7760..000000000000 --- a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_c.hpp +++ /dev/null @@ -1,72 +0,0 @@ -#pragma once - -#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" - -#include -#include - -namespace bb { - -class perm_pos_mem_c_permutation_settings { - public: - // This constant defines how many columns are bundled together to form each set. - constexpr static size_t COLUMNS_PER_SET = 7; - - template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) - { - return (in.poseidon2_mem_op == 1 || in.mem_sel_op_gadget_c == 1); - } - - template static inline auto get_const_entities(const AllEntities& in) - { - return std::forward_as_tuple(in.perm_pos_mem_c, - in.poseidon2_mem_op, - in.poseidon2_mem_op, - in.mem_sel_op_gadget_c, - in.poseidon2_clk, - in.main_space_id, - in.poseidon2_mem_addr_c, - in.poseidon2_a_2, - in.poseidon2_write_line, - in.poseidon2_in_tag, - in.poseidon2_in_tag, - in.mem_clk, - in.mem_space_id, - in.mem_addr, - in.mem_val, - in.mem_rw, - in.mem_r_in_tag, - in.mem_w_in_tag); - } - - template static inline auto get_nonconst_entities(AllEntities& in) - { - return std::forward_as_tuple(in.perm_pos_mem_c, - in.poseidon2_mem_op, - in.poseidon2_mem_op, - in.mem_sel_op_gadget_c, - in.poseidon2_clk, - in.main_space_id, - in.poseidon2_mem_addr_c, - in.poseidon2_a_2, - in.poseidon2_write_line, - in.poseidon2_in_tag, - in.poseidon2_in_tag, - in.mem_clk, - in.mem_space_id, - in.mem_addr, - in.mem_val, - in.mem_rw, - in.mem_r_in_tag, - in.mem_w_in_tag); - } -}; - -template -class perm_pos_mem_c_relation : public GenericPermutationRelation { - public: - static constexpr const char* NAME = "PERM_POS_MEM_C"; -}; -template using perm_pos_mem_c = GenericPermutation; - -} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_d.hpp b/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_d.hpp deleted file mode 100644 index e098501b2a69..000000000000 --- a/barretenberg/cpp/src/barretenberg/relations/generated/avm/perm_pos_mem_d.hpp +++ /dev/null @@ -1,72 +0,0 @@ -#pragma once - -#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" - -#include -#include - -namespace bb { - -class perm_pos_mem_d_permutation_settings { - public: - // This constant defines how many columns are bundled together to form each set. - constexpr static size_t COLUMNS_PER_SET = 7; - - template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) - { - return (in.poseidon2_mem_op == 1 || in.mem_sel_op_gadget_d == 1); - } - - template static inline auto get_const_entities(const AllEntities& in) - { - return std::forward_as_tuple(in.perm_pos_mem_d, - in.poseidon2_mem_op, - in.poseidon2_mem_op, - in.mem_sel_op_gadget_d, - in.poseidon2_clk, - in.main_space_id, - in.poseidon2_mem_addr_d, - in.poseidon2_a_3, - in.poseidon2_write_line, - in.poseidon2_in_tag, - in.poseidon2_in_tag, - in.mem_clk, - in.mem_space_id, - in.mem_addr, - in.mem_val, - in.mem_rw, - in.mem_r_in_tag, - in.mem_w_in_tag); - } - - template static inline auto get_nonconst_entities(AllEntities& in) - { - return std::forward_as_tuple(in.perm_pos_mem_d, - in.poseidon2_mem_op, - in.poseidon2_mem_op, - in.mem_sel_op_gadget_d, - in.poseidon2_clk, - in.main_space_id, - in.poseidon2_mem_addr_d, - in.poseidon2_a_3, - in.poseidon2_write_line, - in.poseidon2_in_tag, - in.poseidon2_in_tag, - in.mem_clk, - in.mem_space_id, - in.mem_addr, - in.mem_val, - in.mem_rw, - in.mem_r_in_tag, - in.mem_w_in_tag); - } -}; - -template -class perm_pos_mem_d_relation : public GenericPermutationRelation { - public: - static constexpr const char* NAME = "PERM_POS_MEM_D"; -}; -template using perm_pos_mem_d = GenericPermutation; - -} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/circuit_builder.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/circuit_builder.cpp index 6a0a47ad19cf..709257a4159a 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/circuit_builder.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/circuit_builder.cpp @@ -26,6 +26,7 @@ AvmCircuitBuilder::ProverPolynomials AvmCircuitBuilder::compute_polynomials() co for (size_t i = 0; i < rows.size(); i++) { polys.main_clk[i] = rows[i].main_clk; polys.main_sel_first[i] = rows[i].main_sel_first; + polys.main_zeroes[i] = rows[i].main_zeroes; polys.kernel_kernel_inputs[i] = rows[i].kernel_kernel_inputs; polys.kernel_kernel_value_out[i] = rows[i].kernel_kernel_value_out; polys.kernel_kernel_side_effect_out[i] = rows[i].kernel_kernel_side_effect_out; @@ -296,6 +297,14 @@ AvmCircuitBuilder::ProverPolynomials AvmCircuitBuilder::compute_polynomials() co polys.mem_sel_op_c[i] = rows[i].mem_sel_op_c; polys.mem_sel_op_cmov[i] = rows[i].mem_sel_op_cmov; polys.mem_sel_op_d[i] = rows[i].mem_sel_op_d; + polys.mem_sel_op_poseidon_read_a[i] = rows[i].mem_sel_op_poseidon_read_a; + polys.mem_sel_op_poseidon_read_b[i] = rows[i].mem_sel_op_poseidon_read_b; + polys.mem_sel_op_poseidon_read_c[i] = rows[i].mem_sel_op_poseidon_read_c; + polys.mem_sel_op_poseidon_read_d[i] = rows[i].mem_sel_op_poseidon_read_d; + polys.mem_sel_op_poseidon_write_a[i] = rows[i].mem_sel_op_poseidon_write_a; + polys.mem_sel_op_poseidon_write_b[i] = rows[i].mem_sel_op_poseidon_write_b; + polys.mem_sel_op_poseidon_write_c[i] = rows[i].mem_sel_op_poseidon_write_c; + polys.mem_sel_op_poseidon_write_d[i] = rows[i].mem_sel_op_poseidon_write_d; polys.mem_sel_op_slice[i] = rows[i].mem_sel_op_slice; polys.mem_sel_resolve_ind_addr_a[i] = rows[i].mem_sel_resolve_ind_addr_a; polys.mem_sel_resolve_ind_addr_b[i] = rows[i].mem_sel_resolve_ind_addr_b; @@ -313,9 +322,285 @@ AvmCircuitBuilder::ProverPolynomials AvmCircuitBuilder::compute_polynomials() co polys.pedersen_input[i] = rows[i].pedersen_input; polys.pedersen_output[i] = rows[i].pedersen_output; polys.pedersen_sel_pedersen[i] = rows[i].pedersen_sel_pedersen; + polys.poseidon2_B_10_0[i] = rows[i].poseidon2_B_10_0; + polys.poseidon2_B_10_1[i] = rows[i].poseidon2_B_10_1; + polys.poseidon2_B_10_2[i] = rows[i].poseidon2_B_10_2; + polys.poseidon2_B_10_3[i] = rows[i].poseidon2_B_10_3; + polys.poseidon2_B_11_0[i] = rows[i].poseidon2_B_11_0; + polys.poseidon2_B_11_1[i] = rows[i].poseidon2_B_11_1; + polys.poseidon2_B_11_2[i] = rows[i].poseidon2_B_11_2; + polys.poseidon2_B_11_3[i] = rows[i].poseidon2_B_11_3; + polys.poseidon2_B_12_0[i] = rows[i].poseidon2_B_12_0; + polys.poseidon2_B_12_1[i] = rows[i].poseidon2_B_12_1; + polys.poseidon2_B_12_2[i] = rows[i].poseidon2_B_12_2; + polys.poseidon2_B_12_3[i] = rows[i].poseidon2_B_12_3; + polys.poseidon2_B_13_0[i] = rows[i].poseidon2_B_13_0; + polys.poseidon2_B_13_1[i] = rows[i].poseidon2_B_13_1; + polys.poseidon2_B_13_2[i] = rows[i].poseidon2_B_13_2; + polys.poseidon2_B_13_3[i] = rows[i].poseidon2_B_13_3; + polys.poseidon2_B_14_0[i] = rows[i].poseidon2_B_14_0; + polys.poseidon2_B_14_1[i] = rows[i].poseidon2_B_14_1; + polys.poseidon2_B_14_2[i] = rows[i].poseidon2_B_14_2; + polys.poseidon2_B_14_3[i] = rows[i].poseidon2_B_14_3; + polys.poseidon2_B_15_0[i] = rows[i].poseidon2_B_15_0; + polys.poseidon2_B_15_1[i] = rows[i].poseidon2_B_15_1; + polys.poseidon2_B_15_2[i] = rows[i].poseidon2_B_15_2; + polys.poseidon2_B_15_3[i] = rows[i].poseidon2_B_15_3; + polys.poseidon2_B_16_0[i] = rows[i].poseidon2_B_16_0; + polys.poseidon2_B_16_1[i] = rows[i].poseidon2_B_16_1; + polys.poseidon2_B_16_2[i] = rows[i].poseidon2_B_16_2; + polys.poseidon2_B_16_3[i] = rows[i].poseidon2_B_16_3; + polys.poseidon2_B_17_0[i] = rows[i].poseidon2_B_17_0; + polys.poseidon2_B_17_1[i] = rows[i].poseidon2_B_17_1; + polys.poseidon2_B_17_2[i] = rows[i].poseidon2_B_17_2; + polys.poseidon2_B_17_3[i] = rows[i].poseidon2_B_17_3; + polys.poseidon2_B_18_0[i] = rows[i].poseidon2_B_18_0; + polys.poseidon2_B_18_1[i] = rows[i].poseidon2_B_18_1; + polys.poseidon2_B_18_2[i] = rows[i].poseidon2_B_18_2; + polys.poseidon2_B_18_3[i] = rows[i].poseidon2_B_18_3; + polys.poseidon2_B_19_0[i] = rows[i].poseidon2_B_19_0; + polys.poseidon2_B_19_1[i] = rows[i].poseidon2_B_19_1; + polys.poseidon2_B_19_2[i] = rows[i].poseidon2_B_19_2; + polys.poseidon2_B_19_3[i] = rows[i].poseidon2_B_19_3; + polys.poseidon2_B_20_0[i] = rows[i].poseidon2_B_20_0; + polys.poseidon2_B_20_1[i] = rows[i].poseidon2_B_20_1; + polys.poseidon2_B_20_2[i] = rows[i].poseidon2_B_20_2; + polys.poseidon2_B_20_3[i] = rows[i].poseidon2_B_20_3; + polys.poseidon2_B_21_0[i] = rows[i].poseidon2_B_21_0; + polys.poseidon2_B_21_1[i] = rows[i].poseidon2_B_21_1; + polys.poseidon2_B_21_2[i] = rows[i].poseidon2_B_21_2; + polys.poseidon2_B_21_3[i] = rows[i].poseidon2_B_21_3; + polys.poseidon2_B_22_0[i] = rows[i].poseidon2_B_22_0; + polys.poseidon2_B_22_1[i] = rows[i].poseidon2_B_22_1; + polys.poseidon2_B_22_2[i] = rows[i].poseidon2_B_22_2; + polys.poseidon2_B_22_3[i] = rows[i].poseidon2_B_22_3; + polys.poseidon2_B_23_0[i] = rows[i].poseidon2_B_23_0; + polys.poseidon2_B_23_1[i] = rows[i].poseidon2_B_23_1; + polys.poseidon2_B_23_2[i] = rows[i].poseidon2_B_23_2; + polys.poseidon2_B_23_3[i] = rows[i].poseidon2_B_23_3; + polys.poseidon2_B_24_0[i] = rows[i].poseidon2_B_24_0; + polys.poseidon2_B_24_1[i] = rows[i].poseidon2_B_24_1; + polys.poseidon2_B_24_2[i] = rows[i].poseidon2_B_24_2; + polys.poseidon2_B_24_3[i] = rows[i].poseidon2_B_24_3; + polys.poseidon2_B_25_0[i] = rows[i].poseidon2_B_25_0; + polys.poseidon2_B_25_1[i] = rows[i].poseidon2_B_25_1; + polys.poseidon2_B_25_2[i] = rows[i].poseidon2_B_25_2; + polys.poseidon2_B_25_3[i] = rows[i].poseidon2_B_25_3; + polys.poseidon2_B_26_0[i] = rows[i].poseidon2_B_26_0; + polys.poseidon2_B_26_1[i] = rows[i].poseidon2_B_26_1; + polys.poseidon2_B_26_2[i] = rows[i].poseidon2_B_26_2; + polys.poseidon2_B_26_3[i] = rows[i].poseidon2_B_26_3; + polys.poseidon2_B_27_0[i] = rows[i].poseidon2_B_27_0; + polys.poseidon2_B_27_1[i] = rows[i].poseidon2_B_27_1; + polys.poseidon2_B_27_2[i] = rows[i].poseidon2_B_27_2; + polys.poseidon2_B_27_3[i] = rows[i].poseidon2_B_27_3; + polys.poseidon2_B_28_0[i] = rows[i].poseidon2_B_28_0; + polys.poseidon2_B_28_1[i] = rows[i].poseidon2_B_28_1; + polys.poseidon2_B_28_2[i] = rows[i].poseidon2_B_28_2; + polys.poseidon2_B_28_3[i] = rows[i].poseidon2_B_28_3; + polys.poseidon2_B_29_0[i] = rows[i].poseidon2_B_29_0; + polys.poseidon2_B_29_1[i] = rows[i].poseidon2_B_29_1; + polys.poseidon2_B_29_2[i] = rows[i].poseidon2_B_29_2; + polys.poseidon2_B_29_3[i] = rows[i].poseidon2_B_29_3; + polys.poseidon2_B_30_0[i] = rows[i].poseidon2_B_30_0; + polys.poseidon2_B_30_1[i] = rows[i].poseidon2_B_30_1; + polys.poseidon2_B_30_2[i] = rows[i].poseidon2_B_30_2; + polys.poseidon2_B_30_3[i] = rows[i].poseidon2_B_30_3; + polys.poseidon2_B_31_0[i] = rows[i].poseidon2_B_31_0; + polys.poseidon2_B_31_1[i] = rows[i].poseidon2_B_31_1; + polys.poseidon2_B_31_2[i] = rows[i].poseidon2_B_31_2; + polys.poseidon2_B_31_3[i] = rows[i].poseidon2_B_31_3; + polys.poseidon2_B_32_0[i] = rows[i].poseidon2_B_32_0; + polys.poseidon2_B_32_1[i] = rows[i].poseidon2_B_32_1; + polys.poseidon2_B_32_2[i] = rows[i].poseidon2_B_32_2; + polys.poseidon2_B_32_3[i] = rows[i].poseidon2_B_32_3; + polys.poseidon2_B_33_0[i] = rows[i].poseidon2_B_33_0; + polys.poseidon2_B_33_1[i] = rows[i].poseidon2_B_33_1; + polys.poseidon2_B_33_2[i] = rows[i].poseidon2_B_33_2; + polys.poseidon2_B_33_3[i] = rows[i].poseidon2_B_33_3; + polys.poseidon2_B_34_0[i] = rows[i].poseidon2_B_34_0; + polys.poseidon2_B_34_1[i] = rows[i].poseidon2_B_34_1; + polys.poseidon2_B_34_2[i] = rows[i].poseidon2_B_34_2; + polys.poseidon2_B_34_3[i] = rows[i].poseidon2_B_34_3; + polys.poseidon2_B_35_0[i] = rows[i].poseidon2_B_35_0; + polys.poseidon2_B_35_1[i] = rows[i].poseidon2_B_35_1; + polys.poseidon2_B_35_2[i] = rows[i].poseidon2_B_35_2; + polys.poseidon2_B_35_3[i] = rows[i].poseidon2_B_35_3; + polys.poseidon2_B_36_0[i] = rows[i].poseidon2_B_36_0; + polys.poseidon2_B_36_1[i] = rows[i].poseidon2_B_36_1; + polys.poseidon2_B_36_2[i] = rows[i].poseidon2_B_36_2; + polys.poseidon2_B_36_3[i] = rows[i].poseidon2_B_36_3; + polys.poseidon2_B_37_0[i] = rows[i].poseidon2_B_37_0; + polys.poseidon2_B_37_1[i] = rows[i].poseidon2_B_37_1; + polys.poseidon2_B_37_2[i] = rows[i].poseidon2_B_37_2; + polys.poseidon2_B_37_3[i] = rows[i].poseidon2_B_37_3; + polys.poseidon2_B_38_0[i] = rows[i].poseidon2_B_38_0; + polys.poseidon2_B_38_1[i] = rows[i].poseidon2_B_38_1; + polys.poseidon2_B_38_2[i] = rows[i].poseidon2_B_38_2; + polys.poseidon2_B_38_3[i] = rows[i].poseidon2_B_38_3; + polys.poseidon2_B_39_0[i] = rows[i].poseidon2_B_39_0; + polys.poseidon2_B_39_1[i] = rows[i].poseidon2_B_39_1; + polys.poseidon2_B_39_2[i] = rows[i].poseidon2_B_39_2; + polys.poseidon2_B_39_3[i] = rows[i].poseidon2_B_39_3; + polys.poseidon2_B_40_0[i] = rows[i].poseidon2_B_40_0; + polys.poseidon2_B_40_1[i] = rows[i].poseidon2_B_40_1; + polys.poseidon2_B_40_2[i] = rows[i].poseidon2_B_40_2; + polys.poseidon2_B_40_3[i] = rows[i].poseidon2_B_40_3; + polys.poseidon2_B_41_0[i] = rows[i].poseidon2_B_41_0; + polys.poseidon2_B_41_1[i] = rows[i].poseidon2_B_41_1; + polys.poseidon2_B_41_2[i] = rows[i].poseidon2_B_41_2; + polys.poseidon2_B_41_3[i] = rows[i].poseidon2_B_41_3; + polys.poseidon2_B_42_0[i] = rows[i].poseidon2_B_42_0; + polys.poseidon2_B_42_1[i] = rows[i].poseidon2_B_42_1; + polys.poseidon2_B_42_2[i] = rows[i].poseidon2_B_42_2; + polys.poseidon2_B_42_3[i] = rows[i].poseidon2_B_42_3; + polys.poseidon2_B_43_0[i] = rows[i].poseidon2_B_43_0; + polys.poseidon2_B_43_1[i] = rows[i].poseidon2_B_43_1; + polys.poseidon2_B_43_2[i] = rows[i].poseidon2_B_43_2; + polys.poseidon2_B_43_3[i] = rows[i].poseidon2_B_43_3; + polys.poseidon2_B_44_0[i] = rows[i].poseidon2_B_44_0; + polys.poseidon2_B_44_1[i] = rows[i].poseidon2_B_44_1; + polys.poseidon2_B_44_2[i] = rows[i].poseidon2_B_44_2; + polys.poseidon2_B_44_3[i] = rows[i].poseidon2_B_44_3; + polys.poseidon2_B_45_0[i] = rows[i].poseidon2_B_45_0; + polys.poseidon2_B_45_1[i] = rows[i].poseidon2_B_45_1; + polys.poseidon2_B_45_2[i] = rows[i].poseidon2_B_45_2; + polys.poseidon2_B_45_3[i] = rows[i].poseidon2_B_45_3; + polys.poseidon2_B_46_0[i] = rows[i].poseidon2_B_46_0; + polys.poseidon2_B_46_1[i] = rows[i].poseidon2_B_46_1; + polys.poseidon2_B_46_2[i] = rows[i].poseidon2_B_46_2; + polys.poseidon2_B_46_3[i] = rows[i].poseidon2_B_46_3; + polys.poseidon2_B_47_0[i] = rows[i].poseidon2_B_47_0; + polys.poseidon2_B_47_1[i] = rows[i].poseidon2_B_47_1; + polys.poseidon2_B_47_2[i] = rows[i].poseidon2_B_47_2; + polys.poseidon2_B_47_3[i] = rows[i].poseidon2_B_47_3; + polys.poseidon2_B_48_0[i] = rows[i].poseidon2_B_48_0; + polys.poseidon2_B_48_1[i] = rows[i].poseidon2_B_48_1; + polys.poseidon2_B_48_2[i] = rows[i].poseidon2_B_48_2; + polys.poseidon2_B_48_3[i] = rows[i].poseidon2_B_48_3; + polys.poseidon2_B_49_0[i] = rows[i].poseidon2_B_49_0; + polys.poseidon2_B_49_1[i] = rows[i].poseidon2_B_49_1; + polys.poseidon2_B_49_2[i] = rows[i].poseidon2_B_49_2; + polys.poseidon2_B_49_3[i] = rows[i].poseidon2_B_49_3; + polys.poseidon2_B_4_0[i] = rows[i].poseidon2_B_4_0; + polys.poseidon2_B_4_1[i] = rows[i].poseidon2_B_4_1; + polys.poseidon2_B_4_2[i] = rows[i].poseidon2_B_4_2; + polys.poseidon2_B_4_3[i] = rows[i].poseidon2_B_4_3; + polys.poseidon2_B_50_0[i] = rows[i].poseidon2_B_50_0; + polys.poseidon2_B_50_1[i] = rows[i].poseidon2_B_50_1; + polys.poseidon2_B_50_2[i] = rows[i].poseidon2_B_50_2; + polys.poseidon2_B_50_3[i] = rows[i].poseidon2_B_50_3; + polys.poseidon2_B_51_0[i] = rows[i].poseidon2_B_51_0; + polys.poseidon2_B_51_1[i] = rows[i].poseidon2_B_51_1; + polys.poseidon2_B_51_2[i] = rows[i].poseidon2_B_51_2; + polys.poseidon2_B_51_3[i] = rows[i].poseidon2_B_51_3; + polys.poseidon2_B_52_0[i] = rows[i].poseidon2_B_52_0; + polys.poseidon2_B_52_1[i] = rows[i].poseidon2_B_52_1; + polys.poseidon2_B_52_2[i] = rows[i].poseidon2_B_52_2; + polys.poseidon2_B_52_3[i] = rows[i].poseidon2_B_52_3; + polys.poseidon2_B_53_0[i] = rows[i].poseidon2_B_53_0; + polys.poseidon2_B_53_1[i] = rows[i].poseidon2_B_53_1; + polys.poseidon2_B_53_2[i] = rows[i].poseidon2_B_53_2; + polys.poseidon2_B_53_3[i] = rows[i].poseidon2_B_53_3; + polys.poseidon2_B_54_0[i] = rows[i].poseidon2_B_54_0; + polys.poseidon2_B_54_1[i] = rows[i].poseidon2_B_54_1; + polys.poseidon2_B_54_2[i] = rows[i].poseidon2_B_54_2; + polys.poseidon2_B_54_3[i] = rows[i].poseidon2_B_54_3; + polys.poseidon2_B_55_0[i] = rows[i].poseidon2_B_55_0; + polys.poseidon2_B_55_1[i] = rows[i].poseidon2_B_55_1; + polys.poseidon2_B_55_2[i] = rows[i].poseidon2_B_55_2; + polys.poseidon2_B_55_3[i] = rows[i].poseidon2_B_55_3; + polys.poseidon2_B_56_0[i] = rows[i].poseidon2_B_56_0; + polys.poseidon2_B_56_1[i] = rows[i].poseidon2_B_56_1; + polys.poseidon2_B_56_2[i] = rows[i].poseidon2_B_56_2; + polys.poseidon2_B_56_3[i] = rows[i].poseidon2_B_56_3; + polys.poseidon2_B_57_0[i] = rows[i].poseidon2_B_57_0; + polys.poseidon2_B_57_1[i] = rows[i].poseidon2_B_57_1; + polys.poseidon2_B_57_2[i] = rows[i].poseidon2_B_57_2; + polys.poseidon2_B_57_3[i] = rows[i].poseidon2_B_57_3; + polys.poseidon2_B_58_0[i] = rows[i].poseidon2_B_58_0; + polys.poseidon2_B_58_1[i] = rows[i].poseidon2_B_58_1; + polys.poseidon2_B_58_2[i] = rows[i].poseidon2_B_58_2; + polys.poseidon2_B_58_3[i] = rows[i].poseidon2_B_58_3; + polys.poseidon2_B_59_0[i] = rows[i].poseidon2_B_59_0; + polys.poseidon2_B_59_1[i] = rows[i].poseidon2_B_59_1; + polys.poseidon2_B_59_2[i] = rows[i].poseidon2_B_59_2; + polys.poseidon2_B_59_3[i] = rows[i].poseidon2_B_59_3; + polys.poseidon2_B_5_0[i] = rows[i].poseidon2_B_5_0; + polys.poseidon2_B_5_1[i] = rows[i].poseidon2_B_5_1; + polys.poseidon2_B_5_2[i] = rows[i].poseidon2_B_5_2; + polys.poseidon2_B_5_3[i] = rows[i].poseidon2_B_5_3; + polys.poseidon2_B_6_0[i] = rows[i].poseidon2_B_6_0; + polys.poseidon2_B_6_1[i] = rows[i].poseidon2_B_6_1; + polys.poseidon2_B_6_2[i] = rows[i].poseidon2_B_6_2; + polys.poseidon2_B_6_3[i] = rows[i].poseidon2_B_6_3; + polys.poseidon2_B_7_0[i] = rows[i].poseidon2_B_7_0; + polys.poseidon2_B_7_1[i] = rows[i].poseidon2_B_7_1; + polys.poseidon2_B_7_2[i] = rows[i].poseidon2_B_7_2; + polys.poseidon2_B_7_3[i] = rows[i].poseidon2_B_7_3; + polys.poseidon2_B_8_0[i] = rows[i].poseidon2_B_8_0; + polys.poseidon2_B_8_1[i] = rows[i].poseidon2_B_8_1; + polys.poseidon2_B_8_2[i] = rows[i].poseidon2_B_8_2; + polys.poseidon2_B_8_3[i] = rows[i].poseidon2_B_8_3; + polys.poseidon2_B_9_0[i] = rows[i].poseidon2_B_9_0; + polys.poseidon2_B_9_1[i] = rows[i].poseidon2_B_9_1; + polys.poseidon2_B_9_2[i] = rows[i].poseidon2_B_9_2; + polys.poseidon2_B_9_3[i] = rows[i].poseidon2_B_9_3; + polys.poseidon2_EXT_LAYER_4[i] = rows[i].poseidon2_EXT_LAYER_4; + polys.poseidon2_EXT_LAYER_5[i] = rows[i].poseidon2_EXT_LAYER_5; + polys.poseidon2_EXT_LAYER_6[i] = rows[i].poseidon2_EXT_LAYER_6; + polys.poseidon2_EXT_LAYER_7[i] = rows[i].poseidon2_EXT_LAYER_7; + polys.poseidon2_T_0_4[i] = rows[i].poseidon2_T_0_4; + polys.poseidon2_T_0_5[i] = rows[i].poseidon2_T_0_5; + polys.poseidon2_T_0_6[i] = rows[i].poseidon2_T_0_6; + polys.poseidon2_T_0_7[i] = rows[i].poseidon2_T_0_7; + polys.poseidon2_T_1_4[i] = rows[i].poseidon2_T_1_4; + polys.poseidon2_T_1_5[i] = rows[i].poseidon2_T_1_5; + polys.poseidon2_T_1_6[i] = rows[i].poseidon2_T_1_6; + polys.poseidon2_T_1_7[i] = rows[i].poseidon2_T_1_7; + polys.poseidon2_T_2_4[i] = rows[i].poseidon2_T_2_4; + polys.poseidon2_T_2_5[i] = rows[i].poseidon2_T_2_5; + polys.poseidon2_T_2_6[i] = rows[i].poseidon2_T_2_6; + polys.poseidon2_T_2_7[i] = rows[i].poseidon2_T_2_7; + polys.poseidon2_T_3_4[i] = rows[i].poseidon2_T_3_4; + polys.poseidon2_T_3_5[i] = rows[i].poseidon2_T_3_5; + polys.poseidon2_T_3_6[i] = rows[i].poseidon2_T_3_6; + polys.poseidon2_T_3_7[i] = rows[i].poseidon2_T_3_7; + polys.poseidon2_T_60_4[i] = rows[i].poseidon2_T_60_4; + polys.poseidon2_T_60_5[i] = rows[i].poseidon2_T_60_5; + polys.poseidon2_T_60_6[i] = rows[i].poseidon2_T_60_6; + polys.poseidon2_T_60_7[i] = rows[i].poseidon2_T_60_7; + polys.poseidon2_T_61_4[i] = rows[i].poseidon2_T_61_4; + polys.poseidon2_T_61_5[i] = rows[i].poseidon2_T_61_5; + polys.poseidon2_T_61_6[i] = rows[i].poseidon2_T_61_6; + polys.poseidon2_T_61_7[i] = rows[i].poseidon2_T_61_7; + polys.poseidon2_T_62_4[i] = rows[i].poseidon2_T_62_4; + polys.poseidon2_T_62_5[i] = rows[i].poseidon2_T_62_5; + polys.poseidon2_T_62_6[i] = rows[i].poseidon2_T_62_6; + polys.poseidon2_T_62_7[i] = rows[i].poseidon2_T_62_7; + polys.poseidon2_T_63_4[i] = rows[i].poseidon2_T_63_4; + polys.poseidon2_T_63_5[i] = rows[i].poseidon2_T_63_5; + polys.poseidon2_T_63_6[i] = rows[i].poseidon2_T_63_6; + polys.poseidon2_T_63_7[i] = rows[i].poseidon2_T_63_7; + polys.poseidon2_a_0[i] = rows[i].poseidon2_a_0; + polys.poseidon2_a_1[i] = rows[i].poseidon2_a_1; + polys.poseidon2_a_2[i] = rows[i].poseidon2_a_2; + polys.poseidon2_a_3[i] = rows[i].poseidon2_a_3; + polys.poseidon2_b_0[i] = rows[i].poseidon2_b_0; + polys.poseidon2_b_1[i] = rows[i].poseidon2_b_1; + polys.poseidon2_b_2[i] = rows[i].poseidon2_b_2; + polys.poseidon2_b_3[i] = rows[i].poseidon2_b_3; polys.poseidon2_clk[i] = rows[i].poseidon2_clk; - polys.poseidon2_input[i] = rows[i].poseidon2_input; - polys.poseidon2_output[i] = rows[i].poseidon2_output; + polys.poseidon2_input_addr[i] = rows[i].poseidon2_input_addr; + polys.poseidon2_mem_addr_read_a[i] = rows[i].poseidon2_mem_addr_read_a; + polys.poseidon2_mem_addr_read_b[i] = rows[i].poseidon2_mem_addr_read_b; + polys.poseidon2_mem_addr_read_c[i] = rows[i].poseidon2_mem_addr_read_c; + polys.poseidon2_mem_addr_read_d[i] = rows[i].poseidon2_mem_addr_read_d; + polys.poseidon2_mem_addr_write_a[i] = rows[i].poseidon2_mem_addr_write_a; + polys.poseidon2_mem_addr_write_b[i] = rows[i].poseidon2_mem_addr_write_b; + polys.poseidon2_mem_addr_write_c[i] = rows[i].poseidon2_mem_addr_write_c; + polys.poseidon2_mem_addr_write_d[i] = rows[i].poseidon2_mem_addr_write_d; + polys.poseidon2_output_addr[i] = rows[i].poseidon2_output_addr; polys.poseidon2_sel_poseidon_perm[i] = rows[i].poseidon2_sel_poseidon_perm; polys.powers_power_of_2[i] = rows[i].powers_power_of_2; polys.sha256_clk[i] = rows[i].sha256_clk; diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/circuit_builder.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/circuit_builder.hpp index cc5b29b4fc45..0f5cf53fb5d1 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/circuit_builder.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/circuit_builder.hpp @@ -20,8 +20,8 @@ class AvmCircuitBuilder { using Polynomial = Flavor::Polynomial; using ProverPolynomials = Flavor::ProverPolynomials; - static constexpr size_t num_fixed_columns = 411; - static constexpr size_t num_polys = 411 + 74; + static constexpr size_t num_fixed_columns = 704; + static constexpr size_t num_polys = 704 + 74; std::vector rows; void set_trace(std::vector&& trace) { rows = std::move(trace); } diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/flavor.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/flavor.cpp index 9868f8db2bb1..6b4758f47b24 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/flavor.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/flavor.cpp @@ -7,489 +7,782 @@ AvmFlavor::AllConstRefValues::AllConstRefValues( const RefArray& il) : main_clk(il[0]) , main_sel_first(il[1]) - , kernel_kernel_inputs(il[2]) - , kernel_kernel_value_out(il[3]) - , kernel_kernel_side_effect_out(il[4]) - , kernel_kernel_metadata_out(il[5]) - , main_calldata(il[6]) - , main_returndata(il[7]) - , alu_a_hi(il[8]) - , alu_a_lo(il[9]) - , alu_b_hi(il[10]) - , alu_b_lo(il[11]) - , alu_borrow(il[12]) - , alu_cf(il[13]) - , alu_clk(il[14]) - , alu_cmp_rng_ctr(il[15]) - , alu_div_u16_r0(il[16]) - , alu_div_u16_r1(il[17]) - , alu_div_u16_r2(il[18]) - , alu_div_u16_r3(il[19]) - , alu_div_u16_r4(il[20]) - , alu_div_u16_r5(il[21]) - , alu_div_u16_r6(il[22]) - , alu_div_u16_r7(il[23]) - , alu_divisor_hi(il[24]) - , alu_divisor_lo(il[25]) - , alu_ff_tag(il[26]) - , alu_ia(il[27]) - , alu_ib(il[28]) - , alu_ic(il[29]) - , alu_in_tag(il[30]) - , alu_op_add(il[31]) - , alu_op_cast(il[32]) - , alu_op_cast_prev(il[33]) - , alu_op_div(il[34]) - , alu_op_div_a_lt_b(il[35]) - , alu_op_div_std(il[36]) - , alu_op_eq(il[37]) - , alu_op_eq_diff_inv(il[38]) - , alu_op_lt(il[39]) - , alu_op_lte(il[40]) - , alu_op_mul(il[41]) - , alu_op_not(il[42]) - , alu_op_shl(il[43]) - , alu_op_shr(il[44]) - , alu_op_sub(il[45]) - , alu_p_a_borrow(il[46]) - , alu_p_b_borrow(il[47]) - , alu_p_sub_a_hi(il[48]) - , alu_p_sub_a_lo(il[49]) - , alu_p_sub_b_hi(il[50]) - , alu_p_sub_b_lo(il[51]) - , alu_partial_prod_hi(il[52]) - , alu_partial_prod_lo(il[53]) - , alu_quotient_hi(il[54]) - , alu_quotient_lo(il[55]) - , alu_remainder(il[56]) - , alu_res_hi(il[57]) - , alu_res_lo(il[58]) - , alu_sel_alu(il[59]) - , alu_sel_cmp(il[60]) - , alu_sel_div_rng_chk(il[61]) - , alu_sel_rng_chk(il[62]) - , alu_sel_rng_chk_lookup(il[63]) - , alu_sel_shift_which(il[64]) - , alu_shift_lt_bit_len(il[65]) - , alu_t_sub_s_bits(il[66]) - , alu_two_pow_s(il[67]) - , alu_two_pow_t_sub_s(il[68]) - , alu_u128_tag(il[69]) - , alu_u16_r0(il[70]) - , alu_u16_r1(il[71]) - , alu_u16_r10(il[72]) - , alu_u16_r11(il[73]) - , alu_u16_r12(il[74]) - , alu_u16_r13(il[75]) - , alu_u16_r14(il[76]) - , alu_u16_r2(il[77]) - , alu_u16_r3(il[78]) - , alu_u16_r4(il[79]) - , alu_u16_r5(il[80]) - , alu_u16_r6(il[81]) - , alu_u16_r7(il[82]) - , alu_u16_r8(il[83]) - , alu_u16_r9(il[84]) - , alu_u16_tag(il[85]) - , alu_u32_tag(il[86]) - , alu_u64_tag(il[87]) - , alu_u8_r0(il[88]) - , alu_u8_r1(il[89]) - , alu_u8_tag(il[90]) - , binary_acc_ia(il[91]) - , binary_acc_ib(il[92]) - , binary_acc_ic(il[93]) - , binary_clk(il[94]) - , binary_ia_bytes(il[95]) - , binary_ib_bytes(il[96]) - , binary_ic_bytes(il[97]) - , binary_in_tag(il[98]) - , binary_mem_tag_ctr(il[99]) - , binary_mem_tag_ctr_inv(il[100]) - , binary_op_id(il[101]) - , binary_sel_bin(il[102]) - , binary_start(il[103]) - , byte_lookup_sel_bin(il[104]) - , byte_lookup_table_byte_lengths(il[105]) - , byte_lookup_table_in_tags(il[106]) - , byte_lookup_table_input_a(il[107]) - , byte_lookup_table_input_b(il[108]) - , byte_lookup_table_op_id(il[109]) - , byte_lookup_table_output(il[110]) - , conversion_clk(il[111]) - , conversion_input(il[112]) - , conversion_num_limbs(il[113]) - , conversion_radix(il[114]) - , conversion_sel_to_radix_le(il[115]) - , gas_da_gas_fixed_table(il[116]) - , gas_l2_gas_fixed_table(il[117]) - , gas_sel_gas_cost(il[118]) - , keccakf1600_clk(il[119]) - , keccakf1600_input(il[120]) - , keccakf1600_output(il[121]) - , keccakf1600_sel_keccakf1600(il[122]) - , kernel_emit_l2_to_l1_msg_write_offset(il[123]) - , kernel_emit_note_hash_write_offset(il[124]) - , kernel_emit_nullifier_write_offset(il[125]) - , kernel_emit_unencrypted_log_write_offset(il[126]) - , kernel_kernel_in_offset(il[127]) - , kernel_kernel_out_offset(il[128]) - , kernel_l1_to_l2_msg_exists_write_offset(il[129]) - , kernel_note_hash_exist_write_offset(il[130]) - , kernel_nullifier_exists_write_offset(il[131]) - , kernel_nullifier_non_exists_write_offset(il[132]) - , kernel_q_public_input_kernel_add_to_table(il[133]) - , kernel_q_public_input_kernel_out_add_to_table(il[134]) - , kernel_side_effect_counter(il[135]) - , kernel_sload_write_offset(il[136]) - , kernel_sstore_write_offset(il[137]) - , main_abs_da_rem_gas_hi(il[138]) - , main_abs_da_rem_gas_lo(il[139]) - , main_abs_l2_rem_gas_hi(il[140]) - , main_abs_l2_rem_gas_lo(il[141]) - , main_alu_in_tag(il[142]) - , main_bin_op_id(il[143]) - , main_call_ptr(il[144]) - , main_da_gas_op_cost(il[145]) - , main_da_gas_remaining(il[146]) - , main_da_out_of_gas(il[147]) - , main_ia(il[148]) - , main_ib(il[149]) - , main_ic(il[150]) - , main_id(il[151]) - , main_id_zero(il[152]) - , main_ind_addr_a(il[153]) - , main_ind_addr_b(il[154]) - , main_ind_addr_c(il[155]) - , main_ind_addr_d(il[156]) - , main_internal_return_ptr(il[157]) - , main_inv(il[158]) - , main_l2_gas_op_cost(il[159]) - , main_l2_gas_remaining(il[160]) - , main_l2_out_of_gas(il[161]) - , main_mem_addr_a(il[162]) - , main_mem_addr_b(il[163]) - , main_mem_addr_c(il[164]) - , main_mem_addr_d(il[165]) - , main_op_err(il[166]) - , main_opcode_val(il[167]) - , main_pc(il[168]) - , main_r_in_tag(il[169]) - , main_rwa(il[170]) - , main_rwb(il[171]) - , main_rwc(il[172]) - , main_rwd(il[173]) - , main_sel_alu(il[174]) - , main_sel_bin(il[175]) - , main_sel_calldata(il[176]) - , main_sel_gas_accounting_active(il[177]) - , main_sel_last(il[178]) - , main_sel_mem_op_a(il[179]) - , main_sel_mem_op_activate_gas(il[180]) - , main_sel_mem_op_b(il[181]) - , main_sel_mem_op_c(il[182]) - , main_sel_mem_op_d(il[183]) - , main_sel_mov_ia_to_ic(il[184]) - , main_sel_mov_ib_to_ic(il[185]) - , main_sel_op_add(il[186]) - , main_sel_op_address(il[187]) - , main_sel_op_and(il[188]) - , main_sel_op_block_number(il[189]) - , main_sel_op_calldata_copy(il[190]) - , main_sel_op_cast(il[191]) - , main_sel_op_chain_id(il[192]) - , main_sel_op_cmov(il[193]) - , main_sel_op_coinbase(il[194]) - , main_sel_op_dagasleft(il[195]) - , main_sel_op_div(il[196]) - , main_sel_op_emit_l2_to_l1_msg(il[197]) - , main_sel_op_emit_note_hash(il[198]) - , main_sel_op_emit_nullifier(il[199]) - , main_sel_op_emit_unencrypted_log(il[200]) - , main_sel_op_eq(il[201]) - , main_sel_op_external_call(il[202]) - , main_sel_op_external_return(il[203]) - , main_sel_op_fdiv(il[204]) - , main_sel_op_fee_per_da_gas(il[205]) - , main_sel_op_fee_per_l2_gas(il[206]) - , main_sel_op_function_selector(il[207]) - , main_sel_op_get_contract_instance(il[208]) - , main_sel_op_halt(il[209]) - , main_sel_op_internal_call(il[210]) - , main_sel_op_internal_return(il[211]) - , main_sel_op_jump(il[212]) - , main_sel_op_jumpi(il[213]) - , main_sel_op_keccak(il[214]) - , main_sel_op_l1_to_l2_msg_exists(il[215]) - , main_sel_op_l2gasleft(il[216]) - , main_sel_op_lt(il[217]) - , main_sel_op_lte(il[218]) - , main_sel_op_mov(il[219]) - , main_sel_op_mul(il[220]) - , main_sel_op_not(il[221]) - , main_sel_op_note_hash_exists(il[222]) - , main_sel_op_nullifier_exists(il[223]) - , main_sel_op_or(il[224]) - , main_sel_op_pedersen(il[225]) - , main_sel_op_poseidon2(il[226]) - , main_sel_op_radix_le(il[227]) - , main_sel_op_sender(il[228]) - , main_sel_op_sha256(il[229]) - , main_sel_op_shl(il[230]) - , main_sel_op_shr(il[231]) - , main_sel_op_sload(il[232]) - , main_sel_op_sstore(il[233]) - , main_sel_op_storage_address(il[234]) - , main_sel_op_sub(il[235]) - , main_sel_op_timestamp(il[236]) - , main_sel_op_transaction_fee(il[237]) - , main_sel_op_version(il[238]) - , main_sel_op_xor(il[239]) - , main_sel_q_kernel_lookup(il[240]) - , main_sel_q_kernel_output_lookup(il[241]) - , main_sel_resolve_ind_addr_a(il[242]) - , main_sel_resolve_ind_addr_b(il[243]) - , main_sel_resolve_ind_addr_c(il[244]) - , main_sel_resolve_ind_addr_d(il[245]) - , main_sel_returndata(il[246]) - , main_sel_rng_16(il[247]) - , main_sel_rng_8(il[248]) - , main_sel_slice_gadget(il[249]) - , main_space_id(il[250]) - , main_tag_err(il[251]) - , main_w_in_tag(il[252]) - , mem_addr(il[253]) - , mem_clk(il[254]) - , mem_diff_hi(il[255]) - , mem_diff_lo(il[256]) - , mem_diff_mid(il[257]) - , mem_glob_addr(il[258]) - , mem_last(il[259]) - , mem_lastAccess(il[260]) - , mem_one_min_inv(il[261]) - , mem_r_in_tag(il[262]) - , mem_rw(il[263]) - , mem_sel_mem(il[264]) - , mem_sel_mov_ia_to_ic(il[265]) - , mem_sel_mov_ib_to_ic(il[266]) - , mem_sel_op_a(il[267]) - , mem_sel_op_b(il[268]) - , mem_sel_op_c(il[269]) - , mem_sel_op_cmov(il[270]) - , mem_sel_op_d(il[271]) - , mem_sel_op_slice(il[272]) - , mem_sel_resolve_ind_addr_a(il[273]) - , mem_sel_resolve_ind_addr_b(il[274]) - , mem_sel_resolve_ind_addr_c(il[275]) - , mem_sel_resolve_ind_addr_d(il[276]) - , mem_sel_rng_chk(il[277]) - , mem_skip_check_tag(il[278]) - , mem_space_id(il[279]) - , mem_tag(il[280]) - , mem_tag_err(il[281]) - , mem_tsp(il[282]) - , mem_val(il[283]) - , mem_w_in_tag(il[284]) - , pedersen_clk(il[285]) - , pedersen_input(il[286]) - , pedersen_output(il[287]) - , pedersen_sel_pedersen(il[288]) - , poseidon2_clk(il[289]) - , poseidon2_input(il[290]) - , poseidon2_output(il[291]) - , poseidon2_sel_poseidon_perm(il[292]) - , powers_power_of_2(il[293]) - , sha256_clk(il[294]) - , sha256_input(il[295]) - , sha256_output(il[296]) - , sha256_sel_sha256_compression(il[297]) - , sha256_state(il[298]) - , slice_addr(il[299]) - , slice_clk(il[300]) - , slice_cnt(il[301]) - , slice_col_offset(il[302]) - , slice_one_min_inv(il[303]) - , slice_sel_cd_cpy(il[304]) - , slice_sel_mem_active(il[305]) - , slice_sel_return(il[306]) - , slice_sel_start(il[307]) - , slice_space_id(il[308]) - , slice_val(il[309]) - , lookup_byte_lengths_counts(il[310]) - , lookup_byte_operations_counts(il[311]) - , lookup_cd_value_counts(il[312]) - , lookup_ret_value_counts(il[313]) - , lookup_opcode_gas_counts(il[314]) - , range_check_l2_gas_hi_counts(il[315]) - , range_check_l2_gas_lo_counts(il[316]) - , range_check_da_gas_hi_counts(il[317]) - , range_check_da_gas_lo_counts(il[318]) - , kernel_output_lookup_counts(il[319]) - , lookup_into_kernel_counts(il[320]) - , incl_main_tag_err_counts(il[321]) - , incl_mem_tag_err_counts(il[322]) - , lookup_mem_rng_chk_lo_counts(il[323]) - , lookup_mem_rng_chk_mid_counts(il[324]) - , lookup_mem_rng_chk_hi_counts(il[325]) - , lookup_pow_2_0_counts(il[326]) - , lookup_pow_2_1_counts(il[327]) - , lookup_u8_0_counts(il[328]) - , lookup_u8_1_counts(il[329]) - , lookup_u16_0_counts(il[330]) - , lookup_u16_1_counts(il[331]) - , lookup_u16_2_counts(il[332]) - , lookup_u16_3_counts(il[333]) - , lookup_u16_4_counts(il[334]) - , lookup_u16_5_counts(il[335]) - , lookup_u16_6_counts(il[336]) - , lookup_u16_7_counts(il[337]) - , lookup_u16_8_counts(il[338]) - , lookup_u16_9_counts(il[339]) - , lookup_u16_10_counts(il[340]) - , lookup_u16_11_counts(il[341]) - , lookup_u16_12_counts(il[342]) - , lookup_u16_13_counts(il[343]) - , lookup_u16_14_counts(il[344]) - , lookup_div_u16_0_counts(il[345]) - , lookup_div_u16_1_counts(il[346]) - , lookup_div_u16_2_counts(il[347]) - , lookup_div_u16_3_counts(il[348]) - , lookup_div_u16_4_counts(il[349]) - , lookup_div_u16_5_counts(il[350]) - , lookup_div_u16_6_counts(il[351]) - , lookup_div_u16_7_counts(il[352]) - , perm_slice_mem(il[353]) - , perm_main_alu(il[354]) - , perm_main_bin(il[355]) - , perm_main_conv(il[356]) - , perm_main_pos2_perm(il[357]) - , perm_main_pedersen(il[358]) - , perm_main_slice(il[359]) - , perm_main_mem_a(il[360]) - , perm_main_mem_b(il[361]) - , perm_main_mem_c(il[362]) - , perm_main_mem_d(il[363]) - , perm_main_mem_ind_addr_a(il[364]) - , perm_main_mem_ind_addr_b(il[365]) - , perm_main_mem_ind_addr_c(il[366]) - , perm_main_mem_ind_addr_d(il[367]) - , lookup_byte_lengths(il[368]) - , lookup_byte_operations(il[369]) - , lookup_cd_value(il[370]) - , lookup_ret_value(il[371]) - , lookup_opcode_gas(il[372]) - , range_check_l2_gas_hi(il[373]) - , range_check_l2_gas_lo(il[374]) - , range_check_da_gas_hi(il[375]) - , range_check_da_gas_lo(il[376]) - , kernel_output_lookup(il[377]) - , lookup_into_kernel(il[378]) - , incl_main_tag_err(il[379]) - , incl_mem_tag_err(il[380]) - , lookup_mem_rng_chk_lo(il[381]) - , lookup_mem_rng_chk_mid(il[382]) - , lookup_mem_rng_chk_hi(il[383]) - , lookup_pow_2_0(il[384]) - , lookup_pow_2_1(il[385]) - , lookup_u8_0(il[386]) - , lookup_u8_1(il[387]) - , lookup_u16_0(il[388]) - , lookup_u16_1(il[389]) - , lookup_u16_2(il[390]) - , lookup_u16_3(il[391]) - , lookup_u16_4(il[392]) - , lookup_u16_5(il[393]) - , lookup_u16_6(il[394]) - , lookup_u16_7(il[395]) - , lookup_u16_8(il[396]) - , lookup_u16_9(il[397]) - , lookup_u16_10(il[398]) - , lookup_u16_11(il[399]) - , lookup_u16_12(il[400]) - , lookup_u16_13(il[401]) - , lookup_u16_14(il[402]) - , lookup_div_u16_0(il[403]) - , lookup_div_u16_1(il[404]) - , lookup_div_u16_2(il[405]) - , lookup_div_u16_3(il[406]) - , lookup_div_u16_4(il[407]) - , lookup_div_u16_5(il[408]) - , lookup_div_u16_6(il[409]) - , lookup_div_u16_7(il[410]) - , alu_a_hi_shift(il[411]) - , alu_a_lo_shift(il[412]) - , alu_b_hi_shift(il[413]) - , alu_b_lo_shift(il[414]) - , alu_cmp_rng_ctr_shift(il[415]) - , alu_div_u16_r0_shift(il[416]) - , alu_div_u16_r1_shift(il[417]) - , alu_div_u16_r2_shift(il[418]) - , alu_div_u16_r3_shift(il[419]) - , alu_div_u16_r4_shift(il[420]) - , alu_div_u16_r5_shift(il[421]) - , alu_div_u16_r6_shift(il[422]) - , alu_div_u16_r7_shift(il[423]) - , alu_op_add_shift(il[424]) - , alu_op_cast_prev_shift(il[425]) - , alu_op_cast_shift(il[426]) - , alu_op_div_shift(il[427]) - , alu_op_mul_shift(il[428]) - , alu_op_shl_shift(il[429]) - , alu_op_shr_shift(il[430]) - , alu_op_sub_shift(il[431]) - , alu_p_sub_a_hi_shift(il[432]) - , alu_p_sub_a_lo_shift(il[433]) - , alu_p_sub_b_hi_shift(il[434]) - , alu_p_sub_b_lo_shift(il[435]) - , alu_sel_alu_shift(il[436]) - , alu_sel_cmp_shift(il[437]) - , alu_sel_div_rng_chk_shift(il[438]) - , alu_sel_rng_chk_lookup_shift(il[439]) - , alu_sel_rng_chk_shift(il[440]) - , alu_u16_r0_shift(il[441]) - , alu_u16_r1_shift(il[442]) - , alu_u16_r2_shift(il[443]) - , alu_u16_r3_shift(il[444]) - , alu_u16_r4_shift(il[445]) - , alu_u16_r5_shift(il[446]) - , alu_u16_r6_shift(il[447]) - , alu_u8_r0_shift(il[448]) - , alu_u8_r1_shift(il[449]) - , binary_acc_ia_shift(il[450]) - , binary_acc_ib_shift(il[451]) - , binary_acc_ic_shift(il[452]) - , binary_mem_tag_ctr_shift(il[453]) - , binary_op_id_shift(il[454]) - , kernel_emit_l2_to_l1_msg_write_offset_shift(il[455]) - , kernel_emit_note_hash_write_offset_shift(il[456]) - , kernel_emit_nullifier_write_offset_shift(il[457]) - , kernel_emit_unencrypted_log_write_offset_shift(il[458]) - , kernel_l1_to_l2_msg_exists_write_offset_shift(il[459]) - , kernel_note_hash_exist_write_offset_shift(il[460]) - , kernel_nullifier_exists_write_offset_shift(il[461]) - , kernel_nullifier_non_exists_write_offset_shift(il[462]) - , kernel_side_effect_counter_shift(il[463]) - , kernel_sload_write_offset_shift(il[464]) - , kernel_sstore_write_offset_shift(il[465]) - , main_da_gas_remaining_shift(il[466]) - , main_internal_return_ptr_shift(il[467]) - , main_l2_gas_remaining_shift(il[468]) - , main_pc_shift(il[469]) - , mem_glob_addr_shift(il[470]) - , mem_rw_shift(il[471]) - , mem_sel_mem_shift(il[472]) - , mem_tag_shift(il[473]) - , mem_tsp_shift(il[474]) - , mem_val_shift(il[475]) - , slice_addr_shift(il[476]) - , slice_clk_shift(il[477]) - , slice_cnt_shift(il[478]) - , slice_col_offset_shift(il[479]) - , slice_sel_cd_cpy_shift(il[480]) - , slice_sel_mem_active_shift(il[481]) - , slice_sel_return_shift(il[482]) - , slice_sel_start_shift(il[483]) - , slice_space_id_shift(il[484]) + , main_zeroes(il[2]) + , kernel_kernel_inputs(il[3]) + , kernel_kernel_value_out(il[4]) + , kernel_kernel_side_effect_out(il[5]) + , kernel_kernel_metadata_out(il[6]) + , main_calldata(il[7]) + , main_returndata(il[8]) + , alu_a_hi(il[9]) + , alu_a_lo(il[10]) + , alu_b_hi(il[11]) + , alu_b_lo(il[12]) + , alu_borrow(il[13]) + , alu_cf(il[14]) + , alu_clk(il[15]) + , alu_cmp_rng_ctr(il[16]) + , alu_div_u16_r0(il[17]) + , alu_div_u16_r1(il[18]) + , alu_div_u16_r2(il[19]) + , alu_div_u16_r3(il[20]) + , alu_div_u16_r4(il[21]) + , alu_div_u16_r5(il[22]) + , alu_div_u16_r6(il[23]) + , alu_div_u16_r7(il[24]) + , alu_divisor_hi(il[25]) + , alu_divisor_lo(il[26]) + , alu_ff_tag(il[27]) + , alu_ia(il[28]) + , alu_ib(il[29]) + , alu_ic(il[30]) + , alu_in_tag(il[31]) + , alu_op_add(il[32]) + , alu_op_cast(il[33]) + , alu_op_cast_prev(il[34]) + , alu_op_div(il[35]) + , alu_op_div_a_lt_b(il[36]) + , alu_op_div_std(il[37]) + , alu_op_eq(il[38]) + , alu_op_eq_diff_inv(il[39]) + , alu_op_lt(il[40]) + , alu_op_lte(il[41]) + , alu_op_mul(il[42]) + , alu_op_not(il[43]) + , alu_op_shl(il[44]) + , alu_op_shr(il[45]) + , alu_op_sub(il[46]) + , alu_p_a_borrow(il[47]) + , alu_p_b_borrow(il[48]) + , alu_p_sub_a_hi(il[49]) + , alu_p_sub_a_lo(il[50]) + , alu_p_sub_b_hi(il[51]) + , alu_p_sub_b_lo(il[52]) + , alu_partial_prod_hi(il[53]) + , alu_partial_prod_lo(il[54]) + , alu_quotient_hi(il[55]) + , alu_quotient_lo(il[56]) + , alu_remainder(il[57]) + , alu_res_hi(il[58]) + , alu_res_lo(il[59]) + , alu_sel_alu(il[60]) + , alu_sel_cmp(il[61]) + , alu_sel_div_rng_chk(il[62]) + , alu_sel_rng_chk(il[63]) + , alu_sel_rng_chk_lookup(il[64]) + , alu_sel_shift_which(il[65]) + , alu_shift_lt_bit_len(il[66]) + , alu_t_sub_s_bits(il[67]) + , alu_two_pow_s(il[68]) + , alu_two_pow_t_sub_s(il[69]) + , alu_u128_tag(il[70]) + , alu_u16_r0(il[71]) + , alu_u16_r1(il[72]) + , alu_u16_r10(il[73]) + , alu_u16_r11(il[74]) + , alu_u16_r12(il[75]) + , alu_u16_r13(il[76]) + , alu_u16_r14(il[77]) + , alu_u16_r2(il[78]) + , alu_u16_r3(il[79]) + , alu_u16_r4(il[80]) + , alu_u16_r5(il[81]) + , alu_u16_r6(il[82]) + , alu_u16_r7(il[83]) + , alu_u16_r8(il[84]) + , alu_u16_r9(il[85]) + , alu_u16_tag(il[86]) + , alu_u32_tag(il[87]) + , alu_u64_tag(il[88]) + , alu_u8_r0(il[89]) + , alu_u8_r1(il[90]) + , alu_u8_tag(il[91]) + , binary_acc_ia(il[92]) + , binary_acc_ib(il[93]) + , binary_acc_ic(il[94]) + , binary_clk(il[95]) + , binary_ia_bytes(il[96]) + , binary_ib_bytes(il[97]) + , binary_ic_bytes(il[98]) + , binary_in_tag(il[99]) + , binary_mem_tag_ctr(il[100]) + , binary_mem_tag_ctr_inv(il[101]) + , binary_op_id(il[102]) + , binary_sel_bin(il[103]) + , binary_start(il[104]) + , byte_lookup_sel_bin(il[105]) + , byte_lookup_table_byte_lengths(il[106]) + , byte_lookup_table_in_tags(il[107]) + , byte_lookup_table_input_a(il[108]) + , byte_lookup_table_input_b(il[109]) + , byte_lookup_table_op_id(il[110]) + , byte_lookup_table_output(il[111]) + , conversion_clk(il[112]) + , conversion_input(il[113]) + , conversion_num_limbs(il[114]) + , conversion_radix(il[115]) + , conversion_sel_to_radix_le(il[116]) + , gas_da_gas_fixed_table(il[117]) + , gas_l2_gas_fixed_table(il[118]) + , gas_sel_gas_cost(il[119]) + , keccakf1600_clk(il[120]) + , keccakf1600_input(il[121]) + , keccakf1600_output(il[122]) + , keccakf1600_sel_keccakf1600(il[123]) + , kernel_emit_l2_to_l1_msg_write_offset(il[124]) + , kernel_emit_note_hash_write_offset(il[125]) + , kernel_emit_nullifier_write_offset(il[126]) + , kernel_emit_unencrypted_log_write_offset(il[127]) + , kernel_kernel_in_offset(il[128]) + , kernel_kernel_out_offset(il[129]) + , kernel_l1_to_l2_msg_exists_write_offset(il[130]) + , kernel_note_hash_exist_write_offset(il[131]) + , kernel_nullifier_exists_write_offset(il[132]) + , kernel_nullifier_non_exists_write_offset(il[133]) + , kernel_q_public_input_kernel_add_to_table(il[134]) + , kernel_q_public_input_kernel_out_add_to_table(il[135]) + , kernel_side_effect_counter(il[136]) + , kernel_sload_write_offset(il[137]) + , kernel_sstore_write_offset(il[138]) + , main_abs_da_rem_gas_hi(il[139]) + , main_abs_da_rem_gas_lo(il[140]) + , main_abs_l2_rem_gas_hi(il[141]) + , main_abs_l2_rem_gas_lo(il[142]) + , main_alu_in_tag(il[143]) + , main_bin_op_id(il[144]) + , main_call_ptr(il[145]) + , main_da_gas_op_cost(il[146]) + , main_da_gas_remaining(il[147]) + , main_da_out_of_gas(il[148]) + , main_ia(il[149]) + , main_ib(il[150]) + , main_ic(il[151]) + , main_id(il[152]) + , main_id_zero(il[153]) + , main_ind_addr_a(il[154]) + , main_ind_addr_b(il[155]) + , main_ind_addr_c(il[156]) + , main_ind_addr_d(il[157]) + , main_internal_return_ptr(il[158]) + , main_inv(il[159]) + , main_l2_gas_op_cost(il[160]) + , main_l2_gas_remaining(il[161]) + , main_l2_out_of_gas(il[162]) + , main_mem_addr_a(il[163]) + , main_mem_addr_b(il[164]) + , main_mem_addr_c(il[165]) + , main_mem_addr_d(il[166]) + , main_op_err(il[167]) + , main_opcode_val(il[168]) + , main_pc(il[169]) + , main_r_in_tag(il[170]) + , main_rwa(il[171]) + , main_rwb(il[172]) + , main_rwc(il[173]) + , main_rwd(il[174]) + , main_sel_alu(il[175]) + , main_sel_bin(il[176]) + , main_sel_calldata(il[177]) + , main_sel_gas_accounting_active(il[178]) + , main_sel_last(il[179]) + , main_sel_mem_op_a(il[180]) + , main_sel_mem_op_activate_gas(il[181]) + , main_sel_mem_op_b(il[182]) + , main_sel_mem_op_c(il[183]) + , main_sel_mem_op_d(il[184]) + , main_sel_mov_ia_to_ic(il[185]) + , main_sel_mov_ib_to_ic(il[186]) + , main_sel_op_add(il[187]) + , main_sel_op_address(il[188]) + , main_sel_op_and(il[189]) + , main_sel_op_block_number(il[190]) + , main_sel_op_calldata_copy(il[191]) + , main_sel_op_cast(il[192]) + , main_sel_op_chain_id(il[193]) + , main_sel_op_cmov(il[194]) + , main_sel_op_coinbase(il[195]) + , main_sel_op_dagasleft(il[196]) + , main_sel_op_div(il[197]) + , main_sel_op_emit_l2_to_l1_msg(il[198]) + , main_sel_op_emit_note_hash(il[199]) + , main_sel_op_emit_nullifier(il[200]) + , main_sel_op_emit_unencrypted_log(il[201]) + , main_sel_op_eq(il[202]) + , main_sel_op_external_call(il[203]) + , main_sel_op_external_return(il[204]) + , main_sel_op_fdiv(il[205]) + , main_sel_op_fee_per_da_gas(il[206]) + , main_sel_op_fee_per_l2_gas(il[207]) + , main_sel_op_function_selector(il[208]) + , main_sel_op_get_contract_instance(il[209]) + , main_sel_op_halt(il[210]) + , main_sel_op_internal_call(il[211]) + , main_sel_op_internal_return(il[212]) + , main_sel_op_jump(il[213]) + , main_sel_op_jumpi(il[214]) + , main_sel_op_keccak(il[215]) + , main_sel_op_l1_to_l2_msg_exists(il[216]) + , main_sel_op_l2gasleft(il[217]) + , main_sel_op_lt(il[218]) + , main_sel_op_lte(il[219]) + , main_sel_op_mov(il[220]) + , main_sel_op_mul(il[221]) + , main_sel_op_not(il[222]) + , main_sel_op_note_hash_exists(il[223]) + , main_sel_op_nullifier_exists(il[224]) + , main_sel_op_or(il[225]) + , main_sel_op_pedersen(il[226]) + , main_sel_op_poseidon2(il[227]) + , main_sel_op_radix_le(il[228]) + , main_sel_op_sender(il[229]) + , main_sel_op_sha256(il[230]) + , main_sel_op_shl(il[231]) + , main_sel_op_shr(il[232]) + , main_sel_op_sload(il[233]) + , main_sel_op_sstore(il[234]) + , main_sel_op_storage_address(il[235]) + , main_sel_op_sub(il[236]) + , main_sel_op_timestamp(il[237]) + , main_sel_op_transaction_fee(il[238]) + , main_sel_op_version(il[239]) + , main_sel_op_xor(il[240]) + , main_sel_q_kernel_lookup(il[241]) + , main_sel_q_kernel_output_lookup(il[242]) + , main_sel_resolve_ind_addr_a(il[243]) + , main_sel_resolve_ind_addr_b(il[244]) + , main_sel_resolve_ind_addr_c(il[245]) + , main_sel_resolve_ind_addr_d(il[246]) + , main_sel_returndata(il[247]) + , main_sel_rng_16(il[248]) + , main_sel_rng_8(il[249]) + , main_sel_slice_gadget(il[250]) + , main_space_id(il[251]) + , main_tag_err(il[252]) + , main_w_in_tag(il[253]) + , mem_addr(il[254]) + , mem_clk(il[255]) + , mem_diff_hi(il[256]) + , mem_diff_lo(il[257]) + , mem_diff_mid(il[258]) + , mem_glob_addr(il[259]) + , mem_last(il[260]) + , mem_lastAccess(il[261]) + , mem_one_min_inv(il[262]) + , mem_r_in_tag(il[263]) + , mem_rw(il[264]) + , mem_sel_mem(il[265]) + , mem_sel_mov_ia_to_ic(il[266]) + , mem_sel_mov_ib_to_ic(il[267]) + , mem_sel_op_a(il[268]) + , mem_sel_op_b(il[269]) + , mem_sel_op_c(il[270]) + , mem_sel_op_cmov(il[271]) + , mem_sel_op_d(il[272]) + , mem_sel_op_poseidon_read_a(il[273]) + , mem_sel_op_poseidon_read_b(il[274]) + , mem_sel_op_poseidon_read_c(il[275]) + , mem_sel_op_poseidon_read_d(il[276]) + , mem_sel_op_poseidon_write_a(il[277]) + , mem_sel_op_poseidon_write_b(il[278]) + , mem_sel_op_poseidon_write_c(il[279]) + , mem_sel_op_poseidon_write_d(il[280]) + , mem_sel_op_slice(il[281]) + , mem_sel_resolve_ind_addr_a(il[282]) + , mem_sel_resolve_ind_addr_b(il[283]) + , mem_sel_resolve_ind_addr_c(il[284]) + , mem_sel_resolve_ind_addr_d(il[285]) + , mem_sel_rng_chk(il[286]) + , mem_skip_check_tag(il[287]) + , mem_space_id(il[288]) + , mem_tag(il[289]) + , mem_tag_err(il[290]) + , mem_tsp(il[291]) + , mem_val(il[292]) + , mem_w_in_tag(il[293]) + , pedersen_clk(il[294]) + , pedersen_input(il[295]) + , pedersen_output(il[296]) + , pedersen_sel_pedersen(il[297]) + , poseidon2_B_10_0(il[298]) + , poseidon2_B_10_1(il[299]) + , poseidon2_B_10_2(il[300]) + , poseidon2_B_10_3(il[301]) + , poseidon2_B_11_0(il[302]) + , poseidon2_B_11_1(il[303]) + , poseidon2_B_11_2(il[304]) + , poseidon2_B_11_3(il[305]) + , poseidon2_B_12_0(il[306]) + , poseidon2_B_12_1(il[307]) + , poseidon2_B_12_2(il[308]) + , poseidon2_B_12_3(il[309]) + , poseidon2_B_13_0(il[310]) + , poseidon2_B_13_1(il[311]) + , poseidon2_B_13_2(il[312]) + , poseidon2_B_13_3(il[313]) + , poseidon2_B_14_0(il[314]) + , poseidon2_B_14_1(il[315]) + , poseidon2_B_14_2(il[316]) + , poseidon2_B_14_3(il[317]) + , poseidon2_B_15_0(il[318]) + , poseidon2_B_15_1(il[319]) + , poseidon2_B_15_2(il[320]) + , poseidon2_B_15_3(il[321]) + , poseidon2_B_16_0(il[322]) + , poseidon2_B_16_1(il[323]) + , poseidon2_B_16_2(il[324]) + , poseidon2_B_16_3(il[325]) + , poseidon2_B_17_0(il[326]) + , poseidon2_B_17_1(il[327]) + , poseidon2_B_17_2(il[328]) + , poseidon2_B_17_3(il[329]) + , poseidon2_B_18_0(il[330]) + , poseidon2_B_18_1(il[331]) + , poseidon2_B_18_2(il[332]) + , poseidon2_B_18_3(il[333]) + , poseidon2_B_19_0(il[334]) + , poseidon2_B_19_1(il[335]) + , poseidon2_B_19_2(il[336]) + , poseidon2_B_19_3(il[337]) + , poseidon2_B_20_0(il[338]) + , poseidon2_B_20_1(il[339]) + , poseidon2_B_20_2(il[340]) + , poseidon2_B_20_3(il[341]) + , poseidon2_B_21_0(il[342]) + , poseidon2_B_21_1(il[343]) + , poseidon2_B_21_2(il[344]) + , poseidon2_B_21_3(il[345]) + , poseidon2_B_22_0(il[346]) + , poseidon2_B_22_1(il[347]) + , poseidon2_B_22_2(il[348]) + , poseidon2_B_22_3(il[349]) + , poseidon2_B_23_0(il[350]) + , poseidon2_B_23_1(il[351]) + , poseidon2_B_23_2(il[352]) + , poseidon2_B_23_3(il[353]) + , poseidon2_B_24_0(il[354]) + , poseidon2_B_24_1(il[355]) + , poseidon2_B_24_2(il[356]) + , poseidon2_B_24_3(il[357]) + , poseidon2_B_25_0(il[358]) + , poseidon2_B_25_1(il[359]) + , poseidon2_B_25_2(il[360]) + , poseidon2_B_25_3(il[361]) + , poseidon2_B_26_0(il[362]) + , poseidon2_B_26_1(il[363]) + , poseidon2_B_26_2(il[364]) + , poseidon2_B_26_3(il[365]) + , poseidon2_B_27_0(il[366]) + , poseidon2_B_27_1(il[367]) + , poseidon2_B_27_2(il[368]) + , poseidon2_B_27_3(il[369]) + , poseidon2_B_28_0(il[370]) + , poseidon2_B_28_1(il[371]) + , poseidon2_B_28_2(il[372]) + , poseidon2_B_28_3(il[373]) + , poseidon2_B_29_0(il[374]) + , poseidon2_B_29_1(il[375]) + , poseidon2_B_29_2(il[376]) + , poseidon2_B_29_3(il[377]) + , poseidon2_B_30_0(il[378]) + , poseidon2_B_30_1(il[379]) + , poseidon2_B_30_2(il[380]) + , poseidon2_B_30_3(il[381]) + , poseidon2_B_31_0(il[382]) + , poseidon2_B_31_1(il[383]) + , poseidon2_B_31_2(il[384]) + , poseidon2_B_31_3(il[385]) + , poseidon2_B_32_0(il[386]) + , poseidon2_B_32_1(il[387]) + , poseidon2_B_32_2(il[388]) + , poseidon2_B_32_3(il[389]) + , poseidon2_B_33_0(il[390]) + , poseidon2_B_33_1(il[391]) + , poseidon2_B_33_2(il[392]) + , poseidon2_B_33_3(il[393]) + , poseidon2_B_34_0(il[394]) + , poseidon2_B_34_1(il[395]) + , poseidon2_B_34_2(il[396]) + , poseidon2_B_34_3(il[397]) + , poseidon2_B_35_0(il[398]) + , poseidon2_B_35_1(il[399]) + , poseidon2_B_35_2(il[400]) + , poseidon2_B_35_3(il[401]) + , poseidon2_B_36_0(il[402]) + , poseidon2_B_36_1(il[403]) + , poseidon2_B_36_2(il[404]) + , poseidon2_B_36_3(il[405]) + , poseidon2_B_37_0(il[406]) + , poseidon2_B_37_1(il[407]) + , poseidon2_B_37_2(il[408]) + , poseidon2_B_37_3(il[409]) + , poseidon2_B_38_0(il[410]) + , poseidon2_B_38_1(il[411]) + , poseidon2_B_38_2(il[412]) + , poseidon2_B_38_3(il[413]) + , poseidon2_B_39_0(il[414]) + , poseidon2_B_39_1(il[415]) + , poseidon2_B_39_2(il[416]) + , poseidon2_B_39_3(il[417]) + , poseidon2_B_40_0(il[418]) + , poseidon2_B_40_1(il[419]) + , poseidon2_B_40_2(il[420]) + , poseidon2_B_40_3(il[421]) + , poseidon2_B_41_0(il[422]) + , poseidon2_B_41_1(il[423]) + , poseidon2_B_41_2(il[424]) + , poseidon2_B_41_3(il[425]) + , poseidon2_B_42_0(il[426]) + , poseidon2_B_42_1(il[427]) + , poseidon2_B_42_2(il[428]) + , poseidon2_B_42_3(il[429]) + , poseidon2_B_43_0(il[430]) + , poseidon2_B_43_1(il[431]) + , poseidon2_B_43_2(il[432]) + , poseidon2_B_43_3(il[433]) + , poseidon2_B_44_0(il[434]) + , poseidon2_B_44_1(il[435]) + , poseidon2_B_44_2(il[436]) + , poseidon2_B_44_3(il[437]) + , poseidon2_B_45_0(il[438]) + , poseidon2_B_45_1(il[439]) + , poseidon2_B_45_2(il[440]) + , poseidon2_B_45_3(il[441]) + , poseidon2_B_46_0(il[442]) + , poseidon2_B_46_1(il[443]) + , poseidon2_B_46_2(il[444]) + , poseidon2_B_46_3(il[445]) + , poseidon2_B_47_0(il[446]) + , poseidon2_B_47_1(il[447]) + , poseidon2_B_47_2(il[448]) + , poseidon2_B_47_3(il[449]) + , poseidon2_B_48_0(il[450]) + , poseidon2_B_48_1(il[451]) + , poseidon2_B_48_2(il[452]) + , poseidon2_B_48_3(il[453]) + , poseidon2_B_49_0(il[454]) + , poseidon2_B_49_1(il[455]) + , poseidon2_B_49_2(il[456]) + , poseidon2_B_49_3(il[457]) + , poseidon2_B_4_0(il[458]) + , poseidon2_B_4_1(il[459]) + , poseidon2_B_4_2(il[460]) + , poseidon2_B_4_3(il[461]) + , poseidon2_B_50_0(il[462]) + , poseidon2_B_50_1(il[463]) + , poseidon2_B_50_2(il[464]) + , poseidon2_B_50_3(il[465]) + , poseidon2_B_51_0(il[466]) + , poseidon2_B_51_1(il[467]) + , poseidon2_B_51_2(il[468]) + , poseidon2_B_51_3(il[469]) + , poseidon2_B_52_0(il[470]) + , poseidon2_B_52_1(il[471]) + , poseidon2_B_52_2(il[472]) + , poseidon2_B_52_3(il[473]) + , poseidon2_B_53_0(il[474]) + , poseidon2_B_53_1(il[475]) + , poseidon2_B_53_2(il[476]) + , poseidon2_B_53_3(il[477]) + , poseidon2_B_54_0(il[478]) + , poseidon2_B_54_1(il[479]) + , poseidon2_B_54_2(il[480]) + , poseidon2_B_54_3(il[481]) + , poseidon2_B_55_0(il[482]) + , poseidon2_B_55_1(il[483]) + , poseidon2_B_55_2(il[484]) + , poseidon2_B_55_3(il[485]) + , poseidon2_B_56_0(il[486]) + , poseidon2_B_56_1(il[487]) + , poseidon2_B_56_2(il[488]) + , poseidon2_B_56_3(il[489]) + , poseidon2_B_57_0(il[490]) + , poseidon2_B_57_1(il[491]) + , poseidon2_B_57_2(il[492]) + , poseidon2_B_57_3(il[493]) + , poseidon2_B_58_0(il[494]) + , poseidon2_B_58_1(il[495]) + , poseidon2_B_58_2(il[496]) + , poseidon2_B_58_3(il[497]) + , poseidon2_B_59_0(il[498]) + , poseidon2_B_59_1(il[499]) + , poseidon2_B_59_2(il[500]) + , poseidon2_B_59_3(il[501]) + , poseidon2_B_5_0(il[502]) + , poseidon2_B_5_1(il[503]) + , poseidon2_B_5_2(il[504]) + , poseidon2_B_5_3(il[505]) + , poseidon2_B_6_0(il[506]) + , poseidon2_B_6_1(il[507]) + , poseidon2_B_6_2(il[508]) + , poseidon2_B_6_3(il[509]) + , poseidon2_B_7_0(il[510]) + , poseidon2_B_7_1(il[511]) + , poseidon2_B_7_2(il[512]) + , poseidon2_B_7_3(il[513]) + , poseidon2_B_8_0(il[514]) + , poseidon2_B_8_1(il[515]) + , poseidon2_B_8_2(il[516]) + , poseidon2_B_8_3(il[517]) + , poseidon2_B_9_0(il[518]) + , poseidon2_B_9_1(il[519]) + , poseidon2_B_9_2(il[520]) + , poseidon2_B_9_3(il[521]) + , poseidon2_EXT_LAYER_4(il[522]) + , poseidon2_EXT_LAYER_5(il[523]) + , poseidon2_EXT_LAYER_6(il[524]) + , poseidon2_EXT_LAYER_7(il[525]) + , poseidon2_T_0_4(il[526]) + , poseidon2_T_0_5(il[527]) + , poseidon2_T_0_6(il[528]) + , poseidon2_T_0_7(il[529]) + , poseidon2_T_1_4(il[530]) + , poseidon2_T_1_5(il[531]) + , poseidon2_T_1_6(il[532]) + , poseidon2_T_1_7(il[533]) + , poseidon2_T_2_4(il[534]) + , poseidon2_T_2_5(il[535]) + , poseidon2_T_2_6(il[536]) + , poseidon2_T_2_7(il[537]) + , poseidon2_T_3_4(il[538]) + , poseidon2_T_3_5(il[539]) + , poseidon2_T_3_6(il[540]) + , poseidon2_T_3_7(il[541]) + , poseidon2_T_60_4(il[542]) + , poseidon2_T_60_5(il[543]) + , poseidon2_T_60_6(il[544]) + , poseidon2_T_60_7(il[545]) + , poseidon2_T_61_4(il[546]) + , poseidon2_T_61_5(il[547]) + , poseidon2_T_61_6(il[548]) + , poseidon2_T_61_7(il[549]) + , poseidon2_T_62_4(il[550]) + , poseidon2_T_62_5(il[551]) + , poseidon2_T_62_6(il[552]) + , poseidon2_T_62_7(il[553]) + , poseidon2_T_63_4(il[554]) + , poseidon2_T_63_5(il[555]) + , poseidon2_T_63_6(il[556]) + , poseidon2_T_63_7(il[557]) + , poseidon2_a_0(il[558]) + , poseidon2_a_1(il[559]) + , poseidon2_a_2(il[560]) + , poseidon2_a_3(il[561]) + , poseidon2_b_0(il[562]) + , poseidon2_b_1(il[563]) + , poseidon2_b_2(il[564]) + , poseidon2_b_3(il[565]) + , poseidon2_clk(il[566]) + , poseidon2_input_addr(il[567]) + , poseidon2_mem_addr_read_a(il[568]) + , poseidon2_mem_addr_read_b(il[569]) + , poseidon2_mem_addr_read_c(il[570]) + , poseidon2_mem_addr_read_d(il[571]) + , poseidon2_mem_addr_write_a(il[572]) + , poseidon2_mem_addr_write_b(il[573]) + , poseidon2_mem_addr_write_c(il[574]) + , poseidon2_mem_addr_write_d(il[575]) + , poseidon2_output_addr(il[576]) + , poseidon2_sel_poseidon_perm(il[577]) + , powers_power_of_2(il[578]) + , sha256_clk(il[579]) + , sha256_input(il[580]) + , sha256_output(il[581]) + , sha256_sel_sha256_compression(il[582]) + , sha256_state(il[583]) + , slice_addr(il[584]) + , slice_clk(il[585]) + , slice_cnt(il[586]) + , slice_col_offset(il[587]) + , slice_one_min_inv(il[588]) + , slice_sel_cd_cpy(il[589]) + , slice_sel_mem_active(il[590]) + , slice_sel_return(il[591]) + , slice_sel_start(il[592]) + , slice_space_id(il[593]) + , slice_val(il[594]) + , lookup_byte_lengths_counts(il[595]) + , lookup_byte_operations_counts(il[596]) + , lookup_cd_value_counts(il[597]) + , lookup_ret_value_counts(il[598]) + , lookup_opcode_gas_counts(il[599]) + , range_check_l2_gas_hi_counts(il[600]) + , range_check_l2_gas_lo_counts(il[601]) + , range_check_da_gas_hi_counts(il[602]) + , range_check_da_gas_lo_counts(il[603]) + , kernel_output_lookup_counts(il[604]) + , lookup_into_kernel_counts(il[605]) + , incl_main_tag_err_counts(il[606]) + , incl_mem_tag_err_counts(il[607]) + , lookup_mem_rng_chk_lo_counts(il[608]) + , lookup_mem_rng_chk_mid_counts(il[609]) + , lookup_mem_rng_chk_hi_counts(il[610]) + , lookup_pow_2_0_counts(il[611]) + , lookup_pow_2_1_counts(il[612]) + , lookup_u8_0_counts(il[613]) + , lookup_u8_1_counts(il[614]) + , lookup_u16_0_counts(il[615]) + , lookup_u16_1_counts(il[616]) + , lookup_u16_2_counts(il[617]) + , lookup_u16_3_counts(il[618]) + , lookup_u16_4_counts(il[619]) + , lookup_u16_5_counts(il[620]) + , lookup_u16_6_counts(il[621]) + , lookup_u16_7_counts(il[622]) + , lookup_u16_8_counts(il[623]) + , lookup_u16_9_counts(il[624]) + , lookup_u16_10_counts(il[625]) + , lookup_u16_11_counts(il[626]) + , lookup_u16_12_counts(il[627]) + , lookup_u16_13_counts(il[628]) + , lookup_u16_14_counts(il[629]) + , lookup_div_u16_0_counts(il[630]) + , lookup_div_u16_1_counts(il[631]) + , lookup_div_u16_2_counts(il[632]) + , lookup_div_u16_3_counts(il[633]) + , lookup_div_u16_4_counts(il[634]) + , lookup_div_u16_5_counts(il[635]) + , lookup_div_u16_6_counts(il[636]) + , lookup_div_u16_7_counts(il[637]) + , perm_pos_mem_read_a(il[638]) + , perm_pos_mem_read_b(il[639]) + , perm_pos_mem_read_c(il[640]) + , perm_pos_mem_read_d(il[641]) + , perm_pos_mem_write_a(il[642]) + , perm_pos_mem_write_b(il[643]) + , perm_pos_mem_write_c(il[644]) + , perm_pos_mem_write_d(il[645]) + , perm_slice_mem(il[646]) + , perm_main_alu(il[647]) + , perm_main_bin(il[648]) + , perm_main_conv(il[649]) + , perm_main_pos2_perm(il[650]) + , perm_main_pedersen(il[651]) + , perm_main_slice(il[652]) + , perm_main_mem_a(il[653]) + , perm_main_mem_b(il[654]) + , perm_main_mem_c(il[655]) + , perm_main_mem_d(il[656]) + , perm_main_mem_ind_addr_a(il[657]) + , perm_main_mem_ind_addr_b(il[658]) + , perm_main_mem_ind_addr_c(il[659]) + , perm_main_mem_ind_addr_d(il[660]) + , lookup_byte_lengths(il[661]) + , lookup_byte_operations(il[662]) + , lookup_cd_value(il[663]) + , lookup_ret_value(il[664]) + , lookup_opcode_gas(il[665]) + , range_check_l2_gas_hi(il[666]) + , range_check_l2_gas_lo(il[667]) + , range_check_da_gas_hi(il[668]) + , range_check_da_gas_lo(il[669]) + , kernel_output_lookup(il[670]) + , lookup_into_kernel(il[671]) + , incl_main_tag_err(il[672]) + , incl_mem_tag_err(il[673]) + , lookup_mem_rng_chk_lo(il[674]) + , lookup_mem_rng_chk_mid(il[675]) + , lookup_mem_rng_chk_hi(il[676]) + , lookup_pow_2_0(il[677]) + , lookup_pow_2_1(il[678]) + , lookup_u8_0(il[679]) + , lookup_u8_1(il[680]) + , lookup_u16_0(il[681]) + , lookup_u16_1(il[682]) + , lookup_u16_2(il[683]) + , lookup_u16_3(il[684]) + , lookup_u16_4(il[685]) + , lookup_u16_5(il[686]) + , lookup_u16_6(il[687]) + , lookup_u16_7(il[688]) + , lookup_u16_8(il[689]) + , lookup_u16_9(il[690]) + , lookup_u16_10(il[691]) + , lookup_u16_11(il[692]) + , lookup_u16_12(il[693]) + , lookup_u16_13(il[694]) + , lookup_u16_14(il[695]) + , lookup_div_u16_0(il[696]) + , lookup_div_u16_1(il[697]) + , lookup_div_u16_2(il[698]) + , lookup_div_u16_3(il[699]) + , lookup_div_u16_4(il[700]) + , lookup_div_u16_5(il[701]) + , lookup_div_u16_6(il[702]) + , lookup_div_u16_7(il[703]) + , alu_a_hi_shift(il[704]) + , alu_a_lo_shift(il[705]) + , alu_b_hi_shift(il[706]) + , alu_b_lo_shift(il[707]) + , alu_cmp_rng_ctr_shift(il[708]) + , alu_div_u16_r0_shift(il[709]) + , alu_div_u16_r1_shift(il[710]) + , alu_div_u16_r2_shift(il[711]) + , alu_div_u16_r3_shift(il[712]) + , alu_div_u16_r4_shift(il[713]) + , alu_div_u16_r5_shift(il[714]) + , alu_div_u16_r6_shift(il[715]) + , alu_div_u16_r7_shift(il[716]) + , alu_op_add_shift(il[717]) + , alu_op_cast_prev_shift(il[718]) + , alu_op_cast_shift(il[719]) + , alu_op_div_shift(il[720]) + , alu_op_mul_shift(il[721]) + , alu_op_shl_shift(il[722]) + , alu_op_shr_shift(il[723]) + , alu_op_sub_shift(il[724]) + , alu_p_sub_a_hi_shift(il[725]) + , alu_p_sub_a_lo_shift(il[726]) + , alu_p_sub_b_hi_shift(il[727]) + , alu_p_sub_b_lo_shift(il[728]) + , alu_sel_alu_shift(il[729]) + , alu_sel_cmp_shift(il[730]) + , alu_sel_div_rng_chk_shift(il[731]) + , alu_sel_rng_chk_lookup_shift(il[732]) + , alu_sel_rng_chk_shift(il[733]) + , alu_u16_r0_shift(il[734]) + , alu_u16_r1_shift(il[735]) + , alu_u16_r2_shift(il[736]) + , alu_u16_r3_shift(il[737]) + , alu_u16_r4_shift(il[738]) + , alu_u16_r5_shift(il[739]) + , alu_u16_r6_shift(il[740]) + , alu_u8_r0_shift(il[741]) + , alu_u8_r1_shift(il[742]) + , binary_acc_ia_shift(il[743]) + , binary_acc_ib_shift(il[744]) + , binary_acc_ic_shift(il[745]) + , binary_mem_tag_ctr_shift(il[746]) + , binary_op_id_shift(il[747]) + , kernel_emit_l2_to_l1_msg_write_offset_shift(il[748]) + , kernel_emit_note_hash_write_offset_shift(il[749]) + , kernel_emit_nullifier_write_offset_shift(il[750]) + , kernel_emit_unencrypted_log_write_offset_shift(il[751]) + , kernel_l1_to_l2_msg_exists_write_offset_shift(il[752]) + , kernel_note_hash_exist_write_offset_shift(il[753]) + , kernel_nullifier_exists_write_offset_shift(il[754]) + , kernel_nullifier_non_exists_write_offset_shift(il[755]) + , kernel_side_effect_counter_shift(il[756]) + , kernel_sload_write_offset_shift(il[757]) + , kernel_sstore_write_offset_shift(il[758]) + , main_da_gas_remaining_shift(il[759]) + , main_internal_return_ptr_shift(il[760]) + , main_l2_gas_remaining_shift(il[761]) + , main_pc_shift(il[762]) + , mem_glob_addr_shift(il[763]) + , mem_rw_shift(il[764]) + , mem_sel_mem_shift(il[765]) + , mem_tag_shift(il[766]) + , mem_tsp_shift(il[767]) + , mem_val_shift(il[768]) + , slice_addr_shift(il[769]) + , slice_clk_shift(il[770]) + , slice_cnt_shift(il[771]) + , slice_col_offset_shift(il[772]) + , slice_sel_cd_cpy_shift(il[773]) + , slice_sel_mem_active_shift(il[774]) + , slice_sel_return_shift(il[775]) + , slice_sel_start_shift(il[776]) + , slice_space_id_shift(il[777]) {} AvmFlavor::ProverPolynomials::ProverPolynomials(ProvingKey& proving_key) @@ -508,6 +801,7 @@ AvmFlavor::AllConstRefValues AvmFlavor::ProverPolynomials::get_row(size_t row_id { return AllConstRefValues(RefArray{ main_clk[row_idx], main_sel_first[row_idx], + main_zeroes[row_idx], kernel_kernel_inputs[row_idx], kernel_kernel_value_out[row_idx], kernel_kernel_side_effect_out[row_idx], @@ -778,6 +1072,14 @@ AvmFlavor::AllConstRefValues AvmFlavor::ProverPolynomials::get_row(size_t row_id mem_sel_op_c[row_idx], mem_sel_op_cmov[row_idx], mem_sel_op_d[row_idx], + mem_sel_op_poseidon_read_a[row_idx], + mem_sel_op_poseidon_read_b[row_idx], + mem_sel_op_poseidon_read_c[row_idx], + mem_sel_op_poseidon_read_d[row_idx], + mem_sel_op_poseidon_write_a[row_idx], + mem_sel_op_poseidon_write_b[row_idx], + mem_sel_op_poseidon_write_c[row_idx], + mem_sel_op_poseidon_write_d[row_idx], mem_sel_op_slice[row_idx], mem_sel_resolve_ind_addr_a[row_idx], mem_sel_resolve_ind_addr_b[row_idx], @@ -795,9 +1097,285 @@ AvmFlavor::AllConstRefValues AvmFlavor::ProverPolynomials::get_row(size_t row_id pedersen_input[row_idx], pedersen_output[row_idx], pedersen_sel_pedersen[row_idx], + poseidon2_B_10_0[row_idx], + poseidon2_B_10_1[row_idx], + poseidon2_B_10_2[row_idx], + poseidon2_B_10_3[row_idx], + poseidon2_B_11_0[row_idx], + poseidon2_B_11_1[row_idx], + poseidon2_B_11_2[row_idx], + poseidon2_B_11_3[row_idx], + poseidon2_B_12_0[row_idx], + poseidon2_B_12_1[row_idx], + poseidon2_B_12_2[row_idx], + poseidon2_B_12_3[row_idx], + poseidon2_B_13_0[row_idx], + poseidon2_B_13_1[row_idx], + poseidon2_B_13_2[row_idx], + poseidon2_B_13_3[row_idx], + poseidon2_B_14_0[row_idx], + poseidon2_B_14_1[row_idx], + poseidon2_B_14_2[row_idx], + poseidon2_B_14_3[row_idx], + poseidon2_B_15_0[row_idx], + poseidon2_B_15_1[row_idx], + poseidon2_B_15_2[row_idx], + poseidon2_B_15_3[row_idx], + poseidon2_B_16_0[row_idx], + poseidon2_B_16_1[row_idx], + poseidon2_B_16_2[row_idx], + poseidon2_B_16_3[row_idx], + poseidon2_B_17_0[row_idx], + poseidon2_B_17_1[row_idx], + poseidon2_B_17_2[row_idx], + poseidon2_B_17_3[row_idx], + poseidon2_B_18_0[row_idx], + poseidon2_B_18_1[row_idx], + poseidon2_B_18_2[row_idx], + poseidon2_B_18_3[row_idx], + poseidon2_B_19_0[row_idx], + poseidon2_B_19_1[row_idx], + poseidon2_B_19_2[row_idx], + poseidon2_B_19_3[row_idx], + poseidon2_B_20_0[row_idx], + poseidon2_B_20_1[row_idx], + poseidon2_B_20_2[row_idx], + poseidon2_B_20_3[row_idx], + poseidon2_B_21_0[row_idx], + poseidon2_B_21_1[row_idx], + poseidon2_B_21_2[row_idx], + poseidon2_B_21_3[row_idx], + poseidon2_B_22_0[row_idx], + poseidon2_B_22_1[row_idx], + poseidon2_B_22_2[row_idx], + poseidon2_B_22_3[row_idx], + poseidon2_B_23_0[row_idx], + poseidon2_B_23_1[row_idx], + poseidon2_B_23_2[row_idx], + poseidon2_B_23_3[row_idx], + poseidon2_B_24_0[row_idx], + poseidon2_B_24_1[row_idx], + poseidon2_B_24_2[row_idx], + poseidon2_B_24_3[row_idx], + poseidon2_B_25_0[row_idx], + poseidon2_B_25_1[row_idx], + poseidon2_B_25_2[row_idx], + poseidon2_B_25_3[row_idx], + poseidon2_B_26_0[row_idx], + poseidon2_B_26_1[row_idx], + poseidon2_B_26_2[row_idx], + poseidon2_B_26_3[row_idx], + poseidon2_B_27_0[row_idx], + poseidon2_B_27_1[row_idx], + poseidon2_B_27_2[row_idx], + poseidon2_B_27_3[row_idx], + poseidon2_B_28_0[row_idx], + poseidon2_B_28_1[row_idx], + poseidon2_B_28_2[row_idx], + poseidon2_B_28_3[row_idx], + poseidon2_B_29_0[row_idx], + poseidon2_B_29_1[row_idx], + poseidon2_B_29_2[row_idx], + poseidon2_B_29_3[row_idx], + poseidon2_B_30_0[row_idx], + poseidon2_B_30_1[row_idx], + poseidon2_B_30_2[row_idx], + poseidon2_B_30_3[row_idx], + poseidon2_B_31_0[row_idx], + poseidon2_B_31_1[row_idx], + poseidon2_B_31_2[row_idx], + poseidon2_B_31_3[row_idx], + poseidon2_B_32_0[row_idx], + poseidon2_B_32_1[row_idx], + poseidon2_B_32_2[row_idx], + poseidon2_B_32_3[row_idx], + poseidon2_B_33_0[row_idx], + poseidon2_B_33_1[row_idx], + poseidon2_B_33_2[row_idx], + poseidon2_B_33_3[row_idx], + poseidon2_B_34_0[row_idx], + poseidon2_B_34_1[row_idx], + poseidon2_B_34_2[row_idx], + poseidon2_B_34_3[row_idx], + poseidon2_B_35_0[row_idx], + poseidon2_B_35_1[row_idx], + poseidon2_B_35_2[row_idx], + poseidon2_B_35_3[row_idx], + poseidon2_B_36_0[row_idx], + poseidon2_B_36_1[row_idx], + poseidon2_B_36_2[row_idx], + poseidon2_B_36_3[row_idx], + poseidon2_B_37_0[row_idx], + poseidon2_B_37_1[row_idx], + poseidon2_B_37_2[row_idx], + poseidon2_B_37_3[row_idx], + poseidon2_B_38_0[row_idx], + poseidon2_B_38_1[row_idx], + poseidon2_B_38_2[row_idx], + poseidon2_B_38_3[row_idx], + poseidon2_B_39_0[row_idx], + poseidon2_B_39_1[row_idx], + poseidon2_B_39_2[row_idx], + poseidon2_B_39_3[row_idx], + poseidon2_B_40_0[row_idx], + poseidon2_B_40_1[row_idx], + poseidon2_B_40_2[row_idx], + poseidon2_B_40_3[row_idx], + poseidon2_B_41_0[row_idx], + poseidon2_B_41_1[row_idx], + poseidon2_B_41_2[row_idx], + poseidon2_B_41_3[row_idx], + poseidon2_B_42_0[row_idx], + poseidon2_B_42_1[row_idx], + poseidon2_B_42_2[row_idx], + poseidon2_B_42_3[row_idx], + poseidon2_B_43_0[row_idx], + poseidon2_B_43_1[row_idx], + poseidon2_B_43_2[row_idx], + poseidon2_B_43_3[row_idx], + poseidon2_B_44_0[row_idx], + poseidon2_B_44_1[row_idx], + poseidon2_B_44_2[row_idx], + poseidon2_B_44_3[row_idx], + poseidon2_B_45_0[row_idx], + poseidon2_B_45_1[row_idx], + poseidon2_B_45_2[row_idx], + poseidon2_B_45_3[row_idx], + poseidon2_B_46_0[row_idx], + poseidon2_B_46_1[row_idx], + poseidon2_B_46_2[row_idx], + poseidon2_B_46_3[row_idx], + poseidon2_B_47_0[row_idx], + poseidon2_B_47_1[row_idx], + poseidon2_B_47_2[row_idx], + poseidon2_B_47_3[row_idx], + poseidon2_B_48_0[row_idx], + poseidon2_B_48_1[row_idx], + poseidon2_B_48_2[row_idx], + poseidon2_B_48_3[row_idx], + poseidon2_B_49_0[row_idx], + poseidon2_B_49_1[row_idx], + poseidon2_B_49_2[row_idx], + poseidon2_B_49_3[row_idx], + poseidon2_B_4_0[row_idx], + poseidon2_B_4_1[row_idx], + poseidon2_B_4_2[row_idx], + poseidon2_B_4_3[row_idx], + poseidon2_B_50_0[row_idx], + poseidon2_B_50_1[row_idx], + poseidon2_B_50_2[row_idx], + poseidon2_B_50_3[row_idx], + poseidon2_B_51_0[row_idx], + poseidon2_B_51_1[row_idx], + poseidon2_B_51_2[row_idx], + poseidon2_B_51_3[row_idx], + poseidon2_B_52_0[row_idx], + poseidon2_B_52_1[row_idx], + poseidon2_B_52_2[row_idx], + poseidon2_B_52_3[row_idx], + poseidon2_B_53_0[row_idx], + poseidon2_B_53_1[row_idx], + poseidon2_B_53_2[row_idx], + poseidon2_B_53_3[row_idx], + poseidon2_B_54_0[row_idx], + poseidon2_B_54_1[row_idx], + poseidon2_B_54_2[row_idx], + poseidon2_B_54_3[row_idx], + poseidon2_B_55_0[row_idx], + poseidon2_B_55_1[row_idx], + poseidon2_B_55_2[row_idx], + poseidon2_B_55_3[row_idx], + poseidon2_B_56_0[row_idx], + poseidon2_B_56_1[row_idx], + poseidon2_B_56_2[row_idx], + poseidon2_B_56_3[row_idx], + poseidon2_B_57_0[row_idx], + poseidon2_B_57_1[row_idx], + poseidon2_B_57_2[row_idx], + poseidon2_B_57_3[row_idx], + poseidon2_B_58_0[row_idx], + poseidon2_B_58_1[row_idx], + poseidon2_B_58_2[row_idx], + poseidon2_B_58_3[row_idx], + poseidon2_B_59_0[row_idx], + poseidon2_B_59_1[row_idx], + poseidon2_B_59_2[row_idx], + poseidon2_B_59_3[row_idx], + poseidon2_B_5_0[row_idx], + poseidon2_B_5_1[row_idx], + poseidon2_B_5_2[row_idx], + poseidon2_B_5_3[row_idx], + poseidon2_B_6_0[row_idx], + poseidon2_B_6_1[row_idx], + poseidon2_B_6_2[row_idx], + poseidon2_B_6_3[row_idx], + poseidon2_B_7_0[row_idx], + poseidon2_B_7_1[row_idx], + poseidon2_B_7_2[row_idx], + poseidon2_B_7_3[row_idx], + poseidon2_B_8_0[row_idx], + poseidon2_B_8_1[row_idx], + poseidon2_B_8_2[row_idx], + poseidon2_B_8_3[row_idx], + poseidon2_B_9_0[row_idx], + poseidon2_B_9_1[row_idx], + poseidon2_B_9_2[row_idx], + poseidon2_B_9_3[row_idx], + poseidon2_EXT_LAYER_4[row_idx], + poseidon2_EXT_LAYER_5[row_idx], + poseidon2_EXT_LAYER_6[row_idx], + poseidon2_EXT_LAYER_7[row_idx], + poseidon2_T_0_4[row_idx], + poseidon2_T_0_5[row_idx], + poseidon2_T_0_6[row_idx], + poseidon2_T_0_7[row_idx], + poseidon2_T_1_4[row_idx], + poseidon2_T_1_5[row_idx], + poseidon2_T_1_6[row_idx], + poseidon2_T_1_7[row_idx], + poseidon2_T_2_4[row_idx], + poseidon2_T_2_5[row_idx], + poseidon2_T_2_6[row_idx], + poseidon2_T_2_7[row_idx], + poseidon2_T_3_4[row_idx], + poseidon2_T_3_5[row_idx], + poseidon2_T_3_6[row_idx], + poseidon2_T_3_7[row_idx], + poseidon2_T_60_4[row_idx], + poseidon2_T_60_5[row_idx], + poseidon2_T_60_6[row_idx], + poseidon2_T_60_7[row_idx], + poseidon2_T_61_4[row_idx], + poseidon2_T_61_5[row_idx], + poseidon2_T_61_6[row_idx], + poseidon2_T_61_7[row_idx], + poseidon2_T_62_4[row_idx], + poseidon2_T_62_5[row_idx], + poseidon2_T_62_6[row_idx], + poseidon2_T_62_7[row_idx], + poseidon2_T_63_4[row_idx], + poseidon2_T_63_5[row_idx], + poseidon2_T_63_6[row_idx], + poseidon2_T_63_7[row_idx], + poseidon2_a_0[row_idx], + poseidon2_a_1[row_idx], + poseidon2_a_2[row_idx], + poseidon2_a_3[row_idx], + poseidon2_b_0[row_idx], + poseidon2_b_1[row_idx], + poseidon2_b_2[row_idx], + poseidon2_b_3[row_idx], poseidon2_clk[row_idx], - poseidon2_input[row_idx], - poseidon2_output[row_idx], + poseidon2_input_addr[row_idx], + poseidon2_mem_addr_read_a[row_idx], + poseidon2_mem_addr_read_b[row_idx], + poseidon2_mem_addr_read_c[row_idx], + poseidon2_mem_addr_read_d[row_idx], + poseidon2_mem_addr_write_a[row_idx], + poseidon2_mem_addr_write_b[row_idx], + poseidon2_mem_addr_write_c[row_idx], + poseidon2_mem_addr_write_d[row_idx], + poseidon2_output_addr[row_idx], poseidon2_sel_poseidon_perm[row_idx], powers_power_of_2[row_idx], sha256_clk[row_idx], @@ -859,6 +1437,14 @@ AvmFlavor::AllConstRefValues AvmFlavor::ProverPolynomials::get_row(size_t row_id lookup_div_u16_5_counts[row_idx], lookup_div_u16_6_counts[row_idx], lookup_div_u16_7_counts[row_idx], + perm_pos_mem_read_a[row_idx], + perm_pos_mem_read_b[row_idx], + perm_pos_mem_read_c[row_idx], + perm_pos_mem_read_d[row_idx], + perm_pos_mem_write_a[row_idx], + perm_pos_mem_write_b[row_idx], + perm_pos_mem_write_c[row_idx], + perm_pos_mem_write_d[row_idx], perm_slice_mem[row_idx], perm_main_alu[row_idx], perm_main_bin[row_idx], @@ -997,6 +1583,7 @@ AvmFlavor::CommitmentLabels::CommitmentLabels() { Base::main_clk = "MAIN_CLK"; Base::main_sel_first = "MAIN_SEL_FIRST"; + Base::main_zeroes = "MAIN_ZEROES"; Base::kernel_kernel_inputs = "KERNEL_KERNEL_INPUTS"; Base::kernel_kernel_value_out = "KERNEL_KERNEL_VALUE_OUT"; Base::kernel_kernel_side_effect_out = "KERNEL_KERNEL_SIDE_EFFECT_OUT"; @@ -1267,6 +1854,14 @@ AvmFlavor::CommitmentLabels::CommitmentLabels() Base::mem_sel_op_c = "MEM_SEL_OP_C"; Base::mem_sel_op_cmov = "MEM_SEL_OP_CMOV"; Base::mem_sel_op_d = "MEM_SEL_OP_D"; + Base::mem_sel_op_poseidon_read_a = "MEM_SEL_OP_POSEIDON_READ_A"; + Base::mem_sel_op_poseidon_read_b = "MEM_SEL_OP_POSEIDON_READ_B"; + Base::mem_sel_op_poseidon_read_c = "MEM_SEL_OP_POSEIDON_READ_C"; + Base::mem_sel_op_poseidon_read_d = "MEM_SEL_OP_POSEIDON_READ_D"; + Base::mem_sel_op_poseidon_write_a = "MEM_SEL_OP_POSEIDON_WRITE_A"; + Base::mem_sel_op_poseidon_write_b = "MEM_SEL_OP_POSEIDON_WRITE_B"; + Base::mem_sel_op_poseidon_write_c = "MEM_SEL_OP_POSEIDON_WRITE_C"; + Base::mem_sel_op_poseidon_write_d = "MEM_SEL_OP_POSEIDON_WRITE_D"; Base::mem_sel_op_slice = "MEM_SEL_OP_SLICE"; Base::mem_sel_resolve_ind_addr_a = "MEM_SEL_RESOLVE_IND_ADDR_A"; Base::mem_sel_resolve_ind_addr_b = "MEM_SEL_RESOLVE_IND_ADDR_B"; @@ -1284,9 +1879,285 @@ AvmFlavor::CommitmentLabels::CommitmentLabels() Base::pedersen_input = "PEDERSEN_INPUT"; Base::pedersen_output = "PEDERSEN_OUTPUT"; Base::pedersen_sel_pedersen = "PEDERSEN_SEL_PEDERSEN"; + Base::poseidon2_B_10_0 = "POSEIDON2_B_10_0"; + Base::poseidon2_B_10_1 = "POSEIDON2_B_10_1"; + Base::poseidon2_B_10_2 = "POSEIDON2_B_10_2"; + Base::poseidon2_B_10_3 = "POSEIDON2_B_10_3"; + Base::poseidon2_B_11_0 = "POSEIDON2_B_11_0"; + Base::poseidon2_B_11_1 = "POSEIDON2_B_11_1"; + Base::poseidon2_B_11_2 = "POSEIDON2_B_11_2"; + Base::poseidon2_B_11_3 = "POSEIDON2_B_11_3"; + Base::poseidon2_B_12_0 = "POSEIDON2_B_12_0"; + Base::poseidon2_B_12_1 = "POSEIDON2_B_12_1"; + Base::poseidon2_B_12_2 = "POSEIDON2_B_12_2"; + Base::poseidon2_B_12_3 = "POSEIDON2_B_12_3"; + Base::poseidon2_B_13_0 = "POSEIDON2_B_13_0"; + Base::poseidon2_B_13_1 = "POSEIDON2_B_13_1"; + Base::poseidon2_B_13_2 = "POSEIDON2_B_13_2"; + Base::poseidon2_B_13_3 = "POSEIDON2_B_13_3"; + Base::poseidon2_B_14_0 = "POSEIDON2_B_14_0"; + Base::poseidon2_B_14_1 = "POSEIDON2_B_14_1"; + Base::poseidon2_B_14_2 = "POSEIDON2_B_14_2"; + Base::poseidon2_B_14_3 = "POSEIDON2_B_14_3"; + Base::poseidon2_B_15_0 = "POSEIDON2_B_15_0"; + Base::poseidon2_B_15_1 = "POSEIDON2_B_15_1"; + Base::poseidon2_B_15_2 = "POSEIDON2_B_15_2"; + Base::poseidon2_B_15_3 = "POSEIDON2_B_15_3"; + Base::poseidon2_B_16_0 = "POSEIDON2_B_16_0"; + Base::poseidon2_B_16_1 = "POSEIDON2_B_16_1"; + Base::poseidon2_B_16_2 = "POSEIDON2_B_16_2"; + Base::poseidon2_B_16_3 = "POSEIDON2_B_16_3"; + Base::poseidon2_B_17_0 = "POSEIDON2_B_17_0"; + Base::poseidon2_B_17_1 = "POSEIDON2_B_17_1"; + Base::poseidon2_B_17_2 = "POSEIDON2_B_17_2"; + Base::poseidon2_B_17_3 = "POSEIDON2_B_17_3"; + Base::poseidon2_B_18_0 = "POSEIDON2_B_18_0"; + Base::poseidon2_B_18_1 = "POSEIDON2_B_18_1"; + Base::poseidon2_B_18_2 = "POSEIDON2_B_18_2"; + Base::poseidon2_B_18_3 = "POSEIDON2_B_18_3"; + Base::poseidon2_B_19_0 = "POSEIDON2_B_19_0"; + Base::poseidon2_B_19_1 = "POSEIDON2_B_19_1"; + Base::poseidon2_B_19_2 = "POSEIDON2_B_19_2"; + Base::poseidon2_B_19_3 = "POSEIDON2_B_19_3"; + Base::poseidon2_B_20_0 = "POSEIDON2_B_20_0"; + Base::poseidon2_B_20_1 = "POSEIDON2_B_20_1"; + Base::poseidon2_B_20_2 = "POSEIDON2_B_20_2"; + Base::poseidon2_B_20_3 = "POSEIDON2_B_20_3"; + Base::poseidon2_B_21_0 = "POSEIDON2_B_21_0"; + Base::poseidon2_B_21_1 = "POSEIDON2_B_21_1"; + Base::poseidon2_B_21_2 = "POSEIDON2_B_21_2"; + Base::poseidon2_B_21_3 = "POSEIDON2_B_21_3"; + Base::poseidon2_B_22_0 = "POSEIDON2_B_22_0"; + Base::poseidon2_B_22_1 = "POSEIDON2_B_22_1"; + Base::poseidon2_B_22_2 = "POSEIDON2_B_22_2"; + Base::poseidon2_B_22_3 = "POSEIDON2_B_22_3"; + Base::poseidon2_B_23_0 = "POSEIDON2_B_23_0"; + Base::poseidon2_B_23_1 = "POSEIDON2_B_23_1"; + Base::poseidon2_B_23_2 = "POSEIDON2_B_23_2"; + Base::poseidon2_B_23_3 = "POSEIDON2_B_23_3"; + Base::poseidon2_B_24_0 = "POSEIDON2_B_24_0"; + Base::poseidon2_B_24_1 = "POSEIDON2_B_24_1"; + Base::poseidon2_B_24_2 = "POSEIDON2_B_24_2"; + Base::poseidon2_B_24_3 = "POSEIDON2_B_24_3"; + Base::poseidon2_B_25_0 = "POSEIDON2_B_25_0"; + Base::poseidon2_B_25_1 = "POSEIDON2_B_25_1"; + Base::poseidon2_B_25_2 = "POSEIDON2_B_25_2"; + Base::poseidon2_B_25_3 = "POSEIDON2_B_25_3"; + Base::poseidon2_B_26_0 = "POSEIDON2_B_26_0"; + Base::poseidon2_B_26_1 = "POSEIDON2_B_26_1"; + Base::poseidon2_B_26_2 = "POSEIDON2_B_26_2"; + Base::poseidon2_B_26_3 = "POSEIDON2_B_26_3"; + Base::poseidon2_B_27_0 = "POSEIDON2_B_27_0"; + Base::poseidon2_B_27_1 = "POSEIDON2_B_27_1"; + Base::poseidon2_B_27_2 = "POSEIDON2_B_27_2"; + Base::poseidon2_B_27_3 = "POSEIDON2_B_27_3"; + Base::poseidon2_B_28_0 = "POSEIDON2_B_28_0"; + Base::poseidon2_B_28_1 = "POSEIDON2_B_28_1"; + Base::poseidon2_B_28_2 = "POSEIDON2_B_28_2"; + Base::poseidon2_B_28_3 = "POSEIDON2_B_28_3"; + Base::poseidon2_B_29_0 = "POSEIDON2_B_29_0"; + Base::poseidon2_B_29_1 = "POSEIDON2_B_29_1"; + Base::poseidon2_B_29_2 = "POSEIDON2_B_29_2"; + Base::poseidon2_B_29_3 = "POSEIDON2_B_29_3"; + Base::poseidon2_B_30_0 = "POSEIDON2_B_30_0"; + Base::poseidon2_B_30_1 = "POSEIDON2_B_30_1"; + Base::poseidon2_B_30_2 = "POSEIDON2_B_30_2"; + Base::poseidon2_B_30_3 = "POSEIDON2_B_30_3"; + Base::poseidon2_B_31_0 = "POSEIDON2_B_31_0"; + Base::poseidon2_B_31_1 = "POSEIDON2_B_31_1"; + Base::poseidon2_B_31_2 = "POSEIDON2_B_31_2"; + Base::poseidon2_B_31_3 = "POSEIDON2_B_31_3"; + Base::poseidon2_B_32_0 = "POSEIDON2_B_32_0"; + Base::poseidon2_B_32_1 = "POSEIDON2_B_32_1"; + Base::poseidon2_B_32_2 = "POSEIDON2_B_32_2"; + Base::poseidon2_B_32_3 = "POSEIDON2_B_32_3"; + Base::poseidon2_B_33_0 = "POSEIDON2_B_33_0"; + Base::poseidon2_B_33_1 = "POSEIDON2_B_33_1"; + Base::poseidon2_B_33_2 = "POSEIDON2_B_33_2"; + Base::poseidon2_B_33_3 = "POSEIDON2_B_33_3"; + Base::poseidon2_B_34_0 = "POSEIDON2_B_34_0"; + Base::poseidon2_B_34_1 = "POSEIDON2_B_34_1"; + Base::poseidon2_B_34_2 = "POSEIDON2_B_34_2"; + Base::poseidon2_B_34_3 = "POSEIDON2_B_34_3"; + Base::poseidon2_B_35_0 = "POSEIDON2_B_35_0"; + Base::poseidon2_B_35_1 = "POSEIDON2_B_35_1"; + Base::poseidon2_B_35_2 = "POSEIDON2_B_35_2"; + Base::poseidon2_B_35_3 = "POSEIDON2_B_35_3"; + Base::poseidon2_B_36_0 = "POSEIDON2_B_36_0"; + Base::poseidon2_B_36_1 = "POSEIDON2_B_36_1"; + Base::poseidon2_B_36_2 = "POSEIDON2_B_36_2"; + Base::poseidon2_B_36_3 = "POSEIDON2_B_36_3"; + Base::poseidon2_B_37_0 = "POSEIDON2_B_37_0"; + Base::poseidon2_B_37_1 = "POSEIDON2_B_37_1"; + Base::poseidon2_B_37_2 = "POSEIDON2_B_37_2"; + Base::poseidon2_B_37_3 = "POSEIDON2_B_37_3"; + Base::poseidon2_B_38_0 = "POSEIDON2_B_38_0"; + Base::poseidon2_B_38_1 = "POSEIDON2_B_38_1"; + Base::poseidon2_B_38_2 = "POSEIDON2_B_38_2"; + Base::poseidon2_B_38_3 = "POSEIDON2_B_38_3"; + Base::poseidon2_B_39_0 = "POSEIDON2_B_39_0"; + Base::poseidon2_B_39_1 = "POSEIDON2_B_39_1"; + Base::poseidon2_B_39_2 = "POSEIDON2_B_39_2"; + Base::poseidon2_B_39_3 = "POSEIDON2_B_39_3"; + Base::poseidon2_B_40_0 = "POSEIDON2_B_40_0"; + Base::poseidon2_B_40_1 = "POSEIDON2_B_40_1"; + Base::poseidon2_B_40_2 = "POSEIDON2_B_40_2"; + Base::poseidon2_B_40_3 = "POSEIDON2_B_40_3"; + Base::poseidon2_B_41_0 = "POSEIDON2_B_41_0"; + Base::poseidon2_B_41_1 = "POSEIDON2_B_41_1"; + Base::poseidon2_B_41_2 = "POSEIDON2_B_41_2"; + Base::poseidon2_B_41_3 = "POSEIDON2_B_41_3"; + Base::poseidon2_B_42_0 = "POSEIDON2_B_42_0"; + Base::poseidon2_B_42_1 = "POSEIDON2_B_42_1"; + Base::poseidon2_B_42_2 = "POSEIDON2_B_42_2"; + Base::poseidon2_B_42_3 = "POSEIDON2_B_42_3"; + Base::poseidon2_B_43_0 = "POSEIDON2_B_43_0"; + Base::poseidon2_B_43_1 = "POSEIDON2_B_43_1"; + Base::poseidon2_B_43_2 = "POSEIDON2_B_43_2"; + Base::poseidon2_B_43_3 = "POSEIDON2_B_43_3"; + Base::poseidon2_B_44_0 = "POSEIDON2_B_44_0"; + Base::poseidon2_B_44_1 = "POSEIDON2_B_44_1"; + Base::poseidon2_B_44_2 = "POSEIDON2_B_44_2"; + Base::poseidon2_B_44_3 = "POSEIDON2_B_44_3"; + Base::poseidon2_B_45_0 = "POSEIDON2_B_45_0"; + Base::poseidon2_B_45_1 = "POSEIDON2_B_45_1"; + Base::poseidon2_B_45_2 = "POSEIDON2_B_45_2"; + Base::poseidon2_B_45_3 = "POSEIDON2_B_45_3"; + Base::poseidon2_B_46_0 = "POSEIDON2_B_46_0"; + Base::poseidon2_B_46_1 = "POSEIDON2_B_46_1"; + Base::poseidon2_B_46_2 = "POSEIDON2_B_46_2"; + Base::poseidon2_B_46_3 = "POSEIDON2_B_46_3"; + Base::poseidon2_B_47_0 = "POSEIDON2_B_47_0"; + Base::poseidon2_B_47_1 = "POSEIDON2_B_47_1"; + Base::poseidon2_B_47_2 = "POSEIDON2_B_47_2"; + Base::poseidon2_B_47_3 = "POSEIDON2_B_47_3"; + Base::poseidon2_B_48_0 = "POSEIDON2_B_48_0"; + Base::poseidon2_B_48_1 = "POSEIDON2_B_48_1"; + Base::poseidon2_B_48_2 = "POSEIDON2_B_48_2"; + Base::poseidon2_B_48_3 = "POSEIDON2_B_48_3"; + Base::poseidon2_B_49_0 = "POSEIDON2_B_49_0"; + Base::poseidon2_B_49_1 = "POSEIDON2_B_49_1"; + Base::poseidon2_B_49_2 = "POSEIDON2_B_49_2"; + Base::poseidon2_B_49_3 = "POSEIDON2_B_49_3"; + Base::poseidon2_B_4_0 = "POSEIDON2_B_4_0"; + Base::poseidon2_B_4_1 = "POSEIDON2_B_4_1"; + Base::poseidon2_B_4_2 = "POSEIDON2_B_4_2"; + Base::poseidon2_B_4_3 = "POSEIDON2_B_4_3"; + Base::poseidon2_B_50_0 = "POSEIDON2_B_50_0"; + Base::poseidon2_B_50_1 = "POSEIDON2_B_50_1"; + Base::poseidon2_B_50_2 = "POSEIDON2_B_50_2"; + Base::poseidon2_B_50_3 = "POSEIDON2_B_50_3"; + Base::poseidon2_B_51_0 = "POSEIDON2_B_51_0"; + Base::poseidon2_B_51_1 = "POSEIDON2_B_51_1"; + Base::poseidon2_B_51_2 = "POSEIDON2_B_51_2"; + Base::poseidon2_B_51_3 = "POSEIDON2_B_51_3"; + Base::poseidon2_B_52_0 = "POSEIDON2_B_52_0"; + Base::poseidon2_B_52_1 = "POSEIDON2_B_52_1"; + Base::poseidon2_B_52_2 = "POSEIDON2_B_52_2"; + Base::poseidon2_B_52_3 = "POSEIDON2_B_52_3"; + Base::poseidon2_B_53_0 = "POSEIDON2_B_53_0"; + Base::poseidon2_B_53_1 = "POSEIDON2_B_53_1"; + Base::poseidon2_B_53_2 = "POSEIDON2_B_53_2"; + Base::poseidon2_B_53_3 = "POSEIDON2_B_53_3"; + Base::poseidon2_B_54_0 = "POSEIDON2_B_54_0"; + Base::poseidon2_B_54_1 = "POSEIDON2_B_54_1"; + Base::poseidon2_B_54_2 = "POSEIDON2_B_54_2"; + Base::poseidon2_B_54_3 = "POSEIDON2_B_54_3"; + Base::poseidon2_B_55_0 = "POSEIDON2_B_55_0"; + Base::poseidon2_B_55_1 = "POSEIDON2_B_55_1"; + Base::poseidon2_B_55_2 = "POSEIDON2_B_55_2"; + Base::poseidon2_B_55_3 = "POSEIDON2_B_55_3"; + Base::poseidon2_B_56_0 = "POSEIDON2_B_56_0"; + Base::poseidon2_B_56_1 = "POSEIDON2_B_56_1"; + Base::poseidon2_B_56_2 = "POSEIDON2_B_56_2"; + Base::poseidon2_B_56_3 = "POSEIDON2_B_56_3"; + Base::poseidon2_B_57_0 = "POSEIDON2_B_57_0"; + Base::poseidon2_B_57_1 = "POSEIDON2_B_57_1"; + Base::poseidon2_B_57_2 = "POSEIDON2_B_57_2"; + Base::poseidon2_B_57_3 = "POSEIDON2_B_57_3"; + Base::poseidon2_B_58_0 = "POSEIDON2_B_58_0"; + Base::poseidon2_B_58_1 = "POSEIDON2_B_58_1"; + Base::poseidon2_B_58_2 = "POSEIDON2_B_58_2"; + Base::poseidon2_B_58_3 = "POSEIDON2_B_58_3"; + Base::poseidon2_B_59_0 = "POSEIDON2_B_59_0"; + Base::poseidon2_B_59_1 = "POSEIDON2_B_59_1"; + Base::poseidon2_B_59_2 = "POSEIDON2_B_59_2"; + Base::poseidon2_B_59_3 = "POSEIDON2_B_59_3"; + Base::poseidon2_B_5_0 = "POSEIDON2_B_5_0"; + Base::poseidon2_B_5_1 = "POSEIDON2_B_5_1"; + Base::poseidon2_B_5_2 = "POSEIDON2_B_5_2"; + Base::poseidon2_B_5_3 = "POSEIDON2_B_5_3"; + Base::poseidon2_B_6_0 = "POSEIDON2_B_6_0"; + Base::poseidon2_B_6_1 = "POSEIDON2_B_6_1"; + Base::poseidon2_B_6_2 = "POSEIDON2_B_6_2"; + Base::poseidon2_B_6_3 = "POSEIDON2_B_6_3"; + Base::poseidon2_B_7_0 = "POSEIDON2_B_7_0"; + Base::poseidon2_B_7_1 = "POSEIDON2_B_7_1"; + Base::poseidon2_B_7_2 = "POSEIDON2_B_7_2"; + Base::poseidon2_B_7_3 = "POSEIDON2_B_7_3"; + Base::poseidon2_B_8_0 = "POSEIDON2_B_8_0"; + Base::poseidon2_B_8_1 = "POSEIDON2_B_8_1"; + Base::poseidon2_B_8_2 = "POSEIDON2_B_8_2"; + Base::poseidon2_B_8_3 = "POSEIDON2_B_8_3"; + Base::poseidon2_B_9_0 = "POSEIDON2_B_9_0"; + Base::poseidon2_B_9_1 = "POSEIDON2_B_9_1"; + Base::poseidon2_B_9_2 = "POSEIDON2_B_9_2"; + Base::poseidon2_B_9_3 = "POSEIDON2_B_9_3"; + Base::poseidon2_EXT_LAYER_4 = "POSEIDON2_EXT_LAYER_4"; + Base::poseidon2_EXT_LAYER_5 = "POSEIDON2_EXT_LAYER_5"; + Base::poseidon2_EXT_LAYER_6 = "POSEIDON2_EXT_LAYER_6"; + Base::poseidon2_EXT_LAYER_7 = "POSEIDON2_EXT_LAYER_7"; + Base::poseidon2_T_0_4 = "POSEIDON2_T_0_4"; + Base::poseidon2_T_0_5 = "POSEIDON2_T_0_5"; + Base::poseidon2_T_0_6 = "POSEIDON2_T_0_6"; + Base::poseidon2_T_0_7 = "POSEIDON2_T_0_7"; + Base::poseidon2_T_1_4 = "POSEIDON2_T_1_4"; + Base::poseidon2_T_1_5 = "POSEIDON2_T_1_5"; + Base::poseidon2_T_1_6 = "POSEIDON2_T_1_6"; + Base::poseidon2_T_1_7 = "POSEIDON2_T_1_7"; + Base::poseidon2_T_2_4 = "POSEIDON2_T_2_4"; + Base::poseidon2_T_2_5 = "POSEIDON2_T_2_5"; + Base::poseidon2_T_2_6 = "POSEIDON2_T_2_6"; + Base::poseidon2_T_2_7 = "POSEIDON2_T_2_7"; + Base::poseidon2_T_3_4 = "POSEIDON2_T_3_4"; + Base::poseidon2_T_3_5 = "POSEIDON2_T_3_5"; + Base::poseidon2_T_3_6 = "POSEIDON2_T_3_6"; + Base::poseidon2_T_3_7 = "POSEIDON2_T_3_7"; + Base::poseidon2_T_60_4 = "POSEIDON2_T_60_4"; + Base::poseidon2_T_60_5 = "POSEIDON2_T_60_5"; + Base::poseidon2_T_60_6 = "POSEIDON2_T_60_6"; + Base::poseidon2_T_60_7 = "POSEIDON2_T_60_7"; + Base::poseidon2_T_61_4 = "POSEIDON2_T_61_4"; + Base::poseidon2_T_61_5 = "POSEIDON2_T_61_5"; + Base::poseidon2_T_61_6 = "POSEIDON2_T_61_6"; + Base::poseidon2_T_61_7 = "POSEIDON2_T_61_7"; + Base::poseidon2_T_62_4 = "POSEIDON2_T_62_4"; + Base::poseidon2_T_62_5 = "POSEIDON2_T_62_5"; + Base::poseidon2_T_62_6 = "POSEIDON2_T_62_6"; + Base::poseidon2_T_62_7 = "POSEIDON2_T_62_7"; + Base::poseidon2_T_63_4 = "POSEIDON2_T_63_4"; + Base::poseidon2_T_63_5 = "POSEIDON2_T_63_5"; + Base::poseidon2_T_63_6 = "POSEIDON2_T_63_6"; + Base::poseidon2_T_63_7 = "POSEIDON2_T_63_7"; + Base::poseidon2_a_0 = "POSEIDON2_A_0"; + Base::poseidon2_a_1 = "POSEIDON2_A_1"; + Base::poseidon2_a_2 = "POSEIDON2_A_2"; + Base::poseidon2_a_3 = "POSEIDON2_A_3"; + Base::poseidon2_b_0 = "POSEIDON2_B_0"; + Base::poseidon2_b_1 = "POSEIDON2_B_1"; + Base::poseidon2_b_2 = "POSEIDON2_B_2"; + Base::poseidon2_b_3 = "POSEIDON2_B_3"; Base::poseidon2_clk = "POSEIDON2_CLK"; - Base::poseidon2_input = "POSEIDON2_INPUT"; - Base::poseidon2_output = "POSEIDON2_OUTPUT"; + Base::poseidon2_input_addr = "POSEIDON2_INPUT_ADDR"; + Base::poseidon2_mem_addr_read_a = "POSEIDON2_MEM_ADDR_READ_A"; + Base::poseidon2_mem_addr_read_b = "POSEIDON2_MEM_ADDR_READ_B"; + Base::poseidon2_mem_addr_read_c = "POSEIDON2_MEM_ADDR_READ_C"; + Base::poseidon2_mem_addr_read_d = "POSEIDON2_MEM_ADDR_READ_D"; + Base::poseidon2_mem_addr_write_a = "POSEIDON2_MEM_ADDR_WRITE_A"; + Base::poseidon2_mem_addr_write_b = "POSEIDON2_MEM_ADDR_WRITE_B"; + Base::poseidon2_mem_addr_write_c = "POSEIDON2_MEM_ADDR_WRITE_C"; + Base::poseidon2_mem_addr_write_d = "POSEIDON2_MEM_ADDR_WRITE_D"; + Base::poseidon2_output_addr = "POSEIDON2_OUTPUT_ADDR"; Base::poseidon2_sel_poseidon_perm = "POSEIDON2_SEL_POSEIDON_PERM"; Base::powers_power_of_2 = "POWERS_POWER_OF_2"; Base::sha256_clk = "SHA256_CLK"; @@ -1305,6 +2176,14 @@ AvmFlavor::CommitmentLabels::CommitmentLabels() Base::slice_sel_start = "SLICE_SEL_START"; Base::slice_space_id = "SLICE_SPACE_ID"; Base::slice_val = "SLICE_VAL"; + Base::perm_pos_mem_read_a = "PERM_POS_MEM_READ_A"; + Base::perm_pos_mem_read_b = "PERM_POS_MEM_READ_B"; + Base::perm_pos_mem_read_c = "PERM_POS_MEM_READ_C"; + Base::perm_pos_mem_read_d = "PERM_POS_MEM_READ_D"; + Base::perm_pos_mem_write_a = "PERM_POS_MEM_WRITE_A"; + Base::perm_pos_mem_write_b = "PERM_POS_MEM_WRITE_B"; + Base::perm_pos_mem_write_c = "PERM_POS_MEM_WRITE_C"; + Base::perm_pos_mem_write_d = "PERM_POS_MEM_WRITE_D"; Base::perm_slice_mem = "PERM_SLICE_MEM"; Base::perm_main_alu = "PERM_MAIN_ALU"; Base::perm_main_bin = "PERM_MAIN_BIN"; @@ -1412,6 +2291,7 @@ AvmFlavor::VerifierCommitments::VerifierCommitments(const std::shared_ptrmain_clk; main_sel_first = verification_key->main_sel_first; + main_zeroes = verification_key->main_zeroes; } void AvmFlavor::Transcript::deserialize_full_transcript() diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/flavor.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/flavor.hpp index 40854a1cddbc..0ae00ebb3529 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/flavor.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/flavor.hpp @@ -84,6 +84,14 @@ #include "barretenberg/vm/avm/generated/relations/perm_main_pedersen.hpp" #include "barretenberg/vm/avm/generated/relations/perm_main_pos2_perm.hpp" #include "barretenberg/vm/avm/generated/relations/perm_main_slice.hpp" +#include "barretenberg/vm/avm/generated/relations/perm_pos_mem_read_a.hpp" +#include "barretenberg/vm/avm/generated/relations/perm_pos_mem_read_b.hpp" +#include "barretenberg/vm/avm/generated/relations/perm_pos_mem_read_c.hpp" +#include "barretenberg/vm/avm/generated/relations/perm_pos_mem_read_d.hpp" +#include "barretenberg/vm/avm/generated/relations/perm_pos_mem_write_a.hpp" +#include "barretenberg/vm/avm/generated/relations/perm_pos_mem_write_b.hpp" +#include "barretenberg/vm/avm/generated/relations/perm_pos_mem_write_c.hpp" +#include "barretenberg/vm/avm/generated/relations/perm_pos_mem_write_d.hpp" #include "barretenberg/vm/avm/generated/relations/perm_slice_mem.hpp" #include "barretenberg/vm/avm/generated/relations/range_check_da_gas_hi.hpp" #include "barretenberg/vm/avm/generated/relations/range_check_da_gas_lo.hpp" @@ -95,9 +103,9 @@ template using tuple_cat_t = decltype(std::tuple_cat(std:: // The entities that will be used in the flavor. // clang-format off -#define PRECOMPUTED_ENTITIES main_clk, main_sel_first -#define WIRE_ENTITIES kernel_kernel_inputs, kernel_kernel_value_out, kernel_kernel_side_effect_out, kernel_kernel_metadata_out, main_calldata, main_returndata, alu_a_hi, alu_a_lo, alu_b_hi, alu_b_lo, alu_borrow, alu_cf, alu_clk, alu_cmp_rng_ctr, alu_div_u16_r0, alu_div_u16_r1, alu_div_u16_r2, alu_div_u16_r3, alu_div_u16_r4, alu_div_u16_r5, alu_div_u16_r6, alu_div_u16_r7, alu_divisor_hi, alu_divisor_lo, alu_ff_tag, alu_ia, alu_ib, alu_ic, alu_in_tag, alu_op_add, alu_op_cast, alu_op_cast_prev, alu_op_div, alu_op_div_a_lt_b, alu_op_div_std, alu_op_eq, alu_op_eq_diff_inv, alu_op_lt, alu_op_lte, alu_op_mul, alu_op_not, alu_op_shl, alu_op_shr, alu_op_sub, alu_p_a_borrow, alu_p_b_borrow, alu_p_sub_a_hi, alu_p_sub_a_lo, alu_p_sub_b_hi, alu_p_sub_b_lo, alu_partial_prod_hi, alu_partial_prod_lo, alu_quotient_hi, alu_quotient_lo, alu_remainder, alu_res_hi, alu_res_lo, alu_sel_alu, alu_sel_cmp, alu_sel_div_rng_chk, alu_sel_rng_chk, alu_sel_rng_chk_lookup, alu_sel_shift_which, alu_shift_lt_bit_len, alu_t_sub_s_bits, alu_two_pow_s, alu_two_pow_t_sub_s, alu_u128_tag, alu_u16_r0, alu_u16_r1, alu_u16_r10, alu_u16_r11, alu_u16_r12, alu_u16_r13, alu_u16_r14, alu_u16_r2, alu_u16_r3, alu_u16_r4, alu_u16_r5, alu_u16_r6, alu_u16_r7, alu_u16_r8, alu_u16_r9, alu_u16_tag, alu_u32_tag, alu_u64_tag, alu_u8_r0, alu_u8_r1, alu_u8_tag, binary_acc_ia, binary_acc_ib, binary_acc_ic, binary_clk, binary_ia_bytes, binary_ib_bytes, binary_ic_bytes, binary_in_tag, binary_mem_tag_ctr, binary_mem_tag_ctr_inv, binary_op_id, binary_sel_bin, binary_start, byte_lookup_sel_bin, byte_lookup_table_byte_lengths, byte_lookup_table_in_tags, byte_lookup_table_input_a, byte_lookup_table_input_b, byte_lookup_table_op_id, byte_lookup_table_output, conversion_clk, conversion_input, conversion_num_limbs, conversion_radix, conversion_sel_to_radix_le, gas_da_gas_fixed_table, gas_l2_gas_fixed_table, gas_sel_gas_cost, keccakf1600_clk, keccakf1600_input, keccakf1600_output, keccakf1600_sel_keccakf1600, kernel_emit_l2_to_l1_msg_write_offset, kernel_emit_note_hash_write_offset, kernel_emit_nullifier_write_offset, kernel_emit_unencrypted_log_write_offset, kernel_kernel_in_offset, kernel_kernel_out_offset, kernel_l1_to_l2_msg_exists_write_offset, kernel_note_hash_exist_write_offset, kernel_nullifier_exists_write_offset, kernel_nullifier_non_exists_write_offset, kernel_q_public_input_kernel_add_to_table, kernel_q_public_input_kernel_out_add_to_table, kernel_side_effect_counter, kernel_sload_write_offset, kernel_sstore_write_offset, main_abs_da_rem_gas_hi, main_abs_da_rem_gas_lo, main_abs_l2_rem_gas_hi, main_abs_l2_rem_gas_lo, main_alu_in_tag, main_bin_op_id, main_call_ptr, main_da_gas_op_cost, main_da_gas_remaining, main_da_out_of_gas, main_ia, main_ib, main_ic, main_id, main_id_zero, main_ind_addr_a, main_ind_addr_b, main_ind_addr_c, main_ind_addr_d, main_internal_return_ptr, main_inv, main_l2_gas_op_cost, main_l2_gas_remaining, main_l2_out_of_gas, main_mem_addr_a, main_mem_addr_b, main_mem_addr_c, main_mem_addr_d, main_op_err, main_opcode_val, main_pc, main_r_in_tag, main_rwa, main_rwb, main_rwc, main_rwd, main_sel_alu, main_sel_bin, main_sel_calldata, main_sel_gas_accounting_active, main_sel_last, main_sel_mem_op_a, main_sel_mem_op_activate_gas, main_sel_mem_op_b, main_sel_mem_op_c, main_sel_mem_op_d, main_sel_mov_ia_to_ic, main_sel_mov_ib_to_ic, main_sel_op_add, main_sel_op_address, main_sel_op_and, main_sel_op_block_number, main_sel_op_calldata_copy, main_sel_op_cast, main_sel_op_chain_id, main_sel_op_cmov, main_sel_op_coinbase, main_sel_op_dagasleft, main_sel_op_div, main_sel_op_emit_l2_to_l1_msg, main_sel_op_emit_note_hash, main_sel_op_emit_nullifier, main_sel_op_emit_unencrypted_log, main_sel_op_eq, main_sel_op_external_call, main_sel_op_external_return, main_sel_op_fdiv, main_sel_op_fee_per_da_gas, main_sel_op_fee_per_l2_gas, main_sel_op_function_selector, main_sel_op_get_contract_instance, main_sel_op_halt, main_sel_op_internal_call, main_sel_op_internal_return, main_sel_op_jump, main_sel_op_jumpi, main_sel_op_keccak, main_sel_op_l1_to_l2_msg_exists, main_sel_op_l2gasleft, main_sel_op_lt, main_sel_op_lte, main_sel_op_mov, main_sel_op_mul, main_sel_op_not, main_sel_op_note_hash_exists, main_sel_op_nullifier_exists, main_sel_op_or, main_sel_op_pedersen, main_sel_op_poseidon2, main_sel_op_radix_le, main_sel_op_sender, main_sel_op_sha256, main_sel_op_shl, main_sel_op_shr, main_sel_op_sload, main_sel_op_sstore, main_sel_op_storage_address, main_sel_op_sub, main_sel_op_timestamp, main_sel_op_transaction_fee, main_sel_op_version, main_sel_op_xor, main_sel_q_kernel_lookup, main_sel_q_kernel_output_lookup, main_sel_resolve_ind_addr_a, main_sel_resolve_ind_addr_b, main_sel_resolve_ind_addr_c, main_sel_resolve_ind_addr_d, main_sel_returndata, main_sel_rng_16, main_sel_rng_8, main_sel_slice_gadget, main_space_id, main_tag_err, main_w_in_tag, mem_addr, mem_clk, mem_diff_hi, mem_diff_lo, mem_diff_mid, mem_glob_addr, mem_last, mem_lastAccess, mem_one_min_inv, mem_r_in_tag, mem_rw, mem_sel_mem, mem_sel_mov_ia_to_ic, mem_sel_mov_ib_to_ic, mem_sel_op_a, mem_sel_op_b, mem_sel_op_c, mem_sel_op_cmov, mem_sel_op_d, mem_sel_op_slice, mem_sel_resolve_ind_addr_a, mem_sel_resolve_ind_addr_b, mem_sel_resolve_ind_addr_c, mem_sel_resolve_ind_addr_d, mem_sel_rng_chk, mem_skip_check_tag, mem_space_id, mem_tag, mem_tag_err, mem_tsp, mem_val, mem_w_in_tag, pedersen_clk, pedersen_input, pedersen_output, pedersen_sel_pedersen, poseidon2_clk, poseidon2_input, poseidon2_output, poseidon2_sel_poseidon_perm, powers_power_of_2, sha256_clk, sha256_input, sha256_output, sha256_sel_sha256_compression, sha256_state, slice_addr, slice_clk, slice_cnt, slice_col_offset, slice_one_min_inv, slice_sel_cd_cpy, slice_sel_mem_active, slice_sel_return, slice_sel_start, slice_space_id, slice_val, lookup_byte_lengths_counts, lookup_byte_operations_counts, lookup_cd_value_counts, lookup_ret_value_counts, lookup_opcode_gas_counts, range_check_l2_gas_hi_counts, range_check_l2_gas_lo_counts, range_check_da_gas_hi_counts, range_check_da_gas_lo_counts, kernel_output_lookup_counts, lookup_into_kernel_counts, incl_main_tag_err_counts, incl_mem_tag_err_counts, lookup_mem_rng_chk_lo_counts, lookup_mem_rng_chk_mid_counts, lookup_mem_rng_chk_hi_counts, lookup_pow_2_0_counts, lookup_pow_2_1_counts, lookup_u8_0_counts, lookup_u8_1_counts, lookup_u16_0_counts, lookup_u16_1_counts, lookup_u16_2_counts, lookup_u16_3_counts, lookup_u16_4_counts, lookup_u16_5_counts, lookup_u16_6_counts, lookup_u16_7_counts, lookup_u16_8_counts, lookup_u16_9_counts, lookup_u16_10_counts, lookup_u16_11_counts, lookup_u16_12_counts, lookup_u16_13_counts, lookup_u16_14_counts, lookup_div_u16_0_counts, lookup_div_u16_1_counts, lookup_div_u16_2_counts, lookup_div_u16_3_counts, lookup_div_u16_4_counts, lookup_div_u16_5_counts, lookup_div_u16_6_counts, lookup_div_u16_7_counts -#define DERIVED_WITNESS_ENTITIES perm_slice_mem, perm_main_alu, perm_main_bin, perm_main_conv, perm_main_pos2_perm, perm_main_pedersen, perm_main_slice, perm_main_mem_a, perm_main_mem_b, perm_main_mem_c, perm_main_mem_d, perm_main_mem_ind_addr_a, perm_main_mem_ind_addr_b, perm_main_mem_ind_addr_c, perm_main_mem_ind_addr_d, lookup_byte_lengths, lookup_byte_operations, lookup_cd_value, lookup_ret_value, lookup_opcode_gas, range_check_l2_gas_hi, range_check_l2_gas_lo, range_check_da_gas_hi, range_check_da_gas_lo, kernel_output_lookup, lookup_into_kernel, incl_main_tag_err, incl_mem_tag_err, lookup_mem_rng_chk_lo, lookup_mem_rng_chk_mid, lookup_mem_rng_chk_hi, lookup_pow_2_0, lookup_pow_2_1, lookup_u8_0, lookup_u8_1, lookup_u16_0, lookup_u16_1, lookup_u16_2, lookup_u16_3, lookup_u16_4, lookup_u16_5, lookup_u16_6, lookup_u16_7, lookup_u16_8, lookup_u16_9, lookup_u16_10, lookup_u16_11, lookup_u16_12, lookup_u16_13, lookup_u16_14, lookup_div_u16_0, lookup_div_u16_1, lookup_div_u16_2, lookup_div_u16_3, lookup_div_u16_4, lookup_div_u16_5, lookup_div_u16_6, lookup_div_u16_7 +#define PRECOMPUTED_ENTITIES main_clk, main_sel_first, main_zeroes +#define WIRE_ENTITIES kernel_kernel_inputs, kernel_kernel_value_out, kernel_kernel_side_effect_out, kernel_kernel_metadata_out, main_calldata, main_returndata, alu_a_hi, alu_a_lo, alu_b_hi, alu_b_lo, alu_borrow, alu_cf, alu_clk, alu_cmp_rng_ctr, alu_div_u16_r0, alu_div_u16_r1, alu_div_u16_r2, alu_div_u16_r3, alu_div_u16_r4, alu_div_u16_r5, alu_div_u16_r6, alu_div_u16_r7, alu_divisor_hi, alu_divisor_lo, alu_ff_tag, alu_ia, alu_ib, alu_ic, alu_in_tag, alu_op_add, alu_op_cast, alu_op_cast_prev, alu_op_div, alu_op_div_a_lt_b, alu_op_div_std, alu_op_eq, alu_op_eq_diff_inv, alu_op_lt, alu_op_lte, alu_op_mul, alu_op_not, alu_op_shl, alu_op_shr, alu_op_sub, alu_p_a_borrow, alu_p_b_borrow, alu_p_sub_a_hi, alu_p_sub_a_lo, alu_p_sub_b_hi, alu_p_sub_b_lo, alu_partial_prod_hi, alu_partial_prod_lo, alu_quotient_hi, alu_quotient_lo, alu_remainder, alu_res_hi, alu_res_lo, alu_sel_alu, alu_sel_cmp, alu_sel_div_rng_chk, alu_sel_rng_chk, alu_sel_rng_chk_lookup, alu_sel_shift_which, alu_shift_lt_bit_len, alu_t_sub_s_bits, alu_two_pow_s, alu_two_pow_t_sub_s, alu_u128_tag, alu_u16_r0, alu_u16_r1, alu_u16_r10, alu_u16_r11, alu_u16_r12, alu_u16_r13, alu_u16_r14, alu_u16_r2, alu_u16_r3, alu_u16_r4, alu_u16_r5, alu_u16_r6, alu_u16_r7, alu_u16_r8, alu_u16_r9, alu_u16_tag, alu_u32_tag, alu_u64_tag, alu_u8_r0, alu_u8_r1, alu_u8_tag, binary_acc_ia, binary_acc_ib, binary_acc_ic, binary_clk, binary_ia_bytes, binary_ib_bytes, binary_ic_bytes, binary_in_tag, binary_mem_tag_ctr, binary_mem_tag_ctr_inv, binary_op_id, binary_sel_bin, binary_start, byte_lookup_sel_bin, byte_lookup_table_byte_lengths, byte_lookup_table_in_tags, byte_lookup_table_input_a, byte_lookup_table_input_b, byte_lookup_table_op_id, byte_lookup_table_output, conversion_clk, conversion_input, conversion_num_limbs, conversion_radix, conversion_sel_to_radix_le, gas_da_gas_fixed_table, gas_l2_gas_fixed_table, gas_sel_gas_cost, keccakf1600_clk, keccakf1600_input, keccakf1600_output, keccakf1600_sel_keccakf1600, kernel_emit_l2_to_l1_msg_write_offset, kernel_emit_note_hash_write_offset, kernel_emit_nullifier_write_offset, kernel_emit_unencrypted_log_write_offset, kernel_kernel_in_offset, kernel_kernel_out_offset, kernel_l1_to_l2_msg_exists_write_offset, kernel_note_hash_exist_write_offset, kernel_nullifier_exists_write_offset, kernel_nullifier_non_exists_write_offset, kernel_q_public_input_kernel_add_to_table, kernel_q_public_input_kernel_out_add_to_table, kernel_side_effect_counter, kernel_sload_write_offset, kernel_sstore_write_offset, main_abs_da_rem_gas_hi, main_abs_da_rem_gas_lo, main_abs_l2_rem_gas_hi, main_abs_l2_rem_gas_lo, main_alu_in_tag, main_bin_op_id, main_call_ptr, main_da_gas_op_cost, main_da_gas_remaining, main_da_out_of_gas, main_ia, main_ib, main_ic, main_id, main_id_zero, main_ind_addr_a, main_ind_addr_b, main_ind_addr_c, main_ind_addr_d, main_internal_return_ptr, main_inv, main_l2_gas_op_cost, main_l2_gas_remaining, main_l2_out_of_gas, main_mem_addr_a, main_mem_addr_b, main_mem_addr_c, main_mem_addr_d, main_op_err, main_opcode_val, main_pc, main_r_in_tag, main_rwa, main_rwb, main_rwc, main_rwd, main_sel_alu, main_sel_bin, main_sel_calldata, main_sel_gas_accounting_active, main_sel_last, main_sel_mem_op_a, main_sel_mem_op_activate_gas, main_sel_mem_op_b, main_sel_mem_op_c, main_sel_mem_op_d, main_sel_mov_ia_to_ic, main_sel_mov_ib_to_ic, main_sel_op_add, main_sel_op_address, main_sel_op_and, main_sel_op_block_number, main_sel_op_calldata_copy, main_sel_op_cast, main_sel_op_chain_id, main_sel_op_cmov, main_sel_op_coinbase, main_sel_op_dagasleft, main_sel_op_div, main_sel_op_emit_l2_to_l1_msg, main_sel_op_emit_note_hash, main_sel_op_emit_nullifier, main_sel_op_emit_unencrypted_log, main_sel_op_eq, main_sel_op_external_call, main_sel_op_external_return, main_sel_op_fdiv, main_sel_op_fee_per_da_gas, main_sel_op_fee_per_l2_gas, main_sel_op_function_selector, main_sel_op_get_contract_instance, main_sel_op_halt, main_sel_op_internal_call, main_sel_op_internal_return, main_sel_op_jump, main_sel_op_jumpi, main_sel_op_keccak, main_sel_op_l1_to_l2_msg_exists, main_sel_op_l2gasleft, main_sel_op_lt, main_sel_op_lte, main_sel_op_mov, main_sel_op_mul, main_sel_op_not, main_sel_op_note_hash_exists, main_sel_op_nullifier_exists, main_sel_op_or, main_sel_op_pedersen, main_sel_op_poseidon2, main_sel_op_radix_le, main_sel_op_sender, main_sel_op_sha256, main_sel_op_shl, main_sel_op_shr, main_sel_op_sload, main_sel_op_sstore, main_sel_op_storage_address, main_sel_op_sub, main_sel_op_timestamp, main_sel_op_transaction_fee, main_sel_op_version, main_sel_op_xor, main_sel_q_kernel_lookup, main_sel_q_kernel_output_lookup, main_sel_resolve_ind_addr_a, main_sel_resolve_ind_addr_b, main_sel_resolve_ind_addr_c, main_sel_resolve_ind_addr_d, main_sel_returndata, main_sel_rng_16, main_sel_rng_8, main_sel_slice_gadget, main_space_id, main_tag_err, main_w_in_tag, mem_addr, mem_clk, mem_diff_hi, mem_diff_lo, mem_diff_mid, mem_glob_addr, mem_last, mem_lastAccess, mem_one_min_inv, mem_r_in_tag, mem_rw, mem_sel_mem, mem_sel_mov_ia_to_ic, mem_sel_mov_ib_to_ic, mem_sel_op_a, mem_sel_op_b, mem_sel_op_c, mem_sel_op_cmov, mem_sel_op_d, mem_sel_op_poseidon_read_a, mem_sel_op_poseidon_read_b, mem_sel_op_poseidon_read_c, mem_sel_op_poseidon_read_d, mem_sel_op_poseidon_write_a, mem_sel_op_poseidon_write_b, mem_sel_op_poseidon_write_c, mem_sel_op_poseidon_write_d, mem_sel_op_slice, mem_sel_resolve_ind_addr_a, mem_sel_resolve_ind_addr_b, mem_sel_resolve_ind_addr_c, mem_sel_resolve_ind_addr_d, mem_sel_rng_chk, mem_skip_check_tag, mem_space_id, mem_tag, mem_tag_err, mem_tsp, mem_val, mem_w_in_tag, pedersen_clk, pedersen_input, pedersen_output, pedersen_sel_pedersen, poseidon2_B_10_0, poseidon2_B_10_1, poseidon2_B_10_2, poseidon2_B_10_3, poseidon2_B_11_0, poseidon2_B_11_1, poseidon2_B_11_2, poseidon2_B_11_3, poseidon2_B_12_0, poseidon2_B_12_1, poseidon2_B_12_2, poseidon2_B_12_3, poseidon2_B_13_0, poseidon2_B_13_1, poseidon2_B_13_2, poseidon2_B_13_3, poseidon2_B_14_0, poseidon2_B_14_1, poseidon2_B_14_2, poseidon2_B_14_3, poseidon2_B_15_0, poseidon2_B_15_1, poseidon2_B_15_2, poseidon2_B_15_3, poseidon2_B_16_0, poseidon2_B_16_1, poseidon2_B_16_2, poseidon2_B_16_3, poseidon2_B_17_0, poseidon2_B_17_1, poseidon2_B_17_2, poseidon2_B_17_3, poseidon2_B_18_0, poseidon2_B_18_1, poseidon2_B_18_2, poseidon2_B_18_3, poseidon2_B_19_0, poseidon2_B_19_1, poseidon2_B_19_2, poseidon2_B_19_3, poseidon2_B_20_0, poseidon2_B_20_1, poseidon2_B_20_2, poseidon2_B_20_3, poseidon2_B_21_0, poseidon2_B_21_1, poseidon2_B_21_2, poseidon2_B_21_3, poseidon2_B_22_0, poseidon2_B_22_1, poseidon2_B_22_2, poseidon2_B_22_3, poseidon2_B_23_0, poseidon2_B_23_1, poseidon2_B_23_2, poseidon2_B_23_3, poseidon2_B_24_0, poseidon2_B_24_1, poseidon2_B_24_2, poseidon2_B_24_3, poseidon2_B_25_0, poseidon2_B_25_1, poseidon2_B_25_2, poseidon2_B_25_3, poseidon2_B_26_0, poseidon2_B_26_1, poseidon2_B_26_2, poseidon2_B_26_3, poseidon2_B_27_0, poseidon2_B_27_1, poseidon2_B_27_2, poseidon2_B_27_3, poseidon2_B_28_0, poseidon2_B_28_1, poseidon2_B_28_2, poseidon2_B_28_3, poseidon2_B_29_0, poseidon2_B_29_1, poseidon2_B_29_2, poseidon2_B_29_3, poseidon2_B_30_0, poseidon2_B_30_1, poseidon2_B_30_2, poseidon2_B_30_3, poseidon2_B_31_0, poseidon2_B_31_1, poseidon2_B_31_2, poseidon2_B_31_3, poseidon2_B_32_0, poseidon2_B_32_1, poseidon2_B_32_2, poseidon2_B_32_3, poseidon2_B_33_0, poseidon2_B_33_1, poseidon2_B_33_2, poseidon2_B_33_3, poseidon2_B_34_0, poseidon2_B_34_1, poseidon2_B_34_2, poseidon2_B_34_3, poseidon2_B_35_0, poseidon2_B_35_1, poseidon2_B_35_2, poseidon2_B_35_3, poseidon2_B_36_0, poseidon2_B_36_1, poseidon2_B_36_2, poseidon2_B_36_3, poseidon2_B_37_0, poseidon2_B_37_1, poseidon2_B_37_2, poseidon2_B_37_3, poseidon2_B_38_0, poseidon2_B_38_1, poseidon2_B_38_2, poseidon2_B_38_3, poseidon2_B_39_0, poseidon2_B_39_1, poseidon2_B_39_2, poseidon2_B_39_3, poseidon2_B_40_0, poseidon2_B_40_1, poseidon2_B_40_2, poseidon2_B_40_3, poseidon2_B_41_0, poseidon2_B_41_1, poseidon2_B_41_2, poseidon2_B_41_3, poseidon2_B_42_0, poseidon2_B_42_1, poseidon2_B_42_2, poseidon2_B_42_3, poseidon2_B_43_0, poseidon2_B_43_1, poseidon2_B_43_2, poseidon2_B_43_3, poseidon2_B_44_0, poseidon2_B_44_1, poseidon2_B_44_2, poseidon2_B_44_3, poseidon2_B_45_0, poseidon2_B_45_1, poseidon2_B_45_2, poseidon2_B_45_3, poseidon2_B_46_0, poseidon2_B_46_1, poseidon2_B_46_2, poseidon2_B_46_3, poseidon2_B_47_0, poseidon2_B_47_1, poseidon2_B_47_2, poseidon2_B_47_3, poseidon2_B_48_0, poseidon2_B_48_1, poseidon2_B_48_2, poseidon2_B_48_3, poseidon2_B_49_0, poseidon2_B_49_1, poseidon2_B_49_2, poseidon2_B_49_3, poseidon2_B_4_0, poseidon2_B_4_1, poseidon2_B_4_2, poseidon2_B_4_3, poseidon2_B_50_0, poseidon2_B_50_1, poseidon2_B_50_2, poseidon2_B_50_3, poseidon2_B_51_0, poseidon2_B_51_1, poseidon2_B_51_2, poseidon2_B_51_3, poseidon2_B_52_0, poseidon2_B_52_1, poseidon2_B_52_2, poseidon2_B_52_3, poseidon2_B_53_0, poseidon2_B_53_1, poseidon2_B_53_2, poseidon2_B_53_3, poseidon2_B_54_0, poseidon2_B_54_1, poseidon2_B_54_2, poseidon2_B_54_3, poseidon2_B_55_0, poseidon2_B_55_1, poseidon2_B_55_2, poseidon2_B_55_3, poseidon2_B_56_0, poseidon2_B_56_1, poseidon2_B_56_2, poseidon2_B_56_3, poseidon2_B_57_0, poseidon2_B_57_1, poseidon2_B_57_2, poseidon2_B_57_3, poseidon2_B_58_0, poseidon2_B_58_1, poseidon2_B_58_2, poseidon2_B_58_3, poseidon2_B_59_0, poseidon2_B_59_1, poseidon2_B_59_2, poseidon2_B_59_3, poseidon2_B_5_0, poseidon2_B_5_1, poseidon2_B_5_2, poseidon2_B_5_3, poseidon2_B_6_0, poseidon2_B_6_1, poseidon2_B_6_2, poseidon2_B_6_3, poseidon2_B_7_0, poseidon2_B_7_1, poseidon2_B_7_2, poseidon2_B_7_3, poseidon2_B_8_0, poseidon2_B_8_1, poseidon2_B_8_2, poseidon2_B_8_3, poseidon2_B_9_0, poseidon2_B_9_1, poseidon2_B_9_2, poseidon2_B_9_3, poseidon2_EXT_LAYER_4, poseidon2_EXT_LAYER_5, poseidon2_EXT_LAYER_6, poseidon2_EXT_LAYER_7, poseidon2_T_0_4, poseidon2_T_0_5, poseidon2_T_0_6, poseidon2_T_0_7, poseidon2_T_1_4, poseidon2_T_1_5, poseidon2_T_1_6, poseidon2_T_1_7, poseidon2_T_2_4, poseidon2_T_2_5, poseidon2_T_2_6, poseidon2_T_2_7, poseidon2_T_3_4, poseidon2_T_3_5, poseidon2_T_3_6, poseidon2_T_3_7, poseidon2_T_60_4, poseidon2_T_60_5, poseidon2_T_60_6, poseidon2_T_60_7, poseidon2_T_61_4, poseidon2_T_61_5, poseidon2_T_61_6, poseidon2_T_61_7, poseidon2_T_62_4, poseidon2_T_62_5, poseidon2_T_62_6, poseidon2_T_62_7, poseidon2_T_63_4, poseidon2_T_63_5, poseidon2_T_63_6, poseidon2_T_63_7, poseidon2_a_0, poseidon2_a_1, poseidon2_a_2, poseidon2_a_3, poseidon2_b_0, poseidon2_b_1, poseidon2_b_2, poseidon2_b_3, poseidon2_clk, poseidon2_input_addr, poseidon2_mem_addr_read_a, poseidon2_mem_addr_read_b, poseidon2_mem_addr_read_c, poseidon2_mem_addr_read_d, poseidon2_mem_addr_write_a, poseidon2_mem_addr_write_b, poseidon2_mem_addr_write_c, poseidon2_mem_addr_write_d, poseidon2_output_addr, poseidon2_sel_poseidon_perm, powers_power_of_2, sha256_clk, sha256_input, sha256_output, sha256_sel_sha256_compression, sha256_state, slice_addr, slice_clk, slice_cnt, slice_col_offset, slice_one_min_inv, slice_sel_cd_cpy, slice_sel_mem_active, slice_sel_return, slice_sel_start, slice_space_id, slice_val, lookup_byte_lengths_counts, lookup_byte_operations_counts, lookup_cd_value_counts, lookup_ret_value_counts, lookup_opcode_gas_counts, range_check_l2_gas_hi_counts, range_check_l2_gas_lo_counts, range_check_da_gas_hi_counts, range_check_da_gas_lo_counts, kernel_output_lookup_counts, lookup_into_kernel_counts, incl_main_tag_err_counts, incl_mem_tag_err_counts, lookup_mem_rng_chk_lo_counts, lookup_mem_rng_chk_mid_counts, lookup_mem_rng_chk_hi_counts, lookup_pow_2_0_counts, lookup_pow_2_1_counts, lookup_u8_0_counts, lookup_u8_1_counts, lookup_u16_0_counts, lookup_u16_1_counts, lookup_u16_2_counts, lookup_u16_3_counts, lookup_u16_4_counts, lookup_u16_5_counts, lookup_u16_6_counts, lookup_u16_7_counts, lookup_u16_8_counts, lookup_u16_9_counts, lookup_u16_10_counts, lookup_u16_11_counts, lookup_u16_12_counts, lookup_u16_13_counts, lookup_u16_14_counts, lookup_div_u16_0_counts, lookup_div_u16_1_counts, lookup_div_u16_2_counts, lookup_div_u16_3_counts, lookup_div_u16_4_counts, lookup_div_u16_5_counts, lookup_div_u16_6_counts, lookup_div_u16_7_counts +#define DERIVED_WITNESS_ENTITIES perm_pos_mem_read_a, perm_pos_mem_read_b, perm_pos_mem_read_c, perm_pos_mem_read_d, perm_pos_mem_write_a, perm_pos_mem_write_b, perm_pos_mem_write_c, perm_pos_mem_write_d, perm_slice_mem, perm_main_alu, perm_main_bin, perm_main_conv, perm_main_pos2_perm, perm_main_pedersen, perm_main_slice, perm_main_mem_a, perm_main_mem_b, perm_main_mem_c, perm_main_mem_d, perm_main_mem_ind_addr_a, perm_main_mem_ind_addr_b, perm_main_mem_ind_addr_c, perm_main_mem_ind_addr_d, lookup_byte_lengths, lookup_byte_operations, lookup_cd_value, lookup_ret_value, lookup_opcode_gas, range_check_l2_gas_hi, range_check_l2_gas_lo, range_check_da_gas_hi, range_check_da_gas_lo, kernel_output_lookup, lookup_into_kernel, incl_main_tag_err, incl_mem_tag_err, lookup_mem_rng_chk_lo, lookup_mem_rng_chk_mid, lookup_mem_rng_chk_hi, lookup_pow_2_0, lookup_pow_2_1, lookup_u8_0, lookup_u8_1, lookup_u16_0, lookup_u16_1, lookup_u16_2, lookup_u16_3, lookup_u16_4, lookup_u16_5, lookup_u16_6, lookup_u16_7, lookup_u16_8, lookup_u16_9, lookup_u16_10, lookup_u16_11, lookup_u16_12, lookup_u16_13, lookup_u16_14, lookup_div_u16_0, lookup_div_u16_1, lookup_div_u16_2, lookup_div_u16_3, lookup_div_u16_4, lookup_div_u16_5, lookup_div_u16_6, lookup_div_u16_7 #define SHIFTED_ENTITIES alu_a_hi_shift, alu_a_lo_shift, alu_b_hi_shift, alu_b_lo_shift, alu_cmp_rng_ctr_shift, alu_div_u16_r0_shift, alu_div_u16_r1_shift, alu_div_u16_r2_shift, alu_div_u16_r3_shift, alu_div_u16_r4_shift, alu_div_u16_r5_shift, alu_div_u16_r6_shift, alu_div_u16_r7_shift, alu_op_add_shift, alu_op_cast_prev_shift, alu_op_cast_shift, alu_op_div_shift, alu_op_mul_shift, alu_op_shl_shift, alu_op_shr_shift, alu_op_sub_shift, alu_p_sub_a_hi_shift, alu_p_sub_a_lo_shift, alu_p_sub_b_hi_shift, alu_p_sub_b_lo_shift, alu_sel_alu_shift, alu_sel_cmp_shift, alu_sel_div_rng_chk_shift, alu_sel_rng_chk_lookup_shift, alu_sel_rng_chk_shift, alu_u16_r0_shift, alu_u16_r1_shift, alu_u16_r2_shift, alu_u16_r3_shift, alu_u16_r4_shift, alu_u16_r5_shift, alu_u16_r6_shift, alu_u8_r0_shift, alu_u8_r1_shift, binary_acc_ia_shift, binary_acc_ib_shift, binary_acc_ic_shift, binary_mem_tag_ctr_shift, binary_op_id_shift, kernel_emit_l2_to_l1_msg_write_offset_shift, kernel_emit_note_hash_write_offset_shift, kernel_emit_nullifier_write_offset_shift, kernel_emit_unencrypted_log_write_offset_shift, kernel_l1_to_l2_msg_exists_write_offset_shift, kernel_note_hash_exist_write_offset_shift, kernel_nullifier_exists_write_offset_shift, kernel_nullifier_non_exists_write_offset_shift, kernel_side_effect_counter_shift, kernel_sload_write_offset_shift, kernel_sstore_write_offset_shift, main_da_gas_remaining_shift, main_internal_return_ptr_shift, main_l2_gas_remaining_shift, main_pc_shift, mem_glob_addr_shift, mem_rw_shift, mem_sel_mem_shift, mem_tag_shift, mem_tsp_shift, mem_val_shift, slice_addr_shift, slice_clk_shift, slice_cnt_shift, slice_col_offset_shift, slice_sel_cd_cpy_shift, slice_sel_mem_active_shift, slice_sel_return_shift, slice_sel_start_shift, slice_space_id_shift #define TO_BE_SHIFTED(e) e.alu_a_hi, e.alu_a_lo, e.alu_b_hi, e.alu_b_lo, e.alu_cmp_rng_ctr, e.alu_div_u16_r0, e.alu_div_u16_r1, e.alu_div_u16_r2, e.alu_div_u16_r3, e.alu_div_u16_r4, e.alu_div_u16_r5, e.alu_div_u16_r6, e.alu_div_u16_r7, e.alu_op_add, e.alu_op_cast_prev, e.alu_op_cast, e.alu_op_div, e.alu_op_mul, e.alu_op_shl, e.alu_op_shr, e.alu_op_sub, e.alu_p_sub_a_hi, e.alu_p_sub_a_lo, e.alu_p_sub_b_hi, e.alu_p_sub_b_lo, e.alu_sel_alu, e.alu_sel_cmp, e.alu_sel_div_rng_chk, e.alu_sel_rng_chk_lookup, e.alu_sel_rng_chk, e.alu_u16_r0, e.alu_u16_r1, e.alu_u16_r2, e.alu_u16_r3, e.alu_u16_r4, e.alu_u16_r5, e.alu_u16_r6, e.alu_u8_r0, e.alu_u8_r1, e.binary_acc_ia, e.binary_acc_ib, e.binary_acc_ic, e.binary_mem_tag_ctr, e.binary_op_id, e.kernel_emit_l2_to_l1_msg_write_offset, e.kernel_emit_note_hash_write_offset, e.kernel_emit_nullifier_write_offset, e.kernel_emit_unencrypted_log_write_offset, e.kernel_l1_to_l2_msg_exists_write_offset, e.kernel_note_hash_exist_write_offset, e.kernel_nullifier_exists_write_offset, e.kernel_nullifier_non_exists_write_offset, e.kernel_side_effect_counter, e.kernel_sload_write_offset, e.kernel_sstore_write_offset, e.main_da_gas_remaining, e.main_internal_return_ptr, e.main_l2_gas_remaining, e.main_pc, e.mem_glob_addr, e.mem_rw, e.mem_sel_mem, e.mem_tag, e.mem_tsp, e.mem_val, e.slice_addr, e.slice_clk, e.slice_cnt, e.slice_col_offset, e.slice_sel_cd_cpy, e.slice_sel_mem_active, e.slice_sel_return, e.slice_sel_start, e.slice_space_id #define ALL_ENTITIES PRECOMPUTED_ENTITIES, WIRE_ENTITIES, DERIVED_WITNESS_ENTITIES, SHIFTED_ENTITIES @@ -121,12 +129,12 @@ class AvmFlavor { using VerifierCommitmentKey = AvmFlavorSettings::VerifierCommitmentKey; using RelationSeparator = AvmFlavorSettings::RelationSeparator; - static constexpr size_t NUM_PRECOMPUTED_ENTITIES = 2; - static constexpr size_t NUM_WITNESS_ENTITIES = 409; + static constexpr size_t NUM_PRECOMPUTED_ENTITIES = 3; + static constexpr size_t NUM_WITNESS_ENTITIES = 701; static constexpr size_t NUM_WIRES = NUM_WITNESS_ENTITIES + NUM_PRECOMPUTED_ENTITIES; // We have two copies of the witness entities, so we subtract the number of fixed ones (they have no shift), one for // the unshifted and one for the shifted - static constexpr size_t NUM_ALL_ENTITIES = 485; + static constexpr size_t NUM_ALL_ENTITIES = 778; using MainRelations = std::tuple< // Relations @@ -146,6 +154,14 @@ class AvmFlavor { using LookupRelations = std::tuple< // Lookups + perm_pos_mem_read_a_relation, + perm_pos_mem_read_b_relation, + perm_pos_mem_read_c_relation, + perm_pos_mem_read_d_relation, + perm_pos_mem_write_a_relation, + perm_pos_mem_write_b_relation, + perm_pos_mem_write_c_relation, + perm_pos_mem_write_d_relation, perm_slice_mem_relation, perm_main_alu_relation, perm_main_bin_relation, diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp index deca7a31789d..e13534845736 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.cpp @@ -21,6 +21,7 @@ template std::vector AvmFullRow::names() { return { "main_clk", "main_sel_first", + "main_zeroes", "kernel_kernel_inputs", "kernel_kernel_value_out", "kernel_kernel_side_effect_out", @@ -291,10 +292,14 @@ template std::vector AvmFullRow::names() "mem_sel_op_c", "mem_sel_op_cmov", "mem_sel_op_d", - "mem_sel_op_gadget_a", - "mem_sel_op_gadget_b", - "mem_sel_op_gadget_c", - "mem_sel_op_gadget_d", + "mem_sel_op_poseidon_read_a", + "mem_sel_op_poseidon_read_b", + "mem_sel_op_poseidon_read_c", + "mem_sel_op_poseidon_read_d", + "mem_sel_op_poseidon_write_a", + "mem_sel_op_poseidon_write_b", + "mem_sel_op_poseidon_write_c", + "mem_sel_op_poseidon_write_d", "mem_sel_op_slice", "mem_sel_resolve_ind_addr_a", "mem_sel_resolve_ind_addr_b", @@ -581,17 +586,17 @@ template std::vector AvmFullRow::names() "poseidon2_b_2", "poseidon2_b_3", "poseidon2_clk", - "poseidon2_in_tag", "poseidon2_input_addr", - "poseidon2_mem_addr_a", - "poseidon2_mem_addr_b", - "poseidon2_mem_addr_c", - "poseidon2_mem_addr_d", - "poseidon2_mem_op", + "poseidon2_mem_addr_read_a", + "poseidon2_mem_addr_read_b", + "poseidon2_mem_addr_read_c", + "poseidon2_mem_addr_read_d", + "poseidon2_mem_addr_write_a", + "poseidon2_mem_addr_write_b", + "poseidon2_mem_addr_write_c", + "poseidon2_mem_addr_write_d", "poseidon2_output_addr", - "poseidon2_read_line", "poseidon2_sel_poseidon_perm", - "poseidon2_write_line", "powers_power_of_2", "sha256_clk", "sha256_input", @@ -609,10 +614,14 @@ template std::vector AvmFullRow::names() "slice_sel_start", "slice_space_id", "slice_val", - "perm_pos_mem_a", - "perm_pos_mem_b", - "perm_pos_mem_c", - "perm_pos_mem_d", + "perm_pos_mem_read_a", + "perm_pos_mem_read_b", + "perm_pos_mem_read_c", + "perm_pos_mem_read_d", + "perm_pos_mem_write_a", + "perm_pos_mem_write_b", + "perm_pos_mem_write_c", + "perm_pos_mem_write_d", "perm_slice_mem", "perm_main_alu", "perm_main_bin", @@ -721,6 +730,7 @@ template RefVector AvmFullRow::as_vector() const return RefVector{ main_clk, main_sel_first, + main_zeroes, kernel_kernel_inputs, kernel_kernel_value_out, kernel_kernel_side_effect_out, @@ -991,10 +1001,14 @@ template RefVector AvmFullRow::as_vector() const mem_sel_op_c, mem_sel_op_cmov, mem_sel_op_d, - mem_sel_op_gadget_a, - mem_sel_op_gadget_b, - mem_sel_op_gadget_c, - mem_sel_op_gadget_d, + mem_sel_op_poseidon_read_a, + mem_sel_op_poseidon_read_b, + mem_sel_op_poseidon_read_c, + mem_sel_op_poseidon_read_d, + mem_sel_op_poseidon_write_a, + mem_sel_op_poseidon_write_b, + mem_sel_op_poseidon_write_c, + mem_sel_op_poseidon_write_d, mem_sel_op_slice, mem_sel_resolve_ind_addr_a, mem_sel_resolve_ind_addr_b, @@ -1281,17 +1295,17 @@ template RefVector AvmFullRow::as_vector() const poseidon2_b_2, poseidon2_b_3, poseidon2_clk, - poseidon2_in_tag, poseidon2_input_addr, - poseidon2_mem_addr_a, - poseidon2_mem_addr_b, - poseidon2_mem_addr_c, - poseidon2_mem_addr_d, - poseidon2_mem_op, + poseidon2_mem_addr_read_a, + poseidon2_mem_addr_read_b, + poseidon2_mem_addr_read_c, + poseidon2_mem_addr_read_d, + poseidon2_mem_addr_write_a, + poseidon2_mem_addr_write_b, + poseidon2_mem_addr_write_c, + poseidon2_mem_addr_write_d, poseidon2_output_addr, - poseidon2_read_line, poseidon2_sel_poseidon_perm, - poseidon2_write_line, powers_power_of_2, sha256_clk, sha256_input, @@ -1309,10 +1323,14 @@ template RefVector AvmFullRow::as_vector() const slice_sel_start, slice_space_id, slice_val, - perm_pos_mem_a, - perm_pos_mem_b, - perm_pos_mem_c, - perm_pos_mem_d, + perm_pos_mem_read_a, + perm_pos_mem_read_b, + perm_pos_mem_read_c, + perm_pos_mem_read_d, + perm_pos_mem_write_a, + perm_pos_mem_write_b, + perm_pos_mem_write_c, + perm_pos_mem_write_d, perm_slice_mem, perm_main_alu, perm_main_bin, diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.hpp index 0c5bc1fe28e3..6feca6cc5075 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/full_row.hpp @@ -12,6 +12,7 @@ namespace bb { template struct AvmFullRow { FF main_clk{}; FF main_sel_first{}; + FF main_zeroes{}; FF kernel_kernel_inputs{}; FF kernel_kernel_value_out{}; FF kernel_kernel_side_effect_out{}; @@ -282,10 +283,14 @@ template struct AvmFullRow { FF mem_sel_op_c{}; FF mem_sel_op_cmov{}; FF mem_sel_op_d{}; - FF mem_sel_op_gadget_a{}; - FF mem_sel_op_gadget_b{}; - FF mem_sel_op_gadget_c{}; - FF mem_sel_op_gadget_d{}; + FF mem_sel_op_poseidon_read_a{}; + FF mem_sel_op_poseidon_read_b{}; + FF mem_sel_op_poseidon_read_c{}; + FF mem_sel_op_poseidon_read_d{}; + FF mem_sel_op_poseidon_write_a{}; + FF mem_sel_op_poseidon_write_b{}; + FF mem_sel_op_poseidon_write_c{}; + FF mem_sel_op_poseidon_write_d{}; FF mem_sel_op_slice{}; FF mem_sel_resolve_ind_addr_a{}; FF mem_sel_resolve_ind_addr_b{}; @@ -572,17 +577,17 @@ template struct AvmFullRow { FF poseidon2_b_2{}; FF poseidon2_b_3{}; FF poseidon2_clk{}; - FF poseidon2_in_tag{}; FF poseidon2_input_addr{}; - FF poseidon2_mem_addr_a{}; - FF poseidon2_mem_addr_b{}; - FF poseidon2_mem_addr_c{}; - FF poseidon2_mem_addr_d{}; - FF poseidon2_mem_op{}; + FF poseidon2_mem_addr_read_a{}; + FF poseidon2_mem_addr_read_b{}; + FF poseidon2_mem_addr_read_c{}; + FF poseidon2_mem_addr_read_d{}; + FF poseidon2_mem_addr_write_a{}; + FF poseidon2_mem_addr_write_b{}; + FF poseidon2_mem_addr_write_c{}; + FF poseidon2_mem_addr_write_d{}; FF poseidon2_output_addr{}; - FF poseidon2_read_line{}; FF poseidon2_sel_poseidon_perm{}; - FF poseidon2_write_line{}; FF powers_power_of_2{}; FF sha256_clk{}; FF sha256_input{}; @@ -600,10 +605,14 @@ template struct AvmFullRow { FF slice_sel_start{}; FF slice_space_id{}; FF slice_val{}; - FF perm_pos_mem_a{}; - FF perm_pos_mem_b{}; - FF perm_pos_mem_c{}; - FF perm_pos_mem_d{}; + FF perm_pos_mem_read_a{}; + FF perm_pos_mem_read_b{}; + FF perm_pos_mem_read_c{}; + FF perm_pos_mem_read_d{}; + FF perm_pos_mem_write_a{}; + FF perm_pos_mem_write_b{}; + FF perm_pos_mem_write_c{}; + FF perm_pos_mem_write_d{}; FF perm_slice_mem{}; FF perm_main_alu{}; FF perm_main_bin{}; @@ -709,7 +718,7 @@ template struct AvmFullRow { RefVector as_vector() const; static std::vector names(); - static constexpr size_t SIZE = 695; + static constexpr size_t SIZE = 704; }; template std::ostream& operator<<(std::ostream& os, AvmFullRow const& row); diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/mem.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/mem.hpp index 80819ffd785c..6265b06c87b3 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/mem.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/mem.hpp @@ -30,10 +30,14 @@ template struct MemRow { FF mem_sel_op_c{}; FF mem_sel_op_cmov{}; FF mem_sel_op_d{}; - FF mem_sel_op_gadget_a{}; - FF mem_sel_op_gadget_b{}; - FF mem_sel_op_gadget_c{}; - FF mem_sel_op_gadget_d{}; + FF mem_sel_op_poseidon_read_a{}; + FF mem_sel_op_poseidon_read_b{}; + FF mem_sel_op_poseidon_read_c{}; + FF mem_sel_op_poseidon_read_d{}; + FF mem_sel_op_poseidon_write_a{}; + FF mem_sel_op_poseidon_write_b{}; + FF mem_sel_op_poseidon_write_c{}; + FF mem_sel_op_poseidon_write_d{}; FF mem_sel_op_slice{}; FF mem_sel_resolve_ind_addr_a{}; FF mem_sel_resolve_ind_addr_b{}; @@ -56,9 +60,10 @@ template class memImpl { public: using FF = FF_; - static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, 3, - 4, 3, 4, 3, 4, 3, 3, 3, 4, 4, 4, 4, 4, 6, 4, - 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3 }; + static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 2, 3, 4, 3, 4, 3, 4, 3, 3, 3, 4, 4, 4, + 4, 4, 6, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3 }; template void static accumulate(ContainerOverSubrelations& evals, @@ -146,10 +151,14 @@ template class memImpl { } { using Accumulator = typename std::tuple_element_t<13, ContainerOverSubrelations>; - auto tmp = (new_term.mem_sel_mem - (((((((((new_term.mem_sel_op_a + new_term.mem_sel_op_gadget_a) + - (new_term.mem_sel_op_b + new_term.mem_sel_op_gadget_b)) + - (new_term.mem_sel_op_c + new_term.mem_sel_op_gadget_c)) + - (new_term.mem_sel_op_d + new_term.mem_sel_op_gadget_d)) + + auto tmp = (new_term.mem_sel_mem - ((((((((((new_term.mem_sel_op_a + new_term.mem_sel_op_poseidon_read_a) + + new_term.mem_sel_op_poseidon_write_a) + + ((new_term.mem_sel_op_b + new_term.mem_sel_op_poseidon_read_b) + + new_term.mem_sel_op_poseidon_write_b)) + + ((new_term.mem_sel_op_c + new_term.mem_sel_op_poseidon_read_c) + + new_term.mem_sel_op_poseidon_write_c)) + + ((new_term.mem_sel_op_d + new_term.mem_sel_op_poseidon_read_d) + + new_term.mem_sel_op_poseidon_write_d)) + new_term.mem_sel_resolve_ind_addr_a) + new_term.mem_sel_resolve_ind_addr_b) + new_term.mem_sel_resolve_ind_addr_c) + @@ -191,21 +200,26 @@ template class memImpl { } { using Accumulator = typename std::tuple_element_t<19, ContainerOverSubrelations>; - auto tmp = - (new_term.mem_tsp - - ((new_term.mem_clk * FF(12)) + - (new_term.mem_sel_mem * - ((((new_term.mem_sel_resolve_ind_addr_b + (new_term.mem_sel_op_b + new_term.mem_sel_op_gadget_b)) + - ((new_term.mem_sel_resolve_ind_addr_c + (new_term.mem_sel_op_c + new_term.mem_sel_op_gadget_c)) * - FF(2))) + - ((new_term.mem_sel_resolve_ind_addr_d + (new_term.mem_sel_op_d + new_term.mem_sel_op_gadget_d)) * - FF(3))) + - (((-(((new_term.mem_sel_resolve_ind_addr_a + new_term.mem_sel_resolve_ind_addr_b) + - new_term.mem_sel_resolve_ind_addr_c) + - new_term.mem_sel_resolve_ind_addr_d) + - FF(1)) + - new_term.mem_rw) * - FF(4)))))); + auto tmp = (new_term.mem_tsp - + ((new_term.mem_clk * FF(12)) + + (new_term.mem_sel_mem * + ((((new_term.mem_sel_resolve_ind_addr_b + + ((new_term.mem_sel_op_b + new_term.mem_sel_op_poseidon_read_b) + + new_term.mem_sel_op_poseidon_write_b)) + + ((new_term.mem_sel_resolve_ind_addr_c + + ((new_term.mem_sel_op_c + new_term.mem_sel_op_poseidon_read_c) + + new_term.mem_sel_op_poseidon_write_c)) * + FF(2))) + + ((new_term.mem_sel_resolve_ind_addr_d + + ((new_term.mem_sel_op_d + new_term.mem_sel_op_poseidon_read_d) + + new_term.mem_sel_op_poseidon_write_d)) * + FF(3))) + + (((-(((new_term.mem_sel_resolve_ind_addr_a + new_term.mem_sel_resolve_ind_addr_b) + + new_term.mem_sel_resolve_ind_addr_c) + + new_term.mem_sel_resolve_ind_addr_d) + + FF(1)) + + new_term.mem_rw) * + FF(4)))))); tmp *= scaling_factor; std::get<19>(evals) += typename Accumulator::View(tmp); } @@ -363,10 +377,58 @@ template class memImpl { } { using Accumulator = typename std::tuple_element_t<43, ContainerOverSubrelations>; - auto tmp = ((new_term.mem_sel_mov_ia_to_ic + new_term.mem_sel_mov_ib_to_ic) * new_term.mem_tag_err); + auto tmp = (new_term.mem_sel_op_poseidon_read_a * (new_term.mem_w_in_tag - FF(6))); tmp *= scaling_factor; std::get<43>(evals) += typename Accumulator::View(tmp); } + { + using Accumulator = typename std::tuple_element_t<44, ContainerOverSubrelations>; + auto tmp = (new_term.mem_sel_op_poseidon_read_b * (new_term.mem_w_in_tag - FF(6))); + tmp *= scaling_factor; + std::get<44>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<45, ContainerOverSubrelations>; + auto tmp = (new_term.mem_sel_op_poseidon_read_c * (new_term.mem_w_in_tag - FF(6))); + tmp *= scaling_factor; + std::get<45>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<46, ContainerOverSubrelations>; + auto tmp = (new_term.mem_sel_op_poseidon_read_d * (new_term.mem_w_in_tag - FF(6))); + tmp *= scaling_factor; + std::get<46>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<47, ContainerOverSubrelations>; + auto tmp = (new_term.mem_sel_op_poseidon_write_a * (new_term.mem_r_in_tag - FF(6))); + tmp *= scaling_factor; + std::get<47>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<48, ContainerOverSubrelations>; + auto tmp = (new_term.mem_sel_op_poseidon_write_b * (new_term.mem_r_in_tag - FF(6))); + tmp *= scaling_factor; + std::get<48>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<49, ContainerOverSubrelations>; + auto tmp = (new_term.mem_sel_op_poseidon_write_c * (new_term.mem_r_in_tag - FF(6))); + tmp *= scaling_factor; + std::get<49>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<50, ContainerOverSubrelations>; + auto tmp = (new_term.mem_sel_op_poseidon_write_d * (new_term.mem_r_in_tag - FF(6))); + tmp *= scaling_factor; + std::get<50>(evals) += typename Accumulator::View(tmp); + } + { + using Accumulator = typename std::tuple_element_t<51, ContainerOverSubrelations>; + auto tmp = ((new_term.mem_sel_mov_ia_to_ic + new_term.mem_sel_mov_ib_to_ic) * new_term.mem_tag_err); + tmp *= scaling_factor; + std::get<51>(evals) += typename Accumulator::View(tmp); + } } }; @@ -409,7 +471,7 @@ template class mem : public Relation> { return "NO_TAG_ERR_WRITE_OR_SKIP"; case 32: return "NO_TAG_ERR_WRITE"; - case 43: + case 51: return "MOV_SAME_TAG"; } return std::to_string(index); diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_a.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_a.hpp new file mode 100644 index 000000000000..55f910a2cdf2 --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_a.hpp @@ -0,0 +1,65 @@ +// AUTOGENERATED FILE +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_read_a_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 5; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_sel_poseidon_perm == 1 || in.mem_sel_op_poseidon_read_a == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_read_a, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_read_a, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_read_a, + in.poseidon2_a_0, + in.main_zeroes, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_read_a, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_read_a, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_read_a, + in.poseidon2_a_0, + in.main_zeroes, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } +}; + +template +class perm_pos_mem_read_a_relation : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_READ_A"; +}; +template using perm_pos_mem_read_a = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_b.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_b.hpp new file mode 100644 index 000000000000..a704aa2b3442 --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_b.hpp @@ -0,0 +1,65 @@ +// AUTOGENERATED FILE +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_read_b_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 5; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_sel_poseidon_perm == 1 || in.mem_sel_op_poseidon_read_b == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_read_b, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_read_b, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_read_b, + in.poseidon2_a_1, + in.main_zeroes, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_read_b, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_read_b, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_read_b, + in.poseidon2_a_1, + in.main_zeroes, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } +}; + +template +class perm_pos_mem_read_b_relation : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_READ_B"; +}; +template using perm_pos_mem_read_b = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_c.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_c.hpp new file mode 100644 index 000000000000..04a34ab0744d --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_c.hpp @@ -0,0 +1,65 @@ +// AUTOGENERATED FILE +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_read_c_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 5; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_sel_poseidon_perm == 1 || in.mem_sel_op_poseidon_read_c == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_read_c, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_read_c, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_read_c, + in.poseidon2_a_2, + in.main_zeroes, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_read_c, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_read_c, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_read_c, + in.poseidon2_a_2, + in.main_zeroes, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } +}; + +template +class perm_pos_mem_read_c_relation : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_READ_C"; +}; +template using perm_pos_mem_read_c = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_d.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_d.hpp new file mode 100644 index 000000000000..3f5ac896d2ed --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_read_d.hpp @@ -0,0 +1,65 @@ +// AUTOGENERATED FILE +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_read_d_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 5; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_sel_poseidon_perm == 1 || in.mem_sel_op_poseidon_read_d == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_read_d, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_read_d, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_read_d, + in.poseidon2_a_3, + in.main_zeroes, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_read_d, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_read_d, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_read_d, + in.poseidon2_a_3, + in.main_zeroes, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } +}; + +template +class perm_pos_mem_read_d_relation : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_READ_D"; +}; +template using perm_pos_mem_read_d = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_a.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_a.hpp new file mode 100644 index 000000000000..141a62e1e75a --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_a.hpp @@ -0,0 +1,66 @@ +// AUTOGENERATED FILE +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_write_a_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 5; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_sel_poseidon_perm == 1 || in.mem_sel_op_poseidon_write_a == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_write_a, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_write_a, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_write_a, + in.poseidon2_b_0, + in.poseidon2_sel_poseidon_perm, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_write_a, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_write_a, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_write_a, + in.poseidon2_b_0, + in.poseidon2_sel_poseidon_perm, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } +}; + +template +class perm_pos_mem_write_a_relation + : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_WRITE_A"; +}; +template using perm_pos_mem_write_a = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_b.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_b.hpp new file mode 100644 index 000000000000..585a5aa90951 --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_b.hpp @@ -0,0 +1,66 @@ +// AUTOGENERATED FILE +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_write_b_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 5; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_sel_poseidon_perm == 1 || in.mem_sel_op_poseidon_write_b == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_write_b, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_write_b, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_write_b, + in.poseidon2_b_1, + in.poseidon2_sel_poseidon_perm, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_write_b, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_write_b, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_write_b, + in.poseidon2_b_1, + in.poseidon2_sel_poseidon_perm, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } +}; + +template +class perm_pos_mem_write_b_relation + : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_WRITE_B"; +}; +template using perm_pos_mem_write_b = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_c.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_c.hpp new file mode 100644 index 000000000000..a83d9d95141d --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_c.hpp @@ -0,0 +1,66 @@ +// AUTOGENERATED FILE +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_write_c_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 5; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_sel_poseidon_perm == 1 || in.mem_sel_op_poseidon_write_c == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_write_c, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_write_c, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_write_c, + in.poseidon2_b_2, + in.poseidon2_sel_poseidon_perm, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_write_c, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_write_c, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_write_c, + in.poseidon2_b_2, + in.poseidon2_sel_poseidon_perm, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } +}; + +template +class perm_pos_mem_write_c_relation + : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_WRITE_C"; +}; +template using perm_pos_mem_write_c = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_d.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_d.hpp new file mode 100644 index 000000000000..4f75387af02e --- /dev/null +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/perm_pos_mem_write_d.hpp @@ -0,0 +1,66 @@ +// AUTOGENERATED FILE +#pragma once + +#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" + +#include +#include + +namespace bb { + +class perm_pos_mem_write_d_permutation_settings { + public: + // This constant defines how many columns are bundled together to form each set. + constexpr static size_t COLUMNS_PER_SET = 5; + + template static inline auto inverse_polynomial_is_computed_at_row(const AllEntities& in) + { + return (in.poseidon2_sel_poseidon_perm == 1 || in.mem_sel_op_poseidon_write_d == 1); + } + + template static inline auto get_const_entities(const AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_write_d, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_write_d, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_write_d, + in.poseidon2_b_3, + in.poseidon2_sel_poseidon_perm, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } + + template static inline auto get_nonconst_entities(AllEntities& in) + { + return std::forward_as_tuple(in.perm_pos_mem_write_d, + in.poseidon2_sel_poseidon_perm, + in.poseidon2_sel_poseidon_perm, + in.mem_sel_op_poseidon_write_d, + in.poseidon2_clk, + in.main_space_id, + in.poseidon2_mem_addr_write_d, + in.poseidon2_b_3, + in.poseidon2_sel_poseidon_perm, + in.mem_clk, + in.mem_space_id, + in.mem_addr, + in.mem_val, + in.mem_rw); + } +}; + +template +class perm_pos_mem_write_d_relation + : public GenericPermutationRelation { + public: + static constexpr const char* NAME = "PERM_POS_MEM_WRITE_D"; +}; +template using perm_pos_mem_write_d = GenericPermutation; + +} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/poseidon2.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/poseidon2.hpp index 77397586b7f0..afa93ba9e6c2 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/poseidon2.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/generated/relations/poseidon2.hpp @@ -268,41 +268,39 @@ template struct Poseidon2Row { FF poseidon2_T_63_6{}; FF poseidon2_T_63_7{}; FF poseidon2_a_0{}; - FF poseidon2_a_0_shift{}; FF poseidon2_a_1{}; - FF poseidon2_a_1_shift{}; FF poseidon2_a_2{}; - FF poseidon2_a_2_shift{}; FF poseidon2_a_3{}; - FF poseidon2_a_3_shift{}; - FF poseidon2_in_tag{}; + FF poseidon2_b_0{}; + FF poseidon2_b_1{}; + FF poseidon2_b_2{}; + FF poseidon2_b_3{}; FF poseidon2_input_addr{}; - FF poseidon2_mem_addr_a{}; - FF poseidon2_mem_addr_b{}; - FF poseidon2_mem_addr_c{}; - FF poseidon2_mem_addr_d{}; - FF poseidon2_mem_op{}; + FF poseidon2_mem_addr_read_a{}; + FF poseidon2_mem_addr_read_b{}; + FF poseidon2_mem_addr_read_c{}; + FF poseidon2_mem_addr_read_d{}; + FF poseidon2_mem_addr_write_a{}; + FF poseidon2_mem_addr_write_b{}; + FF poseidon2_mem_addr_write_c{}; + FF poseidon2_mem_addr_write_d{}; FF poseidon2_output_addr{}; - FF poseidon2_read_line{}; FF poseidon2_sel_poseidon_perm{}; - FF poseidon2_sel_poseidon_perm_shift{}; - FF poseidon2_write_line{}; - FF poseidon2_write_line_shift{}; }; template class poseidon2Impl { public: using FF = FF_; - static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { - 3, 3, 3, 3, 2, 2, 2, 3, 3, 4, 4, 4, 4, 4, 4, 4, 4, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 7, + static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { + 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 4, 4, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, - 8, 7, 7, 7, 8, 7, 7, 7, 8, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 3, 3, 3, 3 + 8, 7, 7, 7, 8, 7, 7, 7, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 8, 3, 3, 3, 3 }; template @@ -319,129 +317,98 @@ template class poseidon2Impl { } { using Accumulator = typename std::tuple_element_t<1, ContainerOverSubrelations>; - auto tmp = (new_term.poseidon2_sel_poseidon_perm * new_term.poseidon2_sel_poseidon_perm_shift); + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_mem_addr_read_a - new_term.poseidon2_input_addr)); tmp *= scaling_factor; std::get<1>(evals) += typename Accumulator::View(tmp); } { using Accumulator = typename std::tuple_element_t<2, ContainerOverSubrelations>; - auto tmp = (new_term.poseidon2_read_line * (-new_term.poseidon2_read_line + FF(1))); + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_mem_addr_read_b - (new_term.poseidon2_input_addr + FF(1)))); tmp *= scaling_factor; std::get<2>(evals) += typename Accumulator::View(tmp); } { using Accumulator = typename std::tuple_element_t<3, ContainerOverSubrelations>; - auto tmp = (new_term.poseidon2_write_line * (-new_term.poseidon2_write_line + FF(1))); + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_mem_addr_read_c - (new_term.poseidon2_input_addr + FF(2)))); tmp *= scaling_factor; std::get<3>(evals) += typename Accumulator::View(tmp); } { using Accumulator = typename std::tuple_element_t<4, ContainerOverSubrelations>; - auto tmp = (new_term.poseidon2_sel_poseidon_perm - new_term.poseidon2_read_line); + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_mem_addr_read_d - (new_term.poseidon2_input_addr + FF(3)))); tmp *= scaling_factor; std::get<4>(evals) += typename Accumulator::View(tmp); } { using Accumulator = typename std::tuple_element_t<5, ContainerOverSubrelations>; - auto tmp = (new_term.poseidon2_sel_poseidon_perm - new_term.poseidon2_write_line_shift); + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_mem_addr_write_a - new_term.poseidon2_output_addr)); tmp *= scaling_factor; std::get<5>(evals) += typename Accumulator::View(tmp); } { using Accumulator = typename std::tuple_element_t<6, ContainerOverSubrelations>; - auto tmp = (new_term.poseidon2_mem_op - (new_term.poseidon2_read_line + new_term.poseidon2_write_line)); + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_mem_addr_write_b - (new_term.poseidon2_output_addr + FF(1)))); tmp *= scaling_factor; std::get<6>(evals) += typename Accumulator::View(tmp); } { using Accumulator = typename std::tuple_element_t<7, ContainerOverSubrelations>; - auto tmp = (new_term.poseidon2_mem_op * (-new_term.poseidon2_mem_op + FF(1))); + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_mem_addr_write_c - (new_term.poseidon2_output_addr + FF(2)))); tmp *= scaling_factor; std::get<7>(evals) += typename Accumulator::View(tmp); } { using Accumulator = typename std::tuple_element_t<8, ContainerOverSubrelations>; - auto tmp = (new_term.poseidon2_mem_op * (new_term.poseidon2_in_tag - FF(6))); + auto tmp = (new_term.poseidon2_sel_poseidon_perm * + (new_term.poseidon2_mem_addr_write_d - (new_term.poseidon2_output_addr + FF(3)))); tmp *= scaling_factor; std::get<8>(evals) += typename Accumulator::View(tmp); } { using Accumulator = typename std::tuple_element_t<9, ContainerOverSubrelations>; - auto tmp = - (new_term.poseidon2_mem_op * - (new_term.poseidon2_mem_addr_a - ((new_term.poseidon2_read_line * new_term.poseidon2_input_addr) + - (new_term.poseidon2_write_line * new_term.poseidon2_output_addr)))); - tmp *= scaling_factor; - std::get<9>(evals) += typename Accumulator::View(tmp); - } - { - using Accumulator = typename std::tuple_element_t<10, ContainerOverSubrelations>; - auto tmp = - (new_term.poseidon2_mem_op * - (new_term.poseidon2_mem_addr_b - (((new_term.poseidon2_read_line * new_term.poseidon2_input_addr) + - (new_term.poseidon2_write_line * new_term.poseidon2_output_addr)) + - FF(1)))); - tmp *= scaling_factor; - std::get<10>(evals) += typename Accumulator::View(tmp); - } - { - using Accumulator = typename std::tuple_element_t<11, ContainerOverSubrelations>; - auto tmp = - (new_term.poseidon2_mem_op * - (new_term.poseidon2_mem_addr_c - (((new_term.poseidon2_read_line * new_term.poseidon2_input_addr) + - (new_term.poseidon2_write_line * new_term.poseidon2_output_addr)) + - FF(2)))); - tmp *= scaling_factor; - std::get<11>(evals) += typename Accumulator::View(tmp); - } - { - using Accumulator = typename std::tuple_element_t<12, ContainerOverSubrelations>; - auto tmp = - (new_term.poseidon2_mem_op * - (new_term.poseidon2_mem_addr_d - (((new_term.poseidon2_read_line * new_term.poseidon2_input_addr) + - (new_term.poseidon2_write_line * new_term.poseidon2_output_addr)) + - FF(3)))); - tmp *= scaling_factor; - std::get<12>(evals) += typename Accumulator::View(tmp); - } - { - using Accumulator = typename std::tuple_element_t<13, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_EXT_LAYER_4 - (((new_term.poseidon2_a_2 + new_term.poseidon2_a_3) * FF(4)) + ((new_term.poseidon2_a_3 * FF(2)) + (new_term.poseidon2_a_0 + new_term.poseidon2_a_1))))); tmp *= scaling_factor; - std::get<13>(evals) += typename Accumulator::View(tmp); + std::get<9>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<14, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<10, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_EXT_LAYER_5 - (((new_term.poseidon2_a_0 + new_term.poseidon2_a_1) * FF(4)) + ((new_term.poseidon2_a_1 * FF(2)) + (new_term.poseidon2_a_2 + new_term.poseidon2_a_3))))); tmp *= scaling_factor; - std::get<14>(evals) += typename Accumulator::View(tmp); + std::get<10>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<15, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<11, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_EXT_LAYER_6 - (((new_term.poseidon2_a_3 * FF(2)) + (new_term.poseidon2_a_0 + new_term.poseidon2_a_1)) + new_term.poseidon2_EXT_LAYER_5))); tmp *= scaling_factor; - std::get<15>(evals) += typename Accumulator::View(tmp); + std::get<11>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<16, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<12, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_EXT_LAYER_7 - (((new_term.poseidon2_a_1 * FF(2)) + (new_term.poseidon2_a_2 + new_term.poseidon2_a_3)) + new_term.poseidon2_EXT_LAYER_4))); tmp *= scaling_factor; - std::get<16>(evals) += typename Accumulator::View(tmp); + std::get<12>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<17, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<13, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_0_4 - ((((((((new_term.poseidon2_EXT_LAYER_7 + FF(uint256_t{ 4466505105966356650UL, @@ -547,10 +514,10 @@ template class poseidon2Impl { 8230667498854222355UL, 2764611904404804029UL })))))))); tmp *= scaling_factor; - std::get<17>(evals) += typename Accumulator::View(tmp); + std::get<13>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<18, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<14, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_0_5 - ((((((((new_term.poseidon2_EXT_LAYER_6 + FF(uint256_t{ 10018390284920759269UL, @@ -656,10 +623,10 @@ template class poseidon2Impl { 1229208533183169201UL, 1549225070791782920UL })))))))); tmp *= scaling_factor; - std::get<18>(evals) += typename Accumulator::View(tmp); + std::get<14>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<19, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<15, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_0_6 - ((((((((new_term.poseidon2_EXT_LAYER_4 + FF(uint256_t{ 15002325471271702008UL, @@ -725,10 +692,10 @@ template class poseidon2Impl { 2764611904404804029UL }))))) + new_term.poseidon2_T_0_5))); tmp *= scaling_factor; - std::get<19>(evals) += typename Accumulator::View(tmp); + std::get<15>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<20, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<16, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_0_7 - ((((((((new_term.poseidon2_EXT_LAYER_5 + FF(uint256_t{ 12486221224710452438UL, @@ -794,10 +761,10 @@ template class poseidon2Impl { 1549225070791782920UL }))))) + new_term.poseidon2_T_0_4))); tmp *= scaling_factor; - std::get<20>(evals) += typename Accumulator::View(tmp); + std::get<16>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<21, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<17, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_1_4 - ((((((((new_term.poseidon2_T_0_7 + FF(uint256_t{ 14339023814126516630UL, @@ -903,10 +870,10 @@ template class poseidon2Impl { 957840840567621315UL, 1024001058677493842UL })))))))); tmp *= scaling_factor; - std::get<21>(evals) += typename Accumulator::View(tmp); + std::get<17>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<22, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<18, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_1_5 - ((((((((new_term.poseidon2_T_0_6 + FF(uint256_t{ 18309653156114024706UL, @@ -1012,10 +979,10 @@ template class poseidon2Impl { 10985380589240272449UL, 1430464474809378870UL })))))))); tmp *= scaling_factor; - std::get<22>(evals) += typename Accumulator::View(tmp); + std::get<18>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<23, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<19, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_1_6 - ((((((((new_term.poseidon2_T_0_4 + FF(uint256_t{ 6214865908119297870UL, @@ -1081,10 +1048,10 @@ template class poseidon2Impl { 1024001058677493842UL }))))) + new_term.poseidon2_T_1_5))); tmp *= scaling_factor; - std::get<23>(evals) += typename Accumulator::View(tmp); + std::get<19>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<24, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<20, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_1_7 - ((((((((new_term.poseidon2_T_0_5 + FF(uint256_t{ 2824096028161810206UL, @@ -1150,10 +1117,10 @@ template class poseidon2Impl { 1430464474809378870UL }))))) + new_term.poseidon2_T_1_4))); tmp *= scaling_factor; - std::get<24>(evals) += typename Accumulator::View(tmp); + std::get<20>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<25, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<21, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_2_4 - ((((((((new_term.poseidon2_T_1_7 + FF(uint256_t{ 9646436663147525449UL, @@ -1259,10 +1226,10 @@ template class poseidon2Impl { 115174089281514891UL, 80808271106704719UL })))))))); tmp *= scaling_factor; - std::get<25>(evals) += typename Accumulator::View(tmp); + std::get<21>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<26, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<22, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_2_5 - @@ -1368,10 +1335,10 @@ template class poseidon2Impl { 2426504795124362174UL, 350059533408463330UL })))))))); tmp *= scaling_factor; - std::get<26>(evals) += typename Accumulator::View(tmp); + std::get<22>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<27, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<23, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_2_6 - ((((((((new_term.poseidon2_T_1_4 + FF(uint256_t{ 5059356740217174171UL, @@ -1437,10 +1404,10 @@ template class poseidon2Impl { 80808271106704719UL }))))) + new_term.poseidon2_T_2_5))); tmp *= scaling_factor; - std::get<27>(evals) += typename Accumulator::View(tmp); + std::get<23>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<28, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<24, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_2_7 - @@ -1506,10 +1473,10 @@ template class poseidon2Impl { 350059533408463330UL }))))) + new_term.poseidon2_T_2_4))); tmp *= scaling_factor; - std::get<28>(evals) += typename Accumulator::View(tmp); + std::get<24>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<29, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<25, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_3_4 - ((((((((new_term.poseidon2_T_2_7 + FF(uint256_t{ 8805379462752425633UL, @@ -1615,10 +1582,10 @@ template class poseidon2Impl { 10343110624935622906UL, 2709590753056582169UL })))))))); tmp *= scaling_factor; - std::get<29>(evals) += typename Accumulator::View(tmp); + std::get<25>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<30, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<26, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_3_5 - ((((((((new_term.poseidon2_T_2_6 + FF(uint256_t{ 14876286709841668328UL, @@ -1724,10 +1691,10 @@ template class poseidon2Impl { 2804088968006330580UL, 728643340397380469UL })))))))); tmp *= scaling_factor; - std::get<30>(evals) += typename Accumulator::View(tmp); + std::get<26>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<31, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<27, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_3_6 - ((((((((new_term.poseidon2_T_2_4 + FF(uint256_t{ 17046614324338172999UL, @@ -1793,10 +1760,10 @@ template class poseidon2Impl { 2709590753056582169UL }))))) + new_term.poseidon2_T_3_5))); tmp *= scaling_factor; - std::get<31>(evals) += typename Accumulator::View(tmp); + std::get<27>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<32, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<28, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_3_7 - ((((((((new_term.poseidon2_T_2_5 + FF(uint256_t{ 16522097747524989503UL, @@ -1862,10 +1829,10 @@ template class poseidon2Impl { 728643340397380469UL }))))) + new_term.poseidon2_T_3_4))); tmp *= scaling_factor; - std::get<32>(evals) += typename Accumulator::View(tmp); + std::get<28>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<33, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<29, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_4_0 - @@ -1915,10 +1882,10 @@ template class poseidon2Impl { (new_term.poseidon2_T_3_7 + FF(0))) + (new_term.poseidon2_T_3_4 + FF(0)))))); tmp *= scaling_factor; - std::get<33>(evals) += typename Accumulator::View(tmp); + std::get<29>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<34, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<30, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_4_1 - @@ -1949,10 +1916,10 @@ template class poseidon2Impl { (new_term.poseidon2_T_3_7 + FF(0))) + (new_term.poseidon2_T_3_4 + FF(0)))))); tmp *= scaling_factor; - std::get<34>(evals) += typename Accumulator::View(tmp); + std::get<30>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<35, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<31, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_4_2 - @@ -1983,10 +1950,10 @@ template class poseidon2Impl { (new_term.poseidon2_T_3_7 + FF(0))) + (new_term.poseidon2_T_3_4 + FF(0)))))); tmp *= scaling_factor; - std::get<35>(evals) += typename Accumulator::View(tmp); + std::get<31>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<36, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<32, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_4_3 - @@ -2017,10 +1984,10 @@ template class poseidon2Impl { (new_term.poseidon2_T_3_7 + FF(0))) + (new_term.poseidon2_T_3_4 + FF(0)))))); tmp *= scaling_factor; - std::get<36>(evals) += typename Accumulator::View(tmp); + std::get<32>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<37, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<33, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_5_0 - @@ -2070,10 +2037,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_4_2 + FF(0))) + (new_term.poseidon2_B_4_3 + FF(0)))))); tmp *= scaling_factor; - std::get<37>(evals) += typename Accumulator::View(tmp); + std::get<33>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<38, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<34, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_5_1 - @@ -2104,10 +2071,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_4_2 + FF(0))) + (new_term.poseidon2_B_4_3 + FF(0)))))); tmp *= scaling_factor; - std::get<38>(evals) += typename Accumulator::View(tmp); + std::get<34>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<39, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<35, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_5_2 - @@ -2138,10 +2105,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_4_2 + FF(0))) + (new_term.poseidon2_B_4_3 + FF(0)))))); tmp *= scaling_factor; - std::get<39>(evals) += typename Accumulator::View(tmp); + std::get<35>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<40, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<36, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_5_3 - @@ -2172,10 +2139,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_4_2 + FF(0))) + (new_term.poseidon2_B_4_3 + FF(0)))))); tmp *= scaling_factor; - std::get<40>(evals) += typename Accumulator::View(tmp); + std::get<36>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<41, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<37, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_6_0 - @@ -2225,10 +2192,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_5_2 + FF(0))) + (new_term.poseidon2_B_5_3 + FF(0)))))); tmp *= scaling_factor; - std::get<41>(evals) += typename Accumulator::View(tmp); + std::get<37>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<42, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<38, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_6_1 - @@ -2259,10 +2226,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_5_2 + FF(0))) + (new_term.poseidon2_B_5_3 + FF(0)))))); tmp *= scaling_factor; - std::get<42>(evals) += typename Accumulator::View(tmp); + std::get<38>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<43, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<39, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_6_2 - @@ -2293,10 +2260,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_5_2 + FF(0))) + (new_term.poseidon2_B_5_3 + FF(0)))))); tmp *= scaling_factor; - std::get<43>(evals) += typename Accumulator::View(tmp); + std::get<39>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<44, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<40, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_6_3 - @@ -2327,10 +2294,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_5_2 + FF(0))) + (new_term.poseidon2_B_5_3 + FF(0)))))); tmp *= scaling_factor; - std::get<44>(evals) += typename Accumulator::View(tmp); + std::get<40>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<45, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<41, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_7_0 - @@ -2380,10 +2347,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_6_2 + FF(0))) + (new_term.poseidon2_B_6_3 + FF(0)))))); tmp *= scaling_factor; - std::get<45>(evals) += typename Accumulator::View(tmp); + std::get<41>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<46, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<42, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_7_1 - @@ -2414,10 +2381,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_6_2 + FF(0))) + (new_term.poseidon2_B_6_3 + FF(0)))))); tmp *= scaling_factor; - std::get<46>(evals) += typename Accumulator::View(tmp); + std::get<42>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<47, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<43, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_7_2 - @@ -2448,10 +2415,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_6_2 + FF(0))) + (new_term.poseidon2_B_6_3 + FF(0)))))); tmp *= scaling_factor; - std::get<47>(evals) += typename Accumulator::View(tmp); + std::get<43>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<48, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<44, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_7_3 - @@ -2482,10 +2449,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_6_2 + FF(0))) + (new_term.poseidon2_B_6_3 + FF(0)))))); tmp *= scaling_factor; - std::get<48>(evals) += typename Accumulator::View(tmp); + std::get<44>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<49, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<45, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_8_0 - @@ -2535,10 +2502,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_7_2 + FF(0))) + (new_term.poseidon2_B_7_3 + FF(0)))))); tmp *= scaling_factor; - std::get<49>(evals) += typename Accumulator::View(tmp); + std::get<45>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<50, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<46, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_8_1 - @@ -2569,10 +2536,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_7_2 + FF(0))) + (new_term.poseidon2_B_7_3 + FF(0)))))); tmp *= scaling_factor; - std::get<50>(evals) += typename Accumulator::View(tmp); + std::get<46>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<51, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<47, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_8_2 - @@ -2603,10 +2570,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_7_2 + FF(0))) + (new_term.poseidon2_B_7_3 + FF(0)))))); tmp *= scaling_factor; - std::get<51>(evals) += typename Accumulator::View(tmp); + std::get<47>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<52, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<48, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_8_3 - @@ -2637,10 +2604,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_7_2 + FF(0))) + (new_term.poseidon2_B_7_3 + FF(0)))))); tmp *= scaling_factor; - std::get<52>(evals) += typename Accumulator::View(tmp); + std::get<48>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<53, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<49, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_9_0 - @@ -2690,10 +2657,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_8_2 + FF(0))) + (new_term.poseidon2_B_8_3 + FF(0)))))); tmp *= scaling_factor; - std::get<53>(evals) += typename Accumulator::View(tmp); + std::get<49>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<54, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<50, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_9_1 - @@ -2724,10 +2691,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_8_2 + FF(0))) + (new_term.poseidon2_B_8_3 + FF(0)))))); tmp *= scaling_factor; - std::get<54>(evals) += typename Accumulator::View(tmp); + std::get<50>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<55, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<51, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_9_2 - @@ -2758,10 +2725,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_8_2 + FF(0))) + (new_term.poseidon2_B_8_3 + FF(0)))))); tmp *= scaling_factor; - std::get<55>(evals) += typename Accumulator::View(tmp); + std::get<51>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<56, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<52, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_9_3 - @@ -2792,10 +2759,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_8_2 + FF(0))) + (new_term.poseidon2_B_8_3 + FF(0)))))); tmp *= scaling_factor; - std::get<56>(evals) += typename Accumulator::View(tmp); + std::get<52>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<57, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<53, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_10_0 - @@ -2845,10 +2812,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_9_2 + FF(0))) + (new_term.poseidon2_B_9_3 + FF(0)))))); tmp *= scaling_factor; - std::get<57>(evals) += typename Accumulator::View(tmp); + std::get<53>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<58, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<54, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_10_1 - @@ -2879,10 +2846,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_9_2 + FF(0))) + (new_term.poseidon2_B_9_3 + FF(0)))))); tmp *= scaling_factor; - std::get<58>(evals) += typename Accumulator::View(tmp); + std::get<54>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<59, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<55, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_10_2 - @@ -2913,10 +2880,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_9_2 + FF(0))) + (new_term.poseidon2_B_9_3 + FF(0)))))); tmp *= scaling_factor; - std::get<59>(evals) += typename Accumulator::View(tmp); + std::get<55>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<60, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<56, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_10_3 - @@ -2947,10 +2914,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_9_2 + FF(0))) + (new_term.poseidon2_B_9_3 + FF(0)))))); tmp *= scaling_factor; - std::get<60>(evals) += typename Accumulator::View(tmp); + std::get<56>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<61, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<57, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_11_0 - @@ -3000,10 +2967,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_10_2 + FF(0))) + (new_term.poseidon2_B_10_3 + FF(0)))))); tmp *= scaling_factor; - std::get<61>(evals) += typename Accumulator::View(tmp); + std::get<57>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<62, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<58, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_11_1 - @@ -3034,10 +3001,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_10_2 + FF(0))) + (new_term.poseidon2_B_10_3 + FF(0)))))); tmp *= scaling_factor; - std::get<62>(evals) += typename Accumulator::View(tmp); + std::get<58>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<63, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<59, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_11_2 - @@ -3068,10 +3035,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_10_2 + FF(0))) + (new_term.poseidon2_B_10_3 + FF(0)))))); tmp *= scaling_factor; - std::get<63>(evals) += typename Accumulator::View(tmp); + std::get<59>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<64, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<60, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_11_3 - @@ -3102,10 +3069,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_10_2 + FF(0))) + (new_term.poseidon2_B_10_3 + FF(0)))))); tmp *= scaling_factor; - std::get<64>(evals) += typename Accumulator::View(tmp); + std::get<60>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<65, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<61, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_12_0 - @@ -3155,10 +3122,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_11_2 + FF(0))) + (new_term.poseidon2_B_11_3 + FF(0)))))); tmp *= scaling_factor; - std::get<65>(evals) += typename Accumulator::View(tmp); + std::get<61>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<66, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<62, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_12_1 - @@ -3189,10 +3156,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_11_2 + FF(0))) + (new_term.poseidon2_B_11_3 + FF(0)))))); tmp *= scaling_factor; - std::get<66>(evals) += typename Accumulator::View(tmp); + std::get<62>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<67, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<63, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_12_2 - @@ -3223,10 +3190,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_11_2 + FF(0))) + (new_term.poseidon2_B_11_3 + FF(0)))))); tmp *= scaling_factor; - std::get<67>(evals) += typename Accumulator::View(tmp); + std::get<63>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<68, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<64, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_12_3 - @@ -3257,10 +3224,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_11_2 + FF(0))) + (new_term.poseidon2_B_11_3 + FF(0)))))); tmp *= scaling_factor; - std::get<68>(evals) += typename Accumulator::View(tmp); + std::get<64>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<69, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<65, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_13_0 - @@ -3310,10 +3277,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_12_2 + FF(0))) + (new_term.poseidon2_B_12_3 + FF(0)))))); tmp *= scaling_factor; - std::get<69>(evals) += typename Accumulator::View(tmp); + std::get<65>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<70, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<66, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_13_1 - @@ -3344,10 +3311,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_12_2 + FF(0))) + (new_term.poseidon2_B_12_3 + FF(0)))))); tmp *= scaling_factor; - std::get<70>(evals) += typename Accumulator::View(tmp); + std::get<66>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<71, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<67, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_13_2 - @@ -3378,10 +3345,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_12_2 + FF(0))) + (new_term.poseidon2_B_12_3 + FF(0)))))); tmp *= scaling_factor; - std::get<71>(evals) += typename Accumulator::View(tmp); + std::get<67>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<72, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<68, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_13_3 - @@ -3412,10 +3379,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_12_2 + FF(0))) + (new_term.poseidon2_B_12_3 + FF(0)))))); tmp *= scaling_factor; - std::get<72>(evals) += typename Accumulator::View(tmp); + std::get<68>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<73, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<69, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_14_0 - @@ -3465,10 +3432,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_13_2 + FF(0))) + (new_term.poseidon2_B_13_3 + FF(0)))))); tmp *= scaling_factor; - std::get<73>(evals) += typename Accumulator::View(tmp); + std::get<69>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<74, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<70, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_14_1 - @@ -3499,10 +3466,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_13_2 + FF(0))) + (new_term.poseidon2_B_13_3 + FF(0)))))); tmp *= scaling_factor; - std::get<74>(evals) += typename Accumulator::View(tmp); + std::get<70>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<75, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<71, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_14_2 - @@ -3533,10 +3500,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_13_2 + FF(0))) + (new_term.poseidon2_B_13_3 + FF(0)))))); tmp *= scaling_factor; - std::get<75>(evals) += typename Accumulator::View(tmp); + std::get<71>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<76, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<72, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_14_3 - @@ -3567,10 +3534,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_13_2 + FF(0))) + (new_term.poseidon2_B_13_3 + FF(0)))))); tmp *= scaling_factor; - std::get<76>(evals) += typename Accumulator::View(tmp); + std::get<72>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<77, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<73, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_15_0 - @@ -3620,10 +3587,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_14_2 + FF(0))) + (new_term.poseidon2_B_14_3 + FF(0)))))); tmp *= scaling_factor; - std::get<77>(evals) += typename Accumulator::View(tmp); + std::get<73>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<78, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<74, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_15_1 - @@ -3654,10 +3621,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_14_2 + FF(0))) + (new_term.poseidon2_B_14_3 + FF(0)))))); tmp *= scaling_factor; - std::get<78>(evals) += typename Accumulator::View(tmp); + std::get<74>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<79, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<75, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_15_2 - @@ -3688,10 +3655,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_14_2 + FF(0))) + (new_term.poseidon2_B_14_3 + FF(0)))))); tmp *= scaling_factor; - std::get<79>(evals) += typename Accumulator::View(tmp); + std::get<75>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<80, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<76, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_15_3 - @@ -3722,10 +3689,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_14_2 + FF(0))) + (new_term.poseidon2_B_14_3 + FF(0)))))); tmp *= scaling_factor; - std::get<80>(evals) += typename Accumulator::View(tmp); + std::get<76>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<81, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<77, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_16_0 - @@ -3775,10 +3742,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_15_2 + FF(0))) + (new_term.poseidon2_B_15_3 + FF(0)))))); tmp *= scaling_factor; - std::get<81>(evals) += typename Accumulator::View(tmp); + std::get<77>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<82, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<78, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_16_1 - @@ -3809,10 +3776,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_15_2 + FF(0))) + (new_term.poseidon2_B_15_3 + FF(0)))))); tmp *= scaling_factor; - std::get<82>(evals) += typename Accumulator::View(tmp); + std::get<78>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<83, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<79, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_16_2 - @@ -3843,10 +3810,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_15_2 + FF(0))) + (new_term.poseidon2_B_15_3 + FF(0)))))); tmp *= scaling_factor; - std::get<83>(evals) += typename Accumulator::View(tmp); + std::get<79>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<84, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<80, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_16_3 - @@ -3877,10 +3844,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_15_2 + FF(0))) + (new_term.poseidon2_B_15_3 + FF(0)))))); tmp *= scaling_factor; - std::get<84>(evals) += typename Accumulator::View(tmp); + std::get<80>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<85, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<81, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_17_0 - @@ -3930,10 +3897,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_16_2 + FF(0))) + (new_term.poseidon2_B_16_3 + FF(0)))))); tmp *= scaling_factor; - std::get<85>(evals) += typename Accumulator::View(tmp); + std::get<81>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<86, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<82, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_17_1 - @@ -3964,10 +3931,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_16_2 + FF(0))) + (new_term.poseidon2_B_16_3 + FF(0)))))); tmp *= scaling_factor; - std::get<86>(evals) += typename Accumulator::View(tmp); + std::get<82>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<87, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<83, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_17_2 - @@ -3998,10 +3965,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_16_2 + FF(0))) + (new_term.poseidon2_B_16_3 + FF(0)))))); tmp *= scaling_factor; - std::get<87>(evals) += typename Accumulator::View(tmp); + std::get<83>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<88, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<84, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_17_3 - @@ -4032,10 +3999,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_16_2 + FF(0))) + (new_term.poseidon2_B_16_3 + FF(0)))))); tmp *= scaling_factor; - std::get<88>(evals) += typename Accumulator::View(tmp); + std::get<84>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<89, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<85, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_18_0 - @@ -4085,10 +4052,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_17_2 + FF(0))) + (new_term.poseidon2_B_17_3 + FF(0)))))); tmp *= scaling_factor; - std::get<89>(evals) += typename Accumulator::View(tmp); + std::get<85>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<90, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<86, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_18_1 - @@ -4119,10 +4086,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_17_2 + FF(0))) + (new_term.poseidon2_B_17_3 + FF(0)))))); tmp *= scaling_factor; - std::get<90>(evals) += typename Accumulator::View(tmp); + std::get<86>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<91, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<87, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_18_2 - @@ -4153,10 +4120,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_17_2 + FF(0))) + (new_term.poseidon2_B_17_3 + FF(0)))))); tmp *= scaling_factor; - std::get<91>(evals) += typename Accumulator::View(tmp); + std::get<87>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<92, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<88, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_18_3 - @@ -4187,10 +4154,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_17_2 + FF(0))) + (new_term.poseidon2_B_17_3 + FF(0)))))); tmp *= scaling_factor; - std::get<92>(evals) += typename Accumulator::View(tmp); + std::get<88>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<93, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<89, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_19_0 - @@ -4240,10 +4207,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_18_2 + FF(0))) + (new_term.poseidon2_B_18_3 + FF(0)))))); tmp *= scaling_factor; - std::get<93>(evals) += typename Accumulator::View(tmp); + std::get<89>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<94, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<90, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_19_1 - @@ -4274,10 +4241,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_18_2 + FF(0))) + (new_term.poseidon2_B_18_3 + FF(0)))))); tmp *= scaling_factor; - std::get<94>(evals) += typename Accumulator::View(tmp); + std::get<90>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<95, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<91, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_19_2 - @@ -4308,10 +4275,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_18_2 + FF(0))) + (new_term.poseidon2_B_18_3 + FF(0)))))); tmp *= scaling_factor; - std::get<95>(evals) += typename Accumulator::View(tmp); + std::get<91>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<96, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<92, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_19_3 - @@ -4342,10 +4309,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_18_2 + FF(0))) + (new_term.poseidon2_B_18_3 + FF(0)))))); tmp *= scaling_factor; - std::get<96>(evals) += typename Accumulator::View(tmp); + std::get<92>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<97, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<93, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_20_0 - @@ -4395,10 +4362,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_19_2 + FF(0))) + (new_term.poseidon2_B_19_3 + FF(0)))))); tmp *= scaling_factor; - std::get<97>(evals) += typename Accumulator::View(tmp); + std::get<93>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<98, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<94, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_20_1 - @@ -4429,10 +4396,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_19_2 + FF(0))) + (new_term.poseidon2_B_19_3 + FF(0)))))); tmp *= scaling_factor; - std::get<98>(evals) += typename Accumulator::View(tmp); + std::get<94>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<99, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<95, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_20_2 - @@ -4463,10 +4430,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_19_2 + FF(0))) + (new_term.poseidon2_B_19_3 + FF(0)))))); tmp *= scaling_factor; - std::get<99>(evals) += typename Accumulator::View(tmp); + std::get<95>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<100, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<96, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_20_3 - @@ -4497,10 +4464,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_19_2 + FF(0))) + (new_term.poseidon2_B_19_3 + FF(0)))))); tmp *= scaling_factor; - std::get<100>(evals) += typename Accumulator::View(tmp); + std::get<96>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<101, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<97, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_21_0 - @@ -4550,10 +4517,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_20_2 + FF(0))) + (new_term.poseidon2_B_20_3 + FF(0)))))); tmp *= scaling_factor; - std::get<101>(evals) += typename Accumulator::View(tmp); + std::get<97>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<102, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<98, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_21_1 - @@ -4584,10 +4551,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_20_2 + FF(0))) + (new_term.poseidon2_B_20_3 + FF(0)))))); tmp *= scaling_factor; - std::get<102>(evals) += typename Accumulator::View(tmp); + std::get<98>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<103, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<99, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_21_2 - @@ -4618,10 +4585,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_20_2 + FF(0))) + (new_term.poseidon2_B_20_3 + FF(0)))))); tmp *= scaling_factor; - std::get<103>(evals) += typename Accumulator::View(tmp); + std::get<99>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<104, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<100, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_21_3 - @@ -4652,10 +4619,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_20_2 + FF(0))) + (new_term.poseidon2_B_20_3 + FF(0)))))); tmp *= scaling_factor; - std::get<104>(evals) += typename Accumulator::View(tmp); + std::get<100>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<105, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<101, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_22_0 - @@ -4705,10 +4672,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_21_2 + FF(0))) + (new_term.poseidon2_B_21_3 + FF(0)))))); tmp *= scaling_factor; - std::get<105>(evals) += typename Accumulator::View(tmp); + std::get<101>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<106, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<102, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_22_1 - @@ -4739,10 +4706,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_21_2 + FF(0))) + (new_term.poseidon2_B_21_3 + FF(0)))))); tmp *= scaling_factor; - std::get<106>(evals) += typename Accumulator::View(tmp); + std::get<102>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<107, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<103, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_22_2 - @@ -4773,10 +4740,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_21_2 + FF(0))) + (new_term.poseidon2_B_21_3 + FF(0)))))); tmp *= scaling_factor; - std::get<107>(evals) += typename Accumulator::View(tmp); + std::get<103>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<108, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<104, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_22_3 - @@ -4807,10 +4774,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_21_2 + FF(0))) + (new_term.poseidon2_B_21_3 + FF(0)))))); tmp *= scaling_factor; - std::get<108>(evals) += typename Accumulator::View(tmp); + std::get<104>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<109, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<105, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_23_0 - @@ -4860,10 +4827,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_22_2 + FF(0))) + (new_term.poseidon2_B_22_3 + FF(0)))))); tmp *= scaling_factor; - std::get<109>(evals) += typename Accumulator::View(tmp); + std::get<105>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<110, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<106, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_23_1 - @@ -4894,10 +4861,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_22_2 + FF(0))) + (new_term.poseidon2_B_22_3 + FF(0)))))); tmp *= scaling_factor; - std::get<110>(evals) += typename Accumulator::View(tmp); + std::get<106>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<111, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<107, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_23_2 - @@ -4928,10 +4895,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_22_2 + FF(0))) + (new_term.poseidon2_B_22_3 + FF(0)))))); tmp *= scaling_factor; - std::get<111>(evals) += typename Accumulator::View(tmp); + std::get<107>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<112, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<108, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_23_3 - @@ -4962,10 +4929,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_22_2 + FF(0))) + (new_term.poseidon2_B_22_3 + FF(0)))))); tmp *= scaling_factor; - std::get<112>(evals) += typename Accumulator::View(tmp); + std::get<108>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<113, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<109, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_24_0 - @@ -5015,10 +4982,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_23_2 + FF(0))) + (new_term.poseidon2_B_23_3 + FF(0)))))); tmp *= scaling_factor; - std::get<113>(evals) += typename Accumulator::View(tmp); + std::get<109>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<114, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<110, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_24_1 - @@ -5049,10 +5016,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_23_2 + FF(0))) + (new_term.poseidon2_B_23_3 + FF(0)))))); tmp *= scaling_factor; - std::get<114>(evals) += typename Accumulator::View(tmp); + std::get<110>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<115, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<111, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_24_2 - @@ -5083,10 +5050,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_23_2 + FF(0))) + (new_term.poseidon2_B_23_3 + FF(0)))))); tmp *= scaling_factor; - std::get<115>(evals) += typename Accumulator::View(tmp); + std::get<111>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<116, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<112, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_24_3 - @@ -5117,10 +5084,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_23_2 + FF(0))) + (new_term.poseidon2_B_23_3 + FF(0)))))); tmp *= scaling_factor; - std::get<116>(evals) += typename Accumulator::View(tmp); + std::get<112>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<117, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<113, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_25_0 - @@ -5170,10 +5137,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_24_2 + FF(0))) + (new_term.poseidon2_B_24_3 + FF(0)))))); tmp *= scaling_factor; - std::get<117>(evals) += typename Accumulator::View(tmp); + std::get<113>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<118, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<114, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_25_1 - @@ -5204,10 +5171,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_24_2 + FF(0))) + (new_term.poseidon2_B_24_3 + FF(0)))))); tmp *= scaling_factor; - std::get<118>(evals) += typename Accumulator::View(tmp); + std::get<114>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<119, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<115, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_25_2 - @@ -5238,10 +5205,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_24_2 + FF(0))) + (new_term.poseidon2_B_24_3 + FF(0)))))); tmp *= scaling_factor; - std::get<119>(evals) += typename Accumulator::View(tmp); + std::get<115>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<120, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<116, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_25_3 - @@ -5272,10 +5239,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_24_2 + FF(0))) + (new_term.poseidon2_B_24_3 + FF(0)))))); tmp *= scaling_factor; - std::get<120>(evals) += typename Accumulator::View(tmp); + std::get<116>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<121, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<117, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_26_0 - @@ -5324,10 +5291,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_25_2 + FF(0))) + (new_term.poseidon2_B_25_3 + FF(0)))))); tmp *= scaling_factor; - std::get<121>(evals) += typename Accumulator::View(tmp); + std::get<117>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<122, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<118, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_26_1 - @@ -5358,10 +5325,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_25_2 + FF(0))) + (new_term.poseidon2_B_25_3 + FF(0)))))); tmp *= scaling_factor; - std::get<122>(evals) += typename Accumulator::View(tmp); + std::get<118>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<123, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<119, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_26_2 - @@ -5392,10 +5359,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_25_2 + FF(0))) + (new_term.poseidon2_B_25_3 + FF(0)))))); tmp *= scaling_factor; - std::get<123>(evals) += typename Accumulator::View(tmp); + std::get<119>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<124, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<120, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_26_3 - @@ -5426,10 +5393,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_25_2 + FF(0))) + (new_term.poseidon2_B_25_3 + FF(0)))))); tmp *= scaling_factor; - std::get<124>(evals) += typename Accumulator::View(tmp); + std::get<120>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<125, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<121, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_27_0 - @@ -5479,10 +5446,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_26_2 + FF(0))) + (new_term.poseidon2_B_26_3 + FF(0)))))); tmp *= scaling_factor; - std::get<125>(evals) += typename Accumulator::View(tmp); + std::get<121>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<126, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<122, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_27_1 - @@ -5513,10 +5480,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_26_2 + FF(0))) + (new_term.poseidon2_B_26_3 + FF(0)))))); tmp *= scaling_factor; - std::get<126>(evals) += typename Accumulator::View(tmp); + std::get<122>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<127, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<123, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_27_2 - @@ -5547,10 +5514,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_26_2 + FF(0))) + (new_term.poseidon2_B_26_3 + FF(0)))))); tmp *= scaling_factor; - std::get<127>(evals) += typename Accumulator::View(tmp); + std::get<123>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<128, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<124, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_27_3 - @@ -5581,10 +5548,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_26_2 + FF(0))) + (new_term.poseidon2_B_26_3 + FF(0)))))); tmp *= scaling_factor; - std::get<128>(evals) += typename Accumulator::View(tmp); + std::get<124>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<129, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<125, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_28_0 - @@ -5634,10 +5601,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_27_2 + FF(0))) + (new_term.poseidon2_B_27_3 + FF(0)))))); tmp *= scaling_factor; - std::get<129>(evals) += typename Accumulator::View(tmp); + std::get<125>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<130, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<126, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_28_1 - @@ -5668,10 +5635,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_27_2 + FF(0))) + (new_term.poseidon2_B_27_3 + FF(0)))))); tmp *= scaling_factor; - std::get<130>(evals) += typename Accumulator::View(tmp); + std::get<126>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<131, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<127, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_28_2 - @@ -5702,10 +5669,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_27_2 + FF(0))) + (new_term.poseidon2_B_27_3 + FF(0)))))); tmp *= scaling_factor; - std::get<131>(evals) += typename Accumulator::View(tmp); + std::get<127>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<132, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<128, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_28_3 - @@ -5736,10 +5703,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_27_2 + FF(0))) + (new_term.poseidon2_B_27_3 + FF(0)))))); tmp *= scaling_factor; - std::get<132>(evals) += typename Accumulator::View(tmp); + std::get<128>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<133, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<129, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_29_0 - @@ -5789,10 +5756,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_28_2 + FF(0))) + (new_term.poseidon2_B_28_3 + FF(0)))))); tmp *= scaling_factor; - std::get<133>(evals) += typename Accumulator::View(tmp); + std::get<129>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<134, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<130, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_29_1 - @@ -5823,10 +5790,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_28_2 + FF(0))) + (new_term.poseidon2_B_28_3 + FF(0)))))); tmp *= scaling_factor; - std::get<134>(evals) += typename Accumulator::View(tmp); + std::get<130>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<135, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<131, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_29_2 - @@ -5857,10 +5824,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_28_2 + FF(0))) + (new_term.poseidon2_B_28_3 + FF(0)))))); tmp *= scaling_factor; - std::get<135>(evals) += typename Accumulator::View(tmp); + std::get<131>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<136, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<132, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_29_3 - @@ -5891,10 +5858,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_28_2 + FF(0))) + (new_term.poseidon2_B_28_3 + FF(0)))))); tmp *= scaling_factor; - std::get<136>(evals) += typename Accumulator::View(tmp); + std::get<132>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<137, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<133, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_30_0 - @@ -5944,10 +5911,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_29_2 + FF(0))) + (new_term.poseidon2_B_29_3 + FF(0)))))); tmp *= scaling_factor; - std::get<137>(evals) += typename Accumulator::View(tmp); + std::get<133>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<138, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<134, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_30_1 - @@ -5978,10 +5945,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_29_2 + FF(0))) + (new_term.poseidon2_B_29_3 + FF(0)))))); tmp *= scaling_factor; - std::get<138>(evals) += typename Accumulator::View(tmp); + std::get<134>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<139, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<135, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_30_2 - @@ -6012,10 +5979,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_29_2 + FF(0))) + (new_term.poseidon2_B_29_3 + FF(0)))))); tmp *= scaling_factor; - std::get<139>(evals) += typename Accumulator::View(tmp); + std::get<135>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<140, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<136, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_30_3 - @@ -6046,10 +6013,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_29_2 + FF(0))) + (new_term.poseidon2_B_29_3 + FF(0)))))); tmp *= scaling_factor; - std::get<140>(evals) += typename Accumulator::View(tmp); + std::get<136>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<141, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<137, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_31_0 - @@ -6099,10 +6066,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_30_2 + FF(0))) + (new_term.poseidon2_B_30_3 + FF(0)))))); tmp *= scaling_factor; - std::get<141>(evals) += typename Accumulator::View(tmp); + std::get<137>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<142, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<138, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_31_1 - @@ -6133,10 +6100,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_30_2 + FF(0))) + (new_term.poseidon2_B_30_3 + FF(0)))))); tmp *= scaling_factor; - std::get<142>(evals) += typename Accumulator::View(tmp); + std::get<138>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<143, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<139, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_31_2 - @@ -6167,10 +6134,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_30_2 + FF(0))) + (new_term.poseidon2_B_30_3 + FF(0)))))); tmp *= scaling_factor; - std::get<143>(evals) += typename Accumulator::View(tmp); + std::get<139>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<144, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<140, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_31_3 - @@ -6201,10 +6168,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_30_2 + FF(0))) + (new_term.poseidon2_B_30_3 + FF(0)))))); tmp *= scaling_factor; - std::get<144>(evals) += typename Accumulator::View(tmp); + std::get<140>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<145, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<141, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_32_0 - @@ -6254,10 +6221,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_31_2 + FF(0))) + (new_term.poseidon2_B_31_3 + FF(0)))))); tmp *= scaling_factor; - std::get<145>(evals) += typename Accumulator::View(tmp); + std::get<141>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<146, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<142, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_32_1 - @@ -6288,10 +6255,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_31_2 + FF(0))) + (new_term.poseidon2_B_31_3 + FF(0)))))); tmp *= scaling_factor; - std::get<146>(evals) += typename Accumulator::View(tmp); + std::get<142>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<147, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<143, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_32_2 - @@ -6322,10 +6289,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_31_2 + FF(0))) + (new_term.poseidon2_B_31_3 + FF(0)))))); tmp *= scaling_factor; - std::get<147>(evals) += typename Accumulator::View(tmp); + std::get<143>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<148, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<144, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_32_3 - @@ -6356,10 +6323,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_31_2 + FF(0))) + (new_term.poseidon2_B_31_3 + FF(0)))))); tmp *= scaling_factor; - std::get<148>(evals) += typename Accumulator::View(tmp); + std::get<144>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<149, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<145, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_33_0 - @@ -6409,10 +6376,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_32_2 + FF(0))) + (new_term.poseidon2_B_32_3 + FF(0)))))); tmp *= scaling_factor; - std::get<149>(evals) += typename Accumulator::View(tmp); + std::get<145>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<150, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<146, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_33_1 - @@ -6443,10 +6410,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_32_2 + FF(0))) + (new_term.poseidon2_B_32_3 + FF(0)))))); tmp *= scaling_factor; - std::get<150>(evals) += typename Accumulator::View(tmp); + std::get<146>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<151, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<147, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_33_2 - @@ -6477,10 +6444,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_32_2 + FF(0))) + (new_term.poseidon2_B_32_3 + FF(0)))))); tmp *= scaling_factor; - std::get<151>(evals) += typename Accumulator::View(tmp); + std::get<147>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<152, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<148, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_33_3 - @@ -6511,10 +6478,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_32_2 + FF(0))) + (new_term.poseidon2_B_32_3 + FF(0)))))); tmp *= scaling_factor; - std::get<152>(evals) += typename Accumulator::View(tmp); + std::get<148>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<153, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<149, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_34_0 - @@ -6564,10 +6531,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_33_2 + FF(0))) + (new_term.poseidon2_B_33_3 + FF(0)))))); tmp *= scaling_factor; - std::get<153>(evals) += typename Accumulator::View(tmp); + std::get<149>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<154, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<150, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_34_1 - @@ -6598,10 +6565,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_33_2 + FF(0))) + (new_term.poseidon2_B_33_3 + FF(0)))))); tmp *= scaling_factor; - std::get<154>(evals) += typename Accumulator::View(tmp); + std::get<150>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<155, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<151, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_34_2 - @@ -6632,10 +6599,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_33_2 + FF(0))) + (new_term.poseidon2_B_33_3 + FF(0)))))); tmp *= scaling_factor; - std::get<155>(evals) += typename Accumulator::View(tmp); + std::get<151>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<156, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<152, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_34_3 - @@ -6666,10 +6633,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_33_2 + FF(0))) + (new_term.poseidon2_B_33_3 + FF(0)))))); tmp *= scaling_factor; - std::get<156>(evals) += typename Accumulator::View(tmp); + std::get<152>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<157, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<153, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_35_0 - @@ -6719,10 +6686,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_34_2 + FF(0))) + (new_term.poseidon2_B_34_3 + FF(0)))))); tmp *= scaling_factor; - std::get<157>(evals) += typename Accumulator::View(tmp); + std::get<153>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<158, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<154, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_35_1 - @@ -6753,10 +6720,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_34_2 + FF(0))) + (new_term.poseidon2_B_34_3 + FF(0)))))); tmp *= scaling_factor; - std::get<158>(evals) += typename Accumulator::View(tmp); + std::get<154>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<159, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<155, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_35_2 - @@ -6787,10 +6754,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_34_2 + FF(0))) + (new_term.poseidon2_B_34_3 + FF(0)))))); tmp *= scaling_factor; - std::get<159>(evals) += typename Accumulator::View(tmp); + std::get<155>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<160, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<156, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_35_3 - @@ -6821,10 +6788,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_34_2 + FF(0))) + (new_term.poseidon2_B_34_3 + FF(0)))))); tmp *= scaling_factor; - std::get<160>(evals) += typename Accumulator::View(tmp); + std::get<156>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<161, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<157, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_36_0 - @@ -6874,10 +6841,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_35_2 + FF(0))) + (new_term.poseidon2_B_35_3 + FF(0)))))); tmp *= scaling_factor; - std::get<161>(evals) += typename Accumulator::View(tmp); + std::get<157>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<162, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<158, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_36_1 - @@ -6908,10 +6875,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_35_2 + FF(0))) + (new_term.poseidon2_B_35_3 + FF(0)))))); tmp *= scaling_factor; - std::get<162>(evals) += typename Accumulator::View(tmp); + std::get<158>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<163, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<159, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_36_2 - @@ -6942,10 +6909,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_35_2 + FF(0))) + (new_term.poseidon2_B_35_3 + FF(0)))))); tmp *= scaling_factor; - std::get<163>(evals) += typename Accumulator::View(tmp); + std::get<159>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<164, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<160, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_36_3 - @@ -6976,10 +6943,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_35_2 + FF(0))) + (new_term.poseidon2_B_35_3 + FF(0)))))); tmp *= scaling_factor; - std::get<164>(evals) += typename Accumulator::View(tmp); + std::get<160>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<165, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<161, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_37_0 - @@ -7029,10 +6996,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_36_2 + FF(0))) + (new_term.poseidon2_B_36_3 + FF(0)))))); tmp *= scaling_factor; - std::get<165>(evals) += typename Accumulator::View(tmp); + std::get<161>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<166, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<162, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_37_1 - @@ -7063,10 +7030,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_36_2 + FF(0))) + (new_term.poseidon2_B_36_3 + FF(0)))))); tmp *= scaling_factor; - std::get<166>(evals) += typename Accumulator::View(tmp); + std::get<162>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<167, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<163, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_37_2 - @@ -7097,10 +7064,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_36_2 + FF(0))) + (new_term.poseidon2_B_36_3 + FF(0)))))); tmp *= scaling_factor; - std::get<167>(evals) += typename Accumulator::View(tmp); + std::get<163>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<168, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<164, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_37_3 - @@ -7131,10 +7098,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_36_2 + FF(0))) + (new_term.poseidon2_B_36_3 + FF(0)))))); tmp *= scaling_factor; - std::get<168>(evals) += typename Accumulator::View(tmp); + std::get<164>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<169, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<165, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_38_0 - @@ -7184,10 +7151,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_37_2 + FF(0))) + (new_term.poseidon2_B_37_3 + FF(0)))))); tmp *= scaling_factor; - std::get<169>(evals) += typename Accumulator::View(tmp); + std::get<165>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<170, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<166, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_38_1 - @@ -7218,10 +7185,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_37_2 + FF(0))) + (new_term.poseidon2_B_37_3 + FF(0)))))); tmp *= scaling_factor; - std::get<170>(evals) += typename Accumulator::View(tmp); + std::get<166>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<171, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<167, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_38_2 - @@ -7252,10 +7219,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_37_2 + FF(0))) + (new_term.poseidon2_B_37_3 + FF(0)))))); tmp *= scaling_factor; - std::get<171>(evals) += typename Accumulator::View(tmp); + std::get<167>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<172, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<168, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_38_3 - @@ -7286,10 +7253,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_37_2 + FF(0))) + (new_term.poseidon2_B_37_3 + FF(0)))))); tmp *= scaling_factor; - std::get<172>(evals) += typename Accumulator::View(tmp); + std::get<168>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<173, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<169, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_39_0 - @@ -7339,10 +7306,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_38_2 + FF(0))) + (new_term.poseidon2_B_38_3 + FF(0)))))); tmp *= scaling_factor; - std::get<173>(evals) += typename Accumulator::View(tmp); + std::get<169>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<174, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<170, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_39_1 - @@ -7373,10 +7340,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_38_2 + FF(0))) + (new_term.poseidon2_B_38_3 + FF(0)))))); tmp *= scaling_factor; - std::get<174>(evals) += typename Accumulator::View(tmp); + std::get<170>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<175, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<171, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_39_2 - @@ -7407,10 +7374,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_38_2 + FF(0))) + (new_term.poseidon2_B_38_3 + FF(0)))))); tmp *= scaling_factor; - std::get<175>(evals) += typename Accumulator::View(tmp); + std::get<171>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<176, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<172, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_39_3 - @@ -7441,10 +7408,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_38_2 + FF(0))) + (new_term.poseidon2_B_38_3 + FF(0)))))); tmp *= scaling_factor; - std::get<176>(evals) += typename Accumulator::View(tmp); + std::get<172>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<177, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<173, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_40_0 - @@ -7494,10 +7461,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_39_2 + FF(0))) + (new_term.poseidon2_B_39_3 + FF(0)))))); tmp *= scaling_factor; - std::get<177>(evals) += typename Accumulator::View(tmp); + std::get<173>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<178, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<174, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_40_1 - @@ -7528,10 +7495,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_39_2 + FF(0))) + (new_term.poseidon2_B_39_3 + FF(0)))))); tmp *= scaling_factor; - std::get<178>(evals) += typename Accumulator::View(tmp); + std::get<174>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<179, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<175, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_40_2 - @@ -7562,10 +7529,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_39_2 + FF(0))) + (new_term.poseidon2_B_39_3 + FF(0)))))); tmp *= scaling_factor; - std::get<179>(evals) += typename Accumulator::View(tmp); + std::get<175>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<180, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<176, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_40_3 - @@ -7596,10 +7563,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_39_2 + FF(0))) + (new_term.poseidon2_B_39_3 + FF(0)))))); tmp *= scaling_factor; - std::get<180>(evals) += typename Accumulator::View(tmp); + std::get<176>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<181, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<177, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_41_0 - @@ -7649,10 +7616,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_40_2 + FF(0))) + (new_term.poseidon2_B_40_3 + FF(0)))))); tmp *= scaling_factor; - std::get<181>(evals) += typename Accumulator::View(tmp); + std::get<177>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<182, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<178, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_41_1 - @@ -7683,10 +7650,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_40_2 + FF(0))) + (new_term.poseidon2_B_40_3 + FF(0)))))); tmp *= scaling_factor; - std::get<182>(evals) += typename Accumulator::View(tmp); + std::get<178>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<183, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<179, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_41_2 - @@ -7717,10 +7684,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_40_2 + FF(0))) + (new_term.poseidon2_B_40_3 + FF(0)))))); tmp *= scaling_factor; - std::get<183>(evals) += typename Accumulator::View(tmp); + std::get<179>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<184, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<180, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_41_3 - @@ -7751,10 +7718,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_40_2 + FF(0))) + (new_term.poseidon2_B_40_3 + FF(0)))))); tmp *= scaling_factor; - std::get<184>(evals) += typename Accumulator::View(tmp); + std::get<180>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<185, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<181, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_42_0 - @@ -7804,10 +7771,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_41_2 + FF(0))) + (new_term.poseidon2_B_41_3 + FF(0)))))); tmp *= scaling_factor; - std::get<185>(evals) += typename Accumulator::View(tmp); + std::get<181>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<186, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<182, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_42_1 - @@ -7838,10 +7805,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_41_2 + FF(0))) + (new_term.poseidon2_B_41_3 + FF(0)))))); tmp *= scaling_factor; - std::get<186>(evals) += typename Accumulator::View(tmp); + std::get<182>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<187, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<183, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_42_2 - @@ -7872,10 +7839,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_41_2 + FF(0))) + (new_term.poseidon2_B_41_3 + FF(0)))))); tmp *= scaling_factor; - std::get<187>(evals) += typename Accumulator::View(tmp); + std::get<183>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<188, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<184, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_42_3 - @@ -7906,10 +7873,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_41_2 + FF(0))) + (new_term.poseidon2_B_41_3 + FF(0)))))); tmp *= scaling_factor; - std::get<188>(evals) += typename Accumulator::View(tmp); + std::get<184>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<189, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<185, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_43_0 - @@ -7959,10 +7926,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_42_2 + FF(0))) + (new_term.poseidon2_B_42_3 + FF(0)))))); tmp *= scaling_factor; - std::get<189>(evals) += typename Accumulator::View(tmp); + std::get<185>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<190, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<186, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_43_1 - @@ -7993,10 +7960,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_42_2 + FF(0))) + (new_term.poseidon2_B_42_3 + FF(0)))))); tmp *= scaling_factor; - std::get<190>(evals) += typename Accumulator::View(tmp); + std::get<186>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<191, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<187, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_43_2 - @@ -8027,10 +7994,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_42_2 + FF(0))) + (new_term.poseidon2_B_42_3 + FF(0)))))); tmp *= scaling_factor; - std::get<191>(evals) += typename Accumulator::View(tmp); + std::get<187>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<192, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<188, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_43_3 - @@ -8061,10 +8028,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_42_2 + FF(0))) + (new_term.poseidon2_B_42_3 + FF(0)))))); tmp *= scaling_factor; - std::get<192>(evals) += typename Accumulator::View(tmp); + std::get<188>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<193, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<189, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_44_0 - @@ -8114,10 +8081,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_43_2 + FF(0))) + (new_term.poseidon2_B_43_3 + FF(0)))))); tmp *= scaling_factor; - std::get<193>(evals) += typename Accumulator::View(tmp); + std::get<189>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<194, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<190, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_44_1 - @@ -8148,10 +8115,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_43_2 + FF(0))) + (new_term.poseidon2_B_43_3 + FF(0)))))); tmp *= scaling_factor; - std::get<194>(evals) += typename Accumulator::View(tmp); + std::get<190>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<195, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<191, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_44_2 - @@ -8182,10 +8149,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_43_2 + FF(0))) + (new_term.poseidon2_B_43_3 + FF(0)))))); tmp *= scaling_factor; - std::get<195>(evals) += typename Accumulator::View(tmp); + std::get<191>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<196, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<192, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_44_3 - @@ -8216,10 +8183,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_43_2 + FF(0))) + (new_term.poseidon2_B_43_3 + FF(0)))))); tmp *= scaling_factor; - std::get<196>(evals) += typename Accumulator::View(tmp); + std::get<192>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<197, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<193, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_45_0 - @@ -8269,10 +8236,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_44_2 + FF(0))) + (new_term.poseidon2_B_44_3 + FF(0)))))); tmp *= scaling_factor; - std::get<197>(evals) += typename Accumulator::View(tmp); + std::get<193>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<198, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<194, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_45_1 - @@ -8303,10 +8270,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_44_2 + FF(0))) + (new_term.poseidon2_B_44_3 + FF(0)))))); tmp *= scaling_factor; - std::get<198>(evals) += typename Accumulator::View(tmp); + std::get<194>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<199, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<195, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_45_2 - @@ -8337,10 +8304,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_44_2 + FF(0))) + (new_term.poseidon2_B_44_3 + FF(0)))))); tmp *= scaling_factor; - std::get<199>(evals) += typename Accumulator::View(tmp); + std::get<195>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<200, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<196, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_45_3 - @@ -8371,10 +8338,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_44_2 + FF(0))) + (new_term.poseidon2_B_44_3 + FF(0)))))); tmp *= scaling_factor; - std::get<200>(evals) += typename Accumulator::View(tmp); + std::get<196>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<201, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<197, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_46_0 - @@ -8424,10 +8391,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_45_2 + FF(0))) + (new_term.poseidon2_B_45_3 + FF(0)))))); tmp *= scaling_factor; - std::get<201>(evals) += typename Accumulator::View(tmp); + std::get<197>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<202, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<198, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_46_1 - @@ -8458,10 +8425,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_45_2 + FF(0))) + (new_term.poseidon2_B_45_3 + FF(0)))))); tmp *= scaling_factor; - std::get<202>(evals) += typename Accumulator::View(tmp); + std::get<198>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<203, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<199, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_46_2 - @@ -8492,10 +8459,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_45_2 + FF(0))) + (new_term.poseidon2_B_45_3 + FF(0)))))); tmp *= scaling_factor; - std::get<203>(evals) += typename Accumulator::View(tmp); + std::get<199>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<204, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<200, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_46_3 - @@ -8526,10 +8493,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_45_2 + FF(0))) + (new_term.poseidon2_B_45_3 + FF(0)))))); tmp *= scaling_factor; - std::get<204>(evals) += typename Accumulator::View(tmp); + std::get<200>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<205, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<201, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_47_0 - @@ -8579,10 +8546,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_46_2 + FF(0))) + (new_term.poseidon2_B_46_3 + FF(0)))))); tmp *= scaling_factor; - std::get<205>(evals) += typename Accumulator::View(tmp); + std::get<201>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<206, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<202, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_47_1 - @@ -8613,10 +8580,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_46_2 + FF(0))) + (new_term.poseidon2_B_46_3 + FF(0)))))); tmp *= scaling_factor; - std::get<206>(evals) += typename Accumulator::View(tmp); + std::get<202>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<207, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<203, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_47_2 - @@ -8647,10 +8614,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_46_2 + FF(0))) + (new_term.poseidon2_B_46_3 + FF(0)))))); tmp *= scaling_factor; - std::get<207>(evals) += typename Accumulator::View(tmp); + std::get<203>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<208, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<204, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_47_3 - @@ -8681,10 +8648,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_46_2 + FF(0))) + (new_term.poseidon2_B_46_3 + FF(0)))))); tmp *= scaling_factor; - std::get<208>(evals) += typename Accumulator::View(tmp); + std::get<204>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<209, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<205, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_48_0 - @@ -8734,10 +8701,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_47_2 + FF(0))) + (new_term.poseidon2_B_47_3 + FF(0)))))); tmp *= scaling_factor; - std::get<209>(evals) += typename Accumulator::View(tmp); + std::get<205>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<210, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<206, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_48_1 - @@ -8768,10 +8735,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_47_2 + FF(0))) + (new_term.poseidon2_B_47_3 + FF(0)))))); tmp *= scaling_factor; - std::get<210>(evals) += typename Accumulator::View(tmp); + std::get<206>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<211, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<207, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_48_2 - @@ -8802,10 +8769,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_47_2 + FF(0))) + (new_term.poseidon2_B_47_3 + FF(0)))))); tmp *= scaling_factor; - std::get<211>(evals) += typename Accumulator::View(tmp); + std::get<207>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<212, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<208, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_48_3 - @@ -8836,10 +8803,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_47_2 + FF(0))) + (new_term.poseidon2_B_47_3 + FF(0)))))); tmp *= scaling_factor; - std::get<212>(evals) += typename Accumulator::View(tmp); + std::get<208>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<213, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<209, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_49_0 - @@ -8889,10 +8856,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_48_2 + FF(0))) + (new_term.poseidon2_B_48_3 + FF(0)))))); tmp *= scaling_factor; - std::get<213>(evals) += typename Accumulator::View(tmp); + std::get<209>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<214, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<210, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_49_1 - @@ -8923,10 +8890,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_48_2 + FF(0))) + (new_term.poseidon2_B_48_3 + FF(0)))))); tmp *= scaling_factor; - std::get<214>(evals) += typename Accumulator::View(tmp); + std::get<210>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<215, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<211, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_49_2 - @@ -8957,10 +8924,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_48_2 + FF(0))) + (new_term.poseidon2_B_48_3 + FF(0)))))); tmp *= scaling_factor; - std::get<215>(evals) += typename Accumulator::View(tmp); + std::get<211>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<216, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<212, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_49_3 - @@ -8991,10 +8958,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_48_2 + FF(0))) + (new_term.poseidon2_B_48_3 + FF(0)))))); tmp *= scaling_factor; - std::get<216>(evals) += typename Accumulator::View(tmp); + std::get<212>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<217, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<213, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_50_0 - @@ -9044,10 +9011,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_49_2 + FF(0))) + (new_term.poseidon2_B_49_3 + FF(0)))))); tmp *= scaling_factor; - std::get<217>(evals) += typename Accumulator::View(tmp); + std::get<213>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<218, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<214, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_50_1 - @@ -9078,10 +9045,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_49_2 + FF(0))) + (new_term.poseidon2_B_49_3 + FF(0)))))); tmp *= scaling_factor; - std::get<218>(evals) += typename Accumulator::View(tmp); + std::get<214>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<219, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<215, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_50_2 - @@ -9112,10 +9079,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_49_2 + FF(0))) + (new_term.poseidon2_B_49_3 + FF(0)))))); tmp *= scaling_factor; - std::get<219>(evals) += typename Accumulator::View(tmp); + std::get<215>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<220, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<216, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_50_3 - @@ -9146,10 +9113,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_49_2 + FF(0))) + (new_term.poseidon2_B_49_3 + FF(0)))))); tmp *= scaling_factor; - std::get<220>(evals) += typename Accumulator::View(tmp); + std::get<216>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<221, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<217, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_51_0 - @@ -9199,10 +9166,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_50_2 + FF(0))) + (new_term.poseidon2_B_50_3 + FF(0)))))); tmp *= scaling_factor; - std::get<221>(evals) += typename Accumulator::View(tmp); + std::get<217>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<222, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<218, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_51_1 - @@ -9233,10 +9200,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_50_2 + FF(0))) + (new_term.poseidon2_B_50_3 + FF(0)))))); tmp *= scaling_factor; - std::get<222>(evals) += typename Accumulator::View(tmp); + std::get<218>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<223, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<219, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_51_2 - @@ -9267,10 +9234,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_50_2 + FF(0))) + (new_term.poseidon2_B_50_3 + FF(0)))))); tmp *= scaling_factor; - std::get<223>(evals) += typename Accumulator::View(tmp); + std::get<219>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<224, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<220, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_51_3 - @@ -9301,10 +9268,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_50_2 + FF(0))) + (new_term.poseidon2_B_50_3 + FF(0)))))); tmp *= scaling_factor; - std::get<224>(evals) += typename Accumulator::View(tmp); + std::get<220>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<225, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<221, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_52_0 - @@ -9354,10 +9321,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_51_2 + FF(0))) + (new_term.poseidon2_B_51_3 + FF(0)))))); tmp *= scaling_factor; - std::get<225>(evals) += typename Accumulator::View(tmp); + std::get<221>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<226, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<222, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_52_1 - @@ -9388,10 +9355,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_51_2 + FF(0))) + (new_term.poseidon2_B_51_3 + FF(0)))))); tmp *= scaling_factor; - std::get<226>(evals) += typename Accumulator::View(tmp); + std::get<222>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<227, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<223, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_52_2 - @@ -9422,10 +9389,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_51_2 + FF(0))) + (new_term.poseidon2_B_51_3 + FF(0)))))); tmp *= scaling_factor; - std::get<227>(evals) += typename Accumulator::View(tmp); + std::get<223>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<228, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<224, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_52_3 - @@ -9456,10 +9423,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_51_2 + FF(0))) + (new_term.poseidon2_B_51_3 + FF(0)))))); tmp *= scaling_factor; - std::get<228>(evals) += typename Accumulator::View(tmp); + std::get<224>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<229, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<225, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_53_0 - @@ -9509,10 +9476,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_52_2 + FF(0))) + (new_term.poseidon2_B_52_3 + FF(0)))))); tmp *= scaling_factor; - std::get<229>(evals) += typename Accumulator::View(tmp); + std::get<225>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<230, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<226, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_53_1 - @@ -9543,10 +9510,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_52_2 + FF(0))) + (new_term.poseidon2_B_52_3 + FF(0)))))); tmp *= scaling_factor; - std::get<230>(evals) += typename Accumulator::View(tmp); + std::get<226>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<231, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<227, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_53_2 - @@ -9577,10 +9544,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_52_2 + FF(0))) + (new_term.poseidon2_B_52_3 + FF(0)))))); tmp *= scaling_factor; - std::get<231>(evals) += typename Accumulator::View(tmp); + std::get<227>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<232, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<228, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_53_3 - @@ -9611,10 +9578,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_52_2 + FF(0))) + (new_term.poseidon2_B_52_3 + FF(0)))))); tmp *= scaling_factor; - std::get<232>(evals) += typename Accumulator::View(tmp); + std::get<228>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<233, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<229, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_54_0 - @@ -9664,10 +9631,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_53_2 + FF(0))) + (new_term.poseidon2_B_53_3 + FF(0)))))); tmp *= scaling_factor; - std::get<233>(evals) += typename Accumulator::View(tmp); + std::get<229>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<234, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<230, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_54_1 - @@ -9698,10 +9665,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_53_2 + FF(0))) + (new_term.poseidon2_B_53_3 + FF(0)))))); tmp *= scaling_factor; - std::get<234>(evals) += typename Accumulator::View(tmp); + std::get<230>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<235, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<231, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_54_2 - @@ -9732,10 +9699,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_53_2 + FF(0))) + (new_term.poseidon2_B_53_3 + FF(0)))))); tmp *= scaling_factor; - std::get<235>(evals) += typename Accumulator::View(tmp); + std::get<231>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<236, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<232, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_54_3 - @@ -9766,10 +9733,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_53_2 + FF(0))) + (new_term.poseidon2_B_53_3 + FF(0)))))); tmp *= scaling_factor; - std::get<236>(evals) += typename Accumulator::View(tmp); + std::get<232>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<237, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<233, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_55_0 - @@ -9819,10 +9786,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_54_2 + FF(0))) + (new_term.poseidon2_B_54_3 + FF(0)))))); tmp *= scaling_factor; - std::get<237>(evals) += typename Accumulator::View(tmp); + std::get<233>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<238, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<234, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_55_1 - @@ -9853,10 +9820,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_54_2 + FF(0))) + (new_term.poseidon2_B_54_3 + FF(0)))))); tmp *= scaling_factor; - std::get<238>(evals) += typename Accumulator::View(tmp); + std::get<234>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<239, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<235, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_55_2 - @@ -9887,10 +9854,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_54_2 + FF(0))) + (new_term.poseidon2_B_54_3 + FF(0)))))); tmp *= scaling_factor; - std::get<239>(evals) += typename Accumulator::View(tmp); + std::get<235>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<240, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<236, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_55_3 - @@ -9921,10 +9888,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_54_2 + FF(0))) + (new_term.poseidon2_B_54_3 + FF(0)))))); tmp *= scaling_factor; - std::get<240>(evals) += typename Accumulator::View(tmp); + std::get<236>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<241, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<237, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_56_0 - @@ -9974,10 +9941,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_55_2 + FF(0))) + (new_term.poseidon2_B_55_3 + FF(0)))))); tmp *= scaling_factor; - std::get<241>(evals) += typename Accumulator::View(tmp); + std::get<237>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<242, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<238, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_56_1 - @@ -10008,10 +9975,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_55_2 + FF(0))) + (new_term.poseidon2_B_55_3 + FF(0)))))); tmp *= scaling_factor; - std::get<242>(evals) += typename Accumulator::View(tmp); + std::get<238>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<243, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<239, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_56_2 - @@ -10042,10 +10009,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_55_2 + FF(0))) + (new_term.poseidon2_B_55_3 + FF(0)))))); tmp *= scaling_factor; - std::get<243>(evals) += typename Accumulator::View(tmp); + std::get<239>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<244, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<240, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_56_3 - @@ -10076,10 +10043,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_55_2 + FF(0))) + (new_term.poseidon2_B_55_3 + FF(0)))))); tmp *= scaling_factor; - std::get<244>(evals) += typename Accumulator::View(tmp); + std::get<240>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<245, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<241, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_57_0 - @@ -10129,10 +10096,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_56_2 + FF(0))) + (new_term.poseidon2_B_56_3 + FF(0)))))); tmp *= scaling_factor; - std::get<245>(evals) += typename Accumulator::View(tmp); + std::get<241>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<246, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<242, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_57_1 - @@ -10163,10 +10130,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_56_2 + FF(0))) + (new_term.poseidon2_B_56_3 + FF(0)))))); tmp *= scaling_factor; - std::get<246>(evals) += typename Accumulator::View(tmp); + std::get<242>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<247, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<243, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_57_2 - @@ -10197,10 +10164,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_56_2 + FF(0))) + (new_term.poseidon2_B_56_3 + FF(0)))))); tmp *= scaling_factor; - std::get<247>(evals) += typename Accumulator::View(tmp); + std::get<243>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<248, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<244, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_57_3 - @@ -10231,10 +10198,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_56_2 + FF(0))) + (new_term.poseidon2_B_56_3 + FF(0)))))); tmp *= scaling_factor; - std::get<248>(evals) += typename Accumulator::View(tmp); + std::get<244>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<249, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<245, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_58_0 - @@ -10284,10 +10251,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_57_2 + FF(0))) + (new_term.poseidon2_B_57_3 + FF(0)))))); tmp *= scaling_factor; - std::get<249>(evals) += typename Accumulator::View(tmp); + std::get<245>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<250, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<246, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_58_1 - @@ -10318,10 +10285,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_57_2 + FF(0))) + (new_term.poseidon2_B_57_3 + FF(0)))))); tmp *= scaling_factor; - std::get<250>(evals) += typename Accumulator::View(tmp); + std::get<246>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<251, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<247, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_58_2 - @@ -10352,10 +10319,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_57_2 + FF(0))) + (new_term.poseidon2_B_57_3 + FF(0)))))); tmp *= scaling_factor; - std::get<251>(evals) += typename Accumulator::View(tmp); + std::get<247>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<252, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<248, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_58_3 - @@ -10386,10 +10353,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_57_2 + FF(0))) + (new_term.poseidon2_B_57_3 + FF(0)))))); tmp *= scaling_factor; - std::get<252>(evals) += typename Accumulator::View(tmp); + std::get<248>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<253, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<249, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_59_0 - @@ -10439,10 +10406,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_58_2 + FF(0))) + (new_term.poseidon2_B_58_3 + FF(0)))))); tmp *= scaling_factor; - std::get<253>(evals) += typename Accumulator::View(tmp); + std::get<249>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<254, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<250, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_59_1 - @@ -10473,10 +10440,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_58_2 + FF(0))) + (new_term.poseidon2_B_58_3 + FF(0)))))); tmp *= scaling_factor; - std::get<254>(evals) += typename Accumulator::View(tmp); + std::get<250>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<255, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<251, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_59_2 - @@ -10507,10 +10474,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_58_2 + FF(0))) + (new_term.poseidon2_B_58_3 + FF(0)))))); tmp *= scaling_factor; - std::get<255>(evals) += typename Accumulator::View(tmp); + std::get<251>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<256, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<252, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_B_59_3 - @@ -10541,10 +10508,10 @@ template class poseidon2Impl { (new_term.poseidon2_B_58_2 + FF(0))) + (new_term.poseidon2_B_58_3 + FF(0)))))); tmp *= scaling_factor; - std::get<256>(evals) += typename Accumulator::View(tmp); + std::get<252>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<257, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<253, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_60_4 - ((((((((new_term.poseidon2_B_59_2 + FF(uint256_t{ 10815195850656127580UL, @@ -10650,10 +10617,10 @@ template class poseidon2Impl { 3676846437799665248UL, 753827773683953838UL })))))))); tmp *= scaling_factor; - std::get<257>(evals) += typename Accumulator::View(tmp); + std::get<253>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<258, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<254, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_60_5 - ((((((((new_term.poseidon2_B_59_0 + FF(uint256_t{ 17559938410729200952UL, @@ -10759,10 +10726,10 @@ template class poseidon2Impl { 6031863836827793624UL, 2698250255620259624UL })))))))); tmp *= scaling_factor; - std::get<258>(evals) += typename Accumulator::View(tmp); + std::get<254>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<259, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<255, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_60_6 - ((((((((new_term.poseidon2_B_59_3 + FF(uint256_t{ 437280840171101279UL, @@ -10828,10 +10795,10 @@ template class poseidon2Impl { 753827773683953838UL }))))) + new_term.poseidon2_T_60_5))); tmp *= scaling_factor; - std::get<259>(evals) += typename Accumulator::View(tmp); + std::get<255>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<260, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<256, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_60_7 - ((((((((new_term.poseidon2_B_59_1 + FF(uint256_t{ 3946956839294125797UL, @@ -10897,10 +10864,10 @@ template class poseidon2Impl { 2698250255620259624UL }))))) + new_term.poseidon2_T_60_4))); tmp *= scaling_factor; - std::get<260>(evals) += typename Accumulator::View(tmp); + std::get<256>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<261, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<257, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_61_4 - ((((((((new_term.poseidon2_T_60_7 + FF(uint256_t{ 10578217394647568846UL, @@ -11006,10 +10973,10 @@ template class poseidon2Impl { 11492645026300260534UL, 1417477149741880787UL })))))))); tmp *= scaling_factor; - std::get<261>(evals) += typename Accumulator::View(tmp); + std::get<257>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<262, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<258, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_61_5 - ((((((((new_term.poseidon2_T_60_6 + FF(uint256_t{ 16961604592822056794UL, @@ -11115,10 +11082,10 @@ template class poseidon2Impl { 12296960536238467913UL, 2434905421004621494UL })))))))); tmp *= scaling_factor; - std::get<262>(evals) += typename Accumulator::View(tmp); + std::get<258>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<263, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<259, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_61_6 - ((((((((new_term.poseidon2_T_60_4 + FF(uint256_t{ 6332539588517624153UL, @@ -11184,10 +11151,10 @@ template class poseidon2Impl { 1417477149741880787UL }))))) + new_term.poseidon2_T_61_5))); tmp *= scaling_factor; - std::get<263>(evals) += typename Accumulator::View(tmp); + std::get<259>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<264, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<260, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_61_7 - ((((((((new_term.poseidon2_T_60_5 + FF(uint256_t{ 3152898413090790038UL, @@ -11253,10 +11220,10 @@ template class poseidon2Impl { 2434905421004621494UL }))))) + new_term.poseidon2_T_61_4))); tmp *= scaling_factor; - std::get<264>(evals) += typename Accumulator::View(tmp); + std::get<260>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<265, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<261, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_62_4 - ((((((((new_term.poseidon2_T_61_7 + FF(uint256_t{ 10329879351081882815UL, @@ -11362,10 +11329,10 @@ template class poseidon2Impl { 16457516735210998920UL, 1084862449077757478UL })))))))); tmp *= scaling_factor; - std::get<265>(evals) += typename Accumulator::View(tmp); + std::get<261>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<266, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<262, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_62_5 - ((((((((new_term.poseidon2_T_61_6 + FF(uint256_t{ 10311634121439582299UL, @@ -11471,10 +11438,10 @@ template class poseidon2Impl { 14909749656931548440UL, 708152185224876794UL })))))))); tmp *= scaling_factor; - std::get<266>(evals) += typename Accumulator::View(tmp); + std::get<262>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<267, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<263, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_62_6 - ((((((((new_term.poseidon2_T_61_4 + FF(uint256_t{ 13199866221884806229UL, @@ -11540,10 +11507,10 @@ template class poseidon2Impl { 1084862449077757478UL }))))) + new_term.poseidon2_T_62_5))); tmp *= scaling_factor; - std::get<267>(evals) += typename Accumulator::View(tmp); + std::get<263>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<268, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<264, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_62_7 - ((((((((new_term.poseidon2_T_61_5 + FF(uint256_t{ 16872849857899172004UL, @@ -11609,10 +11576,10 @@ template class poseidon2Impl { 708152185224876794UL }))))) + new_term.poseidon2_T_62_4))); tmp *= scaling_factor; - std::get<268>(evals) += typename Accumulator::View(tmp); + std::get<264>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<269, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<265, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_63_4 - ((((((((new_term.poseidon2_T_62_7 + FF(uint256_t{ 1233442753680249567UL, @@ -11718,10 +11685,10 @@ template class poseidon2Impl { 2568326884589391367UL, 3166155980659486882UL })))))))); tmp *= scaling_factor; - std::get<269>(evals) += typename Accumulator::View(tmp); + std::get<265>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<270, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<266, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_63_5 - ((((((((new_term.poseidon2_T_62_6 + FF(uint256_t{ 1717216310632203061UL, @@ -11827,10 +11794,10 @@ template class poseidon2Impl { 5095423606777193313UL, 1685862792723606183UL })))))))); tmp *= scaling_factor; - std::get<270>(evals) += typename Accumulator::View(tmp); + std::get<266>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<271, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<267, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_63_6 - ((((((((new_term.poseidon2_T_62_4 + FF(uint256_t{ 4115849303762846724UL, @@ -11896,10 +11863,10 @@ template class poseidon2Impl { 3166155980659486882UL }))))) + new_term.poseidon2_T_63_5))); tmp *= scaling_factor; - std::get<271>(evals) += typename Accumulator::View(tmp); + std::get<267>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<272, ContainerOverSubrelations>; + using Accumulator = typename std::tuple_element_t<268, ContainerOverSubrelations>; auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_T_63_7 - ((((((((new_term.poseidon2_T_62_5 + FF(uint256_t{ 17164141620747686731UL, @@ -11965,35 +11932,31 @@ template class poseidon2Impl { 1685862792723606183UL }))))) + new_term.poseidon2_T_63_4))); tmp *= scaling_factor; - std::get<272>(evals) += typename Accumulator::View(tmp); + std::get<268>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<273, ContainerOverSubrelations>; - auto tmp = - (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_a_0_shift - new_term.poseidon2_T_63_6)); + using Accumulator = typename std::tuple_element_t<269, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_b_0 - new_term.poseidon2_T_63_6)); tmp *= scaling_factor; - std::get<273>(evals) += typename Accumulator::View(tmp); + std::get<269>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<274, ContainerOverSubrelations>; - auto tmp = - (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_a_1_shift - new_term.poseidon2_T_63_5)); + using Accumulator = typename std::tuple_element_t<270, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_b_1 - new_term.poseidon2_T_63_5)); tmp *= scaling_factor; - std::get<274>(evals) += typename Accumulator::View(tmp); + std::get<270>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<275, ContainerOverSubrelations>; - auto tmp = - (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_a_2_shift - new_term.poseidon2_T_63_7)); + using Accumulator = typename std::tuple_element_t<271, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_b_2 - new_term.poseidon2_T_63_7)); tmp *= scaling_factor; - std::get<275>(evals) += typename Accumulator::View(tmp); + std::get<271>(evals) += typename Accumulator::View(tmp); } { - using Accumulator = typename std::tuple_element_t<276, ContainerOverSubrelations>; - auto tmp = - (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_a_3_shift - new_term.poseidon2_T_63_4)); + using Accumulator = typename std::tuple_element_t<272, ContainerOverSubrelations>; + auto tmp = (new_term.poseidon2_sel_poseidon_perm * (new_term.poseidon2_b_3 - new_term.poseidon2_T_63_4)); tmp *= scaling_factor; - std::get<276>(evals) += typename Accumulator::View(tmp); + std::get<272>(evals) += typename Accumulator::View(tmp); } } }; diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.hpp index 8b154ad1712f..6c88f2c3cb43 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/trace/gadgets/poseidon2.hpp @@ -1,5 +1,6 @@ #pragma once +#include "barretenberg/vm/avm/generated/relations/poseidon2.hpp" #include "barretenberg/vm/avm/trace/common.hpp" #include @@ -10,7 +11,7 @@ namespace bb::avm_trace { class AvmPoseidon2TraceBuilder { public: - using Poseidon2Row = bb::avm_trace::Poseidon2Row; + using Poseidon2Row = bb::Avm_vm::Poseidon2Row; struct Poseidon2TraceEntry { uint32_t clk = 0; std::array input; @@ -31,24 +32,8 @@ class AvmPoseidon2TraceBuilder { uint32_t input_addr, uint32_t output_addr); - std::pair static into_canonical(Poseidon2TraceEntry const& src) + Poseidon2Row static into_canonical(Poseidon2TraceEntry const& src) { - // The secondary write row, which is used to write the output of the permutation to memory - Poseidon2Row write_row; - write_row.poseidon2_a_0 = src.output[0]; - write_row.poseidon2_a_1 = src.output[1]; - write_row.poseidon2_a_2 = src.output[2]; - write_row.poseidon2_a_3 = src.output[3]; - write_row.poseidon2_input_addr = src.input_addr; - write_row.poseidon2_output_addr = src.output_addr; - write_row.poseidon2_write_line = FF(1); - write_row.poseidon2_mem_op = FF(1); - write_row.poseidon2_mem_addr_a = src.output_addr; - write_row.poseidon2_mem_addr_b = src.output_addr + 1; - write_row.poseidon2_mem_addr_c = src.output_addr + 2; - write_row.poseidon2_mem_addr_d = src.output_addr + 3; - write_row.poseidon2_in_tag = FF(6); - // The primary input row, which is used to read the input of the permutation from memory Poseidon2Row dest; // Mem Stuff @@ -56,16 +41,21 @@ class AvmPoseidon2TraceBuilder { dest.poseidon2_a_1 = src.input[1]; dest.poseidon2_a_2 = src.input[2]; dest.poseidon2_a_3 = src.input[3]; + dest.poseidon2_b_0 = src.output[0]; + dest.poseidon2_b_1 = src.output[1]; + dest.poseidon2_b_2 = src.output[2]; + dest.poseidon2_b_3 = src.output[3]; dest.poseidon2_input_addr = src.input_addr; dest.poseidon2_output_addr = src.output_addr; - dest.poseidon2_mem_addr_a = src.input_addr; - dest.poseidon2_mem_addr_b = src.input_addr + 1; - dest.poseidon2_mem_addr_c = src.input_addr + 2; - dest.poseidon2_mem_addr_d = src.input_addr + 3; - dest.poseidon2_mem_op = FF(1); - dest.poseidon2_read_line = FF(1); + dest.poseidon2_mem_addr_read_a = src.input_addr; + dest.poseidon2_mem_addr_read_b = src.input_addr + 1; + dest.poseidon2_mem_addr_read_c = src.input_addr + 2; + dest.poseidon2_mem_addr_read_d = src.input_addr + 3; + dest.poseidon2_mem_addr_write_a = src.output_addr; + dest.poseidon2_mem_addr_write_b = src.output_addr + 1; + dest.poseidon2_mem_addr_write_c = src.output_addr + 2; + dest.poseidon2_mem_addr_write_d = src.output_addr + 3; dest.poseidon2_sel_poseidon_perm = FF(1); - dest.poseidon2_in_tag = FF(6); // First Ext Round dest.poseidon2_EXT_LAYER_6 = src.first_ext[0]; dest.poseidon2_EXT_LAYER_5 = src.first_ext[1]; @@ -334,11 +324,30 @@ class AvmPoseidon2TraceBuilder { dest.poseidon2_T_63_7 = src.interm_round_vals[63][2]; dest.poseidon2_T_63_4 = src.interm_round_vals[63][3]; - return { dest, write_row }; + return dest; } template void merge_into(DestRow& dest, Poseidon2Row const& src) { + dest.poseidon2_a_0 = src.poseidon2_a_0; + dest.poseidon2_a_1 = src.poseidon2_a_1; + dest.poseidon2_a_2 = src.poseidon2_a_2; + dest.poseidon2_a_3 = src.poseidon2_a_3; + dest.poseidon2_b_0 = src.poseidon2_b_0; + dest.poseidon2_b_1 = src.poseidon2_b_1; + dest.poseidon2_b_2 = src.poseidon2_b_2; + dest.poseidon2_b_3 = src.poseidon2_b_3; + dest.poseidon2_input_addr = src.poseidon2_input_addr; + dest.poseidon2_output_addr = src.poseidon2_output_addr; + dest.poseidon2_mem_addr_read_a = src.poseidon2_mem_addr_read_a; + dest.poseidon2_mem_addr_read_b = src.poseidon2_mem_addr_read_b; + dest.poseidon2_mem_addr_read_c = src.poseidon2_mem_addr_read_c; + dest.poseidon2_mem_addr_read_d = src.poseidon2_mem_addr_read_d; + dest.poseidon2_mem_addr_write_a = src.poseidon2_mem_addr_write_a; + dest.poseidon2_mem_addr_write_b = src.poseidon2_mem_addr_write_b; + dest.poseidon2_mem_addr_write_c = src.poseidon2_mem_addr_write_c; + dest.poseidon2_mem_addr_write_d = src.poseidon2_mem_addr_write_d; + dest.poseidon2_sel_poseidon_perm = src.poseidon2_sel_poseidon_perm; dest.poseidon2_B_10_0 = src.poseidon2_B_10_0; dest.poseidon2_B_10_1 = src.poseidon2_B_10_1; dest.poseidon2_B_10_2 = src.poseidon2_B_10_2; @@ -595,21 +604,6 @@ class AvmPoseidon2TraceBuilder { dest.poseidon2_T_63_5 = src.poseidon2_T_63_5; dest.poseidon2_T_63_6 = src.poseidon2_T_63_6; dest.poseidon2_T_63_7 = src.poseidon2_T_63_7; - dest.poseidon2_a_0 = src.poseidon2_a_0; - dest.poseidon2_a_1 = src.poseidon2_a_1; - dest.poseidon2_a_2 = src.poseidon2_a_2; - dest.poseidon2_a_3 = src.poseidon2_a_3; - dest.poseidon2_input_addr = src.poseidon2_input_addr; - dest.poseidon2_mem_addr_a = src.poseidon2_mem_addr_a; - dest.poseidon2_mem_addr_b = src.poseidon2_mem_addr_b; - dest.poseidon2_mem_addr_c = src.poseidon2_mem_addr_c; - dest.poseidon2_mem_addr_d = src.poseidon2_mem_addr_d; - dest.poseidon2_mem_op = src.poseidon2_mem_op; - dest.poseidon2_output_addr = src.poseidon2_output_addr; - dest.poseidon2_read_line = src.poseidon2_read_line; - dest.poseidon2_sel_poseidon_perm = src.poseidon2_sel_poseidon_perm; - dest.poseidon2_write_line = src.poseidon2_write_line; - dest.poseidon2_in_tag = src.poseidon2_in_tag; dest.poseidon2_EXT_LAYER_6 = src.poseidon2_EXT_LAYER_6; dest.poseidon2_EXT_LAYER_5 = src.poseidon2_EXT_LAYER_5; dest.poseidon2_EXT_LAYER_7 = src.poseidon2_EXT_LAYER_7; diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.cpp index c3ccbdda3fbd..c9f0731757e0 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.cpp @@ -78,7 +78,7 @@ void AvmMemTraceBuilder::insert_in_mem_trace(uint8_t space_id, mem_trace_entry.m_sel_op_slice = true; break; case MemOpOwner::POSEIDON2: - mem_trace_entry.gadget_mem_op = true; + mem_trace_entry.poseidon_mem_op = true; break; } mem_trace.emplace_back(mem_trace_entry); diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.hpp index 7cc6fb62b69f..10124892b7cd 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/trace/mem_trace.hpp @@ -45,7 +45,7 @@ class AvmMemTraceBuilder { bool m_tag_err_count_relevant = false; bool m_sel_op_slice = false; - bool gadget_mem_op = false; + bool poseidon_mem_op = false; /** * @brief A comparator on MemoryTraceEntry to be used by sorting algorithm. We sort first by diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.cpp b/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.cpp index 921aa59c8ce8..479486d2dcb3 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.cpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.cpp @@ -218,7 +218,7 @@ AvmTraceBuilder::MemOp AvmTraceBuilder::constrained_read_from_memory(uint8_t spa AvmMemoryTag read_tag, AvmMemoryTag write_tag, IntermRegister reg, - bool is_gadget_mem_op) + AvmMemTraceBuilder::MemOpOwner mem_op_owner) { // Get the same matching indirect register for the given intermediate register. // This is a hack that we can replace with a mapping of IntermediateRegister to IndirectRegister. @@ -239,13 +239,7 @@ AvmTraceBuilder::MemOp AvmTraceBuilder::constrained_read_from_memory(uint8_t spa direct_offset = uint32_t(read_ind.val); } auto read_dir = mem_trace_builder.read_and_load_from_memory( - space_id, - clk, - reg, - direct_offset, - read_tag, - write_tag, - is_gadget_mem_op ? AvmMemTraceBuilder::MemOpOwner::POSEIDON2 : AvmMemTraceBuilder::MAIN); + space_id, clk, reg, direct_offset, read_tag, write_tag, mem_op_owner); return MemOp{ .is_indirect = is_indirect, @@ -269,7 +263,7 @@ AvmTraceBuilder::MemOp AvmTraceBuilder::constrained_write_to_memory(uint8_t spac AvmMemoryTag read_tag, AvmMemoryTag write_tag, IntermRegister reg, - bool is_gadget_mem_op) + AvmMemTraceBuilder::MemOpOwner mem_op_owner) { auto indirect_reg = static_cast(reg); uint32_t direct_offset = addr.offset; @@ -286,14 +280,7 @@ AvmTraceBuilder::MemOp AvmTraceBuilder::constrained_write_to_memory(uint8_t spac } direct_offset = uint32_t(read_ind.val); } - mem_trace_builder.write_into_memory(space_id, - clk, - reg, - direct_offset, - value, - read_tag, - write_tag, - is_gadget_mem_op ? AvmMemTraceBuilder::POSEIDON2 : AvmMemTraceBuilder::MAIN); + mem_trace_builder.write_into_memory(space_id, clk, reg, direct_offset, value, read_tag, write_tag, mem_op_owner); return MemOp{ .is_indirect = is_indirect, .indirect_address = indirect_offset, .direct_address = direct_offset, @@ -2983,14 +2970,34 @@ void AvmTraceBuilder::op_poseidon2_permutation(uint8_t indirect, uint32_t input_ // even though they are "performed" by the gadget. AddressWithMode direct_src_offset = { AddressingMode::DIRECT, direct_input_offset }; // This is because passing the mem_builder to the gadget causes some issues regarding copy-move semantics in cpp - auto read_a = constrained_read_from_memory( - call_ptr, clk, direct_src_offset, AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::IA, true); - auto read_b = constrained_read_from_memory( - call_ptr, clk, direct_src_offset + 1, AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::IB, true); - auto read_c = constrained_read_from_memory( - call_ptr, clk, direct_src_offset + 2, AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::IC, true); - auto read_d = constrained_read_from_memory( - call_ptr, clk, direct_src_offset + 3, AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::ID, true); + auto read_a = constrained_read_from_memory(call_ptr, + clk, + direct_src_offset, + AvmMemoryTag::FF, + AvmMemoryTag::FF, + IntermRegister::IA, + AvmMemTraceBuilder::POSEIDON2); + auto read_b = constrained_read_from_memory(call_ptr, + clk, + direct_src_offset + 1, + AvmMemoryTag::FF, + AvmMemoryTag::FF, + IntermRegister::IB, + AvmMemTraceBuilder::POSEIDON2); + auto read_c = constrained_read_from_memory(call_ptr, + clk, + direct_src_offset + 2, + AvmMemoryTag::FF, + AvmMemoryTag::FF, + IntermRegister::IC, + AvmMemTraceBuilder::POSEIDON2); + auto read_d = constrained_read_from_memory(call_ptr, + clk, + direct_src_offset + 3, + AvmMemoryTag::FF, + AvmMemoryTag::FF, + IntermRegister::ID, + AvmMemTraceBuilder::POSEIDON2); std::array input = { read_a.val, read_b.val, read_c.val, read_d.val }; std::array result = @@ -3002,8 +3009,14 @@ void AvmTraceBuilder::op_poseidon2_permutation(uint8_t indirect, uint32_t input_ } // Write the result to memory after, see the comments at read to understand why this happens here. AddressWithMode direct_dst_offset = { AddressingMode::DIRECT, direct_output_offset }; - constrained_write_to_memory( - call_ptr, clk, direct_dst_offset, ff_result[0], AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::IA, true); + constrained_write_to_memory(call_ptr, + clk, + direct_dst_offset, + ff_result[0], + AvmMemoryTag::FF, + AvmMemoryTag::FF, + IntermRegister::IA, + AvmMemTraceBuilder::POSEIDON2); constrained_write_to_memory(call_ptr, clk, direct_dst_offset + 1, @@ -3011,7 +3024,7 @@ void AvmTraceBuilder::op_poseidon2_permutation(uint8_t indirect, uint32_t input_ AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::IB, - true); + AvmMemTraceBuilder::POSEIDON2); constrained_write_to_memory(call_ptr, clk, direct_dst_offset + 2, @@ -3019,7 +3032,7 @@ void AvmTraceBuilder::op_poseidon2_permutation(uint8_t indirect, uint32_t input_ AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::IC, - true); + AvmMemTraceBuilder::POSEIDON2); constrained_write_to_memory(call_ptr, clk, @@ -3028,7 +3041,7 @@ void AvmTraceBuilder::op_poseidon2_permutation(uint8_t indirect, uint32_t input_ AvmMemoryTag::FF, AvmMemoryTag::FF, IntermRegister::ID, - true); + AvmMemTraceBuilder::POSEIDON2); } /** @@ -3991,38 +4004,28 @@ std::vector AvmTraceBuilder::finalize(uint32_t min_trace_size, bool range_c if (!src.m_sel_op_slice) { switch (src.m_sub_clk) { case AvmMemTraceBuilder::SUB_CLK_LOAD_A: + src.poseidon_mem_op ? dest.mem_sel_op_poseidon_read_a = 1 : dest.mem_sel_op_a = 1; + break; case AvmMemTraceBuilder::SUB_CLK_STORE_A: - // TODO: This is temporary, since we need to distinguish between gadget and main trace reads - // in future it would be nice to place this inside the mem_trace_builder - if (src.gadget_mem_op) { - dest.mem_sel_op_gadget_a = 1; - } else { - dest.mem_sel_op_a = 1; - } + src.poseidon_mem_op ? dest.mem_sel_op_poseidon_write_a = 1 : dest.mem_sel_op_a = 1; break; case AvmMemTraceBuilder::SUB_CLK_LOAD_B: + src.poseidon_mem_op ? dest.mem_sel_op_poseidon_read_b = 1 : dest.mem_sel_op_b = 1; + break; case AvmMemTraceBuilder::SUB_CLK_STORE_B: - if (src.gadget_mem_op) { - dest.mem_sel_op_gadget_b = 1; - } else { - dest.mem_sel_op_b = 1; - } + src.poseidon_mem_op ? dest.mem_sel_op_poseidon_write_b = 1 : dest.mem_sel_op_b = 1; break; case AvmMemTraceBuilder::SUB_CLK_LOAD_C: + src.poseidon_mem_op ? dest.mem_sel_op_poseidon_read_c = 1 : dest.mem_sel_op_c = 1; + break; case AvmMemTraceBuilder::SUB_CLK_STORE_C: - if (src.gadget_mem_op) { - dest.mem_sel_op_gadget_c = 1; - } else { - dest.mem_sel_op_c = 1; - } + src.poseidon_mem_op ? dest.mem_sel_op_poseidon_write_c = 1 : dest.mem_sel_op_c = 1; break; case AvmMemTraceBuilder::SUB_CLK_LOAD_D: + src.poseidon_mem_op ? dest.mem_sel_op_poseidon_read_d = 1 : dest.mem_sel_op_d = 1; + break; case AvmMemTraceBuilder::SUB_CLK_STORE_D: - if (src.gadget_mem_op) { - dest.mem_sel_op_gadget_d = 1; - } else { - dest.mem_sel_op_d = 1; - } + src.poseidon_mem_op ? dest.mem_sel_op_poseidon_write_d = 1 : dest.mem_sel_op_d = 1; break; case AvmMemTraceBuilder::SUB_CLK_IND_LOAD_A: dest.mem_sel_resolve_ind_addr_a = 1; @@ -4261,14 +4264,11 @@ std::vector AvmTraceBuilder::finalize(uint32_t min_trace_size, bool range_c // Add Poseidon2 Gadget table for (size_t i = 0; i < poseidon2_trace_size; i++) { - auto& dest = main_trace.at(2 * i); - auto& write_row = main_trace.at(2 * i + 1); + auto& dest = main_trace.at(i); auto const& src = poseidon2_trace.at(i); - auto canonical_trace_rows = bb::avm_trace::AvmPoseidon2TraceBuilder::into_canonical(src); + auto canonical_trace_row = bb::avm_trace::AvmPoseidon2TraceBuilder::into_canonical(src); dest.poseidon2_clk = FF(src.clk); - poseidon2_trace_builder.merge_into(dest, canonical_trace_rows.first); - write_row.poseidon2_clk = FF(src.clk); - poseidon2_trace_builder.merge_into(write_row, canonical_trace_rows.second); + poseidon2_trace_builder.merge_into(dest, canonical_trace_row); } // Add KeccakF1600 Gadget table diff --git a/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.hpp b/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.hpp index ffebc83ac69a..ff06295cc395 100644 --- a/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.hpp +++ b/barretenberg/cpp/src/barretenberg/vm/avm/trace/trace.hpp @@ -246,7 +246,7 @@ class AvmTraceBuilder { AvmMemoryTag read_tag, AvmMemoryTag write_tag, IntermRegister reg, - bool gadget_mem_op = false); + AvmMemTraceBuilder::MemOpOwner mem_op_owner = AvmMemTraceBuilder::MAIN); MemOp constrained_write_to_memory(uint8_t space_id, uint32_t clk, AddressWithMode addr, @@ -254,7 +254,7 @@ class AvmTraceBuilder { AvmMemoryTag read_tag, AvmMemoryTag write_tag, IntermRegister reg, - bool gadget_mem_op = false); + AvmMemTraceBuilder::MemOpOwner mem_op_owner = AvmMemTraceBuilder::MAIN); // TODO(ilyas: #6383): Temporary way to bulk read slices template diff --git a/barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp b/barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp deleted file mode 100644 index f9236b49451f..000000000000 --- a/barretenberg/cpp/src/barretenberg/vm/generated/avm_circuit_builder.hpp +++ /dev/null @@ -1,788 +0,0 @@ -// AUTOGENERATED FILE -#pragma once - -#include -#include - -#include "barretenberg/common/constexpr_utils.hpp" -#include "barretenberg/common/thread.hpp" -#include "barretenberg/common/throw_or_abort.hpp" -#include "barretenberg/ecc/curves/bn254/fr.hpp" -#include "barretenberg/honk/proof_system/logderivative_library.hpp" -#include "barretenberg/relations/generic_lookup/generic_lookup_relation.hpp" -#include "barretenberg/relations/generic_permutation/generic_permutation_relation.hpp" -#include "barretenberg/stdlib_circuit_builders/circuit_builder_base.hpp" - -#include "barretenberg/vm/generated/avm_flavor.hpp" -#include "barretenberg/vm/generated/avm_full_row.hpp" - -namespace bb { - -class AvmCircuitBuilder { - public: - using Flavor = bb::AvmFlavor; - using FF = Flavor::FF; - using Row = AvmFullRow; - - // TODO: template - using Polynomial = Flavor::Polynomial; - using ProverPolynomials = Flavor::ProverPolynomials; - - static constexpr size_t num_fixed_columns = 695; - static constexpr size_t num_polys = 695 + 80; - std::vector rows; - - void set_trace(std::vector&& trace) { rows = std::move(trace); } - - ProverPolynomials compute_polynomials() - { - const auto num_rows = get_circuit_subgroup_size(); - ProverPolynomials polys; - - // Allocate mem for each column - for (auto& poly : polys.get_all()) { - poly = Polynomial(num_rows); - } - - for (size_t i = 0; i < rows.size(); i++) { - polys.main_clk[i] = rows[i].main_clk; - polys.main_sel_first[i] = rows[i].main_sel_first; - polys.kernel_kernel_inputs[i] = rows[i].kernel_kernel_inputs; - polys.kernel_kernel_value_out[i] = rows[i].kernel_kernel_value_out; - polys.kernel_kernel_side_effect_out[i] = rows[i].kernel_kernel_side_effect_out; - polys.kernel_kernel_metadata_out[i] = rows[i].kernel_kernel_metadata_out; - polys.main_calldata[i] = rows[i].main_calldata; - polys.main_returndata[i] = rows[i].main_returndata; - polys.alu_a_hi[i] = rows[i].alu_a_hi; - polys.alu_a_lo[i] = rows[i].alu_a_lo; - polys.alu_b_hi[i] = rows[i].alu_b_hi; - polys.alu_b_lo[i] = rows[i].alu_b_lo; - polys.alu_borrow[i] = rows[i].alu_borrow; - polys.alu_cf[i] = rows[i].alu_cf; - polys.alu_clk[i] = rows[i].alu_clk; - polys.alu_cmp_rng_ctr[i] = rows[i].alu_cmp_rng_ctr; - polys.alu_div_u16_r0[i] = rows[i].alu_div_u16_r0; - polys.alu_div_u16_r1[i] = rows[i].alu_div_u16_r1; - polys.alu_div_u16_r2[i] = rows[i].alu_div_u16_r2; - polys.alu_div_u16_r3[i] = rows[i].alu_div_u16_r3; - polys.alu_div_u16_r4[i] = rows[i].alu_div_u16_r4; - polys.alu_div_u16_r5[i] = rows[i].alu_div_u16_r5; - polys.alu_div_u16_r6[i] = rows[i].alu_div_u16_r6; - polys.alu_div_u16_r7[i] = rows[i].alu_div_u16_r7; - polys.alu_divisor_hi[i] = rows[i].alu_divisor_hi; - polys.alu_divisor_lo[i] = rows[i].alu_divisor_lo; - polys.alu_ff_tag[i] = rows[i].alu_ff_tag; - polys.alu_ia[i] = rows[i].alu_ia; - polys.alu_ib[i] = rows[i].alu_ib; - polys.alu_ic[i] = rows[i].alu_ic; - polys.alu_in_tag[i] = rows[i].alu_in_tag; - polys.alu_op_add[i] = rows[i].alu_op_add; - polys.alu_op_cast[i] = rows[i].alu_op_cast; - polys.alu_op_cast_prev[i] = rows[i].alu_op_cast_prev; - polys.alu_op_div[i] = rows[i].alu_op_div; - polys.alu_op_div_a_lt_b[i] = rows[i].alu_op_div_a_lt_b; - polys.alu_op_div_std[i] = rows[i].alu_op_div_std; - polys.alu_op_eq[i] = rows[i].alu_op_eq; - polys.alu_op_eq_diff_inv[i] = rows[i].alu_op_eq_diff_inv; - polys.alu_op_lt[i] = rows[i].alu_op_lt; - polys.alu_op_lte[i] = rows[i].alu_op_lte; - polys.alu_op_mul[i] = rows[i].alu_op_mul; - polys.alu_op_not[i] = rows[i].alu_op_not; - polys.alu_op_shl[i] = rows[i].alu_op_shl; - polys.alu_op_shr[i] = rows[i].alu_op_shr; - polys.alu_op_sub[i] = rows[i].alu_op_sub; - polys.alu_p_a_borrow[i] = rows[i].alu_p_a_borrow; - polys.alu_p_b_borrow[i] = rows[i].alu_p_b_borrow; - polys.alu_p_sub_a_hi[i] = rows[i].alu_p_sub_a_hi; - polys.alu_p_sub_a_lo[i] = rows[i].alu_p_sub_a_lo; - polys.alu_p_sub_b_hi[i] = rows[i].alu_p_sub_b_hi; - polys.alu_p_sub_b_lo[i] = rows[i].alu_p_sub_b_lo; - polys.alu_partial_prod_hi[i] = rows[i].alu_partial_prod_hi; - polys.alu_partial_prod_lo[i] = rows[i].alu_partial_prod_lo; - polys.alu_quotient_hi[i] = rows[i].alu_quotient_hi; - polys.alu_quotient_lo[i] = rows[i].alu_quotient_lo; - polys.alu_remainder[i] = rows[i].alu_remainder; - polys.alu_res_hi[i] = rows[i].alu_res_hi; - polys.alu_res_lo[i] = rows[i].alu_res_lo; - polys.alu_sel_alu[i] = rows[i].alu_sel_alu; - polys.alu_sel_cmp[i] = rows[i].alu_sel_cmp; - polys.alu_sel_div_rng_chk[i] = rows[i].alu_sel_div_rng_chk; - polys.alu_sel_rng_chk[i] = rows[i].alu_sel_rng_chk; - polys.alu_sel_rng_chk_lookup[i] = rows[i].alu_sel_rng_chk_lookup; - polys.alu_sel_shift_which[i] = rows[i].alu_sel_shift_which; - polys.alu_shift_lt_bit_len[i] = rows[i].alu_shift_lt_bit_len; - polys.alu_t_sub_s_bits[i] = rows[i].alu_t_sub_s_bits; - polys.alu_two_pow_s[i] = rows[i].alu_two_pow_s; - polys.alu_two_pow_t_sub_s[i] = rows[i].alu_two_pow_t_sub_s; - polys.alu_u128_tag[i] = rows[i].alu_u128_tag; - polys.alu_u16_r0[i] = rows[i].alu_u16_r0; - polys.alu_u16_r1[i] = rows[i].alu_u16_r1; - polys.alu_u16_r10[i] = rows[i].alu_u16_r10; - polys.alu_u16_r11[i] = rows[i].alu_u16_r11; - polys.alu_u16_r12[i] = rows[i].alu_u16_r12; - polys.alu_u16_r13[i] = rows[i].alu_u16_r13; - polys.alu_u16_r14[i] = rows[i].alu_u16_r14; - polys.alu_u16_r2[i] = rows[i].alu_u16_r2; - polys.alu_u16_r3[i] = rows[i].alu_u16_r3; - polys.alu_u16_r4[i] = rows[i].alu_u16_r4; - polys.alu_u16_r5[i] = rows[i].alu_u16_r5; - polys.alu_u16_r6[i] = rows[i].alu_u16_r6; - polys.alu_u16_r7[i] = rows[i].alu_u16_r7; - polys.alu_u16_r8[i] = rows[i].alu_u16_r8; - polys.alu_u16_r9[i] = rows[i].alu_u16_r9; - polys.alu_u16_tag[i] = rows[i].alu_u16_tag; - polys.alu_u32_tag[i] = rows[i].alu_u32_tag; - polys.alu_u64_tag[i] = rows[i].alu_u64_tag; - polys.alu_u8_r0[i] = rows[i].alu_u8_r0; - polys.alu_u8_r1[i] = rows[i].alu_u8_r1; - polys.alu_u8_tag[i] = rows[i].alu_u8_tag; - polys.binary_acc_ia[i] = rows[i].binary_acc_ia; - polys.binary_acc_ib[i] = rows[i].binary_acc_ib; - polys.binary_acc_ic[i] = rows[i].binary_acc_ic; - polys.binary_clk[i] = rows[i].binary_clk; - polys.binary_ia_bytes[i] = rows[i].binary_ia_bytes; - polys.binary_ib_bytes[i] = rows[i].binary_ib_bytes; - polys.binary_ic_bytes[i] = rows[i].binary_ic_bytes; - polys.binary_in_tag[i] = rows[i].binary_in_tag; - polys.binary_mem_tag_ctr[i] = rows[i].binary_mem_tag_ctr; - polys.binary_mem_tag_ctr_inv[i] = rows[i].binary_mem_tag_ctr_inv; - polys.binary_op_id[i] = rows[i].binary_op_id; - polys.binary_sel_bin[i] = rows[i].binary_sel_bin; - polys.binary_start[i] = rows[i].binary_start; - polys.byte_lookup_sel_bin[i] = rows[i].byte_lookup_sel_bin; - polys.byte_lookup_table_byte_lengths[i] = rows[i].byte_lookup_table_byte_lengths; - polys.byte_lookup_table_in_tags[i] = rows[i].byte_lookup_table_in_tags; - polys.byte_lookup_table_input_a[i] = rows[i].byte_lookup_table_input_a; - polys.byte_lookup_table_input_b[i] = rows[i].byte_lookup_table_input_b; - polys.byte_lookup_table_op_id[i] = rows[i].byte_lookup_table_op_id; - polys.byte_lookup_table_output[i] = rows[i].byte_lookup_table_output; - polys.conversion_clk[i] = rows[i].conversion_clk; - polys.conversion_input[i] = rows[i].conversion_input; - polys.conversion_num_limbs[i] = rows[i].conversion_num_limbs; - polys.conversion_radix[i] = rows[i].conversion_radix; - polys.conversion_sel_to_radix_le[i] = rows[i].conversion_sel_to_radix_le; - polys.gas_da_gas_fixed_table[i] = rows[i].gas_da_gas_fixed_table; - polys.gas_l2_gas_fixed_table[i] = rows[i].gas_l2_gas_fixed_table; - polys.gas_sel_gas_cost[i] = rows[i].gas_sel_gas_cost; - polys.keccakf1600_clk[i] = rows[i].keccakf1600_clk; - polys.keccakf1600_input[i] = rows[i].keccakf1600_input; - polys.keccakf1600_output[i] = rows[i].keccakf1600_output; - polys.keccakf1600_sel_keccakf1600[i] = rows[i].keccakf1600_sel_keccakf1600; - polys.kernel_emit_l2_to_l1_msg_write_offset[i] = rows[i].kernel_emit_l2_to_l1_msg_write_offset; - polys.kernel_emit_note_hash_write_offset[i] = rows[i].kernel_emit_note_hash_write_offset; - polys.kernel_emit_nullifier_write_offset[i] = rows[i].kernel_emit_nullifier_write_offset; - polys.kernel_emit_unencrypted_log_write_offset[i] = rows[i].kernel_emit_unencrypted_log_write_offset; - polys.kernel_kernel_in_offset[i] = rows[i].kernel_kernel_in_offset; - polys.kernel_kernel_out_offset[i] = rows[i].kernel_kernel_out_offset; - polys.kernel_l1_to_l2_msg_exists_write_offset[i] = rows[i].kernel_l1_to_l2_msg_exists_write_offset; - polys.kernel_note_hash_exist_write_offset[i] = rows[i].kernel_note_hash_exist_write_offset; - polys.kernel_nullifier_exists_write_offset[i] = rows[i].kernel_nullifier_exists_write_offset; - polys.kernel_nullifier_non_exists_write_offset[i] = rows[i].kernel_nullifier_non_exists_write_offset; - polys.kernel_q_public_input_kernel_add_to_table[i] = rows[i].kernel_q_public_input_kernel_add_to_table; - polys.kernel_q_public_input_kernel_out_add_to_table[i] = - rows[i].kernel_q_public_input_kernel_out_add_to_table; - polys.kernel_side_effect_counter[i] = rows[i].kernel_side_effect_counter; - polys.kernel_sload_write_offset[i] = rows[i].kernel_sload_write_offset; - polys.kernel_sstore_write_offset[i] = rows[i].kernel_sstore_write_offset; - polys.main_abs_da_rem_gas_hi[i] = rows[i].main_abs_da_rem_gas_hi; - polys.main_abs_da_rem_gas_lo[i] = rows[i].main_abs_da_rem_gas_lo; - polys.main_abs_l2_rem_gas_hi[i] = rows[i].main_abs_l2_rem_gas_hi; - polys.main_abs_l2_rem_gas_lo[i] = rows[i].main_abs_l2_rem_gas_lo; - polys.main_alu_in_tag[i] = rows[i].main_alu_in_tag; - polys.main_bin_op_id[i] = rows[i].main_bin_op_id; - polys.main_call_ptr[i] = rows[i].main_call_ptr; - polys.main_da_gas_op_cost[i] = rows[i].main_da_gas_op_cost; - polys.main_da_gas_remaining[i] = rows[i].main_da_gas_remaining; - polys.main_da_out_of_gas[i] = rows[i].main_da_out_of_gas; - polys.main_ia[i] = rows[i].main_ia; - polys.main_ib[i] = rows[i].main_ib; - polys.main_ic[i] = rows[i].main_ic; - polys.main_id[i] = rows[i].main_id; - polys.main_id_zero[i] = rows[i].main_id_zero; - polys.main_ind_addr_a[i] = rows[i].main_ind_addr_a; - polys.main_ind_addr_b[i] = rows[i].main_ind_addr_b; - polys.main_ind_addr_c[i] = rows[i].main_ind_addr_c; - polys.main_ind_addr_d[i] = rows[i].main_ind_addr_d; - polys.main_internal_return_ptr[i] = rows[i].main_internal_return_ptr; - polys.main_inv[i] = rows[i].main_inv; - polys.main_l2_gas_op_cost[i] = rows[i].main_l2_gas_op_cost; - polys.main_l2_gas_remaining[i] = rows[i].main_l2_gas_remaining; - polys.main_l2_out_of_gas[i] = rows[i].main_l2_out_of_gas; - polys.main_mem_addr_a[i] = rows[i].main_mem_addr_a; - polys.main_mem_addr_b[i] = rows[i].main_mem_addr_b; - polys.main_mem_addr_c[i] = rows[i].main_mem_addr_c; - polys.main_mem_addr_d[i] = rows[i].main_mem_addr_d; - polys.main_op_err[i] = rows[i].main_op_err; - polys.main_opcode_val[i] = rows[i].main_opcode_val; - polys.main_pc[i] = rows[i].main_pc; - polys.main_r_in_tag[i] = rows[i].main_r_in_tag; - polys.main_rwa[i] = rows[i].main_rwa; - polys.main_rwb[i] = rows[i].main_rwb; - polys.main_rwc[i] = rows[i].main_rwc; - polys.main_rwd[i] = rows[i].main_rwd; - polys.main_sel_alu[i] = rows[i].main_sel_alu; - polys.main_sel_bin[i] = rows[i].main_sel_bin; - polys.main_sel_calldata[i] = rows[i].main_sel_calldata; - polys.main_sel_gas_accounting_active[i] = rows[i].main_sel_gas_accounting_active; - polys.main_sel_last[i] = rows[i].main_sel_last; - polys.main_sel_mem_op_a[i] = rows[i].main_sel_mem_op_a; - polys.main_sel_mem_op_activate_gas[i] = rows[i].main_sel_mem_op_activate_gas; - polys.main_sel_mem_op_b[i] = rows[i].main_sel_mem_op_b; - polys.main_sel_mem_op_c[i] = rows[i].main_sel_mem_op_c; - polys.main_sel_mem_op_d[i] = rows[i].main_sel_mem_op_d; - polys.main_sel_mov_ia_to_ic[i] = rows[i].main_sel_mov_ia_to_ic; - polys.main_sel_mov_ib_to_ic[i] = rows[i].main_sel_mov_ib_to_ic; - polys.main_sel_op_add[i] = rows[i].main_sel_op_add; - polys.main_sel_op_address[i] = rows[i].main_sel_op_address; - polys.main_sel_op_and[i] = rows[i].main_sel_op_and; - polys.main_sel_op_block_number[i] = rows[i].main_sel_op_block_number; - polys.main_sel_op_calldata_copy[i] = rows[i].main_sel_op_calldata_copy; - polys.main_sel_op_cast[i] = rows[i].main_sel_op_cast; - polys.main_sel_op_chain_id[i] = rows[i].main_sel_op_chain_id; - polys.main_sel_op_cmov[i] = rows[i].main_sel_op_cmov; - polys.main_sel_op_coinbase[i] = rows[i].main_sel_op_coinbase; - polys.main_sel_op_dagasleft[i] = rows[i].main_sel_op_dagasleft; - polys.main_sel_op_div[i] = rows[i].main_sel_op_div; - polys.main_sel_op_emit_l2_to_l1_msg[i] = rows[i].main_sel_op_emit_l2_to_l1_msg; - polys.main_sel_op_emit_note_hash[i] = rows[i].main_sel_op_emit_note_hash; - polys.main_sel_op_emit_nullifier[i] = rows[i].main_sel_op_emit_nullifier; - polys.main_sel_op_emit_unencrypted_log[i] = rows[i].main_sel_op_emit_unencrypted_log; - polys.main_sel_op_eq[i] = rows[i].main_sel_op_eq; - polys.main_sel_op_external_call[i] = rows[i].main_sel_op_external_call; - polys.main_sel_op_external_return[i] = rows[i].main_sel_op_external_return; - polys.main_sel_op_fdiv[i] = rows[i].main_sel_op_fdiv; - polys.main_sel_op_fee_per_da_gas[i] = rows[i].main_sel_op_fee_per_da_gas; - polys.main_sel_op_fee_per_l2_gas[i] = rows[i].main_sel_op_fee_per_l2_gas; - polys.main_sel_op_function_selector[i] = rows[i].main_sel_op_function_selector; - polys.main_sel_op_get_contract_instance[i] = rows[i].main_sel_op_get_contract_instance; - polys.main_sel_op_halt[i] = rows[i].main_sel_op_halt; - polys.main_sel_op_internal_call[i] = rows[i].main_sel_op_internal_call; - polys.main_sel_op_internal_return[i] = rows[i].main_sel_op_internal_return; - polys.main_sel_op_jump[i] = rows[i].main_sel_op_jump; - polys.main_sel_op_jumpi[i] = rows[i].main_sel_op_jumpi; - polys.main_sel_op_keccak[i] = rows[i].main_sel_op_keccak; - polys.main_sel_op_l1_to_l2_msg_exists[i] = rows[i].main_sel_op_l1_to_l2_msg_exists; - polys.main_sel_op_l2gasleft[i] = rows[i].main_sel_op_l2gasleft; - polys.main_sel_op_lt[i] = rows[i].main_sel_op_lt; - polys.main_sel_op_lte[i] = rows[i].main_sel_op_lte; - polys.main_sel_op_mov[i] = rows[i].main_sel_op_mov; - polys.main_sel_op_mul[i] = rows[i].main_sel_op_mul; - polys.main_sel_op_not[i] = rows[i].main_sel_op_not; - polys.main_sel_op_note_hash_exists[i] = rows[i].main_sel_op_note_hash_exists; - polys.main_sel_op_nullifier_exists[i] = rows[i].main_sel_op_nullifier_exists; - polys.main_sel_op_or[i] = rows[i].main_sel_op_or; - polys.main_sel_op_pedersen[i] = rows[i].main_sel_op_pedersen; - polys.main_sel_op_poseidon2[i] = rows[i].main_sel_op_poseidon2; - polys.main_sel_op_radix_le[i] = rows[i].main_sel_op_radix_le; - polys.main_sel_op_sender[i] = rows[i].main_sel_op_sender; - polys.main_sel_op_sha256[i] = rows[i].main_sel_op_sha256; - polys.main_sel_op_shl[i] = rows[i].main_sel_op_shl; - polys.main_sel_op_shr[i] = rows[i].main_sel_op_shr; - polys.main_sel_op_sload[i] = rows[i].main_sel_op_sload; - polys.main_sel_op_sstore[i] = rows[i].main_sel_op_sstore; - polys.main_sel_op_storage_address[i] = rows[i].main_sel_op_storage_address; - polys.main_sel_op_sub[i] = rows[i].main_sel_op_sub; - polys.main_sel_op_timestamp[i] = rows[i].main_sel_op_timestamp; - polys.main_sel_op_transaction_fee[i] = rows[i].main_sel_op_transaction_fee; - polys.main_sel_op_version[i] = rows[i].main_sel_op_version; - polys.main_sel_op_xor[i] = rows[i].main_sel_op_xor; - polys.main_sel_q_kernel_lookup[i] = rows[i].main_sel_q_kernel_lookup; - polys.main_sel_q_kernel_output_lookup[i] = rows[i].main_sel_q_kernel_output_lookup; - polys.main_sel_resolve_ind_addr_a[i] = rows[i].main_sel_resolve_ind_addr_a; - polys.main_sel_resolve_ind_addr_b[i] = rows[i].main_sel_resolve_ind_addr_b; - polys.main_sel_resolve_ind_addr_c[i] = rows[i].main_sel_resolve_ind_addr_c; - polys.main_sel_resolve_ind_addr_d[i] = rows[i].main_sel_resolve_ind_addr_d; - polys.main_sel_returndata[i] = rows[i].main_sel_returndata; - polys.main_sel_rng_16[i] = rows[i].main_sel_rng_16; - polys.main_sel_rng_8[i] = rows[i].main_sel_rng_8; - polys.main_sel_slice_gadget[i] = rows[i].main_sel_slice_gadget; - polys.main_space_id[i] = rows[i].main_space_id; - polys.main_tag_err[i] = rows[i].main_tag_err; - polys.main_w_in_tag[i] = rows[i].main_w_in_tag; - polys.mem_addr[i] = rows[i].mem_addr; - polys.mem_clk[i] = rows[i].mem_clk; - polys.mem_diff_hi[i] = rows[i].mem_diff_hi; - polys.mem_diff_lo[i] = rows[i].mem_diff_lo; - polys.mem_diff_mid[i] = rows[i].mem_diff_mid; - polys.mem_glob_addr[i] = rows[i].mem_glob_addr; - polys.mem_last[i] = rows[i].mem_last; - polys.mem_lastAccess[i] = rows[i].mem_lastAccess; - polys.mem_one_min_inv[i] = rows[i].mem_one_min_inv; - polys.mem_r_in_tag[i] = rows[i].mem_r_in_tag; - polys.mem_rw[i] = rows[i].mem_rw; - polys.mem_sel_mem[i] = rows[i].mem_sel_mem; - polys.mem_sel_mov_ia_to_ic[i] = rows[i].mem_sel_mov_ia_to_ic; - polys.mem_sel_mov_ib_to_ic[i] = rows[i].mem_sel_mov_ib_to_ic; - polys.mem_sel_op_a[i] = rows[i].mem_sel_op_a; - polys.mem_sel_op_b[i] = rows[i].mem_sel_op_b; - polys.mem_sel_op_c[i] = rows[i].mem_sel_op_c; - polys.mem_sel_op_cmov[i] = rows[i].mem_sel_op_cmov; - polys.mem_sel_op_d[i] = rows[i].mem_sel_op_d; - polys.mem_sel_op_gadget_a[i] = rows[i].mem_sel_op_gadget_a; - polys.mem_sel_op_gadget_b[i] = rows[i].mem_sel_op_gadget_b; - polys.mem_sel_op_gadget_c[i] = rows[i].mem_sel_op_gadget_c; - polys.mem_sel_op_gadget_d[i] = rows[i].mem_sel_op_gadget_d; - polys.mem_sel_op_slice[i] = rows[i].mem_sel_op_slice; - polys.mem_sel_resolve_ind_addr_a[i] = rows[i].mem_sel_resolve_ind_addr_a; - polys.mem_sel_resolve_ind_addr_b[i] = rows[i].mem_sel_resolve_ind_addr_b; - polys.mem_sel_resolve_ind_addr_c[i] = rows[i].mem_sel_resolve_ind_addr_c; - polys.mem_sel_resolve_ind_addr_d[i] = rows[i].mem_sel_resolve_ind_addr_d; - polys.mem_sel_rng_chk[i] = rows[i].mem_sel_rng_chk; - polys.mem_skip_check_tag[i] = rows[i].mem_skip_check_tag; - polys.mem_space_id[i] = rows[i].mem_space_id; - polys.mem_tag[i] = rows[i].mem_tag; - polys.mem_tag_err[i] = rows[i].mem_tag_err; - polys.mem_tsp[i] = rows[i].mem_tsp; - polys.mem_val[i] = rows[i].mem_val; - polys.mem_w_in_tag[i] = rows[i].mem_w_in_tag; - polys.pedersen_clk[i] = rows[i].pedersen_clk; - polys.pedersen_input[i] = rows[i].pedersen_input; - polys.pedersen_output[i] = rows[i].pedersen_output; - polys.pedersen_sel_pedersen[i] = rows[i].pedersen_sel_pedersen; - polys.poseidon2_B_10_0[i] = rows[i].poseidon2_B_10_0; - polys.poseidon2_B_10_1[i] = rows[i].poseidon2_B_10_1; - polys.poseidon2_B_10_2[i] = rows[i].poseidon2_B_10_2; - polys.poseidon2_B_10_3[i] = rows[i].poseidon2_B_10_3; - polys.poseidon2_B_11_0[i] = rows[i].poseidon2_B_11_0; - polys.poseidon2_B_11_1[i] = rows[i].poseidon2_B_11_1; - polys.poseidon2_B_11_2[i] = rows[i].poseidon2_B_11_2; - polys.poseidon2_B_11_3[i] = rows[i].poseidon2_B_11_3; - polys.poseidon2_B_12_0[i] = rows[i].poseidon2_B_12_0; - polys.poseidon2_B_12_1[i] = rows[i].poseidon2_B_12_1; - polys.poseidon2_B_12_2[i] = rows[i].poseidon2_B_12_2; - polys.poseidon2_B_12_3[i] = rows[i].poseidon2_B_12_3; - polys.poseidon2_B_13_0[i] = rows[i].poseidon2_B_13_0; - polys.poseidon2_B_13_1[i] = rows[i].poseidon2_B_13_1; - polys.poseidon2_B_13_2[i] = rows[i].poseidon2_B_13_2; - polys.poseidon2_B_13_3[i] = rows[i].poseidon2_B_13_3; - polys.poseidon2_B_14_0[i] = rows[i].poseidon2_B_14_0; - polys.poseidon2_B_14_1[i] = rows[i].poseidon2_B_14_1; - polys.poseidon2_B_14_2[i] = rows[i].poseidon2_B_14_2; - polys.poseidon2_B_14_3[i] = rows[i].poseidon2_B_14_3; - polys.poseidon2_B_15_0[i] = rows[i].poseidon2_B_15_0; - polys.poseidon2_B_15_1[i] = rows[i].poseidon2_B_15_1; - polys.poseidon2_B_15_2[i] = rows[i].poseidon2_B_15_2; - polys.poseidon2_B_15_3[i] = rows[i].poseidon2_B_15_3; - polys.poseidon2_B_16_0[i] = rows[i].poseidon2_B_16_0; - polys.poseidon2_B_16_1[i] = rows[i].poseidon2_B_16_1; - polys.poseidon2_B_16_2[i] = rows[i].poseidon2_B_16_2; - polys.poseidon2_B_16_3[i] = rows[i].poseidon2_B_16_3; - polys.poseidon2_B_17_0[i] = rows[i].poseidon2_B_17_0; - polys.poseidon2_B_17_1[i] = rows[i].poseidon2_B_17_1; - polys.poseidon2_B_17_2[i] = rows[i].poseidon2_B_17_2; - polys.poseidon2_B_17_3[i] = rows[i].poseidon2_B_17_3; - polys.poseidon2_B_18_0[i] = rows[i].poseidon2_B_18_0; - polys.poseidon2_B_18_1[i] = rows[i].poseidon2_B_18_1; - polys.poseidon2_B_18_2[i] = rows[i].poseidon2_B_18_2; - polys.poseidon2_B_18_3[i] = rows[i].poseidon2_B_18_3; - polys.poseidon2_B_19_0[i] = rows[i].poseidon2_B_19_0; - polys.poseidon2_B_19_1[i] = rows[i].poseidon2_B_19_1; - polys.poseidon2_B_19_2[i] = rows[i].poseidon2_B_19_2; - polys.poseidon2_B_19_3[i] = rows[i].poseidon2_B_19_3; - polys.poseidon2_B_20_0[i] = rows[i].poseidon2_B_20_0; - polys.poseidon2_B_20_1[i] = rows[i].poseidon2_B_20_1; - polys.poseidon2_B_20_2[i] = rows[i].poseidon2_B_20_2; - polys.poseidon2_B_20_3[i] = rows[i].poseidon2_B_20_3; - polys.poseidon2_B_21_0[i] = rows[i].poseidon2_B_21_0; - polys.poseidon2_B_21_1[i] = rows[i].poseidon2_B_21_1; - polys.poseidon2_B_21_2[i] = rows[i].poseidon2_B_21_2; - polys.poseidon2_B_21_3[i] = rows[i].poseidon2_B_21_3; - polys.poseidon2_B_22_0[i] = rows[i].poseidon2_B_22_0; - polys.poseidon2_B_22_1[i] = rows[i].poseidon2_B_22_1; - polys.poseidon2_B_22_2[i] = rows[i].poseidon2_B_22_2; - polys.poseidon2_B_22_3[i] = rows[i].poseidon2_B_22_3; - polys.poseidon2_B_23_0[i] = rows[i].poseidon2_B_23_0; - polys.poseidon2_B_23_1[i] = rows[i].poseidon2_B_23_1; - polys.poseidon2_B_23_2[i] = rows[i].poseidon2_B_23_2; - polys.poseidon2_B_23_3[i] = rows[i].poseidon2_B_23_3; - polys.poseidon2_B_24_0[i] = rows[i].poseidon2_B_24_0; - polys.poseidon2_B_24_1[i] = rows[i].poseidon2_B_24_1; - polys.poseidon2_B_24_2[i] = rows[i].poseidon2_B_24_2; - polys.poseidon2_B_24_3[i] = rows[i].poseidon2_B_24_3; - polys.poseidon2_B_25_0[i] = rows[i].poseidon2_B_25_0; - polys.poseidon2_B_25_1[i] = rows[i].poseidon2_B_25_1; - polys.poseidon2_B_25_2[i] = rows[i].poseidon2_B_25_2; - polys.poseidon2_B_25_3[i] = rows[i].poseidon2_B_25_3; - polys.poseidon2_B_26_0[i] = rows[i].poseidon2_B_26_0; - polys.poseidon2_B_26_1[i] = rows[i].poseidon2_B_26_1; - polys.poseidon2_B_26_2[i] = rows[i].poseidon2_B_26_2; - polys.poseidon2_B_26_3[i] = rows[i].poseidon2_B_26_3; - polys.poseidon2_B_27_0[i] = rows[i].poseidon2_B_27_0; - polys.poseidon2_B_27_1[i] = rows[i].poseidon2_B_27_1; - polys.poseidon2_B_27_2[i] = rows[i].poseidon2_B_27_2; - polys.poseidon2_B_27_3[i] = rows[i].poseidon2_B_27_3; - polys.poseidon2_B_28_0[i] = rows[i].poseidon2_B_28_0; - polys.poseidon2_B_28_1[i] = rows[i].poseidon2_B_28_1; - polys.poseidon2_B_28_2[i] = rows[i].poseidon2_B_28_2; - polys.poseidon2_B_28_3[i] = rows[i].poseidon2_B_28_3; - polys.poseidon2_B_29_0[i] = rows[i].poseidon2_B_29_0; - polys.poseidon2_B_29_1[i] = rows[i].poseidon2_B_29_1; - polys.poseidon2_B_29_2[i] = rows[i].poseidon2_B_29_2; - polys.poseidon2_B_29_3[i] = rows[i].poseidon2_B_29_3; - polys.poseidon2_B_30_0[i] = rows[i].poseidon2_B_30_0; - polys.poseidon2_B_30_1[i] = rows[i].poseidon2_B_30_1; - polys.poseidon2_B_30_2[i] = rows[i].poseidon2_B_30_2; - polys.poseidon2_B_30_3[i] = rows[i].poseidon2_B_30_3; - polys.poseidon2_B_31_0[i] = rows[i].poseidon2_B_31_0; - polys.poseidon2_B_31_1[i] = rows[i].poseidon2_B_31_1; - polys.poseidon2_B_31_2[i] = rows[i].poseidon2_B_31_2; - polys.poseidon2_B_31_3[i] = rows[i].poseidon2_B_31_3; - polys.poseidon2_B_32_0[i] = rows[i].poseidon2_B_32_0; - polys.poseidon2_B_32_1[i] = rows[i].poseidon2_B_32_1; - polys.poseidon2_B_32_2[i] = rows[i].poseidon2_B_32_2; - polys.poseidon2_B_32_3[i] = rows[i].poseidon2_B_32_3; - polys.poseidon2_B_33_0[i] = rows[i].poseidon2_B_33_0; - polys.poseidon2_B_33_1[i] = rows[i].poseidon2_B_33_1; - polys.poseidon2_B_33_2[i] = rows[i].poseidon2_B_33_2; - polys.poseidon2_B_33_3[i] = rows[i].poseidon2_B_33_3; - polys.poseidon2_B_34_0[i] = rows[i].poseidon2_B_34_0; - polys.poseidon2_B_34_1[i] = rows[i].poseidon2_B_34_1; - polys.poseidon2_B_34_2[i] = rows[i].poseidon2_B_34_2; - polys.poseidon2_B_34_3[i] = rows[i].poseidon2_B_34_3; - polys.poseidon2_B_35_0[i] = rows[i].poseidon2_B_35_0; - polys.poseidon2_B_35_1[i] = rows[i].poseidon2_B_35_1; - polys.poseidon2_B_35_2[i] = rows[i].poseidon2_B_35_2; - polys.poseidon2_B_35_3[i] = rows[i].poseidon2_B_35_3; - polys.poseidon2_B_36_0[i] = rows[i].poseidon2_B_36_0; - polys.poseidon2_B_36_1[i] = rows[i].poseidon2_B_36_1; - polys.poseidon2_B_36_2[i] = rows[i].poseidon2_B_36_2; - polys.poseidon2_B_36_3[i] = rows[i].poseidon2_B_36_3; - polys.poseidon2_B_37_0[i] = rows[i].poseidon2_B_37_0; - polys.poseidon2_B_37_1[i] = rows[i].poseidon2_B_37_1; - polys.poseidon2_B_37_2[i] = rows[i].poseidon2_B_37_2; - polys.poseidon2_B_37_3[i] = rows[i].poseidon2_B_37_3; - polys.poseidon2_B_38_0[i] = rows[i].poseidon2_B_38_0; - polys.poseidon2_B_38_1[i] = rows[i].poseidon2_B_38_1; - polys.poseidon2_B_38_2[i] = rows[i].poseidon2_B_38_2; - polys.poseidon2_B_38_3[i] = rows[i].poseidon2_B_38_3; - polys.poseidon2_B_39_0[i] = rows[i].poseidon2_B_39_0; - polys.poseidon2_B_39_1[i] = rows[i].poseidon2_B_39_1; - polys.poseidon2_B_39_2[i] = rows[i].poseidon2_B_39_2; - polys.poseidon2_B_39_3[i] = rows[i].poseidon2_B_39_3; - polys.poseidon2_B_40_0[i] = rows[i].poseidon2_B_40_0; - polys.poseidon2_B_40_1[i] = rows[i].poseidon2_B_40_1; - polys.poseidon2_B_40_2[i] = rows[i].poseidon2_B_40_2; - polys.poseidon2_B_40_3[i] = rows[i].poseidon2_B_40_3; - polys.poseidon2_B_41_0[i] = rows[i].poseidon2_B_41_0; - polys.poseidon2_B_41_1[i] = rows[i].poseidon2_B_41_1; - polys.poseidon2_B_41_2[i] = rows[i].poseidon2_B_41_2; - polys.poseidon2_B_41_3[i] = rows[i].poseidon2_B_41_3; - polys.poseidon2_B_42_0[i] = rows[i].poseidon2_B_42_0; - polys.poseidon2_B_42_1[i] = rows[i].poseidon2_B_42_1; - polys.poseidon2_B_42_2[i] = rows[i].poseidon2_B_42_2; - polys.poseidon2_B_42_3[i] = rows[i].poseidon2_B_42_3; - polys.poseidon2_B_43_0[i] = rows[i].poseidon2_B_43_0; - polys.poseidon2_B_43_1[i] = rows[i].poseidon2_B_43_1; - polys.poseidon2_B_43_2[i] = rows[i].poseidon2_B_43_2; - polys.poseidon2_B_43_3[i] = rows[i].poseidon2_B_43_3; - polys.poseidon2_B_44_0[i] = rows[i].poseidon2_B_44_0; - polys.poseidon2_B_44_1[i] = rows[i].poseidon2_B_44_1; - polys.poseidon2_B_44_2[i] = rows[i].poseidon2_B_44_2; - polys.poseidon2_B_44_3[i] = rows[i].poseidon2_B_44_3; - polys.poseidon2_B_45_0[i] = rows[i].poseidon2_B_45_0; - polys.poseidon2_B_45_1[i] = rows[i].poseidon2_B_45_1; - polys.poseidon2_B_45_2[i] = rows[i].poseidon2_B_45_2; - polys.poseidon2_B_45_3[i] = rows[i].poseidon2_B_45_3; - polys.poseidon2_B_46_0[i] = rows[i].poseidon2_B_46_0; - polys.poseidon2_B_46_1[i] = rows[i].poseidon2_B_46_1; - polys.poseidon2_B_46_2[i] = rows[i].poseidon2_B_46_2; - polys.poseidon2_B_46_3[i] = rows[i].poseidon2_B_46_3; - polys.poseidon2_B_47_0[i] = rows[i].poseidon2_B_47_0; - polys.poseidon2_B_47_1[i] = rows[i].poseidon2_B_47_1; - polys.poseidon2_B_47_2[i] = rows[i].poseidon2_B_47_2; - polys.poseidon2_B_47_3[i] = rows[i].poseidon2_B_47_3; - polys.poseidon2_B_48_0[i] = rows[i].poseidon2_B_48_0; - polys.poseidon2_B_48_1[i] = rows[i].poseidon2_B_48_1; - polys.poseidon2_B_48_2[i] = rows[i].poseidon2_B_48_2; - polys.poseidon2_B_48_3[i] = rows[i].poseidon2_B_48_3; - polys.poseidon2_B_49_0[i] = rows[i].poseidon2_B_49_0; - polys.poseidon2_B_49_1[i] = rows[i].poseidon2_B_49_1; - polys.poseidon2_B_49_2[i] = rows[i].poseidon2_B_49_2; - polys.poseidon2_B_49_3[i] = rows[i].poseidon2_B_49_3; - polys.poseidon2_B_4_0[i] = rows[i].poseidon2_B_4_0; - polys.poseidon2_B_4_1[i] = rows[i].poseidon2_B_4_1; - polys.poseidon2_B_4_2[i] = rows[i].poseidon2_B_4_2; - polys.poseidon2_B_4_3[i] = rows[i].poseidon2_B_4_3; - polys.poseidon2_B_50_0[i] = rows[i].poseidon2_B_50_0; - polys.poseidon2_B_50_1[i] = rows[i].poseidon2_B_50_1; - polys.poseidon2_B_50_2[i] = rows[i].poseidon2_B_50_2; - polys.poseidon2_B_50_3[i] = rows[i].poseidon2_B_50_3; - polys.poseidon2_B_51_0[i] = rows[i].poseidon2_B_51_0; - polys.poseidon2_B_51_1[i] = rows[i].poseidon2_B_51_1; - polys.poseidon2_B_51_2[i] = rows[i].poseidon2_B_51_2; - polys.poseidon2_B_51_3[i] = rows[i].poseidon2_B_51_3; - polys.poseidon2_B_52_0[i] = rows[i].poseidon2_B_52_0; - polys.poseidon2_B_52_1[i] = rows[i].poseidon2_B_52_1; - polys.poseidon2_B_52_2[i] = rows[i].poseidon2_B_52_2; - polys.poseidon2_B_52_3[i] = rows[i].poseidon2_B_52_3; - polys.poseidon2_B_53_0[i] = rows[i].poseidon2_B_53_0; - polys.poseidon2_B_53_1[i] = rows[i].poseidon2_B_53_1; - polys.poseidon2_B_53_2[i] = rows[i].poseidon2_B_53_2; - polys.poseidon2_B_53_3[i] = rows[i].poseidon2_B_53_3; - polys.poseidon2_B_54_0[i] = rows[i].poseidon2_B_54_0; - polys.poseidon2_B_54_1[i] = rows[i].poseidon2_B_54_1; - polys.poseidon2_B_54_2[i] = rows[i].poseidon2_B_54_2; - polys.poseidon2_B_54_3[i] = rows[i].poseidon2_B_54_3; - polys.poseidon2_B_55_0[i] = rows[i].poseidon2_B_55_0; - polys.poseidon2_B_55_1[i] = rows[i].poseidon2_B_55_1; - polys.poseidon2_B_55_2[i] = rows[i].poseidon2_B_55_2; - polys.poseidon2_B_55_3[i] = rows[i].poseidon2_B_55_3; - polys.poseidon2_B_56_0[i] = rows[i].poseidon2_B_56_0; - polys.poseidon2_B_56_1[i] = rows[i].poseidon2_B_56_1; - polys.poseidon2_B_56_2[i] = rows[i].poseidon2_B_56_2; - polys.poseidon2_B_56_3[i] = rows[i].poseidon2_B_56_3; - polys.poseidon2_B_57_0[i] = rows[i].poseidon2_B_57_0; - polys.poseidon2_B_57_1[i] = rows[i].poseidon2_B_57_1; - polys.poseidon2_B_57_2[i] = rows[i].poseidon2_B_57_2; - polys.poseidon2_B_57_3[i] = rows[i].poseidon2_B_57_3; - polys.poseidon2_B_58_0[i] = rows[i].poseidon2_B_58_0; - polys.poseidon2_B_58_1[i] = rows[i].poseidon2_B_58_1; - polys.poseidon2_B_58_2[i] = rows[i].poseidon2_B_58_2; - polys.poseidon2_B_58_3[i] = rows[i].poseidon2_B_58_3; - polys.poseidon2_B_59_0[i] = rows[i].poseidon2_B_59_0; - polys.poseidon2_B_59_1[i] = rows[i].poseidon2_B_59_1; - polys.poseidon2_B_59_2[i] = rows[i].poseidon2_B_59_2; - polys.poseidon2_B_59_3[i] = rows[i].poseidon2_B_59_3; - polys.poseidon2_B_5_0[i] = rows[i].poseidon2_B_5_0; - polys.poseidon2_B_5_1[i] = rows[i].poseidon2_B_5_1; - polys.poseidon2_B_5_2[i] = rows[i].poseidon2_B_5_2; - polys.poseidon2_B_5_3[i] = rows[i].poseidon2_B_5_3; - polys.poseidon2_B_6_0[i] = rows[i].poseidon2_B_6_0; - polys.poseidon2_B_6_1[i] = rows[i].poseidon2_B_6_1; - polys.poseidon2_B_6_2[i] = rows[i].poseidon2_B_6_2; - polys.poseidon2_B_6_3[i] = rows[i].poseidon2_B_6_3; - polys.poseidon2_B_7_0[i] = rows[i].poseidon2_B_7_0; - polys.poseidon2_B_7_1[i] = rows[i].poseidon2_B_7_1; - polys.poseidon2_B_7_2[i] = rows[i].poseidon2_B_7_2; - polys.poseidon2_B_7_3[i] = rows[i].poseidon2_B_7_3; - polys.poseidon2_B_8_0[i] = rows[i].poseidon2_B_8_0; - polys.poseidon2_B_8_1[i] = rows[i].poseidon2_B_8_1; - polys.poseidon2_B_8_2[i] = rows[i].poseidon2_B_8_2; - polys.poseidon2_B_8_3[i] = rows[i].poseidon2_B_8_3; - polys.poseidon2_B_9_0[i] = rows[i].poseidon2_B_9_0; - polys.poseidon2_B_9_1[i] = rows[i].poseidon2_B_9_1; - polys.poseidon2_B_9_2[i] = rows[i].poseidon2_B_9_2; - polys.poseidon2_B_9_3[i] = rows[i].poseidon2_B_9_3; - polys.poseidon2_EXT_LAYER_4[i] = rows[i].poseidon2_EXT_LAYER_4; - polys.poseidon2_EXT_LAYER_5[i] = rows[i].poseidon2_EXT_LAYER_5; - polys.poseidon2_EXT_LAYER_6[i] = rows[i].poseidon2_EXT_LAYER_6; - polys.poseidon2_EXT_LAYER_7[i] = rows[i].poseidon2_EXT_LAYER_7; - polys.poseidon2_T_0_4[i] = rows[i].poseidon2_T_0_4; - polys.poseidon2_T_0_5[i] = rows[i].poseidon2_T_0_5; - polys.poseidon2_T_0_6[i] = rows[i].poseidon2_T_0_6; - polys.poseidon2_T_0_7[i] = rows[i].poseidon2_T_0_7; - polys.poseidon2_T_1_4[i] = rows[i].poseidon2_T_1_4; - polys.poseidon2_T_1_5[i] = rows[i].poseidon2_T_1_5; - polys.poseidon2_T_1_6[i] = rows[i].poseidon2_T_1_6; - polys.poseidon2_T_1_7[i] = rows[i].poseidon2_T_1_7; - polys.poseidon2_T_2_4[i] = rows[i].poseidon2_T_2_4; - polys.poseidon2_T_2_5[i] = rows[i].poseidon2_T_2_5; - polys.poseidon2_T_2_6[i] = rows[i].poseidon2_T_2_6; - polys.poseidon2_T_2_7[i] = rows[i].poseidon2_T_2_7; - polys.poseidon2_T_3_4[i] = rows[i].poseidon2_T_3_4; - polys.poseidon2_T_3_5[i] = rows[i].poseidon2_T_3_5; - polys.poseidon2_T_3_6[i] = rows[i].poseidon2_T_3_6; - polys.poseidon2_T_3_7[i] = rows[i].poseidon2_T_3_7; - polys.poseidon2_T_60_4[i] = rows[i].poseidon2_T_60_4; - polys.poseidon2_T_60_5[i] = rows[i].poseidon2_T_60_5; - polys.poseidon2_T_60_6[i] = rows[i].poseidon2_T_60_6; - polys.poseidon2_T_60_7[i] = rows[i].poseidon2_T_60_7; - polys.poseidon2_T_61_4[i] = rows[i].poseidon2_T_61_4; - polys.poseidon2_T_61_5[i] = rows[i].poseidon2_T_61_5; - polys.poseidon2_T_61_6[i] = rows[i].poseidon2_T_61_6; - polys.poseidon2_T_61_7[i] = rows[i].poseidon2_T_61_7; - polys.poseidon2_T_62_4[i] = rows[i].poseidon2_T_62_4; - polys.poseidon2_T_62_5[i] = rows[i].poseidon2_T_62_5; - polys.poseidon2_T_62_6[i] = rows[i].poseidon2_T_62_6; - polys.poseidon2_T_62_7[i] = rows[i].poseidon2_T_62_7; - polys.poseidon2_T_63_4[i] = rows[i].poseidon2_T_63_4; - polys.poseidon2_T_63_5[i] = rows[i].poseidon2_T_63_5; - polys.poseidon2_T_63_6[i] = rows[i].poseidon2_T_63_6; - polys.poseidon2_T_63_7[i] = rows[i].poseidon2_T_63_7; - polys.poseidon2_a_0[i] = rows[i].poseidon2_a_0; - polys.poseidon2_a_1[i] = rows[i].poseidon2_a_1; - polys.poseidon2_a_2[i] = rows[i].poseidon2_a_2; - polys.poseidon2_a_3[i] = rows[i].poseidon2_a_3; - polys.poseidon2_b_0[i] = rows[i].poseidon2_b_0; - polys.poseidon2_b_1[i] = rows[i].poseidon2_b_1; - polys.poseidon2_b_2[i] = rows[i].poseidon2_b_2; - polys.poseidon2_b_3[i] = rows[i].poseidon2_b_3; - polys.poseidon2_clk[i] = rows[i].poseidon2_clk; - polys.poseidon2_in_tag[i] = rows[i].poseidon2_in_tag; - polys.poseidon2_input_addr[i] = rows[i].poseidon2_input_addr; - polys.poseidon2_mem_addr_a[i] = rows[i].poseidon2_mem_addr_a; - polys.poseidon2_mem_addr_b[i] = rows[i].poseidon2_mem_addr_b; - polys.poseidon2_mem_addr_c[i] = rows[i].poseidon2_mem_addr_c; - polys.poseidon2_mem_addr_d[i] = rows[i].poseidon2_mem_addr_d; - polys.poseidon2_mem_op[i] = rows[i].poseidon2_mem_op; - polys.poseidon2_output_addr[i] = rows[i].poseidon2_output_addr; - polys.poseidon2_read_line[i] = rows[i].poseidon2_read_line; - polys.poseidon2_sel_poseidon_perm[i] = rows[i].poseidon2_sel_poseidon_perm; - polys.poseidon2_write_line[i] = rows[i].poseidon2_write_line; - polys.powers_power_of_2[i] = rows[i].powers_power_of_2; - polys.sha256_clk[i] = rows[i].sha256_clk; - polys.sha256_input[i] = rows[i].sha256_input; - polys.sha256_output[i] = rows[i].sha256_output; - polys.sha256_sel_sha256_compression[i] = rows[i].sha256_sel_sha256_compression; - polys.sha256_state[i] = rows[i].sha256_state; - polys.slice_addr[i] = rows[i].slice_addr; - polys.slice_clk[i] = rows[i].slice_clk; - polys.slice_cnt[i] = rows[i].slice_cnt; - polys.slice_col_offset[i] = rows[i].slice_col_offset; - polys.slice_one_min_inv[i] = rows[i].slice_one_min_inv; - polys.slice_sel_cd_cpy[i] = rows[i].slice_sel_cd_cpy; - polys.slice_sel_mem_active[i] = rows[i].slice_sel_mem_active; - polys.slice_sel_return[i] = rows[i].slice_sel_return; - polys.slice_sel_start[i] = rows[i].slice_sel_start; - polys.slice_space_id[i] = rows[i].slice_space_id; - polys.slice_val[i] = rows[i].slice_val; - polys.lookup_byte_lengths_counts[i] = rows[i].lookup_byte_lengths_counts; - polys.lookup_byte_operations_counts[i] = rows[i].lookup_byte_operations_counts; - polys.lookup_cd_value_counts[i] = rows[i].lookup_cd_value_counts; - polys.lookup_ret_value_counts[i] = rows[i].lookup_ret_value_counts; - polys.lookup_opcode_gas_counts[i] = rows[i].lookup_opcode_gas_counts; - polys.range_check_l2_gas_hi_counts[i] = rows[i].range_check_l2_gas_hi_counts; - polys.range_check_l2_gas_lo_counts[i] = rows[i].range_check_l2_gas_lo_counts; - polys.range_check_da_gas_hi_counts[i] = rows[i].range_check_da_gas_hi_counts; - polys.range_check_da_gas_lo_counts[i] = rows[i].range_check_da_gas_lo_counts; - polys.kernel_output_lookup_counts[i] = rows[i].kernel_output_lookup_counts; - polys.lookup_into_kernel_counts[i] = rows[i].lookup_into_kernel_counts; - polys.incl_main_tag_err_counts[i] = rows[i].incl_main_tag_err_counts; - polys.incl_mem_tag_err_counts[i] = rows[i].incl_mem_tag_err_counts; - polys.lookup_mem_rng_chk_lo_counts[i] = rows[i].lookup_mem_rng_chk_lo_counts; - polys.lookup_mem_rng_chk_mid_counts[i] = rows[i].lookup_mem_rng_chk_mid_counts; - polys.lookup_mem_rng_chk_hi_counts[i] = rows[i].lookup_mem_rng_chk_hi_counts; - polys.lookup_pow_2_0_counts[i] = rows[i].lookup_pow_2_0_counts; - polys.lookup_pow_2_1_counts[i] = rows[i].lookup_pow_2_1_counts; - polys.lookup_u8_0_counts[i] = rows[i].lookup_u8_0_counts; - polys.lookup_u8_1_counts[i] = rows[i].lookup_u8_1_counts; - polys.lookup_u16_0_counts[i] = rows[i].lookup_u16_0_counts; - polys.lookup_u16_1_counts[i] = rows[i].lookup_u16_1_counts; - polys.lookup_u16_2_counts[i] = rows[i].lookup_u16_2_counts; - polys.lookup_u16_3_counts[i] = rows[i].lookup_u16_3_counts; - polys.lookup_u16_4_counts[i] = rows[i].lookup_u16_4_counts; - polys.lookup_u16_5_counts[i] = rows[i].lookup_u16_5_counts; - polys.lookup_u16_6_counts[i] = rows[i].lookup_u16_6_counts; - polys.lookup_u16_7_counts[i] = rows[i].lookup_u16_7_counts; - polys.lookup_u16_8_counts[i] = rows[i].lookup_u16_8_counts; - polys.lookup_u16_9_counts[i] = rows[i].lookup_u16_9_counts; - polys.lookup_u16_10_counts[i] = rows[i].lookup_u16_10_counts; - polys.lookup_u16_11_counts[i] = rows[i].lookup_u16_11_counts; - polys.lookup_u16_12_counts[i] = rows[i].lookup_u16_12_counts; - polys.lookup_u16_13_counts[i] = rows[i].lookup_u16_13_counts; - polys.lookup_u16_14_counts[i] = rows[i].lookup_u16_14_counts; - polys.lookup_div_u16_0_counts[i] = rows[i].lookup_div_u16_0_counts; - polys.lookup_div_u16_1_counts[i] = rows[i].lookup_div_u16_1_counts; - polys.lookup_div_u16_2_counts[i] = rows[i].lookup_div_u16_2_counts; - polys.lookup_div_u16_3_counts[i] = rows[i].lookup_div_u16_3_counts; - polys.lookup_div_u16_4_counts[i] = rows[i].lookup_div_u16_4_counts; - polys.lookup_div_u16_5_counts[i] = rows[i].lookup_div_u16_5_counts; - polys.lookup_div_u16_6_counts[i] = rows[i].lookup_div_u16_6_counts; - polys.lookup_div_u16_7_counts[i] = rows[i].lookup_div_u16_7_counts; - } - - for (auto [shifted, to_be_shifted] : zip_view(polys.get_shifted(), polys.get_to_be_shifted())) { - shifted = to_be_shifted.shifted(); - } - - return polys; - } - - [[maybe_unused]] bool check_circuit() - { - const FF gamma = FF::random_element(); - const FF beta = FF::random_element(); - bb::RelationParameters params{ - .eta = 0, - .beta = beta, - .gamma = gamma, - .public_input_delta = 0, - .lookup_grand_product_delta = 0, - .beta_sqr = 0, - .beta_cube = 0, - .eccvm_set_permutation_delta = 0, - }; - - auto polys = compute_polynomials(); - const size_t num_rows = polys.get_polynomial_size(); - - // Checks that we will run. - using SignalErrorFn = const std::function&; - std::vector> checks; - - // Add relation checks. - bb::constexpr_for<0, std::tuple_size_v, 1>([&]() { - using Relation = std::tuple_element_t; - checks.push_back([&](SignalErrorFn signal_error) { - typename Relation::SumcheckArrayOfValuesOverSubrelations result; - for (auto& r : result) { - r = 0; - } - constexpr size_t NUM_SUBRELATIONS = result.size(); - - for (size_t r = 0; r < num_rows; ++r) { - Relation::accumulate(result, polys.get_row(r), {}, 1); - for (size_t j = 0; j < NUM_SUBRELATIONS; ++j) { - if (result[j] != 0) { - signal_error(format("Relation ", - Relation::NAME, - ", subrelation ", - Relation::get_subrelation_label(j), - " failed at row ", - r)); - } - } - } - }); - }); - - // Add calculation of logderivatives and lookup/permutation checks. - bb::constexpr_for<0, std::tuple_size_v, 1>([&]() { - using Relation = std::tuple_element_t; - checks.push_back([&, num_rows](SignalErrorFn signal_error) { - // Check the logderivative relation - bb::compute_logderivative_inverse(polys, params, num_rows); - - typename Relation::SumcheckArrayOfValuesOverSubrelations lookup_result; - - for (auto& r : lookup_result) { - r = 0; - } - for (size_t r = 0; r < num_rows; ++r) { - Relation::accumulate(lookup_result, polys.get_row(r), params, 1); - } - for (auto r : lookup_result) { - if (r != 0) { - signal_error(format("Lookup ", Relation::NAME, " failed.")); - } - } - }); - }); - - std::string errors; - auto signal_error = [&](const std::string& error) { - // Thread safety first! - static std::mutex m; - std::lock_guard lock(m); - errors += error + "\n"; - }; - bb::parallel_for(checks.size(), [&](size_t i) { checks[i](signal_error); }); - if (!errors.empty()) { - throw_or_abort(errors); - } - - return errors.empty(); - } - - [[nodiscard]] size_t get_num_gates() const { return rows.size(); } - - [[nodiscard]] size_t get_circuit_subgroup_size() const - { - const size_t num_rows = get_num_gates(); - const auto num_rows_log2 = static_cast(numeric::get_msb64(num_rows)); - size_t num_rows_pow2 = 1UL << (num_rows_log2 + (1UL << num_rows_log2 == num_rows ? 0 : 1)); - return num_rows_pow2; - } -}; - -} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp b/barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp deleted file mode 100644 index a27ec015c004..000000000000 --- a/barretenberg/cpp/src/barretenberg/vm/generated/avm_flavor.hpp +++ /dev/null @@ -1,2727 +0,0 @@ -#pragma once - -#include "barretenberg/commitment_schemes/kzg/kzg.hpp" -#include "barretenberg/ecc/curves/bn254/g1.hpp" -#include "barretenberg/flavor/relation_definitions.hpp" -#include "barretenberg/polynomials/barycentric.hpp" -#include "barretenberg/polynomials/univariate.hpp" - -#include "barretenberg/flavor/flavor.hpp" -#include "barretenberg/flavor/flavor_macros.hpp" -#include "barretenberg/polynomials/evaluation_domain.hpp" -#include "barretenberg/polynomials/polynomial.hpp" -#include "barretenberg/transcript/transcript.hpp" - -#include "barretenberg/vm/generated/avm_flavor_settings.hpp" - -// Relations -#include "barretenberg/relations/generated/avm/alu.hpp" -#include "barretenberg/relations/generated/avm/binary.hpp" -#include "barretenberg/relations/generated/avm/conversion.hpp" -#include "barretenberg/relations/generated/avm/gas.hpp" -#include "barretenberg/relations/generated/avm/keccakf1600.hpp" -#include "barretenberg/relations/generated/avm/kernel.hpp" -#include "barretenberg/relations/generated/avm/main.hpp" -#include "barretenberg/relations/generated/avm/mem.hpp" -#include "barretenberg/relations/generated/avm/mem_slice.hpp" -#include "barretenberg/relations/generated/avm/pedersen.hpp" -#include "barretenberg/relations/generated/avm/poseidon2.hpp" -#include "barretenberg/relations/generated/avm/powers.hpp" -#include "barretenberg/relations/generated/avm/sha256.hpp" - -// Lookup and permutation relations -#include "barretenberg/relations/generated/avm/incl_main_tag_err.hpp" -#include "barretenberg/relations/generated/avm/incl_mem_tag_err.hpp" -#include "barretenberg/relations/generated/avm/kernel_output_lookup.hpp" -#include "barretenberg/relations/generated/avm/lookup_byte_lengths.hpp" -#include "barretenberg/relations/generated/avm/lookup_byte_operations.hpp" -#include "barretenberg/relations/generated/avm/lookup_cd_value.hpp" -#include "barretenberg/relations/generated/avm/lookup_div_u16_0.hpp" -#include "barretenberg/relations/generated/avm/lookup_div_u16_1.hpp" -#include "barretenberg/relations/generated/avm/lookup_div_u16_2.hpp" -#include "barretenberg/relations/generated/avm/lookup_div_u16_3.hpp" -#include "barretenberg/relations/generated/avm/lookup_div_u16_4.hpp" -#include "barretenberg/relations/generated/avm/lookup_div_u16_5.hpp" -#include "barretenberg/relations/generated/avm/lookup_div_u16_6.hpp" -#include "barretenberg/relations/generated/avm/lookup_div_u16_7.hpp" -#include "barretenberg/relations/generated/avm/lookup_into_kernel.hpp" -#include "barretenberg/relations/generated/avm/lookup_mem_rng_chk_hi.hpp" -#include "barretenberg/relations/generated/avm/lookup_mem_rng_chk_lo.hpp" -#include "barretenberg/relations/generated/avm/lookup_mem_rng_chk_mid.hpp" -#include "barretenberg/relations/generated/avm/lookup_opcode_gas.hpp" -#include "barretenberg/relations/generated/avm/lookup_pow_2_0.hpp" -#include "barretenberg/relations/generated/avm/lookup_pow_2_1.hpp" -#include "barretenberg/relations/generated/avm/lookup_ret_value.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_0.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_1.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_10.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_11.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_12.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_13.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_14.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_2.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_3.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_4.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_5.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_6.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_7.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_8.hpp" -#include "barretenberg/relations/generated/avm/lookup_u16_9.hpp" -#include "barretenberg/relations/generated/avm/lookup_u8_0.hpp" -#include "barretenberg/relations/generated/avm/lookup_u8_1.hpp" -#include "barretenberg/relations/generated/avm/perm_main_alu.hpp" -#include "barretenberg/relations/generated/avm/perm_main_bin.hpp" -#include "barretenberg/relations/generated/avm/perm_main_conv.hpp" -#include "barretenberg/relations/generated/avm/perm_main_mem_a.hpp" -#include "barretenberg/relations/generated/avm/perm_main_mem_b.hpp" -#include "barretenberg/relations/generated/avm/perm_main_mem_c.hpp" -#include "barretenberg/relations/generated/avm/perm_main_mem_d.hpp" -#include "barretenberg/relations/generated/avm/perm_main_mem_ind_addr_a.hpp" -#include "barretenberg/relations/generated/avm/perm_main_mem_ind_addr_b.hpp" -#include "barretenberg/relations/generated/avm/perm_main_mem_ind_addr_c.hpp" -#include "barretenberg/relations/generated/avm/perm_main_mem_ind_addr_d.hpp" -#include "barretenberg/relations/generated/avm/perm_main_pedersen.hpp" -#include "barretenberg/relations/generated/avm/perm_main_pos2_perm.hpp" -#include "barretenberg/relations/generated/avm/perm_main_slice.hpp" -#include "barretenberg/relations/generated/avm/perm_pos_mem_a.hpp" -#include "barretenberg/relations/generated/avm/perm_pos_mem_b.hpp" -#include "barretenberg/relations/generated/avm/perm_pos_mem_c.hpp" -#include "barretenberg/relations/generated/avm/perm_pos_mem_d.hpp" -#include "barretenberg/relations/generated/avm/perm_slice_mem.hpp" -#include "barretenberg/relations/generated/avm/range_check_da_gas_hi.hpp" -#include "barretenberg/relations/generated/avm/range_check_da_gas_lo.hpp" -#include "barretenberg/relations/generated/avm/range_check_l2_gas_hi.hpp" -#include "barretenberg/relations/generated/avm/range_check_l2_gas_lo.hpp" - -// Metaprogramming to concatenate tuple types. -template using tuple_cat_t = decltype(std::tuple_cat(std::declval()...)); - -// The entities that will be used in the flavor. -// clang-format off -#define PRECOMPUTED_ENTITIES main_clk, main_sel_first -#define WIRE_ENTITIES kernel_kernel_inputs, kernel_kernel_value_out, kernel_kernel_side_effect_out, kernel_kernel_metadata_out, main_calldata, main_returndata, alu_a_hi, alu_a_lo, alu_b_hi, alu_b_lo, alu_borrow, alu_cf, alu_clk, alu_cmp_rng_ctr, alu_div_u16_r0, alu_div_u16_r1, alu_div_u16_r2, alu_div_u16_r3, alu_div_u16_r4, alu_div_u16_r5, alu_div_u16_r6, alu_div_u16_r7, alu_divisor_hi, alu_divisor_lo, alu_ff_tag, alu_ia, alu_ib, alu_ic, alu_in_tag, alu_op_add, alu_op_cast, alu_op_cast_prev, alu_op_div, alu_op_div_a_lt_b, alu_op_div_std, alu_op_eq, alu_op_eq_diff_inv, alu_op_lt, alu_op_lte, alu_op_mul, alu_op_not, alu_op_shl, alu_op_shr, alu_op_sub, alu_p_a_borrow, alu_p_b_borrow, alu_p_sub_a_hi, alu_p_sub_a_lo, alu_p_sub_b_hi, alu_p_sub_b_lo, alu_partial_prod_hi, alu_partial_prod_lo, alu_quotient_hi, alu_quotient_lo, alu_remainder, alu_res_hi, alu_res_lo, alu_sel_alu, alu_sel_cmp, alu_sel_div_rng_chk, alu_sel_rng_chk, alu_sel_rng_chk_lookup, alu_sel_shift_which, alu_shift_lt_bit_len, alu_t_sub_s_bits, alu_two_pow_s, alu_two_pow_t_sub_s, alu_u128_tag, alu_u16_r0, alu_u16_r1, alu_u16_r10, alu_u16_r11, alu_u16_r12, alu_u16_r13, alu_u16_r14, alu_u16_r2, alu_u16_r3, alu_u16_r4, alu_u16_r5, alu_u16_r6, alu_u16_r7, alu_u16_r8, alu_u16_r9, alu_u16_tag, alu_u32_tag, alu_u64_tag, alu_u8_r0, alu_u8_r1, alu_u8_tag, binary_acc_ia, binary_acc_ib, binary_acc_ic, binary_clk, binary_ia_bytes, binary_ib_bytes, binary_ic_bytes, binary_in_tag, binary_mem_tag_ctr, binary_mem_tag_ctr_inv, binary_op_id, binary_sel_bin, binary_start, byte_lookup_sel_bin, byte_lookup_table_byte_lengths, byte_lookup_table_in_tags, byte_lookup_table_input_a, byte_lookup_table_input_b, byte_lookup_table_op_id, byte_lookup_table_output, conversion_clk, conversion_input, conversion_num_limbs, conversion_radix, conversion_sel_to_radix_le, gas_da_gas_fixed_table, gas_l2_gas_fixed_table, gas_sel_gas_cost, keccakf1600_clk, keccakf1600_input, keccakf1600_output, keccakf1600_sel_keccakf1600, kernel_emit_l2_to_l1_msg_write_offset, kernel_emit_note_hash_write_offset, kernel_emit_nullifier_write_offset, kernel_emit_unencrypted_log_write_offset, kernel_kernel_in_offset, kernel_kernel_out_offset, kernel_l1_to_l2_msg_exists_write_offset, kernel_note_hash_exist_write_offset, kernel_nullifier_exists_write_offset, kernel_nullifier_non_exists_write_offset, kernel_q_public_input_kernel_add_to_table, kernel_q_public_input_kernel_out_add_to_table, kernel_side_effect_counter, kernel_sload_write_offset, kernel_sstore_write_offset, main_abs_da_rem_gas_hi, main_abs_da_rem_gas_lo, main_abs_l2_rem_gas_hi, main_abs_l2_rem_gas_lo, main_alu_in_tag, main_bin_op_id, main_call_ptr, main_da_gas_op_cost, main_da_gas_remaining, main_da_out_of_gas, main_ia, main_ib, main_ic, main_id, main_id_zero, main_ind_addr_a, main_ind_addr_b, main_ind_addr_c, main_ind_addr_d, main_internal_return_ptr, main_inv, main_l2_gas_op_cost, main_l2_gas_remaining, main_l2_out_of_gas, main_mem_addr_a, main_mem_addr_b, main_mem_addr_c, main_mem_addr_d, main_op_err, main_opcode_val, main_pc, main_r_in_tag, main_rwa, main_rwb, main_rwc, main_rwd, main_sel_alu, main_sel_bin, main_sel_calldata, main_sel_gas_accounting_active, main_sel_last, main_sel_mem_op_a, main_sel_mem_op_activate_gas, main_sel_mem_op_b, main_sel_mem_op_c, main_sel_mem_op_d, main_sel_mov_ia_to_ic, main_sel_mov_ib_to_ic, main_sel_op_add, main_sel_op_address, main_sel_op_and, main_sel_op_block_number, main_sel_op_calldata_copy, main_sel_op_cast, main_sel_op_chain_id, main_sel_op_cmov, main_sel_op_coinbase, main_sel_op_dagasleft, main_sel_op_div, main_sel_op_emit_l2_to_l1_msg, main_sel_op_emit_note_hash, main_sel_op_emit_nullifier, main_sel_op_emit_unencrypted_log, main_sel_op_eq, main_sel_op_external_call, main_sel_op_external_return, main_sel_op_fdiv, main_sel_op_fee_per_da_gas, main_sel_op_fee_per_l2_gas, main_sel_op_function_selector, main_sel_op_get_contract_instance, main_sel_op_halt, main_sel_op_internal_call, main_sel_op_internal_return, main_sel_op_jump, main_sel_op_jumpi, main_sel_op_keccak, main_sel_op_l1_to_l2_msg_exists, main_sel_op_l2gasleft, main_sel_op_lt, main_sel_op_lte, main_sel_op_mov, main_sel_op_mul, main_sel_op_not, main_sel_op_note_hash_exists, main_sel_op_nullifier_exists, main_sel_op_or, main_sel_op_pedersen, main_sel_op_poseidon2, main_sel_op_radix_le, main_sel_op_sender, main_sel_op_sha256, main_sel_op_shl, main_sel_op_shr, main_sel_op_sload, main_sel_op_sstore, main_sel_op_storage_address, main_sel_op_sub, main_sel_op_timestamp, main_sel_op_transaction_fee, main_sel_op_version, main_sel_op_xor, main_sel_q_kernel_lookup, main_sel_q_kernel_output_lookup, main_sel_resolve_ind_addr_a, main_sel_resolve_ind_addr_b, main_sel_resolve_ind_addr_c, main_sel_resolve_ind_addr_d, main_sel_returndata, main_sel_rng_16, main_sel_rng_8, main_sel_slice_gadget, main_space_id, main_tag_err, main_w_in_tag, mem_addr, mem_clk, mem_diff_hi, mem_diff_lo, mem_diff_mid, mem_glob_addr, mem_last, mem_lastAccess, mem_one_min_inv, mem_r_in_tag, mem_rw, mem_sel_mem, mem_sel_mov_ia_to_ic, mem_sel_mov_ib_to_ic, mem_sel_op_a, mem_sel_op_b, mem_sel_op_c, mem_sel_op_cmov, mem_sel_op_d, mem_sel_op_gadget_a, mem_sel_op_gadget_b, mem_sel_op_gadget_c, mem_sel_op_gadget_d, mem_sel_op_slice, mem_sel_resolve_ind_addr_a, mem_sel_resolve_ind_addr_b, mem_sel_resolve_ind_addr_c, mem_sel_resolve_ind_addr_d, mem_sel_rng_chk, mem_skip_check_tag, mem_space_id, mem_tag, mem_tag_err, mem_tsp, mem_val, mem_w_in_tag, pedersen_clk, pedersen_input, pedersen_output, pedersen_sel_pedersen, poseidon2_B_10_0, poseidon2_B_10_1, poseidon2_B_10_2, poseidon2_B_10_3, poseidon2_B_11_0, poseidon2_B_11_1, poseidon2_B_11_2, poseidon2_B_11_3, poseidon2_B_12_0, poseidon2_B_12_1, poseidon2_B_12_2, poseidon2_B_12_3, poseidon2_B_13_0, poseidon2_B_13_1, poseidon2_B_13_2, poseidon2_B_13_3, poseidon2_B_14_0, poseidon2_B_14_1, poseidon2_B_14_2, poseidon2_B_14_3, poseidon2_B_15_0, poseidon2_B_15_1, poseidon2_B_15_2, poseidon2_B_15_3, poseidon2_B_16_0, poseidon2_B_16_1, poseidon2_B_16_2, poseidon2_B_16_3, poseidon2_B_17_0, poseidon2_B_17_1, poseidon2_B_17_2, poseidon2_B_17_3, poseidon2_B_18_0, poseidon2_B_18_1, poseidon2_B_18_2, poseidon2_B_18_3, poseidon2_B_19_0, poseidon2_B_19_1, poseidon2_B_19_2, poseidon2_B_19_3, poseidon2_B_20_0, poseidon2_B_20_1, poseidon2_B_20_2, poseidon2_B_20_3, poseidon2_B_21_0, poseidon2_B_21_1, poseidon2_B_21_2, poseidon2_B_21_3, poseidon2_B_22_0, poseidon2_B_22_1, poseidon2_B_22_2, poseidon2_B_22_3, poseidon2_B_23_0, poseidon2_B_23_1, poseidon2_B_23_2, poseidon2_B_23_3, poseidon2_B_24_0, poseidon2_B_24_1, poseidon2_B_24_2, poseidon2_B_24_3, poseidon2_B_25_0, poseidon2_B_25_1, poseidon2_B_25_2, poseidon2_B_25_3, poseidon2_B_26_0, poseidon2_B_26_1, poseidon2_B_26_2, poseidon2_B_26_3, poseidon2_B_27_0, poseidon2_B_27_1, poseidon2_B_27_2, poseidon2_B_27_3, poseidon2_B_28_0, poseidon2_B_28_1, poseidon2_B_28_2, poseidon2_B_28_3, poseidon2_B_29_0, poseidon2_B_29_1, poseidon2_B_29_2, poseidon2_B_29_3, poseidon2_B_30_0, poseidon2_B_30_1, poseidon2_B_30_2, poseidon2_B_30_3, poseidon2_B_31_0, poseidon2_B_31_1, poseidon2_B_31_2, poseidon2_B_31_3, poseidon2_B_32_0, poseidon2_B_32_1, poseidon2_B_32_2, poseidon2_B_32_3, poseidon2_B_33_0, poseidon2_B_33_1, poseidon2_B_33_2, poseidon2_B_33_3, poseidon2_B_34_0, poseidon2_B_34_1, poseidon2_B_34_2, poseidon2_B_34_3, poseidon2_B_35_0, poseidon2_B_35_1, poseidon2_B_35_2, poseidon2_B_35_3, poseidon2_B_36_0, poseidon2_B_36_1, poseidon2_B_36_2, poseidon2_B_36_3, poseidon2_B_37_0, poseidon2_B_37_1, poseidon2_B_37_2, poseidon2_B_37_3, poseidon2_B_38_0, poseidon2_B_38_1, poseidon2_B_38_2, poseidon2_B_38_3, poseidon2_B_39_0, poseidon2_B_39_1, poseidon2_B_39_2, poseidon2_B_39_3, poseidon2_B_40_0, poseidon2_B_40_1, poseidon2_B_40_2, poseidon2_B_40_3, poseidon2_B_41_0, poseidon2_B_41_1, poseidon2_B_41_2, poseidon2_B_41_3, poseidon2_B_42_0, poseidon2_B_42_1, poseidon2_B_42_2, poseidon2_B_42_3, poseidon2_B_43_0, poseidon2_B_43_1, poseidon2_B_43_2, poseidon2_B_43_3, poseidon2_B_44_0, poseidon2_B_44_1, poseidon2_B_44_2, poseidon2_B_44_3, poseidon2_B_45_0, poseidon2_B_45_1, poseidon2_B_45_2, poseidon2_B_45_3, poseidon2_B_46_0, poseidon2_B_46_1, poseidon2_B_46_2, poseidon2_B_46_3, poseidon2_B_47_0, poseidon2_B_47_1, poseidon2_B_47_2, poseidon2_B_47_3, poseidon2_B_48_0, poseidon2_B_48_1, poseidon2_B_48_2, poseidon2_B_48_3, poseidon2_B_49_0, poseidon2_B_49_1, poseidon2_B_49_2, poseidon2_B_49_3, poseidon2_B_4_0, poseidon2_B_4_1, poseidon2_B_4_2, poseidon2_B_4_3, poseidon2_B_50_0, poseidon2_B_50_1, poseidon2_B_50_2, poseidon2_B_50_3, poseidon2_B_51_0, poseidon2_B_51_1, poseidon2_B_51_2, poseidon2_B_51_3, poseidon2_B_52_0, poseidon2_B_52_1, poseidon2_B_52_2, poseidon2_B_52_3, poseidon2_B_53_0, poseidon2_B_53_1, poseidon2_B_53_2, poseidon2_B_53_3, poseidon2_B_54_0, poseidon2_B_54_1, poseidon2_B_54_2, poseidon2_B_54_3, poseidon2_B_55_0, poseidon2_B_55_1, poseidon2_B_55_2, poseidon2_B_55_3, poseidon2_B_56_0, poseidon2_B_56_1, poseidon2_B_56_2, poseidon2_B_56_3, poseidon2_B_57_0, poseidon2_B_57_1, poseidon2_B_57_2, poseidon2_B_57_3, poseidon2_B_58_0, poseidon2_B_58_1, poseidon2_B_58_2, poseidon2_B_58_3, poseidon2_B_59_0, poseidon2_B_59_1, poseidon2_B_59_2, poseidon2_B_59_3, poseidon2_B_5_0, poseidon2_B_5_1, poseidon2_B_5_2, poseidon2_B_5_3, poseidon2_B_6_0, poseidon2_B_6_1, poseidon2_B_6_2, poseidon2_B_6_3, poseidon2_B_7_0, poseidon2_B_7_1, poseidon2_B_7_2, poseidon2_B_7_3, poseidon2_B_8_0, poseidon2_B_8_1, poseidon2_B_8_2, poseidon2_B_8_3, poseidon2_B_9_0, poseidon2_B_9_1, poseidon2_B_9_2, poseidon2_B_9_3, poseidon2_EXT_LAYER_4, poseidon2_EXT_LAYER_5, poseidon2_EXT_LAYER_6, poseidon2_EXT_LAYER_7, poseidon2_T_0_4, poseidon2_T_0_5, poseidon2_T_0_6, poseidon2_T_0_7, poseidon2_T_1_4, poseidon2_T_1_5, poseidon2_T_1_6, poseidon2_T_1_7, poseidon2_T_2_4, poseidon2_T_2_5, poseidon2_T_2_6, poseidon2_T_2_7, poseidon2_T_3_4, poseidon2_T_3_5, poseidon2_T_3_6, poseidon2_T_3_7, poseidon2_T_60_4, poseidon2_T_60_5, poseidon2_T_60_6, poseidon2_T_60_7, poseidon2_T_61_4, poseidon2_T_61_5, poseidon2_T_61_6, poseidon2_T_61_7, poseidon2_T_62_4, poseidon2_T_62_5, poseidon2_T_62_6, poseidon2_T_62_7, poseidon2_T_63_4, poseidon2_T_63_5, poseidon2_T_63_6, poseidon2_T_63_7, poseidon2_a_0, poseidon2_a_1, poseidon2_a_2, poseidon2_a_3, poseidon2_b_0, poseidon2_b_1, poseidon2_b_2, poseidon2_b_3, poseidon2_clk, poseidon2_in_tag, poseidon2_input_addr, poseidon2_mem_addr_a, poseidon2_mem_addr_b, poseidon2_mem_addr_c, poseidon2_mem_addr_d, poseidon2_mem_op, poseidon2_output_addr, poseidon2_read_line, poseidon2_sel_poseidon_perm, poseidon2_write_line, powers_power_of_2, sha256_clk, sha256_input, sha256_output, sha256_sel_sha256_compression, sha256_state, slice_addr, slice_clk, slice_cnt, slice_col_offset, slice_one_min_inv, slice_sel_cd_cpy, slice_sel_mem_active, slice_sel_return, slice_sel_start, slice_space_id, slice_val, lookup_byte_lengths_counts, lookup_byte_operations_counts, lookup_cd_value_counts, lookup_ret_value_counts, lookup_opcode_gas_counts, range_check_l2_gas_hi_counts, range_check_l2_gas_lo_counts, range_check_da_gas_hi_counts, range_check_da_gas_lo_counts, kernel_output_lookup_counts, lookup_into_kernel_counts, incl_main_tag_err_counts, incl_mem_tag_err_counts, lookup_mem_rng_chk_lo_counts, lookup_mem_rng_chk_mid_counts, lookup_mem_rng_chk_hi_counts, lookup_pow_2_0_counts, lookup_pow_2_1_counts, lookup_u8_0_counts, lookup_u8_1_counts, lookup_u16_0_counts, lookup_u16_1_counts, lookup_u16_2_counts, lookup_u16_3_counts, lookup_u16_4_counts, lookup_u16_5_counts, lookup_u16_6_counts, lookup_u16_7_counts, lookup_u16_8_counts, lookup_u16_9_counts, lookup_u16_10_counts, lookup_u16_11_counts, lookup_u16_12_counts, lookup_u16_13_counts, lookup_u16_14_counts, lookup_div_u16_0_counts, lookup_div_u16_1_counts, lookup_div_u16_2_counts, lookup_div_u16_3_counts, lookup_div_u16_4_counts, lookup_div_u16_5_counts, lookup_div_u16_6_counts, lookup_div_u16_7_counts -#define DERIVED_WITNESS_ENTITIES perm_pos_mem_a, perm_pos_mem_b, perm_pos_mem_c, perm_pos_mem_d, perm_slice_mem, perm_main_alu, perm_main_bin, perm_main_conv, perm_main_pos2_perm, perm_main_pedersen, perm_main_slice, perm_main_mem_a, perm_main_mem_b, perm_main_mem_c, perm_main_mem_d, perm_main_mem_ind_addr_a, perm_main_mem_ind_addr_b, perm_main_mem_ind_addr_c, perm_main_mem_ind_addr_d, lookup_byte_lengths, lookup_byte_operations, lookup_cd_value, lookup_ret_value, lookup_opcode_gas, range_check_l2_gas_hi, range_check_l2_gas_lo, range_check_da_gas_hi, range_check_da_gas_lo, kernel_output_lookup, lookup_into_kernel, incl_main_tag_err, incl_mem_tag_err, lookup_mem_rng_chk_lo, lookup_mem_rng_chk_mid, lookup_mem_rng_chk_hi, lookup_pow_2_0, lookup_pow_2_1, lookup_u8_0, lookup_u8_1, lookup_u16_0, lookup_u16_1, lookup_u16_2, lookup_u16_3, lookup_u16_4, lookup_u16_5, lookup_u16_6, lookup_u16_7, lookup_u16_8, lookup_u16_9, lookup_u16_10, lookup_u16_11, lookup_u16_12, lookup_u16_13, lookup_u16_14, lookup_div_u16_0, lookup_div_u16_1, lookup_div_u16_2, lookup_div_u16_3, lookup_div_u16_4, lookup_div_u16_5, lookup_div_u16_6, lookup_div_u16_7 -#define SHIFTED_ENTITIES alu_a_hi_shift, alu_a_lo_shift, alu_b_hi_shift, alu_b_lo_shift, alu_cmp_rng_ctr_shift, alu_div_u16_r0_shift, alu_div_u16_r1_shift, alu_div_u16_r2_shift, alu_div_u16_r3_shift, alu_div_u16_r4_shift, alu_div_u16_r5_shift, alu_div_u16_r6_shift, alu_div_u16_r7_shift, alu_op_add_shift, alu_op_cast_prev_shift, alu_op_cast_shift, alu_op_div_shift, alu_op_mul_shift, alu_op_shl_shift, alu_op_shr_shift, alu_op_sub_shift, alu_p_sub_a_hi_shift, alu_p_sub_a_lo_shift, alu_p_sub_b_hi_shift, alu_p_sub_b_lo_shift, alu_sel_alu_shift, alu_sel_cmp_shift, alu_sel_div_rng_chk_shift, alu_sel_rng_chk_lookup_shift, alu_sel_rng_chk_shift, alu_u16_r0_shift, alu_u16_r1_shift, alu_u16_r2_shift, alu_u16_r3_shift, alu_u16_r4_shift, alu_u16_r5_shift, alu_u16_r6_shift, alu_u8_r0_shift, alu_u8_r1_shift, binary_acc_ia_shift, binary_acc_ib_shift, binary_acc_ic_shift, binary_mem_tag_ctr_shift, binary_op_id_shift, kernel_emit_l2_to_l1_msg_write_offset_shift, kernel_emit_note_hash_write_offset_shift, kernel_emit_nullifier_write_offset_shift, kernel_emit_unencrypted_log_write_offset_shift, kernel_l1_to_l2_msg_exists_write_offset_shift, kernel_note_hash_exist_write_offset_shift, kernel_nullifier_exists_write_offset_shift, kernel_nullifier_non_exists_write_offset_shift, kernel_side_effect_counter_shift, kernel_sload_write_offset_shift, kernel_sstore_write_offset_shift, main_da_gas_remaining_shift, main_internal_return_ptr_shift, main_l2_gas_remaining_shift, main_pc_shift, mem_glob_addr_shift, mem_rw_shift, mem_sel_mem_shift, mem_tag_shift, mem_tsp_shift, mem_val_shift, poseidon2_a_0_shift, poseidon2_a_1_shift, poseidon2_a_2_shift, poseidon2_a_3_shift, poseidon2_sel_poseidon_perm_shift, poseidon2_write_line_shift, slice_addr_shift, slice_clk_shift, slice_cnt_shift, slice_col_offset_shift, slice_sel_cd_cpy_shift, slice_sel_mem_active_shift, slice_sel_return_shift, slice_sel_start_shift, slice_space_id_shift -#define TO_BE_SHIFTED(e) e.alu_a_hi, e.alu_a_lo, e.alu_b_hi, e.alu_b_lo, e.alu_cmp_rng_ctr, e.alu_div_u16_r0, e.alu_div_u16_r1, e.alu_div_u16_r2, e.alu_div_u16_r3, e.alu_div_u16_r4, e.alu_div_u16_r5, e.alu_div_u16_r6, e.alu_div_u16_r7, e.alu_op_add, e.alu_op_cast_prev, e.alu_op_cast, e.alu_op_div, e.alu_op_mul, e.alu_op_shl, e.alu_op_shr, e.alu_op_sub, e.alu_p_sub_a_hi, e.alu_p_sub_a_lo, e.alu_p_sub_b_hi, e.alu_p_sub_b_lo, e.alu_sel_alu, e.alu_sel_cmp, e.alu_sel_div_rng_chk, e.alu_sel_rng_chk_lookup, e.alu_sel_rng_chk, e.alu_u16_r0, e.alu_u16_r1, e.alu_u16_r2, e.alu_u16_r3, e.alu_u16_r4, e.alu_u16_r5, e.alu_u16_r6, e.alu_u8_r0, e.alu_u8_r1, e.binary_acc_ia, e.binary_acc_ib, e.binary_acc_ic, e.binary_mem_tag_ctr, e.binary_op_id, e.kernel_emit_l2_to_l1_msg_write_offset, e.kernel_emit_note_hash_write_offset, e.kernel_emit_nullifier_write_offset, e.kernel_emit_unencrypted_log_write_offset, e.kernel_l1_to_l2_msg_exists_write_offset, e.kernel_note_hash_exist_write_offset, e.kernel_nullifier_exists_write_offset, e.kernel_nullifier_non_exists_write_offset, e.kernel_side_effect_counter, e.kernel_sload_write_offset, e.kernel_sstore_write_offset, e.main_da_gas_remaining, e.main_internal_return_ptr, e.main_l2_gas_remaining, e.main_pc, e.mem_glob_addr, e.mem_rw, e.mem_sel_mem, e.mem_tag, e.mem_tsp, e.mem_val, e.poseidon2_a_0, e.poseidon2_a_1, e.poseidon2_a_2, e.poseidon2_a_3, e.poseidon2_sel_poseidon_perm, e.poseidon2_write_line, e.slice_addr, e.slice_clk, e.slice_cnt, e.slice_col_offset, e.slice_sel_cd_cpy, e.slice_sel_mem_active, e.slice_sel_return, e.slice_sel_start, e.slice_space_id -#define ALL_ENTITIES PRECOMPUTED_ENTITIES, WIRE_ENTITIES, DERIVED_WITNESS_ENTITIES, SHIFTED_ENTITIES -// clang-format on - -namespace bb { - -class AvmFlavor { - public: - using Curve = AvmFlavorSettings::Curve; - using G1 = AvmFlavorSettings::G1; - using PCS = AvmFlavorSettings::PCS; - - using FF = AvmFlavorSettings::FF; - using Polynomial = AvmFlavorSettings::Polynomial; - using PolynomialHandle = AvmFlavorSettings::PolynomialHandle; - using GroupElement = AvmFlavorSettings::GroupElement; - using Commitment = AvmFlavorSettings::Commitment; - using CommitmentHandle = AvmFlavorSettings::CommitmentHandle; - using CommitmentKey = AvmFlavorSettings::CommitmentKey; - using VerifierCommitmentKey = AvmFlavorSettings::VerifierCommitmentKey; - using RelationSeparator = AvmFlavorSettings::RelationSeparator; - - static constexpr size_t NUM_PRECOMPUTED_ENTITIES = 2; - static constexpr size_t NUM_WITNESS_ENTITIES = 693; - static constexpr size_t NUM_WIRES = NUM_WITNESS_ENTITIES + NUM_PRECOMPUTED_ENTITIES; - // We have two copies of the witness entities, so we subtract the number of fixed ones (they have no shift), one for - // the unshifted and one for the shifted - static constexpr size_t NUM_ALL_ENTITIES = 775; - - using MainRelations = std::tuple< - // Relations - Avm_vm::alu, - Avm_vm::binary, - Avm_vm::conversion, - Avm_vm::gas, - Avm_vm::keccakf1600, - Avm_vm::kernel, - Avm_vm::main, - Avm_vm::mem, - Avm_vm::mem_slice, - Avm_vm::pedersen, - Avm_vm::poseidon2, - Avm_vm::powers, - Avm_vm::sha256>; - - using LookupRelations = std::tuple< - // Lookups - perm_pos_mem_a_relation, - perm_pos_mem_b_relation, - perm_pos_mem_c_relation, - perm_pos_mem_d_relation, - perm_slice_mem_relation, - perm_main_alu_relation, - perm_main_bin_relation, - perm_main_conv_relation, - perm_main_pos2_perm_relation, - perm_main_pedersen_relation, - perm_main_slice_relation, - perm_main_mem_a_relation, - perm_main_mem_b_relation, - perm_main_mem_c_relation, - perm_main_mem_d_relation, - perm_main_mem_ind_addr_a_relation, - perm_main_mem_ind_addr_b_relation, - perm_main_mem_ind_addr_c_relation, - perm_main_mem_ind_addr_d_relation, - lookup_byte_lengths_relation, - lookup_byte_operations_relation, - lookup_cd_value_relation, - lookup_ret_value_relation, - lookup_opcode_gas_relation, - range_check_l2_gas_hi_relation, - range_check_l2_gas_lo_relation, - range_check_da_gas_hi_relation, - range_check_da_gas_lo_relation, - kernel_output_lookup_relation, - lookup_into_kernel_relation, - incl_main_tag_err_relation, - incl_mem_tag_err_relation, - lookup_mem_rng_chk_lo_relation, - lookup_mem_rng_chk_mid_relation, - lookup_mem_rng_chk_hi_relation, - lookup_pow_2_0_relation, - lookup_pow_2_1_relation, - lookup_u8_0_relation, - lookup_u8_1_relation, - lookup_u16_0_relation, - lookup_u16_1_relation, - lookup_u16_2_relation, - lookup_u16_3_relation, - lookup_u16_4_relation, - lookup_u16_5_relation, - lookup_u16_6_relation, - lookup_u16_7_relation, - lookup_u16_8_relation, - lookup_u16_9_relation, - lookup_u16_10_relation, - lookup_u16_11_relation, - lookup_u16_12_relation, - lookup_u16_13_relation, - lookup_u16_14_relation, - lookup_div_u16_0_relation, - lookup_div_u16_1_relation, - lookup_div_u16_2_relation, - lookup_div_u16_3_relation, - lookup_div_u16_4_relation, - lookup_div_u16_5_relation, - lookup_div_u16_6_relation, - lookup_div_u16_7_relation>; - - using Relations = tuple_cat_t; - - static constexpr size_t MAX_PARTIAL_RELATION_LENGTH = compute_max_partial_relation_length(); - - // BATCHED_RELATION_PARTIAL_LENGTH = algebraic degree of sumcheck relation *after* multiplying by the `pow_zeta` - // random polynomial e.g. For \sum(x) [A(x) * B(x) + C(x)] * PowZeta(X), relation length = 2 and random relation - // length = 3 - static constexpr size_t BATCHED_RELATION_PARTIAL_LENGTH = MAX_PARTIAL_RELATION_LENGTH + 1; - static constexpr size_t NUM_RELATIONS = std::tuple_size_v; - - template - using ProtogalaxyTupleOfTuplesOfUnivariates = - decltype(create_protogalaxy_tuple_of_tuples_of_univariates()); - using SumcheckTupleOfTuplesOfUnivariates = decltype(create_sumcheck_tuple_of_tuples_of_univariates()); - using TupleOfArraysOfValues = decltype(create_tuple_of_arrays_of_values()); - - static constexpr bool has_zero_row = true; - - private: - template class PrecomputedEntities : public PrecomputedEntitiesBase { - public: - using DataType = DataType_; - - DEFINE_FLAVOR_MEMBERS(DataType, PRECOMPUTED_ENTITIES) - - RefVector get_selectors() { return get_all(); } - RefVector get_sigma_polynomials() { return {}; } - RefVector get_id_polynomials() { return {}; } - RefVector get_table_polynomials() { return {}; } - }; - - template class WireEntities { - public: - DEFINE_FLAVOR_MEMBERS(DataType, WIRE_ENTITIES) - }; - - template class DerivedWitnessEntities { - public: - DEFINE_FLAVOR_MEMBERS(DataType, DERIVED_WITNESS_ENTITIES) - }; - - template class ShiftedEntities { - public: - DEFINE_FLAVOR_MEMBERS(DataType, SHIFTED_ENTITIES) - }; - - template - static auto get_to_be_shifted(PrecomputedAndWitnessEntitiesSuperset& entities) - { - return RefArray{ TO_BE_SHIFTED(entities) }; - } - - template - class WitnessEntities : public WireEntities, public DerivedWitnessEntities { - public: - DEFINE_COMPOUND_GET_ALL(WireEntities, DerivedWitnessEntities) - auto get_wires() { return WireEntities::get_all(); } - auto get_derived() { return DerivedWitnessEntities::get_all(); } - }; - - template - class AllEntities : public PrecomputedEntities, - public WitnessEntities, - public ShiftedEntities { - public: - DEFINE_COMPOUND_GET_ALL(PrecomputedEntities, WitnessEntities, ShiftedEntities) - - auto get_unshifted() - { - return concatenate(PrecomputedEntities::get_all(), WitnessEntities::get_all()); - } - auto get_to_be_shifted() { return AvmFlavor::get_to_be_shifted(*this); } - auto get_shifted() { return ShiftedEntities::get_all(); } - auto get_precomputed() { return PrecomputedEntities::get_all(); } - }; - - public: - class ProvingKey - : public ProvingKeyAvm_, WitnessEntities, CommitmentKey> { - public: - // Expose constructors on the base class - using Base = ProvingKeyAvm_, WitnessEntities, CommitmentKey>; - using Base::Base; - - auto get_to_be_shifted() { return AvmFlavor::get_to_be_shifted(*this); } - }; - - using VerificationKey = VerificationKey_, VerifierCommitmentKey>; - - class AllValues : public AllEntities { - public: - using Base = AllEntities; - using Base::Base; - }; - - class AllConstRefValues { - public: - using DataType = const FF&; - - DEFINE_FLAVOR_MEMBERS(DataType, ALL_ENTITIES) - - AllConstRefValues(const RefArray& il) - : main_clk(il[0]) - , main_sel_first(il[1]) - , kernel_kernel_inputs(il[2]) - , kernel_kernel_value_out(il[3]) - , kernel_kernel_side_effect_out(il[4]) - , kernel_kernel_metadata_out(il[5]) - , main_calldata(il[6]) - , main_returndata(il[7]) - , alu_a_hi(il[8]) - , alu_a_lo(il[9]) - , alu_b_hi(il[10]) - , alu_b_lo(il[11]) - , alu_borrow(il[12]) - , alu_cf(il[13]) - , alu_clk(il[14]) - , alu_cmp_rng_ctr(il[15]) - , alu_div_u16_r0(il[16]) - , alu_div_u16_r1(il[17]) - , alu_div_u16_r2(il[18]) - , alu_div_u16_r3(il[19]) - , alu_div_u16_r4(il[20]) - , alu_div_u16_r5(il[21]) - , alu_div_u16_r6(il[22]) - , alu_div_u16_r7(il[23]) - , alu_divisor_hi(il[24]) - , alu_divisor_lo(il[25]) - , alu_ff_tag(il[26]) - , alu_ia(il[27]) - , alu_ib(il[28]) - , alu_ic(il[29]) - , alu_in_tag(il[30]) - , alu_op_add(il[31]) - , alu_op_cast(il[32]) - , alu_op_cast_prev(il[33]) - , alu_op_div(il[34]) - , alu_op_div_a_lt_b(il[35]) - , alu_op_div_std(il[36]) - , alu_op_eq(il[37]) - , alu_op_eq_diff_inv(il[38]) - , alu_op_lt(il[39]) - , alu_op_lte(il[40]) - , alu_op_mul(il[41]) - , alu_op_not(il[42]) - , alu_op_shl(il[43]) - , alu_op_shr(il[44]) - , alu_op_sub(il[45]) - , alu_p_a_borrow(il[46]) - , alu_p_b_borrow(il[47]) - , alu_p_sub_a_hi(il[48]) - , alu_p_sub_a_lo(il[49]) - , alu_p_sub_b_hi(il[50]) - , alu_p_sub_b_lo(il[51]) - , alu_partial_prod_hi(il[52]) - , alu_partial_prod_lo(il[53]) - , alu_quotient_hi(il[54]) - , alu_quotient_lo(il[55]) - , alu_remainder(il[56]) - , alu_res_hi(il[57]) - , alu_res_lo(il[58]) - , alu_sel_alu(il[59]) - , alu_sel_cmp(il[60]) - , alu_sel_div_rng_chk(il[61]) - , alu_sel_rng_chk(il[62]) - , alu_sel_rng_chk_lookup(il[63]) - , alu_sel_shift_which(il[64]) - , alu_shift_lt_bit_len(il[65]) - , alu_t_sub_s_bits(il[66]) - , alu_two_pow_s(il[67]) - , alu_two_pow_t_sub_s(il[68]) - , alu_u128_tag(il[69]) - , alu_u16_r0(il[70]) - , alu_u16_r1(il[71]) - , alu_u16_r10(il[72]) - , alu_u16_r11(il[73]) - , alu_u16_r12(il[74]) - , alu_u16_r13(il[75]) - , alu_u16_r14(il[76]) - , alu_u16_r2(il[77]) - , alu_u16_r3(il[78]) - , alu_u16_r4(il[79]) - , alu_u16_r5(il[80]) - , alu_u16_r6(il[81]) - , alu_u16_r7(il[82]) - , alu_u16_r8(il[83]) - , alu_u16_r9(il[84]) - , alu_u16_tag(il[85]) - , alu_u32_tag(il[86]) - , alu_u64_tag(il[87]) - , alu_u8_r0(il[88]) - , alu_u8_r1(il[89]) - , alu_u8_tag(il[90]) - , binary_acc_ia(il[91]) - , binary_acc_ib(il[92]) - , binary_acc_ic(il[93]) - , binary_clk(il[94]) - , binary_ia_bytes(il[95]) - , binary_ib_bytes(il[96]) - , binary_ic_bytes(il[97]) - , binary_in_tag(il[98]) - , binary_mem_tag_ctr(il[99]) - , binary_mem_tag_ctr_inv(il[100]) - , binary_op_id(il[101]) - , binary_sel_bin(il[102]) - , binary_start(il[103]) - , byte_lookup_sel_bin(il[104]) - , byte_lookup_table_byte_lengths(il[105]) - , byte_lookup_table_in_tags(il[106]) - , byte_lookup_table_input_a(il[107]) - , byte_lookup_table_input_b(il[108]) - , byte_lookup_table_op_id(il[109]) - , byte_lookup_table_output(il[110]) - , conversion_clk(il[111]) - , conversion_input(il[112]) - , conversion_num_limbs(il[113]) - , conversion_radix(il[114]) - , conversion_sel_to_radix_le(il[115]) - , gas_da_gas_fixed_table(il[116]) - , gas_l2_gas_fixed_table(il[117]) - , gas_sel_gas_cost(il[118]) - , keccakf1600_clk(il[119]) - , keccakf1600_input(il[120]) - , keccakf1600_output(il[121]) - , keccakf1600_sel_keccakf1600(il[122]) - , kernel_emit_l2_to_l1_msg_write_offset(il[123]) - , kernel_emit_note_hash_write_offset(il[124]) - , kernel_emit_nullifier_write_offset(il[125]) - , kernel_emit_unencrypted_log_write_offset(il[126]) - , kernel_kernel_in_offset(il[127]) - , kernel_kernel_out_offset(il[128]) - , kernel_l1_to_l2_msg_exists_write_offset(il[129]) - , kernel_note_hash_exist_write_offset(il[130]) - , kernel_nullifier_exists_write_offset(il[131]) - , kernel_nullifier_non_exists_write_offset(il[132]) - , kernel_q_public_input_kernel_add_to_table(il[133]) - , kernel_q_public_input_kernel_out_add_to_table(il[134]) - , kernel_side_effect_counter(il[135]) - , kernel_sload_write_offset(il[136]) - , kernel_sstore_write_offset(il[137]) - , main_abs_da_rem_gas_hi(il[138]) - , main_abs_da_rem_gas_lo(il[139]) - , main_abs_l2_rem_gas_hi(il[140]) - , main_abs_l2_rem_gas_lo(il[141]) - , main_alu_in_tag(il[142]) - , main_bin_op_id(il[143]) - , main_call_ptr(il[144]) - , main_da_gas_op_cost(il[145]) - , main_da_gas_remaining(il[146]) - , main_da_out_of_gas(il[147]) - , main_ia(il[148]) - , main_ib(il[149]) - , main_ic(il[150]) - , main_id(il[151]) - , main_id_zero(il[152]) - , main_ind_addr_a(il[153]) - , main_ind_addr_b(il[154]) - , main_ind_addr_c(il[155]) - , main_ind_addr_d(il[156]) - , main_internal_return_ptr(il[157]) - , main_inv(il[158]) - , main_l2_gas_op_cost(il[159]) - , main_l2_gas_remaining(il[160]) - , main_l2_out_of_gas(il[161]) - , main_mem_addr_a(il[162]) - , main_mem_addr_b(il[163]) - , main_mem_addr_c(il[164]) - , main_mem_addr_d(il[165]) - , main_op_err(il[166]) - , main_opcode_val(il[167]) - , main_pc(il[168]) - , main_r_in_tag(il[169]) - , main_rwa(il[170]) - , main_rwb(il[171]) - , main_rwc(il[172]) - , main_rwd(il[173]) - , main_sel_alu(il[174]) - , main_sel_bin(il[175]) - , main_sel_calldata(il[176]) - , main_sel_gas_accounting_active(il[177]) - , main_sel_last(il[178]) - , main_sel_mem_op_a(il[179]) - , main_sel_mem_op_activate_gas(il[180]) - , main_sel_mem_op_b(il[181]) - , main_sel_mem_op_c(il[182]) - , main_sel_mem_op_d(il[183]) - , main_sel_mov_ia_to_ic(il[184]) - , main_sel_mov_ib_to_ic(il[185]) - , main_sel_op_add(il[186]) - , main_sel_op_address(il[187]) - , main_sel_op_and(il[188]) - , main_sel_op_block_number(il[189]) - , main_sel_op_calldata_copy(il[190]) - , main_sel_op_cast(il[191]) - , main_sel_op_chain_id(il[192]) - , main_sel_op_cmov(il[193]) - , main_sel_op_coinbase(il[194]) - , main_sel_op_dagasleft(il[195]) - , main_sel_op_div(il[196]) - , main_sel_op_emit_l2_to_l1_msg(il[197]) - , main_sel_op_emit_note_hash(il[198]) - , main_sel_op_emit_nullifier(il[199]) - , main_sel_op_emit_unencrypted_log(il[200]) - , main_sel_op_eq(il[201]) - , main_sel_op_external_call(il[202]) - , main_sel_op_external_return(il[203]) - , main_sel_op_fdiv(il[204]) - , main_sel_op_fee_per_da_gas(il[205]) - , main_sel_op_fee_per_l2_gas(il[206]) - , main_sel_op_function_selector(il[207]) - , main_sel_op_get_contract_instance(il[208]) - , main_sel_op_halt(il[209]) - , main_sel_op_internal_call(il[210]) - , main_sel_op_internal_return(il[211]) - , main_sel_op_jump(il[212]) - , main_sel_op_jumpi(il[213]) - , main_sel_op_keccak(il[214]) - , main_sel_op_l1_to_l2_msg_exists(il[215]) - , main_sel_op_l2gasleft(il[216]) - , main_sel_op_lt(il[217]) - , main_sel_op_lte(il[218]) - , main_sel_op_mov(il[219]) - , main_sel_op_mul(il[220]) - , main_sel_op_not(il[221]) - , main_sel_op_note_hash_exists(il[222]) - , main_sel_op_nullifier_exists(il[223]) - , main_sel_op_or(il[224]) - , main_sel_op_pedersen(il[225]) - , main_sel_op_poseidon2(il[226]) - , main_sel_op_radix_le(il[227]) - , main_sel_op_sender(il[228]) - , main_sel_op_sha256(il[229]) - , main_sel_op_shl(il[230]) - , main_sel_op_shr(il[231]) - , main_sel_op_sload(il[232]) - , main_sel_op_sstore(il[233]) - , main_sel_op_storage_address(il[234]) - , main_sel_op_sub(il[235]) - , main_sel_op_timestamp(il[236]) - , main_sel_op_transaction_fee(il[237]) - , main_sel_op_version(il[238]) - , main_sel_op_xor(il[239]) - , main_sel_q_kernel_lookup(il[240]) - , main_sel_q_kernel_output_lookup(il[241]) - , main_sel_resolve_ind_addr_a(il[242]) - , main_sel_resolve_ind_addr_b(il[243]) - , main_sel_resolve_ind_addr_c(il[244]) - , main_sel_resolve_ind_addr_d(il[245]) - , main_sel_returndata(il[246]) - , main_sel_rng_16(il[247]) - , main_sel_rng_8(il[248]) - , main_sel_slice_gadget(il[249]) - , main_space_id(il[250]) - , main_tag_err(il[251]) - , main_w_in_tag(il[252]) - , mem_addr(il[253]) - , mem_clk(il[254]) - , mem_diff_hi(il[255]) - , mem_diff_lo(il[256]) - , mem_diff_mid(il[257]) - , mem_glob_addr(il[258]) - , mem_last(il[259]) - , mem_lastAccess(il[260]) - , mem_one_min_inv(il[261]) - , mem_r_in_tag(il[262]) - , mem_rw(il[263]) - , mem_sel_mem(il[264]) - , mem_sel_mov_ia_to_ic(il[265]) - , mem_sel_mov_ib_to_ic(il[266]) - , mem_sel_op_a(il[267]) - , mem_sel_op_b(il[268]) - , mem_sel_op_c(il[269]) - , mem_sel_op_cmov(il[270]) - , mem_sel_op_d(il[271]) - , mem_sel_op_gadget_a(il[272]) - , mem_sel_op_gadget_b(il[273]) - , mem_sel_op_gadget_c(il[274]) - , mem_sel_op_gadget_d(il[275]) - , mem_sel_op_slice(il[276]) - , mem_sel_resolve_ind_addr_a(il[277]) - , mem_sel_resolve_ind_addr_b(il[278]) - , mem_sel_resolve_ind_addr_c(il[279]) - , mem_sel_resolve_ind_addr_d(il[280]) - , mem_sel_rng_chk(il[281]) - , mem_skip_check_tag(il[282]) - , mem_space_id(il[283]) - , mem_tag(il[284]) - , mem_tag_err(il[285]) - , mem_tsp(il[286]) - , mem_val(il[287]) - , mem_w_in_tag(il[288]) - , pedersen_clk(il[289]) - , pedersen_input(il[290]) - , pedersen_output(il[291]) - , pedersen_sel_pedersen(il[292]) - , poseidon2_B_10_0(il[293]) - , poseidon2_B_10_1(il[294]) - , poseidon2_B_10_2(il[295]) - , poseidon2_B_10_3(il[296]) - , poseidon2_B_11_0(il[297]) - , poseidon2_B_11_1(il[298]) - , poseidon2_B_11_2(il[299]) - , poseidon2_B_11_3(il[300]) - , poseidon2_B_12_0(il[301]) - , poseidon2_B_12_1(il[302]) - , poseidon2_B_12_2(il[303]) - , poseidon2_B_12_3(il[304]) - , poseidon2_B_13_0(il[305]) - , poseidon2_B_13_1(il[306]) - , poseidon2_B_13_2(il[307]) - , poseidon2_B_13_3(il[308]) - , poseidon2_B_14_0(il[309]) - , poseidon2_B_14_1(il[310]) - , poseidon2_B_14_2(il[311]) - , poseidon2_B_14_3(il[312]) - , poseidon2_B_15_0(il[313]) - , poseidon2_B_15_1(il[314]) - , poseidon2_B_15_2(il[315]) - , poseidon2_B_15_3(il[316]) - , poseidon2_B_16_0(il[317]) - , poseidon2_B_16_1(il[318]) - , poseidon2_B_16_2(il[319]) - , poseidon2_B_16_3(il[320]) - , poseidon2_B_17_0(il[321]) - , poseidon2_B_17_1(il[322]) - , poseidon2_B_17_2(il[323]) - , poseidon2_B_17_3(il[324]) - , poseidon2_B_18_0(il[325]) - , poseidon2_B_18_1(il[326]) - , poseidon2_B_18_2(il[327]) - , poseidon2_B_18_3(il[328]) - , poseidon2_B_19_0(il[329]) - , poseidon2_B_19_1(il[330]) - , poseidon2_B_19_2(il[331]) - , poseidon2_B_19_3(il[332]) - , poseidon2_B_20_0(il[333]) - , poseidon2_B_20_1(il[334]) - , poseidon2_B_20_2(il[335]) - , poseidon2_B_20_3(il[336]) - , poseidon2_B_21_0(il[337]) - , poseidon2_B_21_1(il[338]) - , poseidon2_B_21_2(il[339]) - , poseidon2_B_21_3(il[340]) - , poseidon2_B_22_0(il[341]) - , poseidon2_B_22_1(il[342]) - , poseidon2_B_22_2(il[343]) - , poseidon2_B_22_3(il[344]) - , poseidon2_B_23_0(il[345]) - , poseidon2_B_23_1(il[346]) - , poseidon2_B_23_2(il[347]) - , poseidon2_B_23_3(il[348]) - , poseidon2_B_24_0(il[349]) - , poseidon2_B_24_1(il[350]) - , poseidon2_B_24_2(il[351]) - , poseidon2_B_24_3(il[352]) - , poseidon2_B_25_0(il[353]) - , poseidon2_B_25_1(il[354]) - , poseidon2_B_25_2(il[355]) - , poseidon2_B_25_3(il[356]) - , poseidon2_B_26_0(il[357]) - , poseidon2_B_26_1(il[358]) - , poseidon2_B_26_2(il[359]) - , poseidon2_B_26_3(il[360]) - , poseidon2_B_27_0(il[361]) - , poseidon2_B_27_1(il[362]) - , poseidon2_B_27_2(il[363]) - , poseidon2_B_27_3(il[364]) - , poseidon2_B_28_0(il[365]) - , poseidon2_B_28_1(il[366]) - , poseidon2_B_28_2(il[367]) - , poseidon2_B_28_3(il[368]) - , poseidon2_B_29_0(il[369]) - , poseidon2_B_29_1(il[370]) - , poseidon2_B_29_2(il[371]) - , poseidon2_B_29_3(il[372]) - , poseidon2_B_30_0(il[373]) - , poseidon2_B_30_1(il[374]) - , poseidon2_B_30_2(il[375]) - , poseidon2_B_30_3(il[376]) - , poseidon2_B_31_0(il[377]) - , poseidon2_B_31_1(il[378]) - , poseidon2_B_31_2(il[379]) - , poseidon2_B_31_3(il[380]) - , poseidon2_B_32_0(il[381]) - , poseidon2_B_32_1(il[382]) - , poseidon2_B_32_2(il[383]) - , poseidon2_B_32_3(il[384]) - , poseidon2_B_33_0(il[385]) - , poseidon2_B_33_1(il[386]) - , poseidon2_B_33_2(il[387]) - , poseidon2_B_33_3(il[388]) - , poseidon2_B_34_0(il[389]) - , poseidon2_B_34_1(il[390]) - , poseidon2_B_34_2(il[391]) - , poseidon2_B_34_3(il[392]) - , poseidon2_B_35_0(il[393]) - , poseidon2_B_35_1(il[394]) - , poseidon2_B_35_2(il[395]) - , poseidon2_B_35_3(il[396]) - , poseidon2_B_36_0(il[397]) - , poseidon2_B_36_1(il[398]) - , poseidon2_B_36_2(il[399]) - , poseidon2_B_36_3(il[400]) - , poseidon2_B_37_0(il[401]) - , poseidon2_B_37_1(il[402]) - , poseidon2_B_37_2(il[403]) - , poseidon2_B_37_3(il[404]) - , poseidon2_B_38_0(il[405]) - , poseidon2_B_38_1(il[406]) - , poseidon2_B_38_2(il[407]) - , poseidon2_B_38_3(il[408]) - , poseidon2_B_39_0(il[409]) - , poseidon2_B_39_1(il[410]) - , poseidon2_B_39_2(il[411]) - , poseidon2_B_39_3(il[412]) - , poseidon2_B_40_0(il[413]) - , poseidon2_B_40_1(il[414]) - , poseidon2_B_40_2(il[415]) - , poseidon2_B_40_3(il[416]) - , poseidon2_B_41_0(il[417]) - , poseidon2_B_41_1(il[418]) - , poseidon2_B_41_2(il[419]) - , poseidon2_B_41_3(il[420]) - , poseidon2_B_42_0(il[421]) - , poseidon2_B_42_1(il[422]) - , poseidon2_B_42_2(il[423]) - , poseidon2_B_42_3(il[424]) - , poseidon2_B_43_0(il[425]) - , poseidon2_B_43_1(il[426]) - , poseidon2_B_43_2(il[427]) - , poseidon2_B_43_3(il[428]) - , poseidon2_B_44_0(il[429]) - , poseidon2_B_44_1(il[430]) - , poseidon2_B_44_2(il[431]) - , poseidon2_B_44_3(il[432]) - , poseidon2_B_45_0(il[433]) - , poseidon2_B_45_1(il[434]) - , poseidon2_B_45_2(il[435]) - , poseidon2_B_45_3(il[436]) - , poseidon2_B_46_0(il[437]) - , poseidon2_B_46_1(il[438]) - , poseidon2_B_46_2(il[439]) - , poseidon2_B_46_3(il[440]) - , poseidon2_B_47_0(il[441]) - , poseidon2_B_47_1(il[442]) - , poseidon2_B_47_2(il[443]) - , poseidon2_B_47_3(il[444]) - , poseidon2_B_48_0(il[445]) - , poseidon2_B_48_1(il[446]) - , poseidon2_B_48_2(il[447]) - , poseidon2_B_48_3(il[448]) - , poseidon2_B_49_0(il[449]) - , poseidon2_B_49_1(il[450]) - , poseidon2_B_49_2(il[451]) - , poseidon2_B_49_3(il[452]) - , poseidon2_B_4_0(il[453]) - , poseidon2_B_4_1(il[454]) - , poseidon2_B_4_2(il[455]) - , poseidon2_B_4_3(il[456]) - , poseidon2_B_50_0(il[457]) - , poseidon2_B_50_1(il[458]) - , poseidon2_B_50_2(il[459]) - , poseidon2_B_50_3(il[460]) - , poseidon2_B_51_0(il[461]) - , poseidon2_B_51_1(il[462]) - , poseidon2_B_51_2(il[463]) - , poseidon2_B_51_3(il[464]) - , poseidon2_B_52_0(il[465]) - , poseidon2_B_52_1(il[466]) - , poseidon2_B_52_2(il[467]) - , poseidon2_B_52_3(il[468]) - , poseidon2_B_53_0(il[469]) - , poseidon2_B_53_1(il[470]) - , poseidon2_B_53_2(il[471]) - , poseidon2_B_53_3(il[472]) - , poseidon2_B_54_0(il[473]) - , poseidon2_B_54_1(il[474]) - , poseidon2_B_54_2(il[475]) - , poseidon2_B_54_3(il[476]) - , poseidon2_B_55_0(il[477]) - , poseidon2_B_55_1(il[478]) - , poseidon2_B_55_2(il[479]) - , poseidon2_B_55_3(il[480]) - , poseidon2_B_56_0(il[481]) - , poseidon2_B_56_1(il[482]) - , poseidon2_B_56_2(il[483]) - , poseidon2_B_56_3(il[484]) - , poseidon2_B_57_0(il[485]) - , poseidon2_B_57_1(il[486]) - , poseidon2_B_57_2(il[487]) - , poseidon2_B_57_3(il[488]) - , poseidon2_B_58_0(il[489]) - , poseidon2_B_58_1(il[490]) - , poseidon2_B_58_2(il[491]) - , poseidon2_B_58_3(il[492]) - , poseidon2_B_59_0(il[493]) - , poseidon2_B_59_1(il[494]) - , poseidon2_B_59_2(il[495]) - , poseidon2_B_59_3(il[496]) - , poseidon2_B_5_0(il[497]) - , poseidon2_B_5_1(il[498]) - , poseidon2_B_5_2(il[499]) - , poseidon2_B_5_3(il[500]) - , poseidon2_B_6_0(il[501]) - , poseidon2_B_6_1(il[502]) - , poseidon2_B_6_2(il[503]) - , poseidon2_B_6_3(il[504]) - , poseidon2_B_7_0(il[505]) - , poseidon2_B_7_1(il[506]) - , poseidon2_B_7_2(il[507]) - , poseidon2_B_7_3(il[508]) - , poseidon2_B_8_0(il[509]) - , poseidon2_B_8_1(il[510]) - , poseidon2_B_8_2(il[511]) - , poseidon2_B_8_3(il[512]) - , poseidon2_B_9_0(il[513]) - , poseidon2_B_9_1(il[514]) - , poseidon2_B_9_2(il[515]) - , poseidon2_B_9_3(il[516]) - , poseidon2_EXT_LAYER_4(il[517]) - , poseidon2_EXT_LAYER_5(il[518]) - , poseidon2_EXT_LAYER_6(il[519]) - , poseidon2_EXT_LAYER_7(il[520]) - , poseidon2_T_0_4(il[521]) - , poseidon2_T_0_5(il[522]) - , poseidon2_T_0_6(il[523]) - , poseidon2_T_0_7(il[524]) - , poseidon2_T_1_4(il[525]) - , poseidon2_T_1_5(il[526]) - , poseidon2_T_1_6(il[527]) - , poseidon2_T_1_7(il[528]) - , poseidon2_T_2_4(il[529]) - , poseidon2_T_2_5(il[530]) - , poseidon2_T_2_6(il[531]) - , poseidon2_T_2_7(il[532]) - , poseidon2_T_3_4(il[533]) - , poseidon2_T_3_5(il[534]) - , poseidon2_T_3_6(il[535]) - , poseidon2_T_3_7(il[536]) - , poseidon2_T_60_4(il[537]) - , poseidon2_T_60_5(il[538]) - , poseidon2_T_60_6(il[539]) - , poseidon2_T_60_7(il[540]) - , poseidon2_T_61_4(il[541]) - , poseidon2_T_61_5(il[542]) - , poseidon2_T_61_6(il[543]) - , poseidon2_T_61_7(il[544]) - , poseidon2_T_62_4(il[545]) - , poseidon2_T_62_5(il[546]) - , poseidon2_T_62_6(il[547]) - , poseidon2_T_62_7(il[548]) - , poseidon2_T_63_4(il[549]) - , poseidon2_T_63_5(il[550]) - , poseidon2_T_63_6(il[551]) - , poseidon2_T_63_7(il[552]) - , poseidon2_a_0(il[553]) - , poseidon2_a_1(il[554]) - , poseidon2_a_2(il[555]) - , poseidon2_a_3(il[556]) - , poseidon2_b_0(il[557]) - , poseidon2_b_1(il[558]) - , poseidon2_b_2(il[559]) - , poseidon2_b_3(il[560]) - , poseidon2_clk(il[561]) - , poseidon2_in_tag(il[562]) - , poseidon2_input_addr(il[563]) - , poseidon2_mem_addr_a(il[564]) - , poseidon2_mem_addr_b(il[565]) - , poseidon2_mem_addr_c(il[566]) - , poseidon2_mem_addr_d(il[567]) - , poseidon2_mem_op(il[568]) - , poseidon2_output_addr(il[569]) - , poseidon2_read_line(il[570]) - , poseidon2_sel_poseidon_perm(il[571]) - , poseidon2_write_line(il[572]) - , powers_power_of_2(il[573]) - , sha256_clk(il[574]) - , sha256_input(il[575]) - , sha256_output(il[576]) - , sha256_sel_sha256_compression(il[577]) - , sha256_state(il[578]) - , slice_addr(il[579]) - , slice_clk(il[580]) - , slice_cnt(il[581]) - , slice_col_offset(il[582]) - , slice_one_min_inv(il[583]) - , slice_sel_cd_cpy(il[584]) - , slice_sel_mem_active(il[585]) - , slice_sel_return(il[586]) - , slice_sel_start(il[587]) - , slice_space_id(il[588]) - , slice_val(il[589]) - , lookup_byte_lengths_counts(il[590]) - , lookup_byte_operations_counts(il[591]) - , lookup_cd_value_counts(il[592]) - , lookup_ret_value_counts(il[593]) - , lookup_opcode_gas_counts(il[594]) - , range_check_l2_gas_hi_counts(il[595]) - , range_check_l2_gas_lo_counts(il[596]) - , range_check_da_gas_hi_counts(il[597]) - , range_check_da_gas_lo_counts(il[598]) - , kernel_output_lookup_counts(il[599]) - , lookup_into_kernel_counts(il[600]) - , incl_main_tag_err_counts(il[601]) - , incl_mem_tag_err_counts(il[602]) - , lookup_mem_rng_chk_lo_counts(il[603]) - , lookup_mem_rng_chk_mid_counts(il[604]) - , lookup_mem_rng_chk_hi_counts(il[605]) - , lookup_pow_2_0_counts(il[606]) - , lookup_pow_2_1_counts(il[607]) - , lookup_u8_0_counts(il[608]) - , lookup_u8_1_counts(il[609]) - , lookup_u16_0_counts(il[610]) - , lookup_u16_1_counts(il[611]) - , lookup_u16_2_counts(il[612]) - , lookup_u16_3_counts(il[613]) - , lookup_u16_4_counts(il[614]) - , lookup_u16_5_counts(il[615]) - , lookup_u16_6_counts(il[616]) - , lookup_u16_7_counts(il[617]) - , lookup_u16_8_counts(il[618]) - , lookup_u16_9_counts(il[619]) - , lookup_u16_10_counts(il[620]) - , lookup_u16_11_counts(il[621]) - , lookup_u16_12_counts(il[622]) - , lookup_u16_13_counts(il[623]) - , lookup_u16_14_counts(il[624]) - , lookup_div_u16_0_counts(il[625]) - , lookup_div_u16_1_counts(il[626]) - , lookup_div_u16_2_counts(il[627]) - , lookup_div_u16_3_counts(il[628]) - , lookup_div_u16_4_counts(il[629]) - , lookup_div_u16_5_counts(il[630]) - , lookup_div_u16_6_counts(il[631]) - , lookup_div_u16_7_counts(il[632]) - , perm_pos_mem_a(il[633]) - , perm_pos_mem_b(il[634]) - , perm_pos_mem_c(il[635]) - , perm_pos_mem_d(il[636]) - , perm_slice_mem(il[637]) - , perm_main_alu(il[638]) - , perm_main_bin(il[639]) - , perm_main_conv(il[640]) - , perm_main_pos2_perm(il[641]) - , perm_main_pedersen(il[642]) - , perm_main_slice(il[643]) - , perm_main_mem_a(il[644]) - , perm_main_mem_b(il[645]) - , perm_main_mem_c(il[646]) - , perm_main_mem_d(il[647]) - , perm_main_mem_ind_addr_a(il[648]) - , perm_main_mem_ind_addr_b(il[649]) - , perm_main_mem_ind_addr_c(il[650]) - , perm_main_mem_ind_addr_d(il[651]) - , lookup_byte_lengths(il[652]) - , lookup_byte_operations(il[653]) - , lookup_cd_value(il[654]) - , lookup_ret_value(il[655]) - , lookup_opcode_gas(il[656]) - , range_check_l2_gas_hi(il[657]) - , range_check_l2_gas_lo(il[658]) - , range_check_da_gas_hi(il[659]) - , range_check_da_gas_lo(il[660]) - , kernel_output_lookup(il[661]) - , lookup_into_kernel(il[662]) - , incl_main_tag_err(il[663]) - , incl_mem_tag_err(il[664]) - , lookup_mem_rng_chk_lo(il[665]) - , lookup_mem_rng_chk_mid(il[666]) - , lookup_mem_rng_chk_hi(il[667]) - , lookup_pow_2_0(il[668]) - , lookup_pow_2_1(il[669]) - , lookup_u8_0(il[670]) - , lookup_u8_1(il[671]) - , lookup_u16_0(il[672]) - , lookup_u16_1(il[673]) - , lookup_u16_2(il[674]) - , lookup_u16_3(il[675]) - , lookup_u16_4(il[676]) - , lookup_u16_5(il[677]) - , lookup_u16_6(il[678]) - , lookup_u16_7(il[679]) - , lookup_u16_8(il[680]) - , lookup_u16_9(il[681]) - , lookup_u16_10(il[682]) - , lookup_u16_11(il[683]) - , lookup_u16_12(il[684]) - , lookup_u16_13(il[685]) - , lookup_u16_14(il[686]) - , lookup_div_u16_0(il[687]) - , lookup_div_u16_1(il[688]) - , lookup_div_u16_2(il[689]) - , lookup_div_u16_3(il[690]) - , lookup_div_u16_4(il[691]) - , lookup_div_u16_5(il[692]) - , lookup_div_u16_6(il[693]) - , lookup_div_u16_7(il[694]) - , alu_a_hi_shift(il[695]) - , alu_a_lo_shift(il[696]) - , alu_b_hi_shift(il[697]) - , alu_b_lo_shift(il[698]) - , alu_cmp_rng_ctr_shift(il[699]) - , alu_div_u16_r0_shift(il[700]) - , alu_div_u16_r1_shift(il[701]) - , alu_div_u16_r2_shift(il[702]) - , alu_div_u16_r3_shift(il[703]) - , alu_div_u16_r4_shift(il[704]) - , alu_div_u16_r5_shift(il[705]) - , alu_div_u16_r6_shift(il[706]) - , alu_div_u16_r7_shift(il[707]) - , alu_op_add_shift(il[708]) - , alu_op_cast_prev_shift(il[709]) - , alu_op_cast_shift(il[710]) - , alu_op_div_shift(il[711]) - , alu_op_mul_shift(il[712]) - , alu_op_shl_shift(il[713]) - , alu_op_shr_shift(il[714]) - , alu_op_sub_shift(il[715]) - , alu_p_sub_a_hi_shift(il[716]) - , alu_p_sub_a_lo_shift(il[717]) - , alu_p_sub_b_hi_shift(il[718]) - , alu_p_sub_b_lo_shift(il[719]) - , alu_sel_alu_shift(il[720]) - , alu_sel_cmp_shift(il[721]) - , alu_sel_div_rng_chk_shift(il[722]) - , alu_sel_rng_chk_lookup_shift(il[723]) - , alu_sel_rng_chk_shift(il[724]) - , alu_u16_r0_shift(il[725]) - , alu_u16_r1_shift(il[726]) - , alu_u16_r2_shift(il[727]) - , alu_u16_r3_shift(il[728]) - , alu_u16_r4_shift(il[729]) - , alu_u16_r5_shift(il[730]) - , alu_u16_r6_shift(il[731]) - , alu_u8_r0_shift(il[732]) - , alu_u8_r1_shift(il[733]) - , binary_acc_ia_shift(il[734]) - , binary_acc_ib_shift(il[735]) - , binary_acc_ic_shift(il[736]) - , binary_mem_tag_ctr_shift(il[737]) - , binary_op_id_shift(il[738]) - , kernel_emit_l2_to_l1_msg_write_offset_shift(il[739]) - , kernel_emit_note_hash_write_offset_shift(il[740]) - , kernel_emit_nullifier_write_offset_shift(il[741]) - , kernel_emit_unencrypted_log_write_offset_shift(il[742]) - , kernel_l1_to_l2_msg_exists_write_offset_shift(il[743]) - , kernel_note_hash_exist_write_offset_shift(il[744]) - , kernel_nullifier_exists_write_offset_shift(il[745]) - , kernel_nullifier_non_exists_write_offset_shift(il[746]) - , kernel_side_effect_counter_shift(il[747]) - , kernel_sload_write_offset_shift(il[748]) - , kernel_sstore_write_offset_shift(il[749]) - , main_da_gas_remaining_shift(il[750]) - , main_internal_return_ptr_shift(il[751]) - , main_l2_gas_remaining_shift(il[752]) - , main_pc_shift(il[753]) - , mem_glob_addr_shift(il[754]) - , mem_rw_shift(il[755]) - , mem_sel_mem_shift(il[756]) - , mem_tag_shift(il[757]) - , mem_tsp_shift(il[758]) - , mem_val_shift(il[759]) - , poseidon2_a_0_shift(il[760]) - , poseidon2_a_1_shift(il[761]) - , poseidon2_a_2_shift(il[762]) - , poseidon2_a_3_shift(il[763]) - , poseidon2_sel_poseidon_perm_shift(il[764]) - , poseidon2_write_line_shift(il[765]) - , slice_addr_shift(il[766]) - , slice_clk_shift(il[767]) - , slice_cnt_shift(il[768]) - , slice_col_offset_shift(il[769]) - , slice_sel_cd_cpy_shift(il[770]) - , slice_sel_mem_active_shift(il[771]) - , slice_sel_return_shift(il[772]) - , slice_sel_start_shift(il[773]) - , slice_space_id_shift(il[774]) - {} - }; - - /** - * @brief A container for the prover polynomials handles. - */ - class ProverPolynomials : public AllEntities { - public: - // Define all operations as default, except copy construction/assignment - ProverPolynomials() = default; - ProverPolynomials& operator=(const ProverPolynomials&) = delete; - ProverPolynomials(const ProverPolynomials& o) = delete; - ProverPolynomials(ProverPolynomials&& o) noexcept = default; - ProverPolynomials& operator=(ProverPolynomials&& o) noexcept = default; - ~ProverPolynomials() = default; - - ProverPolynomials(ProvingKey& proving_key) - { - for (auto [prover_poly, key_poly] : zip_view(this->get_unshifted(), proving_key.get_all())) { - ASSERT(flavor_get_label(*this, prover_poly) == flavor_get_label(proving_key, key_poly)); - prover_poly = key_poly.share(); - } - for (auto [prover_poly, key_poly] : zip_view(this->get_shifted(), proving_key.get_to_be_shifted())) { - ASSERT(flavor_get_label(*this, prover_poly) == (flavor_get_label(proving_key, key_poly) + "_shift")); - prover_poly = key_poly.shifted(); - } - } - - [[nodiscard]] size_t get_polynomial_size() const { return kernel_kernel_inputs.size(); } - /** - * @brief Returns the evaluations of all prover polynomials at one point on the boolean hypercube, which - * represents one row in the execution trace. - */ - [[nodiscard]] AllConstRefValues get_row(size_t row_idx) const - { - return AllConstRefValues(RefArray{ main_clk[row_idx], - main_sel_first[row_idx], - kernel_kernel_inputs[row_idx], - kernel_kernel_value_out[row_idx], - kernel_kernel_side_effect_out[row_idx], - kernel_kernel_metadata_out[row_idx], - main_calldata[row_idx], - main_returndata[row_idx], - alu_a_hi[row_idx], - alu_a_lo[row_idx], - alu_b_hi[row_idx], - alu_b_lo[row_idx], - alu_borrow[row_idx], - alu_cf[row_idx], - alu_clk[row_idx], - alu_cmp_rng_ctr[row_idx], - alu_div_u16_r0[row_idx], - alu_div_u16_r1[row_idx], - alu_div_u16_r2[row_idx], - alu_div_u16_r3[row_idx], - alu_div_u16_r4[row_idx], - alu_div_u16_r5[row_idx], - alu_div_u16_r6[row_idx], - alu_div_u16_r7[row_idx], - alu_divisor_hi[row_idx], - alu_divisor_lo[row_idx], - alu_ff_tag[row_idx], - alu_ia[row_idx], - alu_ib[row_idx], - alu_ic[row_idx], - alu_in_tag[row_idx], - alu_op_add[row_idx], - alu_op_cast[row_idx], - alu_op_cast_prev[row_idx], - alu_op_div[row_idx], - alu_op_div_a_lt_b[row_idx], - alu_op_div_std[row_idx], - alu_op_eq[row_idx], - alu_op_eq_diff_inv[row_idx], - alu_op_lt[row_idx], - alu_op_lte[row_idx], - alu_op_mul[row_idx], - alu_op_not[row_idx], - alu_op_shl[row_idx], - alu_op_shr[row_idx], - alu_op_sub[row_idx], - alu_p_a_borrow[row_idx], - alu_p_b_borrow[row_idx], - alu_p_sub_a_hi[row_idx], - alu_p_sub_a_lo[row_idx], - alu_p_sub_b_hi[row_idx], - alu_p_sub_b_lo[row_idx], - alu_partial_prod_hi[row_idx], - alu_partial_prod_lo[row_idx], - alu_quotient_hi[row_idx], - alu_quotient_lo[row_idx], - alu_remainder[row_idx], - alu_res_hi[row_idx], - alu_res_lo[row_idx], - alu_sel_alu[row_idx], - alu_sel_cmp[row_idx], - alu_sel_div_rng_chk[row_idx], - alu_sel_rng_chk[row_idx], - alu_sel_rng_chk_lookup[row_idx], - alu_sel_shift_which[row_idx], - alu_shift_lt_bit_len[row_idx], - alu_t_sub_s_bits[row_idx], - alu_two_pow_s[row_idx], - alu_two_pow_t_sub_s[row_idx], - alu_u128_tag[row_idx], - alu_u16_r0[row_idx], - alu_u16_r1[row_idx], - alu_u16_r10[row_idx], - alu_u16_r11[row_idx], - alu_u16_r12[row_idx], - alu_u16_r13[row_idx], - alu_u16_r14[row_idx], - alu_u16_r2[row_idx], - alu_u16_r3[row_idx], - alu_u16_r4[row_idx], - alu_u16_r5[row_idx], - alu_u16_r6[row_idx], - alu_u16_r7[row_idx], - alu_u16_r8[row_idx], - alu_u16_r9[row_idx], - alu_u16_tag[row_idx], - alu_u32_tag[row_idx], - alu_u64_tag[row_idx], - alu_u8_r0[row_idx], - alu_u8_r1[row_idx], - alu_u8_tag[row_idx], - binary_acc_ia[row_idx], - binary_acc_ib[row_idx], - binary_acc_ic[row_idx], - binary_clk[row_idx], - binary_ia_bytes[row_idx], - binary_ib_bytes[row_idx], - binary_ic_bytes[row_idx], - binary_in_tag[row_idx], - binary_mem_tag_ctr[row_idx], - binary_mem_tag_ctr_inv[row_idx], - binary_op_id[row_idx], - binary_sel_bin[row_idx], - binary_start[row_idx], - byte_lookup_sel_bin[row_idx], - byte_lookup_table_byte_lengths[row_idx], - byte_lookup_table_in_tags[row_idx], - byte_lookup_table_input_a[row_idx], - byte_lookup_table_input_b[row_idx], - byte_lookup_table_op_id[row_idx], - byte_lookup_table_output[row_idx], - conversion_clk[row_idx], - conversion_input[row_idx], - conversion_num_limbs[row_idx], - conversion_radix[row_idx], - conversion_sel_to_radix_le[row_idx], - gas_da_gas_fixed_table[row_idx], - gas_l2_gas_fixed_table[row_idx], - gas_sel_gas_cost[row_idx], - keccakf1600_clk[row_idx], - keccakf1600_input[row_idx], - keccakf1600_output[row_idx], - keccakf1600_sel_keccakf1600[row_idx], - kernel_emit_l2_to_l1_msg_write_offset[row_idx], - kernel_emit_note_hash_write_offset[row_idx], - kernel_emit_nullifier_write_offset[row_idx], - kernel_emit_unencrypted_log_write_offset[row_idx], - kernel_kernel_in_offset[row_idx], - kernel_kernel_out_offset[row_idx], - kernel_l1_to_l2_msg_exists_write_offset[row_idx], - kernel_note_hash_exist_write_offset[row_idx], - kernel_nullifier_exists_write_offset[row_idx], - kernel_nullifier_non_exists_write_offset[row_idx], - kernel_q_public_input_kernel_add_to_table[row_idx], - kernel_q_public_input_kernel_out_add_to_table[row_idx], - kernel_side_effect_counter[row_idx], - kernel_sload_write_offset[row_idx], - kernel_sstore_write_offset[row_idx], - main_abs_da_rem_gas_hi[row_idx], - main_abs_da_rem_gas_lo[row_idx], - main_abs_l2_rem_gas_hi[row_idx], - main_abs_l2_rem_gas_lo[row_idx], - main_alu_in_tag[row_idx], - main_bin_op_id[row_idx], - main_call_ptr[row_idx], - main_da_gas_op_cost[row_idx], - main_da_gas_remaining[row_idx], - main_da_out_of_gas[row_idx], - main_ia[row_idx], - main_ib[row_idx], - main_ic[row_idx], - main_id[row_idx], - main_id_zero[row_idx], - main_ind_addr_a[row_idx], - main_ind_addr_b[row_idx], - main_ind_addr_c[row_idx], - main_ind_addr_d[row_idx], - main_internal_return_ptr[row_idx], - main_inv[row_idx], - main_l2_gas_op_cost[row_idx], - main_l2_gas_remaining[row_idx], - main_l2_out_of_gas[row_idx], - main_mem_addr_a[row_idx], - main_mem_addr_b[row_idx], - main_mem_addr_c[row_idx], - main_mem_addr_d[row_idx], - main_op_err[row_idx], - main_opcode_val[row_idx], - main_pc[row_idx], - main_r_in_tag[row_idx], - main_rwa[row_idx], - main_rwb[row_idx], - main_rwc[row_idx], - main_rwd[row_idx], - main_sel_alu[row_idx], - main_sel_bin[row_idx], - main_sel_calldata[row_idx], - main_sel_gas_accounting_active[row_idx], - main_sel_last[row_idx], - main_sel_mem_op_a[row_idx], - main_sel_mem_op_activate_gas[row_idx], - main_sel_mem_op_b[row_idx], - main_sel_mem_op_c[row_idx], - main_sel_mem_op_d[row_idx], - main_sel_mov_ia_to_ic[row_idx], - main_sel_mov_ib_to_ic[row_idx], - main_sel_op_add[row_idx], - main_sel_op_address[row_idx], - main_sel_op_and[row_idx], - main_sel_op_block_number[row_idx], - main_sel_op_calldata_copy[row_idx], - main_sel_op_cast[row_idx], - main_sel_op_chain_id[row_idx], - main_sel_op_cmov[row_idx], - main_sel_op_coinbase[row_idx], - main_sel_op_dagasleft[row_idx], - main_sel_op_div[row_idx], - main_sel_op_emit_l2_to_l1_msg[row_idx], - main_sel_op_emit_note_hash[row_idx], - main_sel_op_emit_nullifier[row_idx], - main_sel_op_emit_unencrypted_log[row_idx], - main_sel_op_eq[row_idx], - main_sel_op_external_call[row_idx], - main_sel_op_external_return[row_idx], - main_sel_op_fdiv[row_idx], - main_sel_op_fee_per_da_gas[row_idx], - main_sel_op_fee_per_l2_gas[row_idx], - main_sel_op_function_selector[row_idx], - main_sel_op_get_contract_instance[row_idx], - main_sel_op_halt[row_idx], - main_sel_op_internal_call[row_idx], - main_sel_op_internal_return[row_idx], - main_sel_op_jump[row_idx], - main_sel_op_jumpi[row_idx], - main_sel_op_keccak[row_idx], - main_sel_op_l1_to_l2_msg_exists[row_idx], - main_sel_op_l2gasleft[row_idx], - main_sel_op_lt[row_idx], - main_sel_op_lte[row_idx], - main_sel_op_mov[row_idx], - main_sel_op_mul[row_idx], - main_sel_op_not[row_idx], - main_sel_op_note_hash_exists[row_idx], - main_sel_op_nullifier_exists[row_idx], - main_sel_op_or[row_idx], - main_sel_op_pedersen[row_idx], - main_sel_op_poseidon2[row_idx], - main_sel_op_radix_le[row_idx], - main_sel_op_sender[row_idx], - main_sel_op_sha256[row_idx], - main_sel_op_shl[row_idx], - main_sel_op_shr[row_idx], - main_sel_op_sload[row_idx], - main_sel_op_sstore[row_idx], - main_sel_op_storage_address[row_idx], - main_sel_op_sub[row_idx], - main_sel_op_timestamp[row_idx], - main_sel_op_transaction_fee[row_idx], - main_sel_op_version[row_idx], - main_sel_op_xor[row_idx], - main_sel_q_kernel_lookup[row_idx], - main_sel_q_kernel_output_lookup[row_idx], - main_sel_resolve_ind_addr_a[row_idx], - main_sel_resolve_ind_addr_b[row_idx], - main_sel_resolve_ind_addr_c[row_idx], - main_sel_resolve_ind_addr_d[row_idx], - main_sel_returndata[row_idx], - main_sel_rng_16[row_idx], - main_sel_rng_8[row_idx], - main_sel_slice_gadget[row_idx], - main_space_id[row_idx], - main_tag_err[row_idx], - main_w_in_tag[row_idx], - mem_addr[row_idx], - mem_clk[row_idx], - mem_diff_hi[row_idx], - mem_diff_lo[row_idx], - mem_diff_mid[row_idx], - mem_glob_addr[row_idx], - mem_last[row_idx], - mem_lastAccess[row_idx], - mem_one_min_inv[row_idx], - mem_r_in_tag[row_idx], - mem_rw[row_idx], - mem_sel_mem[row_idx], - mem_sel_mov_ia_to_ic[row_idx], - mem_sel_mov_ib_to_ic[row_idx], - mem_sel_op_a[row_idx], - mem_sel_op_b[row_idx], - mem_sel_op_c[row_idx], - mem_sel_op_cmov[row_idx], - mem_sel_op_d[row_idx], - mem_sel_op_gadget_a[row_idx], - mem_sel_op_gadget_b[row_idx], - mem_sel_op_gadget_c[row_idx], - mem_sel_op_gadget_d[row_idx], - mem_sel_op_slice[row_idx], - mem_sel_resolve_ind_addr_a[row_idx], - mem_sel_resolve_ind_addr_b[row_idx], - mem_sel_resolve_ind_addr_c[row_idx], - mem_sel_resolve_ind_addr_d[row_idx], - mem_sel_rng_chk[row_idx], - mem_skip_check_tag[row_idx], - mem_space_id[row_idx], - mem_tag[row_idx], - mem_tag_err[row_idx], - mem_tsp[row_idx], - mem_val[row_idx], - mem_w_in_tag[row_idx], - pedersen_clk[row_idx], - pedersen_input[row_idx], - pedersen_output[row_idx], - pedersen_sel_pedersen[row_idx], - poseidon2_B_10_0[row_idx], - poseidon2_B_10_1[row_idx], - poseidon2_B_10_2[row_idx], - poseidon2_B_10_3[row_idx], - poseidon2_B_11_0[row_idx], - poseidon2_B_11_1[row_idx], - poseidon2_B_11_2[row_idx], - poseidon2_B_11_3[row_idx], - poseidon2_B_12_0[row_idx], - poseidon2_B_12_1[row_idx], - poseidon2_B_12_2[row_idx], - poseidon2_B_12_3[row_idx], - poseidon2_B_13_0[row_idx], - poseidon2_B_13_1[row_idx], - poseidon2_B_13_2[row_idx], - poseidon2_B_13_3[row_idx], - poseidon2_B_14_0[row_idx], - poseidon2_B_14_1[row_idx], - poseidon2_B_14_2[row_idx], - poseidon2_B_14_3[row_idx], - poseidon2_B_15_0[row_idx], - poseidon2_B_15_1[row_idx], - poseidon2_B_15_2[row_idx], - poseidon2_B_15_3[row_idx], - poseidon2_B_16_0[row_idx], - poseidon2_B_16_1[row_idx], - poseidon2_B_16_2[row_idx], - poseidon2_B_16_3[row_idx], - poseidon2_B_17_0[row_idx], - poseidon2_B_17_1[row_idx], - poseidon2_B_17_2[row_idx], - poseidon2_B_17_3[row_idx], - poseidon2_B_18_0[row_idx], - poseidon2_B_18_1[row_idx], - poseidon2_B_18_2[row_idx], - poseidon2_B_18_3[row_idx], - poseidon2_B_19_0[row_idx], - poseidon2_B_19_1[row_idx], - poseidon2_B_19_2[row_idx], - poseidon2_B_19_3[row_idx], - poseidon2_B_20_0[row_idx], - poseidon2_B_20_1[row_idx], - poseidon2_B_20_2[row_idx], - poseidon2_B_20_3[row_idx], - poseidon2_B_21_0[row_idx], - poseidon2_B_21_1[row_idx], - poseidon2_B_21_2[row_idx], - poseidon2_B_21_3[row_idx], - poseidon2_B_22_0[row_idx], - poseidon2_B_22_1[row_idx], - poseidon2_B_22_2[row_idx], - poseidon2_B_22_3[row_idx], - poseidon2_B_23_0[row_idx], - poseidon2_B_23_1[row_idx], - poseidon2_B_23_2[row_idx], - poseidon2_B_23_3[row_idx], - poseidon2_B_24_0[row_idx], - poseidon2_B_24_1[row_idx], - poseidon2_B_24_2[row_idx], - poseidon2_B_24_3[row_idx], - poseidon2_B_25_0[row_idx], - poseidon2_B_25_1[row_idx], - poseidon2_B_25_2[row_idx], - poseidon2_B_25_3[row_idx], - poseidon2_B_26_0[row_idx], - poseidon2_B_26_1[row_idx], - poseidon2_B_26_2[row_idx], - poseidon2_B_26_3[row_idx], - poseidon2_B_27_0[row_idx], - poseidon2_B_27_1[row_idx], - poseidon2_B_27_2[row_idx], - poseidon2_B_27_3[row_idx], - poseidon2_B_28_0[row_idx], - poseidon2_B_28_1[row_idx], - poseidon2_B_28_2[row_idx], - poseidon2_B_28_3[row_idx], - poseidon2_B_29_0[row_idx], - poseidon2_B_29_1[row_idx], - poseidon2_B_29_2[row_idx], - poseidon2_B_29_3[row_idx], - poseidon2_B_30_0[row_idx], - poseidon2_B_30_1[row_idx], - poseidon2_B_30_2[row_idx], - poseidon2_B_30_3[row_idx], - poseidon2_B_31_0[row_idx], - poseidon2_B_31_1[row_idx], - poseidon2_B_31_2[row_idx], - poseidon2_B_31_3[row_idx], - poseidon2_B_32_0[row_idx], - poseidon2_B_32_1[row_idx], - poseidon2_B_32_2[row_idx], - poseidon2_B_32_3[row_idx], - poseidon2_B_33_0[row_idx], - poseidon2_B_33_1[row_idx], - poseidon2_B_33_2[row_idx], - poseidon2_B_33_3[row_idx], - poseidon2_B_34_0[row_idx], - poseidon2_B_34_1[row_idx], - poseidon2_B_34_2[row_idx], - poseidon2_B_34_3[row_idx], - poseidon2_B_35_0[row_idx], - poseidon2_B_35_1[row_idx], - poseidon2_B_35_2[row_idx], - poseidon2_B_35_3[row_idx], - poseidon2_B_36_0[row_idx], - poseidon2_B_36_1[row_idx], - poseidon2_B_36_2[row_idx], - poseidon2_B_36_3[row_idx], - poseidon2_B_37_0[row_idx], - poseidon2_B_37_1[row_idx], - poseidon2_B_37_2[row_idx], - poseidon2_B_37_3[row_idx], - poseidon2_B_38_0[row_idx], - poseidon2_B_38_1[row_idx], - poseidon2_B_38_2[row_idx], - poseidon2_B_38_3[row_idx], - poseidon2_B_39_0[row_idx], - poseidon2_B_39_1[row_idx], - poseidon2_B_39_2[row_idx], - poseidon2_B_39_3[row_idx], - poseidon2_B_40_0[row_idx], - poseidon2_B_40_1[row_idx], - poseidon2_B_40_2[row_idx], - poseidon2_B_40_3[row_idx], - poseidon2_B_41_0[row_idx], - poseidon2_B_41_1[row_idx], - poseidon2_B_41_2[row_idx], - poseidon2_B_41_3[row_idx], - poseidon2_B_42_0[row_idx], - poseidon2_B_42_1[row_idx], - poseidon2_B_42_2[row_idx], - poseidon2_B_42_3[row_idx], - poseidon2_B_43_0[row_idx], - poseidon2_B_43_1[row_idx], - poseidon2_B_43_2[row_idx], - poseidon2_B_43_3[row_idx], - poseidon2_B_44_0[row_idx], - poseidon2_B_44_1[row_idx], - poseidon2_B_44_2[row_idx], - poseidon2_B_44_3[row_idx], - poseidon2_B_45_0[row_idx], - poseidon2_B_45_1[row_idx], - poseidon2_B_45_2[row_idx], - poseidon2_B_45_3[row_idx], - poseidon2_B_46_0[row_idx], - poseidon2_B_46_1[row_idx], - poseidon2_B_46_2[row_idx], - poseidon2_B_46_3[row_idx], - poseidon2_B_47_0[row_idx], - poseidon2_B_47_1[row_idx], - poseidon2_B_47_2[row_idx], - poseidon2_B_47_3[row_idx], - poseidon2_B_48_0[row_idx], - poseidon2_B_48_1[row_idx], - poseidon2_B_48_2[row_idx], - poseidon2_B_48_3[row_idx], - poseidon2_B_49_0[row_idx], - poseidon2_B_49_1[row_idx], - poseidon2_B_49_2[row_idx], - poseidon2_B_49_3[row_idx], - poseidon2_B_4_0[row_idx], - poseidon2_B_4_1[row_idx], - poseidon2_B_4_2[row_idx], - poseidon2_B_4_3[row_idx], - poseidon2_B_50_0[row_idx], - poseidon2_B_50_1[row_idx], - poseidon2_B_50_2[row_idx], - poseidon2_B_50_3[row_idx], - poseidon2_B_51_0[row_idx], - poseidon2_B_51_1[row_idx], - poseidon2_B_51_2[row_idx], - poseidon2_B_51_3[row_idx], - poseidon2_B_52_0[row_idx], - poseidon2_B_52_1[row_idx], - poseidon2_B_52_2[row_idx], - poseidon2_B_52_3[row_idx], - poseidon2_B_53_0[row_idx], - poseidon2_B_53_1[row_idx], - poseidon2_B_53_2[row_idx], - poseidon2_B_53_3[row_idx], - poseidon2_B_54_0[row_idx], - poseidon2_B_54_1[row_idx], - poseidon2_B_54_2[row_idx], - poseidon2_B_54_3[row_idx], - poseidon2_B_55_0[row_idx], - poseidon2_B_55_1[row_idx], - poseidon2_B_55_2[row_idx], - poseidon2_B_55_3[row_idx], - poseidon2_B_56_0[row_idx], - poseidon2_B_56_1[row_idx], - poseidon2_B_56_2[row_idx], - poseidon2_B_56_3[row_idx], - poseidon2_B_57_0[row_idx], - poseidon2_B_57_1[row_idx], - poseidon2_B_57_2[row_idx], - poseidon2_B_57_3[row_idx], - poseidon2_B_58_0[row_idx], - poseidon2_B_58_1[row_idx], - poseidon2_B_58_2[row_idx], - poseidon2_B_58_3[row_idx], - poseidon2_B_59_0[row_idx], - poseidon2_B_59_1[row_idx], - poseidon2_B_59_2[row_idx], - poseidon2_B_59_3[row_idx], - poseidon2_B_5_0[row_idx], - poseidon2_B_5_1[row_idx], - poseidon2_B_5_2[row_idx], - poseidon2_B_5_3[row_idx], - poseidon2_B_6_0[row_idx], - poseidon2_B_6_1[row_idx], - poseidon2_B_6_2[row_idx], - poseidon2_B_6_3[row_idx], - poseidon2_B_7_0[row_idx], - poseidon2_B_7_1[row_idx], - poseidon2_B_7_2[row_idx], - poseidon2_B_7_3[row_idx], - poseidon2_B_8_0[row_idx], - poseidon2_B_8_1[row_idx], - poseidon2_B_8_2[row_idx], - poseidon2_B_8_3[row_idx], - poseidon2_B_9_0[row_idx], - poseidon2_B_9_1[row_idx], - poseidon2_B_9_2[row_idx], - poseidon2_B_9_3[row_idx], - poseidon2_EXT_LAYER_4[row_idx], - poseidon2_EXT_LAYER_5[row_idx], - poseidon2_EXT_LAYER_6[row_idx], - poseidon2_EXT_LAYER_7[row_idx], - poseidon2_T_0_4[row_idx], - poseidon2_T_0_5[row_idx], - poseidon2_T_0_6[row_idx], - poseidon2_T_0_7[row_idx], - poseidon2_T_1_4[row_idx], - poseidon2_T_1_5[row_idx], - poseidon2_T_1_6[row_idx], - poseidon2_T_1_7[row_idx], - poseidon2_T_2_4[row_idx], - poseidon2_T_2_5[row_idx], - poseidon2_T_2_6[row_idx], - poseidon2_T_2_7[row_idx], - poseidon2_T_3_4[row_idx], - poseidon2_T_3_5[row_idx], - poseidon2_T_3_6[row_idx], - poseidon2_T_3_7[row_idx], - poseidon2_T_60_4[row_idx], - poseidon2_T_60_5[row_idx], - poseidon2_T_60_6[row_idx], - poseidon2_T_60_7[row_idx], - poseidon2_T_61_4[row_idx], - poseidon2_T_61_5[row_idx], - poseidon2_T_61_6[row_idx], - poseidon2_T_61_7[row_idx], - poseidon2_T_62_4[row_idx], - poseidon2_T_62_5[row_idx], - poseidon2_T_62_6[row_idx], - poseidon2_T_62_7[row_idx], - poseidon2_T_63_4[row_idx], - poseidon2_T_63_5[row_idx], - poseidon2_T_63_6[row_idx], - poseidon2_T_63_7[row_idx], - poseidon2_a_0[row_idx], - poseidon2_a_1[row_idx], - poseidon2_a_2[row_idx], - poseidon2_a_3[row_idx], - poseidon2_b_0[row_idx], - poseidon2_b_1[row_idx], - poseidon2_b_2[row_idx], - poseidon2_b_3[row_idx], - poseidon2_clk[row_idx], - poseidon2_in_tag[row_idx], - poseidon2_input_addr[row_idx], - poseidon2_mem_addr_a[row_idx], - poseidon2_mem_addr_b[row_idx], - poseidon2_mem_addr_c[row_idx], - poseidon2_mem_addr_d[row_idx], - poseidon2_mem_op[row_idx], - poseidon2_output_addr[row_idx], - poseidon2_read_line[row_idx], - poseidon2_sel_poseidon_perm[row_idx], - poseidon2_write_line[row_idx], - powers_power_of_2[row_idx], - sha256_clk[row_idx], - sha256_input[row_idx], - sha256_output[row_idx], - sha256_sel_sha256_compression[row_idx], - sha256_state[row_idx], - slice_addr[row_idx], - slice_clk[row_idx], - slice_cnt[row_idx], - slice_col_offset[row_idx], - slice_one_min_inv[row_idx], - slice_sel_cd_cpy[row_idx], - slice_sel_mem_active[row_idx], - slice_sel_return[row_idx], - slice_sel_start[row_idx], - slice_space_id[row_idx], - slice_val[row_idx], - lookup_byte_lengths_counts[row_idx], - lookup_byte_operations_counts[row_idx], - lookup_cd_value_counts[row_idx], - lookup_ret_value_counts[row_idx], - lookup_opcode_gas_counts[row_idx], - range_check_l2_gas_hi_counts[row_idx], - range_check_l2_gas_lo_counts[row_idx], - range_check_da_gas_hi_counts[row_idx], - range_check_da_gas_lo_counts[row_idx], - kernel_output_lookup_counts[row_idx], - lookup_into_kernel_counts[row_idx], - incl_main_tag_err_counts[row_idx], - incl_mem_tag_err_counts[row_idx], - lookup_mem_rng_chk_lo_counts[row_idx], - lookup_mem_rng_chk_mid_counts[row_idx], - lookup_mem_rng_chk_hi_counts[row_idx], - lookup_pow_2_0_counts[row_idx], - lookup_pow_2_1_counts[row_idx], - lookup_u8_0_counts[row_idx], - lookup_u8_1_counts[row_idx], - lookup_u16_0_counts[row_idx], - lookup_u16_1_counts[row_idx], - lookup_u16_2_counts[row_idx], - lookup_u16_3_counts[row_idx], - lookup_u16_4_counts[row_idx], - lookup_u16_5_counts[row_idx], - lookup_u16_6_counts[row_idx], - lookup_u16_7_counts[row_idx], - lookup_u16_8_counts[row_idx], - lookup_u16_9_counts[row_idx], - lookup_u16_10_counts[row_idx], - lookup_u16_11_counts[row_idx], - lookup_u16_12_counts[row_idx], - lookup_u16_13_counts[row_idx], - lookup_u16_14_counts[row_idx], - lookup_div_u16_0_counts[row_idx], - lookup_div_u16_1_counts[row_idx], - lookup_div_u16_2_counts[row_idx], - lookup_div_u16_3_counts[row_idx], - lookup_div_u16_4_counts[row_idx], - lookup_div_u16_5_counts[row_idx], - lookup_div_u16_6_counts[row_idx], - lookup_div_u16_7_counts[row_idx], - perm_pos_mem_a[row_idx], - perm_pos_mem_b[row_idx], - perm_pos_mem_c[row_idx], - perm_pos_mem_d[row_idx], - perm_slice_mem[row_idx], - perm_main_alu[row_idx], - perm_main_bin[row_idx], - perm_main_conv[row_idx], - perm_main_pos2_perm[row_idx], - perm_main_pedersen[row_idx], - perm_main_slice[row_idx], - perm_main_mem_a[row_idx], - perm_main_mem_b[row_idx], - perm_main_mem_c[row_idx], - perm_main_mem_d[row_idx], - perm_main_mem_ind_addr_a[row_idx], - perm_main_mem_ind_addr_b[row_idx], - perm_main_mem_ind_addr_c[row_idx], - perm_main_mem_ind_addr_d[row_idx], - lookup_byte_lengths[row_idx], - lookup_byte_operations[row_idx], - lookup_cd_value[row_idx], - lookup_ret_value[row_idx], - lookup_opcode_gas[row_idx], - range_check_l2_gas_hi[row_idx], - range_check_l2_gas_lo[row_idx], - range_check_da_gas_hi[row_idx], - range_check_da_gas_lo[row_idx], - kernel_output_lookup[row_idx], - lookup_into_kernel[row_idx], - incl_main_tag_err[row_idx], - incl_mem_tag_err[row_idx], - lookup_mem_rng_chk_lo[row_idx], - lookup_mem_rng_chk_mid[row_idx], - lookup_mem_rng_chk_hi[row_idx], - lookup_pow_2_0[row_idx], - lookup_pow_2_1[row_idx], - lookup_u8_0[row_idx], - lookup_u8_1[row_idx], - lookup_u16_0[row_idx], - lookup_u16_1[row_idx], - lookup_u16_2[row_idx], - lookup_u16_3[row_idx], - lookup_u16_4[row_idx], - lookup_u16_5[row_idx], - lookup_u16_6[row_idx], - lookup_u16_7[row_idx], - lookup_u16_8[row_idx], - lookup_u16_9[row_idx], - lookup_u16_10[row_idx], - lookup_u16_11[row_idx], - lookup_u16_12[row_idx], - lookup_u16_13[row_idx], - lookup_u16_14[row_idx], - lookup_div_u16_0[row_idx], - lookup_div_u16_1[row_idx], - lookup_div_u16_2[row_idx], - lookup_div_u16_3[row_idx], - lookup_div_u16_4[row_idx], - lookup_div_u16_5[row_idx], - lookup_div_u16_6[row_idx], - lookup_div_u16_7[row_idx], - alu_a_hi_shift[row_idx], - alu_a_lo_shift[row_idx], - alu_b_hi_shift[row_idx], - alu_b_lo_shift[row_idx], - alu_cmp_rng_ctr_shift[row_idx], - alu_div_u16_r0_shift[row_idx], - alu_div_u16_r1_shift[row_idx], - alu_div_u16_r2_shift[row_idx], - alu_div_u16_r3_shift[row_idx], - alu_div_u16_r4_shift[row_idx], - alu_div_u16_r5_shift[row_idx], - alu_div_u16_r6_shift[row_idx], - alu_div_u16_r7_shift[row_idx], - alu_op_add_shift[row_idx], - alu_op_cast_prev_shift[row_idx], - alu_op_cast_shift[row_idx], - alu_op_div_shift[row_idx], - alu_op_mul_shift[row_idx], - alu_op_shl_shift[row_idx], - alu_op_shr_shift[row_idx], - alu_op_sub_shift[row_idx], - alu_p_sub_a_hi_shift[row_idx], - alu_p_sub_a_lo_shift[row_idx], - alu_p_sub_b_hi_shift[row_idx], - alu_p_sub_b_lo_shift[row_idx], - alu_sel_alu_shift[row_idx], - alu_sel_cmp_shift[row_idx], - alu_sel_div_rng_chk_shift[row_idx], - alu_sel_rng_chk_lookup_shift[row_idx], - alu_sel_rng_chk_shift[row_idx], - alu_u16_r0_shift[row_idx], - alu_u16_r1_shift[row_idx], - alu_u16_r2_shift[row_idx], - alu_u16_r3_shift[row_idx], - alu_u16_r4_shift[row_idx], - alu_u16_r5_shift[row_idx], - alu_u16_r6_shift[row_idx], - alu_u8_r0_shift[row_idx], - alu_u8_r1_shift[row_idx], - binary_acc_ia_shift[row_idx], - binary_acc_ib_shift[row_idx], - binary_acc_ic_shift[row_idx], - binary_mem_tag_ctr_shift[row_idx], - binary_op_id_shift[row_idx], - kernel_emit_l2_to_l1_msg_write_offset_shift[row_idx], - kernel_emit_note_hash_write_offset_shift[row_idx], - kernel_emit_nullifier_write_offset_shift[row_idx], - kernel_emit_unencrypted_log_write_offset_shift[row_idx], - kernel_l1_to_l2_msg_exists_write_offset_shift[row_idx], - kernel_note_hash_exist_write_offset_shift[row_idx], - kernel_nullifier_exists_write_offset_shift[row_idx], - kernel_nullifier_non_exists_write_offset_shift[row_idx], - kernel_side_effect_counter_shift[row_idx], - kernel_sload_write_offset_shift[row_idx], - kernel_sstore_write_offset_shift[row_idx], - main_da_gas_remaining_shift[row_idx], - main_internal_return_ptr_shift[row_idx], - main_l2_gas_remaining_shift[row_idx], - main_pc_shift[row_idx], - mem_glob_addr_shift[row_idx], - mem_rw_shift[row_idx], - mem_sel_mem_shift[row_idx], - mem_tag_shift[row_idx], - mem_tsp_shift[row_idx], - mem_val_shift[row_idx], - poseidon2_a_0_shift[row_idx], - poseidon2_a_1_shift[row_idx], - poseidon2_a_2_shift[row_idx], - poseidon2_a_3_shift[row_idx], - poseidon2_sel_poseidon_perm_shift[row_idx], - poseidon2_write_line_shift[row_idx], - slice_addr_shift[row_idx], - slice_clk_shift[row_idx], - slice_cnt_shift[row_idx], - slice_col_offset_shift[row_idx], - slice_sel_cd_cpy_shift[row_idx], - slice_sel_mem_active_shift[row_idx], - slice_sel_return_shift[row_idx], - slice_sel_start_shift[row_idx], - slice_space_id_shift[row_idx] }); - } - }; - - class PartiallyEvaluatedMultivariates : public AllEntities { - public: - PartiallyEvaluatedMultivariates() = default; - PartiallyEvaluatedMultivariates(const size_t circuit_size) - { - // Storage is only needed after the first partial evaluation, hence polynomials of size (n / 2) - for (auto& poly : get_all()) { - poly = Polynomial(circuit_size / 2); - } - } - }; - - /** - * @brief A container for univariates used during Protogalaxy folding and sumcheck. - * @details During folding and sumcheck, the prover evaluates the relations on these univariates. - */ - template using ProverUnivariates = AllEntities>; - - /** - * @brief A container for univariates used during Protogalaxy folding and sumcheck with some of the computation - * optimistically ignored - * @details During folding and sumcheck, the prover evaluates the relations on these univariates. - */ - template - using OptimisedProverUnivariates = AllEntities>; - - /** - * @brief A container for univariates produced during the hot loop in sumcheck. - */ - using ExtendedEdges = ProverUnivariates; - - /** - * @brief A container for the witness commitments. - * - */ - using WitnessCommitments = WitnessEntities; - - class CommitmentLabels : public AllEntities { - private: - using Base = AllEntities; - - public: - CommitmentLabels() - { - Base::main_clk = "MAIN_CLK"; - Base::main_sel_first = "MAIN_SEL_FIRST"; - Base::kernel_kernel_inputs = "KERNEL_KERNEL_INPUTS"; - Base::kernel_kernel_value_out = "KERNEL_KERNEL_VALUE_OUT"; - Base::kernel_kernel_side_effect_out = "KERNEL_KERNEL_SIDE_EFFECT_OUT"; - Base::kernel_kernel_metadata_out = "KERNEL_KERNEL_METADATA_OUT"; - Base::main_calldata = "MAIN_CALLDATA"; - Base::main_returndata = "MAIN_RETURNDATA"; - Base::alu_a_hi = "ALU_A_HI"; - Base::alu_a_lo = "ALU_A_LO"; - Base::alu_b_hi = "ALU_B_HI"; - Base::alu_b_lo = "ALU_B_LO"; - Base::alu_borrow = "ALU_BORROW"; - Base::alu_cf = "ALU_CF"; - Base::alu_clk = "ALU_CLK"; - Base::alu_cmp_rng_ctr = "ALU_CMP_RNG_CTR"; - Base::alu_div_u16_r0 = "ALU_DIV_U16_R0"; - Base::alu_div_u16_r1 = "ALU_DIV_U16_R1"; - Base::alu_div_u16_r2 = "ALU_DIV_U16_R2"; - Base::alu_div_u16_r3 = "ALU_DIV_U16_R3"; - Base::alu_div_u16_r4 = "ALU_DIV_U16_R4"; - Base::alu_div_u16_r5 = "ALU_DIV_U16_R5"; - Base::alu_div_u16_r6 = "ALU_DIV_U16_R6"; - Base::alu_div_u16_r7 = "ALU_DIV_U16_R7"; - Base::alu_divisor_hi = "ALU_DIVISOR_HI"; - Base::alu_divisor_lo = "ALU_DIVISOR_LO"; - Base::alu_ff_tag = "ALU_FF_TAG"; - Base::alu_ia = "ALU_IA"; - Base::alu_ib = "ALU_IB"; - Base::alu_ic = "ALU_IC"; - Base::alu_in_tag = "ALU_IN_TAG"; - Base::alu_op_add = "ALU_OP_ADD"; - Base::alu_op_cast = "ALU_OP_CAST"; - Base::alu_op_cast_prev = "ALU_OP_CAST_PREV"; - Base::alu_op_div = "ALU_OP_DIV"; - Base::alu_op_div_a_lt_b = "ALU_OP_DIV_A_LT_B"; - Base::alu_op_div_std = "ALU_OP_DIV_STD"; - Base::alu_op_eq = "ALU_OP_EQ"; - Base::alu_op_eq_diff_inv = "ALU_OP_EQ_DIFF_INV"; - Base::alu_op_lt = "ALU_OP_LT"; - Base::alu_op_lte = "ALU_OP_LTE"; - Base::alu_op_mul = "ALU_OP_MUL"; - Base::alu_op_not = "ALU_OP_NOT"; - Base::alu_op_shl = "ALU_OP_SHL"; - Base::alu_op_shr = "ALU_OP_SHR"; - Base::alu_op_sub = "ALU_OP_SUB"; - Base::alu_p_a_borrow = "ALU_P_A_BORROW"; - Base::alu_p_b_borrow = "ALU_P_B_BORROW"; - Base::alu_p_sub_a_hi = "ALU_P_SUB_A_HI"; - Base::alu_p_sub_a_lo = "ALU_P_SUB_A_LO"; - Base::alu_p_sub_b_hi = "ALU_P_SUB_B_HI"; - Base::alu_p_sub_b_lo = "ALU_P_SUB_B_LO"; - Base::alu_partial_prod_hi = "ALU_PARTIAL_PROD_HI"; - Base::alu_partial_prod_lo = "ALU_PARTIAL_PROD_LO"; - Base::alu_quotient_hi = "ALU_QUOTIENT_HI"; - Base::alu_quotient_lo = "ALU_QUOTIENT_LO"; - Base::alu_remainder = "ALU_REMAINDER"; - Base::alu_res_hi = "ALU_RES_HI"; - Base::alu_res_lo = "ALU_RES_LO"; - Base::alu_sel_alu = "ALU_SEL_ALU"; - Base::alu_sel_cmp = "ALU_SEL_CMP"; - Base::alu_sel_div_rng_chk = "ALU_SEL_DIV_RNG_CHK"; - Base::alu_sel_rng_chk = "ALU_SEL_RNG_CHK"; - Base::alu_sel_rng_chk_lookup = "ALU_SEL_RNG_CHK_LOOKUP"; - Base::alu_sel_shift_which = "ALU_SEL_SHIFT_WHICH"; - Base::alu_shift_lt_bit_len = "ALU_SHIFT_LT_BIT_LEN"; - Base::alu_t_sub_s_bits = "ALU_T_SUB_S_BITS"; - Base::alu_two_pow_s = "ALU_TWO_POW_S"; - Base::alu_two_pow_t_sub_s = "ALU_TWO_POW_T_SUB_S"; - Base::alu_u128_tag = "ALU_U128_TAG"; - Base::alu_u16_r0 = "ALU_U16_R0"; - Base::alu_u16_r1 = "ALU_U16_R1"; - Base::alu_u16_r10 = "ALU_U16_R10"; - Base::alu_u16_r11 = "ALU_U16_R11"; - Base::alu_u16_r12 = "ALU_U16_R12"; - Base::alu_u16_r13 = "ALU_U16_R13"; - Base::alu_u16_r14 = "ALU_U16_R14"; - Base::alu_u16_r2 = "ALU_U16_R2"; - Base::alu_u16_r3 = "ALU_U16_R3"; - Base::alu_u16_r4 = "ALU_U16_R4"; - Base::alu_u16_r5 = "ALU_U16_R5"; - Base::alu_u16_r6 = "ALU_U16_R6"; - Base::alu_u16_r7 = "ALU_U16_R7"; - Base::alu_u16_r8 = "ALU_U16_R8"; - Base::alu_u16_r9 = "ALU_U16_R9"; - Base::alu_u16_tag = "ALU_U16_TAG"; - Base::alu_u32_tag = "ALU_U32_TAG"; - Base::alu_u64_tag = "ALU_U64_TAG"; - Base::alu_u8_r0 = "ALU_U8_R0"; - Base::alu_u8_r1 = "ALU_U8_R1"; - Base::alu_u8_tag = "ALU_U8_TAG"; - Base::binary_acc_ia = "BINARY_ACC_IA"; - Base::binary_acc_ib = "BINARY_ACC_IB"; - Base::binary_acc_ic = "BINARY_ACC_IC"; - Base::binary_clk = "BINARY_CLK"; - Base::binary_ia_bytes = "BINARY_IA_BYTES"; - Base::binary_ib_bytes = "BINARY_IB_BYTES"; - Base::binary_ic_bytes = "BINARY_IC_BYTES"; - Base::binary_in_tag = "BINARY_IN_TAG"; - Base::binary_mem_tag_ctr = "BINARY_MEM_TAG_CTR"; - Base::binary_mem_tag_ctr_inv = "BINARY_MEM_TAG_CTR_INV"; - Base::binary_op_id = "BINARY_OP_ID"; - Base::binary_sel_bin = "BINARY_SEL_BIN"; - Base::binary_start = "BINARY_START"; - Base::byte_lookup_sel_bin = "BYTE_LOOKUP_SEL_BIN"; - Base::byte_lookup_table_byte_lengths = "BYTE_LOOKUP_TABLE_BYTE_LENGTHS"; - Base::byte_lookup_table_in_tags = "BYTE_LOOKUP_TABLE_IN_TAGS"; - Base::byte_lookup_table_input_a = "BYTE_LOOKUP_TABLE_INPUT_A"; - Base::byte_lookup_table_input_b = "BYTE_LOOKUP_TABLE_INPUT_B"; - Base::byte_lookup_table_op_id = "BYTE_LOOKUP_TABLE_OP_ID"; - Base::byte_lookup_table_output = "BYTE_LOOKUP_TABLE_OUTPUT"; - Base::conversion_clk = "CONVERSION_CLK"; - Base::conversion_input = "CONVERSION_INPUT"; - Base::conversion_num_limbs = "CONVERSION_NUM_LIMBS"; - Base::conversion_radix = "CONVERSION_RADIX"; - Base::conversion_sel_to_radix_le = "CONVERSION_SEL_TO_RADIX_LE"; - Base::gas_da_gas_fixed_table = "GAS_DA_GAS_FIXED_TABLE"; - Base::gas_l2_gas_fixed_table = "GAS_L2_GAS_FIXED_TABLE"; - Base::gas_sel_gas_cost = "GAS_SEL_GAS_COST"; - Base::keccakf1600_clk = "KECCAKF1600_CLK"; - Base::keccakf1600_input = "KECCAKF1600_INPUT"; - Base::keccakf1600_output = "KECCAKF1600_OUTPUT"; - Base::keccakf1600_sel_keccakf1600 = "KECCAKF1600_SEL_KECCAKF1600"; - Base::kernel_emit_l2_to_l1_msg_write_offset = "KERNEL_EMIT_L2_TO_L1_MSG_WRITE_OFFSET"; - Base::kernel_emit_note_hash_write_offset = "KERNEL_EMIT_NOTE_HASH_WRITE_OFFSET"; - Base::kernel_emit_nullifier_write_offset = "KERNEL_EMIT_NULLIFIER_WRITE_OFFSET"; - Base::kernel_emit_unencrypted_log_write_offset = "KERNEL_EMIT_UNENCRYPTED_LOG_WRITE_OFFSET"; - Base::kernel_kernel_in_offset = "KERNEL_KERNEL_IN_OFFSET"; - Base::kernel_kernel_out_offset = "KERNEL_KERNEL_OUT_OFFSET"; - Base::kernel_l1_to_l2_msg_exists_write_offset = "KERNEL_L1_TO_L2_MSG_EXISTS_WRITE_OFFSET"; - Base::kernel_note_hash_exist_write_offset = "KERNEL_NOTE_HASH_EXIST_WRITE_OFFSET"; - Base::kernel_nullifier_exists_write_offset = "KERNEL_NULLIFIER_EXISTS_WRITE_OFFSET"; - Base::kernel_nullifier_non_exists_write_offset = "KERNEL_NULLIFIER_NON_EXISTS_WRITE_OFFSET"; - Base::kernel_q_public_input_kernel_add_to_table = "KERNEL_Q_PUBLIC_INPUT_KERNEL_ADD_TO_TABLE"; - Base::kernel_q_public_input_kernel_out_add_to_table = "KERNEL_Q_PUBLIC_INPUT_KERNEL_OUT_ADD_TO_TABLE"; - Base::kernel_side_effect_counter = "KERNEL_SIDE_EFFECT_COUNTER"; - Base::kernel_sload_write_offset = "KERNEL_SLOAD_WRITE_OFFSET"; - Base::kernel_sstore_write_offset = "KERNEL_SSTORE_WRITE_OFFSET"; - Base::main_abs_da_rem_gas_hi = "MAIN_ABS_DA_REM_GAS_HI"; - Base::main_abs_da_rem_gas_lo = "MAIN_ABS_DA_REM_GAS_LO"; - Base::main_abs_l2_rem_gas_hi = "MAIN_ABS_L2_REM_GAS_HI"; - Base::main_abs_l2_rem_gas_lo = "MAIN_ABS_L2_REM_GAS_LO"; - Base::main_alu_in_tag = "MAIN_ALU_IN_TAG"; - Base::main_bin_op_id = "MAIN_BIN_OP_ID"; - Base::main_call_ptr = "MAIN_CALL_PTR"; - Base::main_da_gas_op_cost = "MAIN_DA_GAS_OP_COST"; - Base::main_da_gas_remaining = "MAIN_DA_GAS_REMAINING"; - Base::main_da_out_of_gas = "MAIN_DA_OUT_OF_GAS"; - Base::main_ia = "MAIN_IA"; - Base::main_ib = "MAIN_IB"; - Base::main_ic = "MAIN_IC"; - Base::main_id = "MAIN_ID"; - Base::main_id_zero = "MAIN_ID_ZERO"; - Base::main_ind_addr_a = "MAIN_IND_ADDR_A"; - Base::main_ind_addr_b = "MAIN_IND_ADDR_B"; - Base::main_ind_addr_c = "MAIN_IND_ADDR_C"; - Base::main_ind_addr_d = "MAIN_IND_ADDR_D"; - Base::main_internal_return_ptr = "MAIN_INTERNAL_RETURN_PTR"; - Base::main_inv = "MAIN_INV"; - Base::main_l2_gas_op_cost = "MAIN_L2_GAS_OP_COST"; - Base::main_l2_gas_remaining = "MAIN_L2_GAS_REMAINING"; - Base::main_l2_out_of_gas = "MAIN_L2_OUT_OF_GAS"; - Base::main_mem_addr_a = "MAIN_MEM_ADDR_A"; - Base::main_mem_addr_b = "MAIN_MEM_ADDR_B"; - Base::main_mem_addr_c = "MAIN_MEM_ADDR_C"; - Base::main_mem_addr_d = "MAIN_MEM_ADDR_D"; - Base::main_op_err = "MAIN_OP_ERR"; - Base::main_opcode_val = "MAIN_OPCODE_VAL"; - Base::main_pc = "MAIN_PC"; - Base::main_r_in_tag = "MAIN_R_IN_TAG"; - Base::main_rwa = "MAIN_RWA"; - Base::main_rwb = "MAIN_RWB"; - Base::main_rwc = "MAIN_RWC"; - Base::main_rwd = "MAIN_RWD"; - Base::main_sel_alu = "MAIN_SEL_ALU"; - Base::main_sel_bin = "MAIN_SEL_BIN"; - Base::main_sel_calldata = "MAIN_SEL_CALLDATA"; - Base::main_sel_gas_accounting_active = "MAIN_SEL_GAS_ACCOUNTING_ACTIVE"; - Base::main_sel_last = "MAIN_SEL_LAST"; - Base::main_sel_mem_op_a = "MAIN_SEL_MEM_OP_A"; - Base::main_sel_mem_op_activate_gas = "MAIN_SEL_MEM_OP_ACTIVATE_GAS"; - Base::main_sel_mem_op_b = "MAIN_SEL_MEM_OP_B"; - Base::main_sel_mem_op_c = "MAIN_SEL_MEM_OP_C"; - Base::main_sel_mem_op_d = "MAIN_SEL_MEM_OP_D"; - Base::main_sel_mov_ia_to_ic = "MAIN_SEL_MOV_IA_TO_IC"; - Base::main_sel_mov_ib_to_ic = "MAIN_SEL_MOV_IB_TO_IC"; - Base::main_sel_op_add = "MAIN_SEL_OP_ADD"; - Base::main_sel_op_address = "MAIN_SEL_OP_ADDRESS"; - Base::main_sel_op_and = "MAIN_SEL_OP_AND"; - Base::main_sel_op_block_number = "MAIN_SEL_OP_BLOCK_NUMBER"; - Base::main_sel_op_calldata_copy = "MAIN_SEL_OP_CALLDATA_COPY"; - Base::main_sel_op_cast = "MAIN_SEL_OP_CAST"; - Base::main_sel_op_chain_id = "MAIN_SEL_OP_CHAIN_ID"; - Base::main_sel_op_cmov = "MAIN_SEL_OP_CMOV"; - Base::main_sel_op_coinbase = "MAIN_SEL_OP_COINBASE"; - Base::main_sel_op_dagasleft = "MAIN_SEL_OP_DAGASLEFT"; - Base::main_sel_op_div = "MAIN_SEL_OP_DIV"; - Base::main_sel_op_emit_l2_to_l1_msg = "MAIN_SEL_OP_EMIT_L2_TO_L1_MSG"; - Base::main_sel_op_emit_note_hash = "MAIN_SEL_OP_EMIT_NOTE_HASH"; - Base::main_sel_op_emit_nullifier = "MAIN_SEL_OP_EMIT_NULLIFIER"; - Base::main_sel_op_emit_unencrypted_log = "MAIN_SEL_OP_EMIT_UNENCRYPTED_LOG"; - Base::main_sel_op_eq = "MAIN_SEL_OP_EQ"; - Base::main_sel_op_external_call = "MAIN_SEL_OP_EXTERNAL_CALL"; - Base::main_sel_op_external_return = "MAIN_SEL_OP_EXTERNAL_RETURN"; - Base::main_sel_op_fdiv = "MAIN_SEL_OP_FDIV"; - Base::main_sel_op_fee_per_da_gas = "MAIN_SEL_OP_FEE_PER_DA_GAS"; - Base::main_sel_op_fee_per_l2_gas = "MAIN_SEL_OP_FEE_PER_L2_GAS"; - Base::main_sel_op_function_selector = "MAIN_SEL_OP_FUNCTION_SELECTOR"; - Base::main_sel_op_get_contract_instance = "MAIN_SEL_OP_GET_CONTRACT_INSTANCE"; - Base::main_sel_op_halt = "MAIN_SEL_OP_HALT"; - Base::main_sel_op_internal_call = "MAIN_SEL_OP_INTERNAL_CALL"; - Base::main_sel_op_internal_return = "MAIN_SEL_OP_INTERNAL_RETURN"; - Base::main_sel_op_jump = "MAIN_SEL_OP_JUMP"; - Base::main_sel_op_jumpi = "MAIN_SEL_OP_JUMPI"; - Base::main_sel_op_keccak = "MAIN_SEL_OP_KECCAK"; - Base::main_sel_op_l1_to_l2_msg_exists = "MAIN_SEL_OP_L1_TO_L2_MSG_EXISTS"; - Base::main_sel_op_l2gasleft = "MAIN_SEL_OP_L2GASLEFT"; - Base::main_sel_op_lt = "MAIN_SEL_OP_LT"; - Base::main_sel_op_lte = "MAIN_SEL_OP_LTE"; - Base::main_sel_op_mov = "MAIN_SEL_OP_MOV"; - Base::main_sel_op_mul = "MAIN_SEL_OP_MUL"; - Base::main_sel_op_not = "MAIN_SEL_OP_NOT"; - Base::main_sel_op_note_hash_exists = "MAIN_SEL_OP_NOTE_HASH_EXISTS"; - Base::main_sel_op_nullifier_exists = "MAIN_SEL_OP_NULLIFIER_EXISTS"; - Base::main_sel_op_or = "MAIN_SEL_OP_OR"; - Base::main_sel_op_pedersen = "MAIN_SEL_OP_PEDERSEN"; - Base::main_sel_op_poseidon2 = "MAIN_SEL_OP_POSEIDON2"; - Base::main_sel_op_radix_le = "MAIN_SEL_OP_RADIX_LE"; - Base::main_sel_op_sender = "MAIN_SEL_OP_SENDER"; - Base::main_sel_op_sha256 = "MAIN_SEL_OP_SHA256"; - Base::main_sel_op_shl = "MAIN_SEL_OP_SHL"; - Base::main_sel_op_shr = "MAIN_SEL_OP_SHR"; - Base::main_sel_op_sload = "MAIN_SEL_OP_SLOAD"; - Base::main_sel_op_sstore = "MAIN_SEL_OP_SSTORE"; - Base::main_sel_op_storage_address = "MAIN_SEL_OP_STORAGE_ADDRESS"; - Base::main_sel_op_sub = "MAIN_SEL_OP_SUB"; - Base::main_sel_op_timestamp = "MAIN_SEL_OP_TIMESTAMP"; - Base::main_sel_op_transaction_fee = "MAIN_SEL_OP_TRANSACTION_FEE"; - Base::main_sel_op_version = "MAIN_SEL_OP_VERSION"; - Base::main_sel_op_xor = "MAIN_SEL_OP_XOR"; - Base::main_sel_q_kernel_lookup = "MAIN_SEL_Q_KERNEL_LOOKUP"; - Base::main_sel_q_kernel_output_lookup = "MAIN_SEL_Q_KERNEL_OUTPUT_LOOKUP"; - Base::main_sel_resolve_ind_addr_a = "MAIN_SEL_RESOLVE_IND_ADDR_A"; - Base::main_sel_resolve_ind_addr_b = "MAIN_SEL_RESOLVE_IND_ADDR_B"; - Base::main_sel_resolve_ind_addr_c = "MAIN_SEL_RESOLVE_IND_ADDR_C"; - Base::main_sel_resolve_ind_addr_d = "MAIN_SEL_RESOLVE_IND_ADDR_D"; - Base::main_sel_returndata = "MAIN_SEL_RETURNDATA"; - Base::main_sel_rng_16 = "MAIN_SEL_RNG_16"; - Base::main_sel_rng_8 = "MAIN_SEL_RNG_8"; - Base::main_sel_slice_gadget = "MAIN_SEL_SLICE_GADGET"; - Base::main_space_id = "MAIN_SPACE_ID"; - Base::main_tag_err = "MAIN_TAG_ERR"; - Base::main_w_in_tag = "MAIN_W_IN_TAG"; - Base::mem_addr = "MEM_ADDR"; - Base::mem_clk = "MEM_CLK"; - Base::mem_diff_hi = "MEM_DIFF_HI"; - Base::mem_diff_lo = "MEM_DIFF_LO"; - Base::mem_diff_mid = "MEM_DIFF_MID"; - Base::mem_glob_addr = "MEM_GLOB_ADDR"; - Base::mem_last = "MEM_LAST"; - Base::mem_lastAccess = "MEM_LAST_ACCESS"; - Base::mem_one_min_inv = "MEM_ONE_MIN_INV"; - Base::mem_r_in_tag = "MEM_R_IN_TAG"; - Base::mem_rw = "MEM_RW"; - Base::mem_sel_mem = "MEM_SEL_MEM"; - Base::mem_sel_mov_ia_to_ic = "MEM_SEL_MOV_IA_TO_IC"; - Base::mem_sel_mov_ib_to_ic = "MEM_SEL_MOV_IB_TO_IC"; - Base::mem_sel_op_a = "MEM_SEL_OP_A"; - Base::mem_sel_op_b = "MEM_SEL_OP_B"; - Base::mem_sel_op_c = "MEM_SEL_OP_C"; - Base::mem_sel_op_cmov = "MEM_SEL_OP_CMOV"; - Base::mem_sel_op_d = "MEM_SEL_OP_D"; - Base::mem_sel_op_gadget_a = "MEM_SEL_OP_GADGET_A"; - Base::mem_sel_op_gadget_b = "MEM_SEL_OP_GADGET_B"; - Base::mem_sel_op_gadget_c = "MEM_SEL_OP_GADGET_C"; - Base::mem_sel_op_gadget_d = "MEM_SEL_OP_GADGET_D"; - Base::mem_sel_op_slice = "MEM_SEL_OP_SLICE"; - Base::mem_sel_resolve_ind_addr_a = "MEM_SEL_RESOLVE_IND_ADDR_A"; - Base::mem_sel_resolve_ind_addr_b = "MEM_SEL_RESOLVE_IND_ADDR_B"; - Base::mem_sel_resolve_ind_addr_c = "MEM_SEL_RESOLVE_IND_ADDR_C"; - Base::mem_sel_resolve_ind_addr_d = "MEM_SEL_RESOLVE_IND_ADDR_D"; - Base::mem_sel_rng_chk = "MEM_SEL_RNG_CHK"; - Base::mem_skip_check_tag = "MEM_SKIP_CHECK_TAG"; - Base::mem_space_id = "MEM_SPACE_ID"; - Base::mem_tag = "MEM_TAG"; - Base::mem_tag_err = "MEM_TAG_ERR"; - Base::mem_tsp = "MEM_TSP"; - Base::mem_val = "MEM_VAL"; - Base::mem_w_in_tag = "MEM_W_IN_TAG"; - Base::pedersen_clk = "PEDERSEN_CLK"; - Base::pedersen_input = "PEDERSEN_INPUT"; - Base::pedersen_output = "PEDERSEN_OUTPUT"; - Base::pedersen_sel_pedersen = "PEDERSEN_SEL_PEDERSEN"; - Base::poseidon2_B_10_0 = "POSEIDON2_B_10_0"; - Base::poseidon2_B_10_1 = "POSEIDON2_B_10_1"; - Base::poseidon2_B_10_2 = "POSEIDON2_B_10_2"; - Base::poseidon2_B_10_3 = "POSEIDON2_B_10_3"; - Base::poseidon2_B_11_0 = "POSEIDON2_B_11_0"; - Base::poseidon2_B_11_1 = "POSEIDON2_B_11_1"; - Base::poseidon2_B_11_2 = "POSEIDON2_B_11_2"; - Base::poseidon2_B_11_3 = "POSEIDON2_B_11_3"; - Base::poseidon2_B_12_0 = "POSEIDON2_B_12_0"; - Base::poseidon2_B_12_1 = "POSEIDON2_B_12_1"; - Base::poseidon2_B_12_2 = "POSEIDON2_B_12_2"; - Base::poseidon2_B_12_3 = "POSEIDON2_B_12_3"; - Base::poseidon2_B_13_0 = "POSEIDON2_B_13_0"; - Base::poseidon2_B_13_1 = "POSEIDON2_B_13_1"; - Base::poseidon2_B_13_2 = "POSEIDON2_B_13_2"; - Base::poseidon2_B_13_3 = "POSEIDON2_B_13_3"; - Base::poseidon2_B_14_0 = "POSEIDON2_B_14_0"; - Base::poseidon2_B_14_1 = "POSEIDON2_B_14_1"; - Base::poseidon2_B_14_2 = "POSEIDON2_B_14_2"; - Base::poseidon2_B_14_3 = "POSEIDON2_B_14_3"; - Base::poseidon2_B_15_0 = "POSEIDON2_B_15_0"; - Base::poseidon2_B_15_1 = "POSEIDON2_B_15_1"; - Base::poseidon2_B_15_2 = "POSEIDON2_B_15_2"; - Base::poseidon2_B_15_3 = "POSEIDON2_B_15_3"; - Base::poseidon2_B_16_0 = "POSEIDON2_B_16_0"; - Base::poseidon2_B_16_1 = "POSEIDON2_B_16_1"; - Base::poseidon2_B_16_2 = "POSEIDON2_B_16_2"; - Base::poseidon2_B_16_3 = "POSEIDON2_B_16_3"; - Base::poseidon2_B_17_0 = "POSEIDON2_B_17_0"; - Base::poseidon2_B_17_1 = "POSEIDON2_B_17_1"; - Base::poseidon2_B_17_2 = "POSEIDON2_B_17_2"; - Base::poseidon2_B_17_3 = "POSEIDON2_B_17_3"; - Base::poseidon2_B_18_0 = "POSEIDON2_B_18_0"; - Base::poseidon2_B_18_1 = "POSEIDON2_B_18_1"; - Base::poseidon2_B_18_2 = "POSEIDON2_B_18_2"; - Base::poseidon2_B_18_3 = "POSEIDON2_B_18_3"; - Base::poseidon2_B_19_0 = "POSEIDON2_B_19_0"; - Base::poseidon2_B_19_1 = "POSEIDON2_B_19_1"; - Base::poseidon2_B_19_2 = "POSEIDON2_B_19_2"; - Base::poseidon2_B_19_3 = "POSEIDON2_B_19_3"; - Base::poseidon2_B_20_0 = "POSEIDON2_B_20_0"; - Base::poseidon2_B_20_1 = "POSEIDON2_B_20_1"; - Base::poseidon2_B_20_2 = "POSEIDON2_B_20_2"; - Base::poseidon2_B_20_3 = "POSEIDON2_B_20_3"; - Base::poseidon2_B_21_0 = "POSEIDON2_B_21_0"; - Base::poseidon2_B_21_1 = "POSEIDON2_B_21_1"; - Base::poseidon2_B_21_2 = "POSEIDON2_B_21_2"; - Base::poseidon2_B_21_3 = "POSEIDON2_B_21_3"; - Base::poseidon2_B_22_0 = "POSEIDON2_B_22_0"; - Base::poseidon2_B_22_1 = "POSEIDON2_B_22_1"; - Base::poseidon2_B_22_2 = "POSEIDON2_B_22_2"; - Base::poseidon2_B_22_3 = "POSEIDON2_B_22_3"; - Base::poseidon2_B_23_0 = "POSEIDON2_B_23_0"; - Base::poseidon2_B_23_1 = "POSEIDON2_B_23_1"; - Base::poseidon2_B_23_2 = "POSEIDON2_B_23_2"; - Base::poseidon2_B_23_3 = "POSEIDON2_B_23_3"; - Base::poseidon2_B_24_0 = "POSEIDON2_B_24_0"; - Base::poseidon2_B_24_1 = "POSEIDON2_B_24_1"; - Base::poseidon2_B_24_2 = "POSEIDON2_B_24_2"; - Base::poseidon2_B_24_3 = "POSEIDON2_B_24_3"; - Base::poseidon2_B_25_0 = "POSEIDON2_B_25_0"; - Base::poseidon2_B_25_1 = "POSEIDON2_B_25_1"; - Base::poseidon2_B_25_2 = "POSEIDON2_B_25_2"; - Base::poseidon2_B_25_3 = "POSEIDON2_B_25_3"; - Base::poseidon2_B_26_0 = "POSEIDON2_B_26_0"; - Base::poseidon2_B_26_1 = "POSEIDON2_B_26_1"; - Base::poseidon2_B_26_2 = "POSEIDON2_B_26_2"; - Base::poseidon2_B_26_3 = "POSEIDON2_B_26_3"; - Base::poseidon2_B_27_0 = "POSEIDON2_B_27_0"; - Base::poseidon2_B_27_1 = "POSEIDON2_B_27_1"; - Base::poseidon2_B_27_2 = "POSEIDON2_B_27_2"; - Base::poseidon2_B_27_3 = "POSEIDON2_B_27_3"; - Base::poseidon2_B_28_0 = "POSEIDON2_B_28_0"; - Base::poseidon2_B_28_1 = "POSEIDON2_B_28_1"; - Base::poseidon2_B_28_2 = "POSEIDON2_B_28_2"; - Base::poseidon2_B_28_3 = "POSEIDON2_B_28_3"; - Base::poseidon2_B_29_0 = "POSEIDON2_B_29_0"; - Base::poseidon2_B_29_1 = "POSEIDON2_B_29_1"; - Base::poseidon2_B_29_2 = "POSEIDON2_B_29_2"; - Base::poseidon2_B_29_3 = "POSEIDON2_B_29_3"; - Base::poseidon2_B_30_0 = "POSEIDON2_B_30_0"; - Base::poseidon2_B_30_1 = "POSEIDON2_B_30_1"; - Base::poseidon2_B_30_2 = "POSEIDON2_B_30_2"; - Base::poseidon2_B_30_3 = "POSEIDON2_B_30_3"; - Base::poseidon2_B_31_0 = "POSEIDON2_B_31_0"; - Base::poseidon2_B_31_1 = "POSEIDON2_B_31_1"; - Base::poseidon2_B_31_2 = "POSEIDON2_B_31_2"; - Base::poseidon2_B_31_3 = "POSEIDON2_B_31_3"; - Base::poseidon2_B_32_0 = "POSEIDON2_B_32_0"; - Base::poseidon2_B_32_1 = "POSEIDON2_B_32_1"; - Base::poseidon2_B_32_2 = "POSEIDON2_B_32_2"; - Base::poseidon2_B_32_3 = "POSEIDON2_B_32_3"; - Base::poseidon2_B_33_0 = "POSEIDON2_B_33_0"; - Base::poseidon2_B_33_1 = "POSEIDON2_B_33_1"; - Base::poseidon2_B_33_2 = "POSEIDON2_B_33_2"; - Base::poseidon2_B_33_3 = "POSEIDON2_B_33_3"; - Base::poseidon2_B_34_0 = "POSEIDON2_B_34_0"; - Base::poseidon2_B_34_1 = "POSEIDON2_B_34_1"; - Base::poseidon2_B_34_2 = "POSEIDON2_B_34_2"; - Base::poseidon2_B_34_3 = "POSEIDON2_B_34_3"; - Base::poseidon2_B_35_0 = "POSEIDON2_B_35_0"; - Base::poseidon2_B_35_1 = "POSEIDON2_B_35_1"; - Base::poseidon2_B_35_2 = "POSEIDON2_B_35_2"; - Base::poseidon2_B_35_3 = "POSEIDON2_B_35_3"; - Base::poseidon2_B_36_0 = "POSEIDON2_B_36_0"; - Base::poseidon2_B_36_1 = "POSEIDON2_B_36_1"; - Base::poseidon2_B_36_2 = "POSEIDON2_B_36_2"; - Base::poseidon2_B_36_3 = "POSEIDON2_B_36_3"; - Base::poseidon2_B_37_0 = "POSEIDON2_B_37_0"; - Base::poseidon2_B_37_1 = "POSEIDON2_B_37_1"; - Base::poseidon2_B_37_2 = "POSEIDON2_B_37_2"; - Base::poseidon2_B_37_3 = "POSEIDON2_B_37_3"; - Base::poseidon2_B_38_0 = "POSEIDON2_B_38_0"; - Base::poseidon2_B_38_1 = "POSEIDON2_B_38_1"; - Base::poseidon2_B_38_2 = "POSEIDON2_B_38_2"; - Base::poseidon2_B_38_3 = "POSEIDON2_B_38_3"; - Base::poseidon2_B_39_0 = "POSEIDON2_B_39_0"; - Base::poseidon2_B_39_1 = "POSEIDON2_B_39_1"; - Base::poseidon2_B_39_2 = "POSEIDON2_B_39_2"; - Base::poseidon2_B_39_3 = "POSEIDON2_B_39_3"; - Base::poseidon2_B_40_0 = "POSEIDON2_B_40_0"; - Base::poseidon2_B_40_1 = "POSEIDON2_B_40_1"; - Base::poseidon2_B_40_2 = "POSEIDON2_B_40_2"; - Base::poseidon2_B_40_3 = "POSEIDON2_B_40_3"; - Base::poseidon2_B_41_0 = "POSEIDON2_B_41_0"; - Base::poseidon2_B_41_1 = "POSEIDON2_B_41_1"; - Base::poseidon2_B_41_2 = "POSEIDON2_B_41_2"; - Base::poseidon2_B_41_3 = "POSEIDON2_B_41_3"; - Base::poseidon2_B_42_0 = "POSEIDON2_B_42_0"; - Base::poseidon2_B_42_1 = "POSEIDON2_B_42_1"; - Base::poseidon2_B_42_2 = "POSEIDON2_B_42_2"; - Base::poseidon2_B_42_3 = "POSEIDON2_B_42_3"; - Base::poseidon2_B_43_0 = "POSEIDON2_B_43_0"; - Base::poseidon2_B_43_1 = "POSEIDON2_B_43_1"; - Base::poseidon2_B_43_2 = "POSEIDON2_B_43_2"; - Base::poseidon2_B_43_3 = "POSEIDON2_B_43_3"; - Base::poseidon2_B_44_0 = "POSEIDON2_B_44_0"; - Base::poseidon2_B_44_1 = "POSEIDON2_B_44_1"; - Base::poseidon2_B_44_2 = "POSEIDON2_B_44_2"; - Base::poseidon2_B_44_3 = "POSEIDON2_B_44_3"; - Base::poseidon2_B_45_0 = "POSEIDON2_B_45_0"; - Base::poseidon2_B_45_1 = "POSEIDON2_B_45_1"; - Base::poseidon2_B_45_2 = "POSEIDON2_B_45_2"; - Base::poseidon2_B_45_3 = "POSEIDON2_B_45_3"; - Base::poseidon2_B_46_0 = "POSEIDON2_B_46_0"; - Base::poseidon2_B_46_1 = "POSEIDON2_B_46_1"; - Base::poseidon2_B_46_2 = "POSEIDON2_B_46_2"; - Base::poseidon2_B_46_3 = "POSEIDON2_B_46_3"; - Base::poseidon2_B_47_0 = "POSEIDON2_B_47_0"; - Base::poseidon2_B_47_1 = "POSEIDON2_B_47_1"; - Base::poseidon2_B_47_2 = "POSEIDON2_B_47_2"; - Base::poseidon2_B_47_3 = "POSEIDON2_B_47_3"; - Base::poseidon2_B_48_0 = "POSEIDON2_B_48_0"; - Base::poseidon2_B_48_1 = "POSEIDON2_B_48_1"; - Base::poseidon2_B_48_2 = "POSEIDON2_B_48_2"; - Base::poseidon2_B_48_3 = "POSEIDON2_B_48_3"; - Base::poseidon2_B_49_0 = "POSEIDON2_B_49_0"; - Base::poseidon2_B_49_1 = "POSEIDON2_B_49_1"; - Base::poseidon2_B_49_2 = "POSEIDON2_B_49_2"; - Base::poseidon2_B_49_3 = "POSEIDON2_B_49_3"; - Base::poseidon2_B_4_0 = "POSEIDON2_B_4_0"; - Base::poseidon2_B_4_1 = "POSEIDON2_B_4_1"; - Base::poseidon2_B_4_2 = "POSEIDON2_B_4_2"; - Base::poseidon2_B_4_3 = "POSEIDON2_B_4_3"; - Base::poseidon2_B_50_0 = "POSEIDON2_B_50_0"; - Base::poseidon2_B_50_1 = "POSEIDON2_B_50_1"; - Base::poseidon2_B_50_2 = "POSEIDON2_B_50_2"; - Base::poseidon2_B_50_3 = "POSEIDON2_B_50_3"; - Base::poseidon2_B_51_0 = "POSEIDON2_B_51_0"; - Base::poseidon2_B_51_1 = "POSEIDON2_B_51_1"; - Base::poseidon2_B_51_2 = "POSEIDON2_B_51_2"; - Base::poseidon2_B_51_3 = "POSEIDON2_B_51_3"; - Base::poseidon2_B_52_0 = "POSEIDON2_B_52_0"; - Base::poseidon2_B_52_1 = "POSEIDON2_B_52_1"; - Base::poseidon2_B_52_2 = "POSEIDON2_B_52_2"; - Base::poseidon2_B_52_3 = "POSEIDON2_B_52_3"; - Base::poseidon2_B_53_0 = "POSEIDON2_B_53_0"; - Base::poseidon2_B_53_1 = "POSEIDON2_B_53_1"; - Base::poseidon2_B_53_2 = "POSEIDON2_B_53_2"; - Base::poseidon2_B_53_3 = "POSEIDON2_B_53_3"; - Base::poseidon2_B_54_0 = "POSEIDON2_B_54_0"; - Base::poseidon2_B_54_1 = "POSEIDON2_B_54_1"; - Base::poseidon2_B_54_2 = "POSEIDON2_B_54_2"; - Base::poseidon2_B_54_3 = "POSEIDON2_B_54_3"; - Base::poseidon2_B_55_0 = "POSEIDON2_B_55_0"; - Base::poseidon2_B_55_1 = "POSEIDON2_B_55_1"; - Base::poseidon2_B_55_2 = "POSEIDON2_B_55_2"; - Base::poseidon2_B_55_3 = "POSEIDON2_B_55_3"; - Base::poseidon2_B_56_0 = "POSEIDON2_B_56_0"; - Base::poseidon2_B_56_1 = "POSEIDON2_B_56_1"; - Base::poseidon2_B_56_2 = "POSEIDON2_B_56_2"; - Base::poseidon2_B_56_3 = "POSEIDON2_B_56_3"; - Base::poseidon2_B_57_0 = "POSEIDON2_B_57_0"; - Base::poseidon2_B_57_1 = "POSEIDON2_B_57_1"; - Base::poseidon2_B_57_2 = "POSEIDON2_B_57_2"; - Base::poseidon2_B_57_3 = "POSEIDON2_B_57_3"; - Base::poseidon2_B_58_0 = "POSEIDON2_B_58_0"; - Base::poseidon2_B_58_1 = "POSEIDON2_B_58_1"; - Base::poseidon2_B_58_2 = "POSEIDON2_B_58_2"; - Base::poseidon2_B_58_3 = "POSEIDON2_B_58_3"; - Base::poseidon2_B_59_0 = "POSEIDON2_B_59_0"; - Base::poseidon2_B_59_1 = "POSEIDON2_B_59_1"; - Base::poseidon2_B_59_2 = "POSEIDON2_B_59_2"; - Base::poseidon2_B_59_3 = "POSEIDON2_B_59_3"; - Base::poseidon2_B_5_0 = "POSEIDON2_B_5_0"; - Base::poseidon2_B_5_1 = "POSEIDON2_B_5_1"; - Base::poseidon2_B_5_2 = "POSEIDON2_B_5_2"; - Base::poseidon2_B_5_3 = "POSEIDON2_B_5_3"; - Base::poseidon2_B_6_0 = "POSEIDON2_B_6_0"; - Base::poseidon2_B_6_1 = "POSEIDON2_B_6_1"; - Base::poseidon2_B_6_2 = "POSEIDON2_B_6_2"; - Base::poseidon2_B_6_3 = "POSEIDON2_B_6_3"; - Base::poseidon2_B_7_0 = "POSEIDON2_B_7_0"; - Base::poseidon2_B_7_1 = "POSEIDON2_B_7_1"; - Base::poseidon2_B_7_2 = "POSEIDON2_B_7_2"; - Base::poseidon2_B_7_3 = "POSEIDON2_B_7_3"; - Base::poseidon2_B_8_0 = "POSEIDON2_B_8_0"; - Base::poseidon2_B_8_1 = "POSEIDON2_B_8_1"; - Base::poseidon2_B_8_2 = "POSEIDON2_B_8_2"; - Base::poseidon2_B_8_3 = "POSEIDON2_B_8_3"; - Base::poseidon2_B_9_0 = "POSEIDON2_B_9_0"; - Base::poseidon2_B_9_1 = "POSEIDON2_B_9_1"; - Base::poseidon2_B_9_2 = "POSEIDON2_B_9_2"; - Base::poseidon2_B_9_3 = "POSEIDON2_B_9_3"; - Base::poseidon2_EXT_LAYER_4 = "POSEIDON2_EXT_LAYER_4"; - Base::poseidon2_EXT_LAYER_5 = "POSEIDON2_EXT_LAYER_5"; - Base::poseidon2_EXT_LAYER_6 = "POSEIDON2_EXT_LAYER_6"; - Base::poseidon2_EXT_LAYER_7 = "POSEIDON2_EXT_LAYER_7"; - Base::poseidon2_T_0_4 = "POSEIDON2_T_0_4"; - Base::poseidon2_T_0_5 = "POSEIDON2_T_0_5"; - Base::poseidon2_T_0_6 = "POSEIDON2_T_0_6"; - Base::poseidon2_T_0_7 = "POSEIDON2_T_0_7"; - Base::poseidon2_T_1_4 = "POSEIDON2_T_1_4"; - Base::poseidon2_T_1_5 = "POSEIDON2_T_1_5"; - Base::poseidon2_T_1_6 = "POSEIDON2_T_1_6"; - Base::poseidon2_T_1_7 = "POSEIDON2_T_1_7"; - Base::poseidon2_T_2_4 = "POSEIDON2_T_2_4"; - Base::poseidon2_T_2_5 = "POSEIDON2_T_2_5"; - Base::poseidon2_T_2_6 = "POSEIDON2_T_2_6"; - Base::poseidon2_T_2_7 = "POSEIDON2_T_2_7"; - Base::poseidon2_T_3_4 = "POSEIDON2_T_3_4"; - Base::poseidon2_T_3_5 = "POSEIDON2_T_3_5"; - Base::poseidon2_T_3_6 = "POSEIDON2_T_3_6"; - Base::poseidon2_T_3_7 = "POSEIDON2_T_3_7"; - Base::poseidon2_T_60_4 = "POSEIDON2_T_60_4"; - Base::poseidon2_T_60_5 = "POSEIDON2_T_60_5"; - Base::poseidon2_T_60_6 = "POSEIDON2_T_60_6"; - Base::poseidon2_T_60_7 = "POSEIDON2_T_60_7"; - Base::poseidon2_T_61_4 = "POSEIDON2_T_61_4"; - Base::poseidon2_T_61_5 = "POSEIDON2_T_61_5"; - Base::poseidon2_T_61_6 = "POSEIDON2_T_61_6"; - Base::poseidon2_T_61_7 = "POSEIDON2_T_61_7"; - Base::poseidon2_T_62_4 = "POSEIDON2_T_62_4"; - Base::poseidon2_T_62_5 = "POSEIDON2_T_62_5"; - Base::poseidon2_T_62_6 = "POSEIDON2_T_62_6"; - Base::poseidon2_T_62_7 = "POSEIDON2_T_62_7"; - Base::poseidon2_T_63_4 = "POSEIDON2_T_63_4"; - Base::poseidon2_T_63_5 = "POSEIDON2_T_63_5"; - Base::poseidon2_T_63_6 = "POSEIDON2_T_63_6"; - Base::poseidon2_T_63_7 = "POSEIDON2_T_63_7"; - Base::poseidon2_a_0 = "POSEIDON2_A_0"; - Base::poseidon2_a_1 = "POSEIDON2_A_1"; - Base::poseidon2_a_2 = "POSEIDON2_A_2"; - Base::poseidon2_a_3 = "POSEIDON2_A_3"; - Base::poseidon2_b_0 = "POSEIDON2_B_0"; - Base::poseidon2_b_1 = "POSEIDON2_B_1"; - Base::poseidon2_b_2 = "POSEIDON2_B_2"; - Base::poseidon2_b_3 = "POSEIDON2_B_3"; - Base::poseidon2_clk = "POSEIDON2_CLK"; - Base::poseidon2_in_tag = "POSEIDON2_IN_TAG"; - Base::poseidon2_input_addr = "POSEIDON2_INPUT_ADDR"; - Base::poseidon2_mem_addr_a = "POSEIDON2_MEM_ADDR_A"; - Base::poseidon2_mem_addr_b = "POSEIDON2_MEM_ADDR_B"; - Base::poseidon2_mem_addr_c = "POSEIDON2_MEM_ADDR_C"; - Base::poseidon2_mem_addr_d = "POSEIDON2_MEM_ADDR_D"; - Base::poseidon2_mem_op = "POSEIDON2_MEM_OP"; - Base::poseidon2_output_addr = "POSEIDON2_OUTPUT_ADDR"; - Base::poseidon2_read_line = "POSEIDON2_READ_LINE"; - Base::poseidon2_sel_poseidon_perm = "POSEIDON2_SEL_POSEIDON_PERM"; - Base::poseidon2_write_line = "POSEIDON2_WRITE_LINE"; - Base::powers_power_of_2 = "POWERS_POWER_OF_2"; - Base::sha256_clk = "SHA256_CLK"; - Base::sha256_input = "SHA256_INPUT"; - Base::sha256_output = "SHA256_OUTPUT"; - Base::sha256_sel_sha256_compression = "SHA256_SEL_SHA256_COMPRESSION"; - Base::sha256_state = "SHA256_STATE"; - Base::slice_addr = "SLICE_ADDR"; - Base::slice_clk = "SLICE_CLK"; - Base::slice_cnt = "SLICE_CNT"; - Base::slice_col_offset = "SLICE_COL_OFFSET"; - Base::slice_one_min_inv = "SLICE_ONE_MIN_INV"; - Base::slice_sel_cd_cpy = "SLICE_SEL_CD_CPY"; - Base::slice_sel_mem_active = "SLICE_SEL_MEM_ACTIVE"; - Base::slice_sel_return = "SLICE_SEL_RETURN"; - Base::slice_sel_start = "SLICE_SEL_START"; - Base::slice_space_id = "SLICE_SPACE_ID"; - Base::slice_val = "SLICE_VAL"; - Base::perm_pos_mem_a = "PERM_POS_MEM_A"; - Base::perm_pos_mem_b = "PERM_POS_MEM_B"; - Base::perm_pos_mem_c = "PERM_POS_MEM_C"; - Base::perm_pos_mem_d = "PERM_POS_MEM_D"; - Base::perm_slice_mem = "PERM_SLICE_MEM"; - Base::perm_main_alu = "PERM_MAIN_ALU"; - Base::perm_main_bin = "PERM_MAIN_BIN"; - Base::perm_main_conv = "PERM_MAIN_CONV"; - Base::perm_main_pos2_perm = "PERM_MAIN_POS2_PERM"; - Base::perm_main_pedersen = "PERM_MAIN_PEDERSEN"; - Base::perm_main_slice = "PERM_MAIN_SLICE"; - Base::perm_main_mem_a = "PERM_MAIN_MEM_A"; - Base::perm_main_mem_b = "PERM_MAIN_MEM_B"; - Base::perm_main_mem_c = "PERM_MAIN_MEM_C"; - Base::perm_main_mem_d = "PERM_MAIN_MEM_D"; - Base::perm_main_mem_ind_addr_a = "PERM_MAIN_MEM_IND_ADDR_A"; - Base::perm_main_mem_ind_addr_b = "PERM_MAIN_MEM_IND_ADDR_B"; - Base::perm_main_mem_ind_addr_c = "PERM_MAIN_MEM_IND_ADDR_C"; - Base::perm_main_mem_ind_addr_d = "PERM_MAIN_MEM_IND_ADDR_D"; - Base::lookup_byte_lengths = "LOOKUP_BYTE_LENGTHS"; - Base::lookup_byte_operations = "LOOKUP_BYTE_OPERATIONS"; - Base::lookup_cd_value = "LOOKUP_CD_VALUE"; - Base::lookup_ret_value = "LOOKUP_RET_VALUE"; - Base::lookup_opcode_gas = "LOOKUP_OPCODE_GAS"; - Base::range_check_l2_gas_hi = "RANGE_CHECK_L2_GAS_HI"; - Base::range_check_l2_gas_lo = "RANGE_CHECK_L2_GAS_LO"; - Base::range_check_da_gas_hi = "RANGE_CHECK_DA_GAS_HI"; - Base::range_check_da_gas_lo = "RANGE_CHECK_DA_GAS_LO"; - Base::kernel_output_lookup = "KERNEL_OUTPUT_LOOKUP"; - Base::lookup_into_kernel = "LOOKUP_INTO_KERNEL"; - Base::incl_main_tag_err = "INCL_MAIN_TAG_ERR"; - Base::incl_mem_tag_err = "INCL_MEM_TAG_ERR"; - Base::lookup_mem_rng_chk_lo = "LOOKUP_MEM_RNG_CHK_LO"; - Base::lookup_mem_rng_chk_mid = "LOOKUP_MEM_RNG_CHK_MID"; - Base::lookup_mem_rng_chk_hi = "LOOKUP_MEM_RNG_CHK_HI"; - Base::lookup_pow_2_0 = "LOOKUP_POW_2_0"; - Base::lookup_pow_2_1 = "LOOKUP_POW_2_1"; - Base::lookup_u8_0 = "LOOKUP_U8_0"; - Base::lookup_u8_1 = "LOOKUP_U8_1"; - Base::lookup_u16_0 = "LOOKUP_U16_0"; - Base::lookup_u16_1 = "LOOKUP_U16_1"; - Base::lookup_u16_2 = "LOOKUP_U16_2"; - Base::lookup_u16_3 = "LOOKUP_U16_3"; - Base::lookup_u16_4 = "LOOKUP_U16_4"; - Base::lookup_u16_5 = "LOOKUP_U16_5"; - Base::lookup_u16_6 = "LOOKUP_U16_6"; - Base::lookup_u16_7 = "LOOKUP_U16_7"; - Base::lookup_u16_8 = "LOOKUP_U16_8"; - Base::lookup_u16_9 = "LOOKUP_U16_9"; - Base::lookup_u16_10 = "LOOKUP_U16_10"; - Base::lookup_u16_11 = "LOOKUP_U16_11"; - Base::lookup_u16_12 = "LOOKUP_U16_12"; - Base::lookup_u16_13 = "LOOKUP_U16_13"; - Base::lookup_u16_14 = "LOOKUP_U16_14"; - Base::lookup_div_u16_0 = "LOOKUP_DIV_U16_0"; - Base::lookup_div_u16_1 = "LOOKUP_DIV_U16_1"; - Base::lookup_div_u16_2 = "LOOKUP_DIV_U16_2"; - Base::lookup_div_u16_3 = "LOOKUP_DIV_U16_3"; - Base::lookup_div_u16_4 = "LOOKUP_DIV_U16_4"; - Base::lookup_div_u16_5 = "LOOKUP_DIV_U16_5"; - Base::lookup_div_u16_6 = "LOOKUP_DIV_U16_6"; - Base::lookup_div_u16_7 = "LOOKUP_DIV_U16_7"; - Base::lookup_byte_lengths_counts = "LOOKUP_BYTE_LENGTHS_COUNTS"; - Base::lookup_byte_operations_counts = "LOOKUP_BYTE_OPERATIONS_COUNTS"; - Base::lookup_cd_value_counts = "LOOKUP_CD_VALUE_COUNTS"; - Base::lookup_ret_value_counts = "LOOKUP_RET_VALUE_COUNTS"; - Base::lookup_opcode_gas_counts = "LOOKUP_OPCODE_GAS_COUNTS"; - Base::range_check_l2_gas_hi_counts = "RANGE_CHECK_L2_GAS_HI_COUNTS"; - Base::range_check_l2_gas_lo_counts = "RANGE_CHECK_L2_GAS_LO_COUNTS"; - Base::range_check_da_gas_hi_counts = "RANGE_CHECK_DA_GAS_HI_COUNTS"; - Base::range_check_da_gas_lo_counts = "RANGE_CHECK_DA_GAS_LO_COUNTS"; - Base::kernel_output_lookup_counts = "KERNEL_OUTPUT_LOOKUP_COUNTS"; - Base::lookup_into_kernel_counts = "LOOKUP_INTO_KERNEL_COUNTS"; - Base::incl_main_tag_err_counts = "INCL_MAIN_TAG_ERR_COUNTS"; - Base::incl_mem_tag_err_counts = "INCL_MEM_TAG_ERR_COUNTS"; - Base::lookup_mem_rng_chk_lo_counts = "LOOKUP_MEM_RNG_CHK_LO_COUNTS"; - Base::lookup_mem_rng_chk_mid_counts = "LOOKUP_MEM_RNG_CHK_MID_COUNTS"; - Base::lookup_mem_rng_chk_hi_counts = "LOOKUP_MEM_RNG_CHK_HI_COUNTS"; - Base::lookup_pow_2_0_counts = "LOOKUP_POW_2_0_COUNTS"; - Base::lookup_pow_2_1_counts = "LOOKUP_POW_2_1_COUNTS"; - Base::lookup_u8_0_counts = "LOOKUP_U8_0_COUNTS"; - Base::lookup_u8_1_counts = "LOOKUP_U8_1_COUNTS"; - Base::lookup_u16_0_counts = "LOOKUP_U16_0_COUNTS"; - Base::lookup_u16_1_counts = "LOOKUP_U16_1_COUNTS"; - Base::lookup_u16_2_counts = "LOOKUP_U16_2_COUNTS"; - Base::lookup_u16_3_counts = "LOOKUP_U16_3_COUNTS"; - Base::lookup_u16_4_counts = "LOOKUP_U16_4_COUNTS"; - Base::lookup_u16_5_counts = "LOOKUP_U16_5_COUNTS"; - Base::lookup_u16_6_counts = "LOOKUP_U16_6_COUNTS"; - Base::lookup_u16_7_counts = "LOOKUP_U16_7_COUNTS"; - Base::lookup_u16_8_counts = "LOOKUP_U16_8_COUNTS"; - Base::lookup_u16_9_counts = "LOOKUP_U16_9_COUNTS"; - Base::lookup_u16_10_counts = "LOOKUP_U16_10_COUNTS"; - Base::lookup_u16_11_counts = "LOOKUP_U16_11_COUNTS"; - Base::lookup_u16_12_counts = "LOOKUP_U16_12_COUNTS"; - Base::lookup_u16_13_counts = "LOOKUP_U16_13_COUNTS"; - Base::lookup_u16_14_counts = "LOOKUP_U16_14_COUNTS"; - Base::lookup_div_u16_0_counts = "LOOKUP_DIV_U16_0_COUNTS"; - Base::lookup_div_u16_1_counts = "LOOKUP_DIV_U16_1_COUNTS"; - Base::lookup_div_u16_2_counts = "LOOKUP_DIV_U16_2_COUNTS"; - Base::lookup_div_u16_3_counts = "LOOKUP_DIV_U16_3_COUNTS"; - Base::lookup_div_u16_4_counts = "LOOKUP_DIV_U16_4_COUNTS"; - Base::lookup_div_u16_5_counts = "LOOKUP_DIV_U16_5_COUNTS"; - Base::lookup_div_u16_6_counts = "LOOKUP_DIV_U16_6_COUNTS"; - Base::lookup_div_u16_7_counts = "LOOKUP_DIV_U16_7_COUNTS"; - }; - }; - - class VerifierCommitments : public AllEntities { - private: - using Base = AllEntities; - - public: - VerifierCommitments(const std::shared_ptr& verification_key) - { - main_clk = verification_key->main_clk; - main_sel_first = verification_key->main_sel_first; - } - }; - - class Transcript : public NativeTranscript { - public: - uint32_t circuit_size; - - std::array commitments; - - std::vector> sumcheck_univariates; - std::array sumcheck_evaluations; - std::vector zm_cq_comms; - Commitment zm_cq_comm; - Commitment zm_pi_comm; - - Transcript() = default; - - Transcript(const std::vector& proof) - : NativeTranscript(proof) - {} - - void deserialize_full_transcript() - { - size_t num_frs_read = 0; - circuit_size = deserialize_from_buffer(proof_data, num_frs_read); - size_t log_n = numeric::get_msb(circuit_size); - - for (auto& commitment : commitments) { - commitment = deserialize_from_buffer(proof_data, num_frs_read); - } - for (size_t i = 0; i < log_n; ++i) { - sumcheck_univariates.emplace_back( - deserialize_from_buffer>(Transcript::proof_data, - num_frs_read)); - } - sumcheck_evaluations = - deserialize_from_buffer>(Transcript::proof_data, num_frs_read); - for (size_t i = 0; i < log_n; ++i) { - zm_cq_comms.push_back(deserialize_from_buffer(proof_data, num_frs_read)); - } - zm_cq_comm = deserialize_from_buffer(proof_data, num_frs_read); - zm_pi_comm = deserialize_from_buffer(proof_data, num_frs_read); - } - - void serialize_full_transcript() - { - size_t old_proof_length = proof_data.size(); - Transcript::proof_data.clear(); - size_t log_n = numeric::get_msb(circuit_size); - - serialize_to_buffer(circuit_size, Transcript::proof_data); - - for (const auto& commitment : commitments) { - serialize_to_buffer(commitment, Transcript::proof_data); - } - for (size_t i = 0; i < log_n; ++i) { - serialize_to_buffer(sumcheck_univariates[i], Transcript::proof_data); - } - serialize_to_buffer(sumcheck_evaluations, Transcript::proof_data); - for (size_t i = 0; i < log_n; ++i) { - serialize_to_buffer(zm_cq_comms[i], proof_data); - } - serialize_to_buffer(zm_cq_comm, proof_data); - serialize_to_buffer(zm_pi_comm, proof_data); - - // sanity check to make sure we generate the same length of proof as before. - ASSERT(proof_data.size() == old_proof_length); - } - }; -}; - -} // namespace bb \ No newline at end of file diff --git a/barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp b/barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp deleted file mode 100644 index 71f1b08f9cff..000000000000 --- a/barretenberg/cpp/src/barretenberg/vm/generated/avm_verifier.cpp +++ /dev/null @@ -1,248 +0,0 @@ -#include "barretenberg/vm/generated/avm_verifier.hpp" - -#include "barretenberg/commitment_schemes/zeromorph/zeromorph.hpp" -#include "barretenberg/numeric/bitop/get_msb.hpp" -#include "barretenberg/polynomials/polynomial.hpp" -#include "barretenberg/transcript/transcript.hpp" - -namespace bb { - -AvmVerifier::AvmVerifier(std::shared_ptr verifier_key) - : key(verifier_key) -{} - -AvmVerifier::AvmVerifier(AvmVerifier&& other) noexcept - : key(std::move(other.key)) - , pcs_verification_key(std::move(other.pcs_verification_key)) -{} - -AvmVerifier& AvmVerifier::operator=(AvmVerifier&& other) noexcept -{ - key = other.key; - pcs_verification_key = (std::move(other.pcs_verification_key)); - commitments.clear(); - return *this; -} - -using FF = AvmFlavor::FF; - -// Evaluate the given public input column over the multivariate challenge points -[[maybe_unused]] inline FF evaluate_public_input_column(const std::vector& points, - const size_t circuit_size, - std::vector challenges) -{ - - // TODO(https://github.com/AztecProtocol/aztec-packages/issues/6361): we pad the points to the circuit size in order - // to get the correct evaluation. This is not efficient, and will not be valid in production. - std::vector new_points(circuit_size, 0); - std::copy(points.begin(), points.end(), new_points.data()); - - Polynomial polynomial(new_points); - return polynomial.evaluate_mle(challenges); -} - -/** - * @brief This function verifies an Avm Honk proof for given program settings. - * - */ -bool AvmVerifier::verify_proof(const HonkProof& proof, const std::vector>& public_inputs) -{ - using Flavor = AvmFlavor; - using FF = Flavor::FF; - using Commitment = Flavor::Commitment; - // using PCS = Flavor::PCS; - // using Curve = Flavor::Curve; - // using ZeroMorph = ZeroMorphVerifier_; - using VerifierCommitments = Flavor::VerifierCommitments; - using CommitmentLabels = Flavor::CommitmentLabels; - - RelationParameters relation_parameters; - - transcript = std::make_shared(proof); - - VerifierCommitments commitments{ key }; - CommitmentLabels commitment_labels; - - const auto circuit_size = transcript->template receive_from_prover("circuit_size"); - - if (circuit_size != key->circuit_size) { - return false; - } - - // Get commitments to VM wires - for (auto [comm, label] : zip_view(commitments.get_wires(), commitment_labels.get_wires())) { - comm = transcript->template receive_from_prover(label); - } - - auto [beta, gamm] = transcript->template get_challenges("beta", "gamma"); - relation_parameters.beta = beta; - relation_parameters.gamma = gamm; - - // Get commitments to inverses - commitments.perm_pos_mem_a = transcript->template receive_from_prover(commitment_labels.perm_pos_mem_a); - commitments.perm_pos_mem_b = transcript->template receive_from_prover(commitment_labels.perm_pos_mem_b); - commitments.perm_pos_mem_c = transcript->template receive_from_prover(commitment_labels.perm_pos_mem_c); - commitments.perm_pos_mem_d = transcript->template receive_from_prover(commitment_labels.perm_pos_mem_d); - commitments.perm_slice_mem = transcript->template receive_from_prover(commitment_labels.perm_slice_mem); - commitments.perm_main_alu = transcript->template receive_from_prover(commitment_labels.perm_main_alu); - commitments.perm_main_bin = transcript->template receive_from_prover(commitment_labels.perm_main_bin); - commitments.perm_main_conv = transcript->template receive_from_prover(commitment_labels.perm_main_conv); - commitments.perm_main_pos2_perm = - transcript->template receive_from_prover(commitment_labels.perm_main_pos2_perm); - commitments.perm_main_pedersen = - transcript->template receive_from_prover(commitment_labels.perm_main_pedersen); - commitments.perm_main_slice = - transcript->template receive_from_prover(commitment_labels.perm_main_slice); - commitments.perm_main_mem_a = - transcript->template receive_from_prover(commitment_labels.perm_main_mem_a); - commitments.perm_main_mem_b = - transcript->template receive_from_prover(commitment_labels.perm_main_mem_b); - commitments.perm_main_mem_c = - transcript->template receive_from_prover(commitment_labels.perm_main_mem_c); - commitments.perm_main_mem_d = - transcript->template receive_from_prover(commitment_labels.perm_main_mem_d); - commitments.perm_main_mem_ind_addr_a = - transcript->template receive_from_prover(commitment_labels.perm_main_mem_ind_addr_a); - commitments.perm_main_mem_ind_addr_b = - transcript->template receive_from_prover(commitment_labels.perm_main_mem_ind_addr_b); - commitments.perm_main_mem_ind_addr_c = - transcript->template receive_from_prover(commitment_labels.perm_main_mem_ind_addr_c); - commitments.perm_main_mem_ind_addr_d = - transcript->template receive_from_prover(commitment_labels.perm_main_mem_ind_addr_d); - commitments.lookup_byte_lengths = - transcript->template receive_from_prover(commitment_labels.lookup_byte_lengths); - commitments.lookup_byte_operations = - transcript->template receive_from_prover(commitment_labels.lookup_byte_operations); - commitments.lookup_cd_value = - transcript->template receive_from_prover(commitment_labels.lookup_cd_value); - commitments.lookup_ret_value = - transcript->template receive_from_prover(commitment_labels.lookup_ret_value); - commitments.lookup_opcode_gas = - transcript->template receive_from_prover(commitment_labels.lookup_opcode_gas); - commitments.range_check_l2_gas_hi = - transcript->template receive_from_prover(commitment_labels.range_check_l2_gas_hi); - commitments.range_check_l2_gas_lo = - transcript->template receive_from_prover(commitment_labels.range_check_l2_gas_lo); - commitments.range_check_da_gas_hi = - transcript->template receive_from_prover(commitment_labels.range_check_da_gas_hi); - commitments.range_check_da_gas_lo = - transcript->template receive_from_prover(commitment_labels.range_check_da_gas_lo); - commitments.kernel_output_lookup = - transcript->template receive_from_prover(commitment_labels.kernel_output_lookup); - commitments.lookup_into_kernel = - transcript->template receive_from_prover(commitment_labels.lookup_into_kernel); - commitments.incl_main_tag_err = - transcript->template receive_from_prover(commitment_labels.incl_main_tag_err); - commitments.incl_mem_tag_err = - transcript->template receive_from_prover(commitment_labels.incl_mem_tag_err); - commitments.lookup_mem_rng_chk_lo = - transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_lo); - commitments.lookup_mem_rng_chk_mid = - transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_mid); - commitments.lookup_mem_rng_chk_hi = - transcript->template receive_from_prover(commitment_labels.lookup_mem_rng_chk_hi); - commitments.lookup_pow_2_0 = transcript->template receive_from_prover(commitment_labels.lookup_pow_2_0); - commitments.lookup_pow_2_1 = transcript->template receive_from_prover(commitment_labels.lookup_pow_2_1); - commitments.lookup_u8_0 = transcript->template receive_from_prover(commitment_labels.lookup_u8_0); - commitments.lookup_u8_1 = transcript->template receive_from_prover(commitment_labels.lookup_u8_1); - commitments.lookup_u16_0 = transcript->template receive_from_prover(commitment_labels.lookup_u16_0); - commitments.lookup_u16_1 = transcript->template receive_from_prover(commitment_labels.lookup_u16_1); - commitments.lookup_u16_2 = transcript->template receive_from_prover(commitment_labels.lookup_u16_2); - commitments.lookup_u16_3 = transcript->template receive_from_prover(commitment_labels.lookup_u16_3); - commitments.lookup_u16_4 = transcript->template receive_from_prover(commitment_labels.lookup_u16_4); - commitments.lookup_u16_5 = transcript->template receive_from_prover(commitment_labels.lookup_u16_5); - commitments.lookup_u16_6 = transcript->template receive_from_prover(commitment_labels.lookup_u16_6); - commitments.lookup_u16_7 = transcript->template receive_from_prover(commitment_labels.lookup_u16_7); - commitments.lookup_u16_8 = transcript->template receive_from_prover(commitment_labels.lookup_u16_8); - commitments.lookup_u16_9 = transcript->template receive_from_prover(commitment_labels.lookup_u16_9); - commitments.lookup_u16_10 = transcript->template receive_from_prover(commitment_labels.lookup_u16_10); - commitments.lookup_u16_11 = transcript->template receive_from_prover(commitment_labels.lookup_u16_11); - commitments.lookup_u16_12 = transcript->template receive_from_prover(commitment_labels.lookup_u16_12); - commitments.lookup_u16_13 = transcript->template receive_from_prover(commitment_labels.lookup_u16_13); - commitments.lookup_u16_14 = transcript->template receive_from_prover(commitment_labels.lookup_u16_14); - commitments.lookup_div_u16_0 = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_0); - commitments.lookup_div_u16_1 = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_1); - commitments.lookup_div_u16_2 = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_2); - commitments.lookup_div_u16_3 = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_3); - commitments.lookup_div_u16_4 = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_4); - commitments.lookup_div_u16_5 = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_5); - commitments.lookup_div_u16_6 = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_6); - commitments.lookup_div_u16_7 = - transcript->template receive_from_prover(commitment_labels.lookup_div_u16_7); - - // Execute Sumcheck Verifier - const size_t log_circuit_size = numeric::get_msb(circuit_size); - auto sumcheck = SumcheckVerifier(log_circuit_size, transcript); - - FF alpha = transcript->template get_challenge("Sumcheck:alpha"); - - auto gate_challenges = std::vector(log_circuit_size); - for (size_t idx = 0; idx < log_circuit_size; idx++) { - gate_challenges[idx] = transcript->template get_challenge("Sumcheck:gate_challenge_" + std::to_string(idx)); - } - - auto [multivariate_challenge, claimed_evaluations, sumcheck_verified] = - sumcheck.verify(relation_parameters, alpha, gate_challenges); - - // If Sumcheck did not verify, return false - if (sumcheck_verified.has_value() && !sumcheck_verified.value()) { - return false; - } - - // Public columns evaluation checks - std::vector mle_challenge(multivariate_challenge.begin(), - multivariate_challenge.begin() + static_cast(log_circuit_size)); - - FF kernel_kernel_inputs_evaluation = evaluate_public_input_column(public_inputs[0], circuit_size, mle_challenge); - if (kernel_kernel_inputs_evaluation != claimed_evaluations.kernel_kernel_inputs) { - return false; - } - FF kernel_kernel_value_out_evaluation = evaluate_public_input_column(public_inputs[1], circuit_size, mle_challenge); - if (kernel_kernel_value_out_evaluation != claimed_evaluations.kernel_kernel_value_out) { - return false; - } - FF kernel_kernel_side_effect_out_evaluation = - evaluate_public_input_column(public_inputs[2], circuit_size, mle_challenge); - if (kernel_kernel_side_effect_out_evaluation != claimed_evaluations.kernel_kernel_side_effect_out) { - return false; - } - FF kernel_kernel_metadata_out_evaluation = - evaluate_public_input_column(public_inputs[3], circuit_size, mle_challenge); - if (kernel_kernel_metadata_out_evaluation != claimed_evaluations.kernel_kernel_metadata_out) { - return false; - } - FF main_calldata_evaluation = evaluate_public_input_column(public_inputs[4], circuit_size, mle_challenge); - if (main_calldata_evaluation != claimed_evaluations.main_calldata) { - return false; - } - FF main_returndata_evaluation = evaluate_public_input_column(public_inputs[5], circuit_size, mle_challenge); - if (main_returndata_evaluation != claimed_evaluations.main_returndata) { - return false; - } - - // Execute ZeroMorph rounds. See https://hackmd.io/dlf9xEwhTQyE3hiGbq4FsA?view for a complete description of the - // unrolled protocol. - // NOTE: temporarily disabled - facing integration issues - // auto opening_claim = ZeroMorph::verify(circuit_size, - // commitments.get_unshifted(), - // commitments.get_to_be_shifted(), - // claimed_evaluations.get_unshifted(), - // claimed_evaluations.get_shifted(), - // multivariate_challenge, - // pcs_verification_key->get_g1_identity(), - // transcript); - - // auto pairing_points = PCS::reduce_verify(opening_claim, transcript); - // auto verified = pcs_verification_key->pairing_check(pairing_points[0], pairing_points[1]); - // return sumcheck_verified.value() && verified; - return sumcheck_verified.value(); -} - -} // namespace bb diff --git a/barretenberg/srs_db/grumpkin/monomial/transcript00.dat b/barretenberg/srs_db/grumpkin/monomial/transcript00.dat deleted file mode 100644 index 7971743c1a87df13d27a4ee78cfcb09db0ad763f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 92 zcmZQz00TxK3Bn)%qZ#I%|2xk`