From c91c34756aa1fa077764f44ddc86679577a3db44 Mon Sep 17 00:00:00 2001 From: Jean M <132435771+jeanmon@users.noreply.github.com> Date: Wed, 22 Apr 2026 15:50:05 +0200 Subject: [PATCH 1/2] chore(avm)!: execution internal audit second pass (#22552) Linear issue: [AVM-242](https://linear.app/aztec-labs/issue/AVM-242/execution-second-pass) --- barretenberg/cpp/pil/vm2/context.pil | 27 +- barretenberg/cpp/pil/vm2/execution.pil | 397 +++++++++++++----- .../cpp/pil/vm2/execution/addressing.pil | 82 ++-- barretenberg/cpp/pil/vm2/execution/gas.pil | 27 +- .../cpp/pil/vm2/execution/registers.pil | 24 +- barretenberg/cpp/pil/vm2/memory.pil | 2 +- .../cpp/pil/vm2/trees/public_data_check.pil | 2 +- .../cpp/pil/vm2/trees/public_data_squash.pil | 2 +- barretenberg/cpp/pil/vm2/tx.pil | 84 ++-- barretenberg/cpp/pil/vm2/tx_context.pil | 10 +- .../harness/external_call.fuzzer.cpp | 2 + .../relations/addressing.test.cpp | 138 +++--- .../relations/exec_op_id.test.cpp | 4 +- .../constraining/relations/execution.test.cpp | 111 ++++- .../vm2/constraining/relations/gas.test.cpp | 14 +- .../relations/get_env_var.test.cpp | 30 +- .../constraining/relations/registers.test.cpp | 20 +- .../vm2/constraining/relations/tx.test.cpp | 17 +- .../relations/tx_context.test.cpp | 6 +- .../barretenberg/vm2/generated/columns.hpp | 4 +- .../vm2/generated/relations/addressing.hpp | 4 +- .../generated/relations/addressing_impl.hpp | 83 ++-- .../vm2/generated/relations/execution.hpp | 9 +- .../generated/relations/execution_impl.hpp | 58 ++- .../vm2/generated/relations/gas.hpp | 10 +- .../vm2/generated/relations/gas_impl.hpp | 8 +- .../vm2/generated/relations/lookups_gas.hpp | 6 +- .../vm2/generated/relations/lookups_tx.hpp | 10 +- .../vm2/generated/relations/memory.hpp | 2 +- .../vm2/generated/relations/memory_impl.hpp | 5 +- .../generated/relations/perms_addressing.hpp | 14 +- .../vm2/generated/relations/perms_tx.hpp | 6 +- .../generated/relations/public_data_check.hpp | 2 +- .../relations/public_data_check_impl.hpp | 6 +- .../relations/public_data_squash.hpp | 2 +- .../relations/public_data_squash_impl.hpp | 6 +- .../vm2/generated/relations/registers.hpp | 2 +- .../generated/relations/registers_impl.hpp | 26 +- .../generated/relations/tx_context_impl.hpp | 10 +- .../vm2/generated/relations/tx_impl.hpp | 54 +-- .../vm2/simulation/gadgets/execution.cpp | 5 +- .../vm2/simulation/gadgets/execution.hpp | 32 +- .../gadgets/execution_components.cpp | 20 +- .../gadgets/execution_components.hpp | 21 +- .../vm2/tracegen/execution_trace.cpp | 140 ++++-- .../vm2/tracegen/execution_trace.test.cpp | 21 +- .../barretenberg/vm2/tracegen/tx_trace.cpp | 14 +- 47 files changed, 985 insertions(+), 594 deletions(-) diff --git a/barretenberg/cpp/pil/vm2/context.pil b/barretenberg/cpp/pil/vm2/context.pil index bf050b4e4c58..6000b268fd2d 100644 --- a/barretenberg/cpp/pil/vm2/context.pil +++ b/barretenberg/cpp/pil/vm2/context.pil @@ -9,24 +9,27 @@ include "opcodes/internal_call.pil"; // This subtrace has interactions with context_stack.pil. namespace execution; - // This the same sel as in execution + // This is the same sel as in execution #[skippable_if] sel = 0; // Guaranteed to be boolean because sel_execute_call & sel_execute_static_call are mutually exclusive + // (by #[EXEC_OP_ID_DECOMPOSITION] in execution.pil, which makes sel_execute_call, sel_execute_static_call, + // sel_execute_return, and sel_execute_revert pairwise mutually exclusive). pol commit sel_enter_call; // @boolean (by definition) // The following selectors will be 0 if there is an error during execution (before the opcode execution step). sel_enter_call = sel_execute_call + sel_execute_static_call; - // sel_enter_call and precomputed.first_row are mutually exclusive because - // `sel == 0` ==> `sel_enter_call == 0` as explained in execution.pil and `sel` has a shift and - // must be 0 on the first row. - - // sel_exit_call is used to flag if we are returning or reverting or there has been ANY error during execution - // sel_execute_revert & sel_execute_return are mutually exclusive. - // By #[INFALLIBLE_OPCODES_SUCCESS] in execution.pil, sel_opcode_error is mutually exclusive - // with sel_execute_revert and sel_execute_return. As sel_opcode_error is a specific error of the last temporality - // group, sel_error is mutually exclusive with sel_execute_revert and sel_execute_return. Namely, if - // an error occurs earlier neither sel_execute_revert nor sel_execute_return can be activated. + // sel_enter_call is mutually exclusive with: + // - precomputed.first_row: `sel == 0` ==> `sel_enter_call == 0` as explained in execution.pil, + // and `sel` has a shift and must be 0 on the first row. + // - sel_exit_call: `sel_error == 1` deactivates (cascade) sel_execute_call and sel_execute_static_call. + + // sel_exit_call is used to flag if we are returning or reverting or there has been ANY error during execution. + // It is boolean because sel_execute_revert, sel_execute_return, and sel_error are pairwise mutually exclusive: + // - sel_execute_revert and sel_execute_return: by #[EXEC_OP_ID_DECOMPOSITION] in execution.pil. + // - sel_opcode_error with sel_execute_revert/_return: by #[INFALLIBLE_OPCODES_SUCCESS] in execution.pil. + // Since sel_opcode_error is the error of the last temporality group, sel_error is mutually exclusive + // with sel_execute_revert and sel_execute_return. pol commit sel_exit_call; // @boolean (by definition) sel_exit_call = sel_failure + sel_execute_return; // sel_failure = sel_error + sel_execute_revert (discard.pil) @@ -155,7 +158,7 @@ namespace execution; /* Partitioning of an active row: * - * In what most of the constraints below, we partition the active rows into the following cases: + * In most of the constraints below, we partition the active rows into the following cases: * - Enter nested call: sel_enter_call == 1 * - Nested return: nested_return == 1 * - Nested failure: nested_failure == 1 diff --git a/barretenberg/cpp/pil/vm2/execution.pil b/barretenberg/cpp/pil/vm2/execution.pil index 359021d2c84d..98bffa729581 100644 --- a/barretenberg/cpp/pil/vm2/execution.pil +++ b/barretenberg/cpp/pil/vm2/execution.pil @@ -1,63 +1,195 @@ include "alu.pil"; -include "range_check.pil"; include "bitwise.pil"; -include "memory.pil"; -include "keccakf1600.pil"; -include "precomputed.pil"; -include "sha256_mem.pil"; +include "data_copy.pil"; include "ecc_mem.pil"; -include "poseidon2_mem.pil"; -include "scalar_mul.pil"; -include "to_radix_mem.pil"; include "ff_gt.pil"; include "gt.pil"; -include "context.pil"; -include "context_stack.pil"; +include "keccakf1600.pil"; +include "memory.pil"; +include "poseidon2_mem.pil"; +include "precomputed.pil"; include "public_inputs.pil"; - -include "data_copy.pil"; -include "internal_call_stack.pil"; - -include "execution/addressing.pil"; -include "execution/discard.pil"; -include "execution/gas.pil"; -include "execution/registers.pil"; - -include "trees/merkle_check.pil"; -include "trees/indexed_tree_check.pil"; -include "trees/public_data_check.pil"; -include "trees/l1_to_l2_message_tree_check.pil"; +include "range_check.pil"; +include "scalar_mul.pil"; +include "sha256_mem.pil"; +include "to_radix_mem.pil"; include "bytecode/address_derivation.pil"; include "bytecode/bc_decomposition.pil"; include "bytecode/bc_hashing.pil"; include "bytecode/bc_retrieval.pil"; -include "bytecode/instr_fetching.pil"; include "bytecode/class_id_derivation.pil"; +include "bytecode/instr_fetching.pil"; include "bytecode/update_check.pil"; -include "opcodes/get_env_var.pil"; +include "opcodes/emit_public_log.pil"; include "opcodes/get_contract_instance.pil"; -include "opcodes/internal_call.pil"; -include "opcodes/external_call.pil"; -include "opcodes/sload.pil"; -include "opcodes/sstore.pil"; -include "opcodes/notehash_exists.pil"; + +include "trees/indexed_tree_check.pil"; +include "trees/l1_to_l2_message_tree_check.pil"; +include "trees/merkle_check.pil"; +include "trees/public_data_check.pil"; + +// Components that extend namespace execution (share columns with the execution trace). +include "context.pil"; + +include "execution/addressing.pil"; +include "execution/discard.pil"; +include "execution/gas.pil"; +include "execution/registers.pil"; + include "opcodes/emit_notehash.pil"; +include "opcodes/emit_nullifier.pil"; +include "opcodes/external_call.pil"; +include "opcodes/get_env_var.pil"; +include "opcodes/internal_call.pil"; include "opcodes/l1_to_l2_message_exists.pil"; +include "opcodes/notehash_exists.pil"; include "opcodes/nullifier_exists.pil"; -include "opcodes/emit_nullifier.pil"; -include "opcodes/emit_public_log.pil"; include "opcodes/send_l2_to_l1_msg.pil"; +include "opcodes/sload.pil"; +include "opcodes/sstore.pil"; /** -* Usage: Exactly two permutations from the tx trace to dispatch execution of an enqueued call. -* First one is to dispatch the start of an enqueued call to the execution trace and the -* second one is to retrieve the results from the end of an enqueued call to the execution trace. -* - #[DISPATCH_EXEC_START]: destination selector `enqueued_call_start` -* - #[DISPATCH_EXEC_END]: destination selector `enqueued_call_end` -* See details in tx.pil. -*/ + * EXECUTION TRACE + * + * This is the main trace for AVM execution. Each active row corresponds to the execution of + * exactly one opcode. The active rows are organized in contiguous blocks, where each block + * corresponds to the execution of a public call request (enqueued call) dispatched by tx.pil. + * A block starts with `enqueued_call_start == 1` and ends with `enqueued_call_end == 1`. + * A context represents the per-call execution state (contract address, pc, gas, memory, etc.) + * identified by a `context_id`. + * Within a block, nested calls (CALL/STATICCALL) switch context without breaking the contiguous + * row sequence — the context stack (context_stack.pil) tracks saved/restored state. + * + * TRACE SHAPE + * + * Row 0 is always inactive (sel == 0). Active rows follow contiguously until the last + * enqueued call ends, after which all remaining rows are inactive. Each active row + * processes one opcode. Each block of active rows between `enqueued_call_start == 1` + * and `enqueued_call_end == 1` represents the full execution of one public call request + * (enqueued call) sent by tx.pil (via #[DISPATCH_EXEC_START] and #[DISPATCH_EXEC_END]). + * + * | row | sel | enqueued_call_start | enqueued_call_end | context_id | opcode | + * |-----|-----|---------------------|-------------------|------------|------------| + * | 0 | 0 | 0 | 0 | 0 | | + * | 1 | 1 | 1 | 0 | 1 | SET | <- enqueued call 1 start + * | 2 | 1 | 0 | 0 | 1 | CALL | + * | 3 | 1 | 0 | 0 | 2 | ADD | <- nested context + * | 4 | 1 | 0 | 0 | 2 | RETURN | + * | 5 | 1 | 0 | 0 | 1 | MOV | <- back to parent + * | 6 | 1 | 0 | 1 | 1 | RETURN | <- enqueued call 1 end + * | 7 | 1 | 1 | 0 | 3 | SET | <- enqueued call 2 start + * | 8 | 1 | 0 | 1 | 3 | RETURN | <- enqueued call 2 end + * | 9 | 0 | 0 | 0 | 0 | | <- inactive padding + * + * TEMPORALITY GROUPS + * + * Each row processes one instruction through 6 sequential temporality groups. An error in any + * group stops processing for subsequent groups on that row: + * + * TG1: Bytecode retrieval — retrieve bytecode (first row in context only). + * TG2: Instruction fetching — fetch and decode instruction, resolve operand addresses. + * TG3: Register read — read input registers from memory, validate tags. + * TG4: Gas — consume base + dynamic gas. + * TG5: Opcode execution — execute opcode logic, dispatch to subtraces. + * TG6: Register write — write output registers to memory. Cannot error. + * + * The temporality group selectors form a deactivation cascade (see SELECTOR DEACTIVATION CASCADE + * below): sel == 0 deactivates all of them, and an error in group N deactivates subsequent groups. + * See ERRORS below for the per-group error labels. + * + * ERRORS + * + * Errors are mutually exclusive (at most one per row) and collected in `sel_error`. When any + * error occurs, the context halts exceptionally: all remaining gas is consumed, and the context + * is marked as failed. The mutual exclusion is enforced by the temporality group cascade: an + * error in group N deactivates all subsequent groups, preventing later errors. See the comment + * at `sel_error` for the full proof. + * + * The 6 error types, in temporality group order (selector | ExecutionError label): + * 1. sel_bytecode_retrieval_failure | BYTECODE_RETRIEVAL (TG1): Bytecode for the contract + * could not be retrieved (e.g., contract not deployed, too many unique bytecodes). + * 2. sel_instruction_fetching_failure | INSTRUCTION_FETCHING (TG2): Instruction at the current + * PC could not be decoded (e.g., invalid opcode, PC out of bounds). + * 3. sel_addressing_error | ADDRESSING (TG2): Operand address resolution + * failed (e.g., invalid base address tag, relative overflow, invalid tag after indirection). + * 4. sel_register_read_error | REGISTER_READ (TG3): Input register tag does + * not match the expected tag for the opcode. + * 5. sel_out_of_gas | GAS (TG4): Cumulative gas usage + * exceeds the gas limit (L2 or DA). + * 6. sel_opcode_error | OPCODE_EXECUTION (TG5): Opcode-specific execution + * error (e.g., division by zero, static context violation, nullifier collision, + * maximum side effects reached). + * + * INTERACTIONS (outgoing — this trace as source) + * + * Bytecode: + * - #[BYTECODE_RETRIEVAL_RESULT] -> bc_retrieval: retrieve bytecode for a context. + * - #[INSTRUCTION_FETCHING_RESULT] -> instr_fetching: check if instruction fetch succeeds. + * - #[INSTRUCTION_FETCHING_BODY] -> instr_fetching: fetch instruction opcode and operands. + * - #[EXEC_SPEC_READ] -> precomputed: read execution spec (gas costs, register info, subtrace dispatch). + * + * Gas (dynamic): + * - #[DYN_L2_FACTOR_BITWISE] -> precomputed: tag-based byte length for bitwise gas. + * - #[CHECK_RADIX_GT_256] -> gt: compare radix > 256. + * - #[GET_P_LIMBS] -> precomputed: lookup num_p_limbs for to_radix gas. + * - #[GET_MAX_LIMBS] -> gt: compare num_limbs > num_p_limbs. + * - #[CHECK_WRITTEN_STORAGE_SLOT] -> indexed_tree_check: check if slot was previously + * written (sstore gas). + * + * Opcode dispatch (lookups for pure/deduplicated computations): + * - #[DISPATCH_TO_ALU] -> alu (arithmetic): ADD, SUB, MUL, DIV, FDIV, EQ, LT, LTE, NOT, SHL, SHR. + * - #[DISPATCH_TO_BITWISE] -> bitwise: AND, OR, XOR. + * - #[DISPATCH_TO_CAST] -> alu (truncate): CAST. + * - #[DISPATCH_TO_SET] -> alu (truncate): SET. + * + * Opcode dispatch (permutations for side-effecting/memory-writing computations): + * - #[DISPATCH_TO_CD_COPY] -> data_copy: CALLDATACOPY. + * - #[DISPATCH_TO_RD_COPY] -> data_copy: RETURNDATACOPY. + * - #[DISPATCH_TO_GET_CONTRACT_INSTANCE] -> get_contract_instance: GETCONTRACTINSTANCE. + * - #[DISPATCH_TO_EMIT_PUBLIC_LOG] -> emit_public_log: EMITPUBLICLOG. + * - #[DISPATCH_TO_POSEIDON2_PERM] -> poseidon2_perm_mem: POSEIDON2PERM. + * - #[DISPATCH_TO_SHA256_COMPRESSION] -> sha256: SHA256COMPRESSION. + * - #[DISPATCH_TO_KECCAKF1600] -> keccakf1600: KECCAKF1600. + * - #[DISPATCH_TO_ECC_ADD] -> ecc_add_mem: ECADD. + * - #[DISPATCH_TO_TO_RADIX] -> to_radix_mem: TORADIXBE. + * + * VIRTUAL SUBTRACES (files sharing namespace execution) + * + * The following PIL files define constraints under `namespace execution` and share columns + * with this trace. They are "virtual" subtraces — not separate traces but additional + * constraint sets over the same rows: + * + * Core: + * - context.pil: Context propagation (context_id, parent_id, pc, gas, tree state, etc.). + * - execution/addressing.pil: Operand resolution (relative addressing, indirection). + * - execution/discard.pil: Side-effect discarding on error (discard flag, dying context). + * - execution/gas.pil: Gas computation and out-of-gas detection. + * - execution/registers.pil: Register read/write memory operations and tag checks. + * + * Opcodes (each constrains opcode-specific columns on execution rows): + * - opcodes/emit_notehash.pil: EMITNOTEHASH opcode. + * - opcodes/emit_nullifier.pil: EMITNULLIFIER opcode. + * - opcodes/external_call.pil: CALL and STATICCALL opcodes. + * - opcodes/get_env_var.pil: GETENVVAR opcode. + * - opcodes/internal_call.pil: INTERNALCALL and INTERNALRETURN opcodes. + * - opcodes/l1_to_l2_message_exists.pil: L1TOL2MSGEXISTS opcode. + * - opcodes/notehash_exists.pil: NOTEHASHEXISTS opcode. + * - opcodes/nullifier_exists.pil: NULLIFIEREXISTS opcode. + * - opcodes/send_l2_to_l1_msg.pil: SENDL2TOL1MSG opcode. + * - opcodes/sload.pil: SLOAD opcode. + * - opcodes/sstore.pil: SSTORE opcode. + * + * INTERACTIONS (incoming — this trace as destination) + * + * From tx.pil: + * - #[DISPATCH_EXEC_START]: permutation into `enqueued_call_start`. Initializes context_id, + * msg_sender, contract_address, gas limits, tree state, side effect counters, etc. + * - #[DISPATCH_EXEC_END]: permutation into `enqueued_call_end`. Retrieves next_context_id, + * sel_failure, discard, final tree state, side effect counters, gas used. + * See tx.pil for the full tuple definitions. + */ namespace execution; @@ -79,8 +211,8 @@ sel * (1 - sel) = 0; * In particular, the opcode selectors or dispatching selectors to other sub-traces. * We observe the following deactivation cascade of selectors: * `sel == 0` ==> `sel_bytecode_retrieval_success == 0` ==> `sel_instruction_fetching_success == 0` -* ==> `sel_should_read_registers == 0` ==> `sel_should_check_gas == 0` ==> `sel_should_execute_opcode == 0` -* ==> `sel_should_write_registers = 0` +* ==> `sel_read_registers == 0` ==> `sel_check_gas == 0` ==> `sel_execute_opcode == 0` +* ==> `sel_write_registers == 0` * By #[SUBTRACE_ID_DECOMPOSITION], this implies that dispatching selectors are off on an inactive row, * i.e., `sel_exec_dispatch_execution == 0`, `sel_exec_dispatch_alu == 0`, `sel_exec_dispatch_bitwise == 0`, ... * From #[EXEC_OP_ID_DECOMPOSITION], we have the selectors for execution opcodes: @@ -90,10 +222,18 @@ sel * (1 - sel) = 0; // Selector indicating enqueued call boundaries. // Used by TX trace for lookups to dispatch and retrieve results/reverted. -pol commit enqueued_call_start; // @boolean -pol commit enqueued_call_end; // @boolean -// Both `enqueued_call_XXX` selectors are boolean on active rows by definition. -// On non-active rows, they are 0 (explanations below). +pol commit enqueued_call_start; // @boolean (see below) +pol commit enqueued_call_end; // @boolean (see below) + +// enqueued_call_start is boolean: +// enqueued_call_start' = (precomputed.first_row + enqueued_call_end) * sel'. Since sel' is explicitly +// boolean, we show that enqueued_call_end is mutually exclusive with precomputed.first_row. +// This follows from `sel == 0 ==> enqueued_call_end == 0` (proven below) and the fact that +// sel cannot be 1 on the first row. +// +// enqueued_call_end is boolean: +// enqueued_call_end = sel_exit_call * (1 - has_parent_ctx) where has_parent_ctx is explicitly boolean. +// sel_exit_call is shown to be boolean in context.pil. // (enqueued_call_start == 1) <==> (is first active execution row) // or (is first active row after an enqueued call ends) @@ -108,33 +248,57 @@ enqueued_call_end = sel_exit_call * (1 - has_parent_ctx); // First row after *CALL, or first row of enqueued call // This is the only row where bytecode retrieval is active. -pol commit sel_first_row_in_context; // @boolean +pol commit sel_first_row_in_context; // @boolean (see below) sel_first_row_in_context' = sel_enter_call + enqueued_call_start'; -// This selector is boolean because when sel_enter_call == 1, this row cannot -// error per #[INFALLIBLE_OPCODES_SUCCESS] and therefore next row cannot -// have `enqueued_call_start == 1`. +// sel_first_row_in_context is boolean: +// sel_enter_call and enqueued_call_start' being boolean, we need to show mutual exclusion. +// When sel_enter_call == 1: +// - As shown in context.pil, sel_exit_call and sel_enter_call are mutually exclusive. +// Therefore sel_exit_call = 0, giving enqueued_call_end = 0. +// - sel_enter_call == 1 requires sel == 1 and therefore it cannot be the first row. +// - By definition (#[ENQUEUED_CALL_START]), enqueued_call_start' = 0. +// +// Note on row 0: sel_first_row_in_context is a shifted column, so the proving system guarantees +// it is 0 on the first row. -/** -* DEACTIVATION FOR ENQUEUED_CALL_START/END/SEL_FIRST_ROW_IN_CONTEXT -* If `sel == 0`, we have `enqueued_call_start == 0` by definition (#[ENQUEUED_CALL_START]); -* From the "above cascade of de-activation": -* `sel == 0` ==> `sel_execute_call == 0` and `sel_execute_static_call == 0`. -* Thus, `sel_enter_call == 0` by definition in context.pil. -* As a consequence, `sel_first_row_in_context == 0` by definition. -* As explained below at the definition of `sel_error`, we also have `sel_error == 0` if `sel == 0`. -* Combining this with `sel_exec_return == 0`, `sel_exec_revert == 0`, and the definition of `sel_exit_call` -* in context.pil, we have `sel_exit_call == 0` if `sel == 0`. -* Finally, it follows that enqueued_call_end == 0 if `sel == 0`. -*/ -// If sel = 0, and it's not the first row, then all following rows should have sel = 0. +// `sel` can change only at the first row or at the end of an enqueued call. #[TRACE_CONTINUITY] -(1 - sel) * (1 - precomputed.first_row) * sel' = 0; +(1 - precomputed.first_row - enqueued_call_end) * (sel - sel') = 0; + +// Remark: The relations above are a variant of the recipe for contiguous multi-row computation. +// See https://github.com/AztecProtocol/aztec-packages/blob/next/barretenberg/cpp/pil/vm2/docs/recipes.md#contiguous-multi-rows-computation-trace +// The difference is that explicit boolean relations are not required and we apply a stricter version +// of #[START_AFTER_LATCH] with #[ENQUEUED_CALL_START] which gives us the guarantee that +// `sel == 0 ==> enqueued_call_start == 0`. +// The property `sel == 0 ==> enqueued_call_end == 0` is also not explicit but is given +// below (paragraph on DEACTIVATION FOR ...). +// As a consequence, we guarantee that the active part of the trace is contiguous and composed +// of successive enqueued call blocks starting with `enqueued_call_start == 1` and ending with +// `enqueued_call_end == 1`. + + +// DEACTIVATION FOR ENQUEUED_CALL_START/END/SEL_FIRST_ROW_IN_CONTEXT +// If `sel == 0`, we have `enqueued_call_start == 0` by definition (#[ENQUEUED_CALL_START]). +// +// For `sel_first_row_in_context`: recall that `sel_first_row_in_context' = sel_enter_call + enqueued_call_start'`, +// so `sel_first_row_in_context` on row r depends on `sel_enter_call` on row r-1 and `enqueued_call_start` on row r. +// We already showed `enqueued_call_start == 0` on row r. For `sel_enter_call` on row r-1: +// By #[TRACE_CONTINUITY], either `sel[r-1] == 0` (cascade gives `sel_enter_call == 0`) or +// `enqueued_call_end[r-1] == 1` (which requires `sel_exit_call == 1`, and since `sel_enter_call` +// and `sel_exit_call` are mutually exclusive — see context.pil — we get `sel_enter_call == 0`). +// In both cases, `sel_first_row_in_context[r] = 0 + 0 = 0`. +// +// As explained below at the definition of `sel_error`, we also have `sel_error == 0` if `sel == 0`. +// Combining this with `sel_execute_return == 0`, `sel_execute_revert == 0`, and the definition of `sel_exit_call` +// in context.pil, we have `sel_exit_call == 0` if `sel == 0`. +// Finally, it follows that `enqueued_call_end == 0` if `sel == 0`. + pol commit clk; -// Initialize clk to 0 on the first row and at the same time enforces that clk is 0 if sel = 0. +// Initialize clk to 0 on the first row and at the same time it enforces that clk is 0 if sel = 0. #[EXEC_CLK_INIT] (1 - sel) * clk = 0; @@ -146,9 +310,17 @@ sel' * (clk + 1 - clk') = 0; * Temporality group 1: Bytecode retrieval (unconditional) **************************************************************************************************/ -pol commit sel_bytecode_retrieval_failure; // @Boolean -// When `sel_first_row_in_context == 1`, sel_bytecode_retrieval_failure is boolean -// thanks to #[BYTECODE_RETRIEVAL_RESULT]. Otherwise, it is 0 from #[BYTECODE_RETRIEVAL_NO_FAILURE]. +pol commit sel_bytecode_retrieval_failure; // @boolean +// sel_bytecode_retrieval_failure is boolean by case analysis on sel_first_row_in_context: +// - If sel_first_row_in_context == 1: constrained by #[BYTECODE_RETRIEVAL_RESULT] to match +// bc_retrieval.error (boolean). The lookup selector is 1 (boolean), so the lookup is sound. +// - If sel_first_row_in_context != 1 (any other field value, not just 0): #[BYTECODE_RETRIEVAL_NO_FAILURE] +// gives (1 - sel_first_row_in_context) * sel_bytecode_retrieval_failure = 0, and since +// (1 - sel_first_row_in_context) != 0, we get sel_bytecode_retrieval_failure = 0. +// Crucially, this argument does NOT require sel_first_row_in_context to be boolean. This matters +// because proving sel_first_row_in_context boolean depends on the cascade of temporality group selectors +// (including sel_bytecode_retrieval_failure). Relying on sel_first_row_in_context being boolean +// here would create a circular dependency. // We perform this lookup "only" on the first row of the context and therefore, // we need to propagate `bytecode_id`, etc. down to the subsequent rows in the context. @@ -185,12 +357,17 @@ sel_first_row_in_context { #[BYTECODE_RETRIEVAL_NO_FAILURE] (1 - sel_first_row_in_context) * sel_bytecode_retrieval_failure = 0; -// Since `sel == 0` ==> `sel_first_row_in_context == 0`, we have: -// `sel == 0` ==> `sel_bytecode_retrieval_failure == 0` +// Since `sel == 0 ==> sel_first_row_in_context == 0`, we have: +// `sel == 0 ==> sel_bytecode_retrieval_failure == 0` pol commit sel_bytecode_retrieval_success; // @boolean (by definition) // If sel = 0, we enforce sel_bytecode_retrieval_success = 0. sel_bytecode_retrieval_success = sel * (1 - sel_bytecode_retrieval_failure); +// Important: We cannot simplify the above relation to +// `sel_bytecode_retrieval_success = sel - sel_bytecode_retrieval_failure` +// because the "sel" multiplicative factor is necessary for the "de-activation cascade" of selectors +// which is necessary to show that `sel == 0 ==> sel_first_row_in_context == 0` and implies +// `sel == 0 ==> sel_bytecode_retrieval_failure == 0`. /************************************************************************************************** * Temporality group 2: Instruction fetching @@ -223,13 +400,14 @@ sel_bytecode_retrieval_success { instr_fetching.pc, instr_fetching.bytecode_id, instr_fetching.sel_parsing_err }; -pol commit sel_instruction_fetching_success; // @boolean (by definition) -// If sel = 0, note that sel_instruction_fetching_success = 0 by transitive reasoning. -sel_instruction_fetching_success = sel_bytecode_retrieval_success * (1 - sel_instruction_fetching_failure); - #[NO_FETCHING_NO_INSTR_FETCH_ERROR] (1 - sel_bytecode_retrieval_success) * sel_instruction_fetching_failure = 0; +pol commit sel_instruction_fetching_success; // @boolean (by definition) +// Subtraction is valid because #[NO_FETCHING_NO_INSTR_FETCH_ERROR] guarantees +// sel_instruction_fetching_failure == 0 whenever sel_bytecode_retrieval_success == 0. +sel_instruction_fetching_success = sel_bytecode_retrieval_success - sel_instruction_fetching_failure; + #[INSTRUCTION_FETCHING_BODY] sel_instruction_fetching_success { pc, @@ -367,26 +545,27 @@ precomputed.sel_exec_spec { //////// ADDRESSING //////// // We run "addressing" whenever sel_instruction_fetching_success is 1. -// For readability we alias it to SEL_SHOULD_RESOLVE_ADDRESS. -pol SEL_SHOULD_RESOLVE_ADDRESS = sel_instruction_fetching_success; +// For readability we alias it to SEL_RESOLVE_ADDRESS. +pol SEL_RESOLVE_ADDRESS = sel_instruction_fetching_success; // resolved operands pol commit rop[7]; // NOTE: Constraints on the resolved operands are in addressing.pil. -// The "output we want is" sel_addressing_error from addressing.pil. +// The "output we want" is sel_addressing_error from addressing.pil. /************************************************************************************************** * Temporality group 3: Register read. **************************************************************************************************/ -pol commit sel_should_read_registers; // @boolean (by definition) -// Note that sel == 0 ==> sel_should_read_registers = 0 by transitive reasoning. -sel_should_read_registers = SEL_SHOULD_RESOLVE_ADDRESS * (1 - sel_addressing_error); +pol commit sel_read_registers; // @boolean (by definition) +// Subtraction is valid because #[NO_ADDRESSING_ERROR_IF_NOT_RESOLVING] guarantees +// sel_addressing_error == 0 whenever SEL_RESOLVE_ADDRESS == 0. +sel_read_registers = SEL_RESOLVE_ADDRESS - sel_addressing_error; // Registers pol commit register[6]; -// Memory Acccesses +// Memory Accesses pol commit sel_mem_op_reg[6]; // @boolean (when `sel_instruction_fetching_success == 1`) // Read / Write selectors pol commit rw_reg[6]; // @boolean (when `sel_instruction_fetching_success == 1`) @@ -404,9 +583,10 @@ pol commit expected_tag_reg[6]; * Temporality group 4: Gas. **************************************************************************************************/ -pol commit sel_should_check_gas; // @boolean (by definition) -// Note that sel == 0 ==> sel_should_check_gas = 0 by transitive reasoning. -sel_should_check_gas = sel_should_read_registers * (1 - sel_register_read_error); +pol commit sel_check_gas; // @boolean (by definition) +// Subtraction is valid because #[REGISTER_READ_TAG_CHECK] guarantees +// sel_register_read_error == 0 whenever sel_read_registers == 0. +sel_check_gas = sel_read_registers - sel_register_read_error; // NOTE: Gas is constrained in gas.pil but we set here the following dynamic gas factors: pol commit dynamic_l2_gas_factor; @@ -433,7 +613,7 @@ pol commit sel_gas_bitwise; // @boolean pol commit sel_gas_emit_public_log; // @boolean pol commit sel_gas_sstore; // @boolean -// Bolean constraints +// Boolean constraints sel_gas_calldata_copy * (1 - sel_gas_calldata_copy) = 0; sel_gas_returndata_copy * (1 - sel_gas_returndata_copy) = 0; sel_gas_to_radix * (1 - sel_gas_to_radix) = 0; @@ -450,7 +630,7 @@ sel_gas_emit_public_log * constants.AVM_DYN_GAS_ID_EMITPUBLICLOG + sel_gas_sstore * constants.AVM_DYN_GAS_ID_SSTORE // We force the selectors to be 0 if we failed before gas checks // or when we are not in the execution subtrace. -= sel_should_check_gas * dyn_gas_id; += sel_check_gas * dyn_gas_id; ////////////////////////////////////////// // Bitwise, Dynamic L2 Gas Calculation @@ -500,8 +680,7 @@ sel_gas_to_radix * sel_radix_gt_256 * (num_p_limbs - 32) = 0; #[GET_P_LIMBS] sel_lookup_num_p_limbs { /*radix=*/register[1], num_p_limbs } in -precomputed.sel_to_radix_p_limb_counts - { precomputed.idx, precomputed.to_radix_num_limbs_for_p }; +precomputed.sel_to_radix_p_limb_counts { precomputed.idx, precomputed.to_radix_num_limbs_for_p }; // We now compute the dynamic l2 gas factor as max(num_limbs, num_p_limbs) // The easiest way to do this is to check if `num_limbs > num_p_limbs`. @@ -586,9 +765,10 @@ sel_gas_emit_public_log * (/*log_size=*/ register[0] - dynamic_da_gas_factor) = * Temporality group 5: Opcode execution **************************************************************************************************/ -pol commit sel_should_execute_opcode; // @boolean (by definition) -// Note that sel == 0 ==> sel_should_check_gas = 0 by transitive reasoning. -sel_should_execute_opcode = sel_should_check_gas * (1 - sel_out_of_gas); +pol commit sel_execute_opcode; // @boolean (by definition) +// Subtraction is valid because #[NO_OOG_IF_NO_GAS_CHECK] guarantees +// sel_out_of_gas == 0 whenever sel_check_gas == 0. +sel_execute_opcode = sel_check_gas - sel_out_of_gas; // Unique identifiers mapping exactly one of selectors below through // a bit decomposition (from precomputed.pil see #[EXEC_SPEC_READ]). @@ -648,7 +828,7 @@ sel_exec_dispatch_keccakf1600 * constants.AVM_SUBTRACE_ID_KECCAKF1600 + sel_exec_dispatch_ecc_add * constants.AVM_SUBTRACE_ID_ECC + sel_exec_dispatch_to_radix * constants.AVM_SUBTRACE_ID_TO_RADIX // We force the selectors to be 0 if we are not executing an opcode. -= sel_should_execute_opcode * subtrace_id; += sel_execute_opcode * subtrace_id; // Embedded execution opcode selectors. // Each of these selectors takes into account both which opcode we are considering executing @@ -723,7 +903,7 @@ sel_execute_nullifier_exists * constants.AVM_EXEC_OP_ID_NULLIFIER_EXISTS + sel_execute_emit_nullifier * constants.AVM_EXEC_OP_ID_EMIT_NULLIFIER + sel_execute_send_l2_to_l1_msg * constants.AVM_EXEC_OP_ID_SENDL2TOL1MSG // We force the selectors to be 0 if we are not executing an opcode - // of the execution subtrace. Note that sel_should_execute_opcode == 0 + // of the execution subtrace. Note that sel_execute_opcode == 0 // implies sel_exec_dispatch_execution == 0. (#[SUBTRACE_ID_DECOMPOSITION]) = sel_exec_dispatch_execution * subtrace_operation_id; @@ -748,12 +928,18 @@ sel_execute_send_l2_to_l1_msg * constants.AVM_EXEC_OP_ID_SENDL2TOL1MSG // - SSTORE (sstore.pil) // Note that DEBUGLOG is trivially handled as a "no op". +// While we use pc' in the relation, there is no need to condition by sel' because +// sel_execute_internal_call and sel_execute_jump are infallible opcodes. +// Complementary pc constraints in context.pil: +// - #[PC_NEW_CONTEXT_INIT]: pc = 0 on the first row of a context (sel_first_row_in_context == 1). +// - #[PC_NEXT_ROW_DEFAULT]: pc' = next_pc on non-jump default context rows (DEFAULT_CTX_ROW). #[PC_NEXT_ROW_INT_CALL_JUMP] -sel' * (sel_execute_internal_call + sel_execute_jump) * (pc' - rop[0]) = 0; +(sel_execute_internal_call + sel_execute_jump) * (pc' - rop[0]) = 0; // For JUMPI opcode, the conditional value is U1 and stored in register[0]. +// JUMPI is infallible, so there is no need to condition by sel'. #[PC_NEXT_ROW_JUMPI] -sel' * sel_execute_jumpi * (register[0] * (rop[1] - next_pc) + next_pc - pc') = 0; +sel_execute_jumpi * (register[0] * (rop[1] - next_pc) + next_pc - pc') = 0; #[MOV_SAME_VALUE] sel_execute_mov * (register[0] - register[1]) = 0; @@ -770,7 +956,7 @@ sel_execute_returndata_size * (register[0] - last_child_returndata_size) = 0; // #[RETURNDATA_SIZE_U32_TAG] sel_execute_returndata_size * (mem_tag_reg[0] - constants.MEM_TAG_U32) = 0; // Write Tag must be U32 -// Tree and sideffect state can only change in specific opcodes. +// Tree and side effect state can only change in specific opcodes. #[PUBLIC_DATA_TREE_ROOT_NOT_CHANGED] (1 - sel_execute_sstore) * (prev_public_data_tree_root - public_data_tree_root) = 0; #[PUBLIC_DATA_TREE_SIZE_NOT_CHANGED] @@ -849,14 +1035,17 @@ sel_opcode_error * (1 - sel_opcode_error) = 0; // - TO_RADIX: #[DISPATCH_TO_TO_RADIX] // Enforce sel_opcode_error = 0 if we are not executing an opcode. - (1 - sel_should_execute_opcode) * sel_opcode_error = 0; + #[NO_OPCODE_ERROR_IF_NOT_EXECUTING] + (1 - sel_execute_opcode) * sel_opcode_error = 0; /************************************************************************************************** * Temporality group 6: Register write. **************************************************************************************************/ -pol commit sel_should_write_registers; // @boolean (by definition) -sel_should_write_registers = sel_should_execute_opcode * (1 - sel_opcode_error); +pol commit sel_write_registers; // @boolean (by definition) +// Subtraction is valid because #[NO_OPCODE_ERROR_IF_NOT_EXECUTING] guarantees +// sel_opcode_error == 0 whenever sel_execute_opcode == 0. +sel_write_registers = sel_execute_opcode - sel_opcode_error; // NOTE: Constraints on the registers are in execution/registers.pil. // There is no output because this group cannot fail. @@ -875,12 +1064,12 @@ pol commit sel_error; // @boolean // and from #[NO_FETCHING_NO_INSTR_FETCH_ERROR] we have `sel_instruction_fetching_failure == 0`. // By definition, `sel_bytecode_retrieval_success == 0` implies `sel_instruction_fetching_success == 0`. // Similarly, `sel_instruction_fetching_success == 0` implies `sel_addressing_error == 0` according -// to #[NO_ADDRESSING_ERROR_IF_NOT_RESOLVING] (see addressing.pil) and `sel_should_read_registers == 0`. +// to #[NO_ADDRESSING_ERROR_IF_NOT_RESOLVING] (see addressing.pil) and `sel_read_registers == 0`. // #[REGISTER_READ_TAG_CHECK] (registers.pil) constrains that `sel_register_read_error == 0` if -// `sel_should_read_registers == 0`. We also have `sel_should_check_gas == 0` when `sel_should_read_registers == 0`. -// In gas.pil, we have `sel_should_check_gas == 0` implies `sel_out_of_gas == 0`. By definition, -// `sel_should_check_gas == 0` implies `sel_should_execute_opcode == 0`. Above, we enforce that -// `sel_should_execute_opcode == 0` implies `sel_opcode_error == 0`. +// `sel_read_registers == 0`. We also have `sel_check_gas == 0` when `sel_read_registers == 0`. +// In gas.pil, we have `sel_check_gas == 0` implies `sel_out_of_gas == 0`. By definition, +// `sel_check_gas == 0` implies `sel_execute_opcode == 0`. Above, we enforce that +// `sel_execute_opcode == 0` implies `sel_opcode_error == 0`. // sel_error is therefore a boolean. // Note also that `sel == 0` ==> `sel_error == 0` from the above explanation. sel_error = sel_bytecode_retrieval_failure + sel_instruction_fetching_failure + sel_addressing_error @@ -890,7 +1079,7 @@ sel_error = sel_bytecode_retrieval_failure + sel_instruction_fetching_failure + * Dispatching to other subtraces **************************************************************************************************/ -// This contains all the lookups/permutations dispatching opcode computation to their pertaining sub-trace. +// This contains all the lookups/permutations dispatching opcode computation to their pertaining sub-traces. // For every entry in the enum SubtraceSel, there is a lookup table except for SubtraceSel::EXECUTION // which are handled by the execution subtrace. diff --git a/barretenberg/cpp/pil/vm2/execution/addressing.pil b/barretenberg/cpp/pil/vm2/execution/addressing.pil index e8f8cea23b3c..0a9b633f1c90 100644 --- a/barretenberg/cpp/pil/vm2/execution/addressing.pil +++ b/barretenberg/cpp/pil/vm2/execution/addressing.pil @@ -15,7 +15,7 @@ include "../gt.pil"; // We guarantee that the resolved operands are either immediates or valid addresses. // Inputs (from execution.pil): -// - SEL_SHOULD_RESOLVE_ADDRESS (alias for sel_instruction_fetching_success) +// - SEL_RESOLVE_ADDRESS (alias for sel_instruction_fetching_success) // - sel_op_is_address[7] (via exec spec; derived from ExecInstructionSpec.num_addresses) // - addressing_mode (via instruction fetching) // - op[7] (via instruction fetching) @@ -54,7 +54,7 @@ include "../gt.pil"; namespace execution; #[skippable_if] -SEL_SHOULD_RESOLVE_ADDRESS = 0; +SEL_RESOLVE_ADDRESS = 0; /************************************************************************************************** * Setup @@ -83,7 +83,7 @@ sel_op_is_indirect_wire[7] * (1 - sel_op_is_indirect_wire[7]) = 0; // addressing_mode comes from instruction fetching via execution.pil. #[ADDRESSING_MODE_RECONSTRUCTION] -SEL_SHOULD_RESOLVE_ADDRESS * addressing_mode = +SEL_RESOLVE_ADDRESS * addressing_mode = ( 2**0 * sel_op_is_indirect_wire[0] + 2**1 * sel_op_is_relative_wire[0] + 2**2 * sel_op_is_indirect_wire[1] + 2**3 * sel_op_is_relative_wire[1] + 2**4 * sel_op_is_indirect_wire[2] + 2**5 * sel_op_is_relative_wire[2] @@ -103,7 +103,7 @@ SEL_SHOULD_RESOLVE_ADDRESS * addressing_mode = // Whether each operand is an address for the given opcode. // Retrieved from the instruction spec in execution.pil. Therefore, there is no need to constrain it to be a boolean. // If an operand is not an address, then the resolved operand is expected to be the same as the original operand. -pol commit sel_op_is_address[7]; // @boolean when SEL_SHOULD_RESOLVE_ADDRESS == 1 (see #[EXEC_SPEC_READ]) +pol commit sel_op_is_address[7]; // @boolean when SEL_RESOLVE_ADDRESS == 1 (see #[EXEC_SPEC_READ]) // We need an extra step in the computation of is_indirect and is_relative: // We only really want to apply the indirection and relative resolution if we are resolving an address. @@ -127,8 +127,8 @@ pol SEL_OP_IS_INDIRECT_EFFECTIVE_4_ = sel_op_is_indirect_wire[4] * sel_op_is_add pol SEL_OP_IS_INDIRECT_EFFECTIVE_5_ = sel_op_is_indirect_wire[5] * sel_op_is_address[5]; pol SEL_OP_IS_INDIRECT_EFFECTIVE_6_ = sel_op_is_indirect_wire[6] * sel_op_is_address[6]; -// We recall that sel_op_is_address[i] is constrained only when `SEL_SHOULD_RESOLVE_ADDRESS == 1`. -// If `SEL_SHOULD_RESOLVE_ADDRESS == 0`, we have `sel_op_is_relative_wire[i] == 0` and +// We recall that sel_op_is_address[i] is constrained only when `SEL_RESOLVE_ADDRESS == 1`. +// If `SEL_RESOLVE_ADDRESS == 0`, we have `sel_op_is_relative_wire[i] == 0` and // `sel_op_is_indirect_wire[i] == 0` according to #[ADDRESSING_MODE_RECONSTRUCTION]. This implies that // `SEL_OP_IS_INDIRECT_EFFECTIVE_i_ == 0` and `SEL_OP_IS_RELATIVE_EFFECTIVE_i_ == 0`. // This also shows that SEL_OP_IS_INDIRECT_EFFECTIVE_i_ and SEL_OP_IS_RELATIVE_EFFECTIVE_i_ are @@ -228,9 +228,9 @@ op_after_relative[5] = op[5] + SEL_OP_IS_RELATIVE_EFFECTIVE_5_ * RELATIVE_RESOLU #[RELATIVE_RESOLUTION_6] op_after_relative[6] = op[6] + SEL_OP_IS_RELATIVE_EFFECTIVE_6_ * RELATIVE_RESOLUTION_FILTER; -// In tracegen, each op[i] is 0 when SHOULD_RESOLVE_ADDRESS == 0 because #[INSTRUCTION_FETCHING_BODY] -// is not active. Therefore, we do not have to gate the above relations by SEL_SHOULD_RESOLVE_ADDRESS. -// In addition, the above relations can be skipped when SEL_SHOULD_RESOLVE_ADDRESS == 0 (skippable condition). +// In tracegen, each op[i] is 0 when SEL_RESOLVE_ADDRESS == 0 because #[INSTRUCTION_FETCHING_BODY] +// is not active. Therefore, we do not have to gate the above relations by SEL_RESOLVE_ADDRESS. +// In addition, the above relations can be skipped when SEL_RESOLVE_ADDRESS == 0 (skippable condition). pol commit sel_op_do_overflow_check[7]; // @boolean (by definition) sel_op_do_overflow_check[0] = SEL_OP_IS_RELATIVE_EFFECTIVE_0_ * (1 - sel_base_address_failure); @@ -244,7 +244,7 @@ sel_op_do_overflow_check[6] = SEL_OP_IS_RELATIVE_EFFECTIVE_6_ * (1 - sel_base_ad // Helper columns for overflow range check. pol commit highest_address; // Lookup constant support: remove when we support constants in a lookup tuple. -SEL_SHOULD_RESOLVE_ADDRESS * (highest_address - constants.AVM_HIGHEST_MEM_ADDRESS) = 0; +SEL_RESOLVE_ADDRESS * (highest_address - constants.AVM_HIGHEST_MEM_ADDRESS) = 0; // sel_relative_overflow[i] == 1 iff op_after_relative[i] > highest_address. // Preconditions to `gt` gadget require both inputs to be bounded by 2^128. // `op_after_relative[i]` is bounded by 2^128 because it is the sum of a base address (U32 tag checked in #[BASE_ADDRESS_CHECK]) @@ -272,64 +272,64 @@ sel_op_do_overflow_check[6] { op_after_relative[6], highest_address, sel_relativ // We only do this if the indirect bit is set AND nothing else failed so far (for this operand). // Recall that from #[NOT_RELATIVE_OR_BASE_FAILURE_NO_OVERFLOW_i] (i = 0, ..., 6), we have: // `sel_base_address_failure == 1` ==> `sel_relative_overflow[i] == 0` and therefore they are mutually exclusive. -pol commit sel_should_apply_indirection[7]; // @boolean (from definition and above remark) +pol commit sel_apply_indirection[7]; // @boolean (from definition and above remark) #[INDIRECT_GATING_0] -sel_should_apply_indirection[0] = SEL_OP_IS_INDIRECT_EFFECTIVE_0_ * (1 - sel_relative_overflow[0] - sel_base_address_failure); +sel_apply_indirection[0] = SEL_OP_IS_INDIRECT_EFFECTIVE_0_ * (1 - sel_relative_overflow[0] - sel_base_address_failure); #[INDIRECT_GATING_1] -sel_should_apply_indirection[1] = SEL_OP_IS_INDIRECT_EFFECTIVE_1_ * (1 - sel_relative_overflow[1] - sel_base_address_failure); +sel_apply_indirection[1] = SEL_OP_IS_INDIRECT_EFFECTIVE_1_ * (1 - sel_relative_overflow[1] - sel_base_address_failure); #[INDIRECT_GATING_2] -sel_should_apply_indirection[2] = SEL_OP_IS_INDIRECT_EFFECTIVE_2_ * (1 - sel_relative_overflow[2] - sel_base_address_failure); +sel_apply_indirection[2] = SEL_OP_IS_INDIRECT_EFFECTIVE_2_ * (1 - sel_relative_overflow[2] - sel_base_address_failure); #[INDIRECT_GATING_3] -sel_should_apply_indirection[3] = SEL_OP_IS_INDIRECT_EFFECTIVE_3_ * (1 - sel_relative_overflow[3] - sel_base_address_failure); +sel_apply_indirection[3] = SEL_OP_IS_INDIRECT_EFFECTIVE_3_ * (1 - sel_relative_overflow[3] - sel_base_address_failure); #[INDIRECT_GATING_4] -sel_should_apply_indirection[4] = SEL_OP_IS_INDIRECT_EFFECTIVE_4_ * (1 - sel_relative_overflow[4] - sel_base_address_failure); +sel_apply_indirection[4] = SEL_OP_IS_INDIRECT_EFFECTIVE_4_ * (1 - sel_relative_overflow[4] - sel_base_address_failure); #[INDIRECT_GATING_5] -sel_should_apply_indirection[5] = SEL_OP_IS_INDIRECT_EFFECTIVE_5_ * (1 - sel_relative_overflow[5] - sel_base_address_failure); +sel_apply_indirection[5] = SEL_OP_IS_INDIRECT_EFFECTIVE_5_ * (1 - sel_relative_overflow[5] - sel_base_address_failure); #[INDIRECT_GATING_6] -sel_should_apply_indirection[6] = SEL_OP_IS_INDIRECT_EFFECTIVE_6_ * (1 - sel_relative_overflow[6] - sel_base_address_failure); +sel_apply_indirection[6] = SEL_OP_IS_INDIRECT_EFFECTIVE_6_ * (1 - sel_relative_overflow[6] - sel_base_address_failure); // This is the tag of the operand if it came from an indirection. Otherwise it's unconstrained. pol commit rop_tag[7]; // If indirection is applied, we need to lookup the value from memory. -// If sel_should_apply_indirection is 1, then we know the address is valid therefore we can make the permutations. +// If sel_apply_indirection is 1, then we know the address is valid therefore we can make the permutations. #[INDIRECT_FROM_MEMORY_0] -sel_should_apply_indirection[0] { clk, context_id, /*address=*/op_after_relative[0], /*value=*/rop[0], /*tag=*/rop_tag[0], /*rw=*/precomputed.zero/*(read)*/ } +sel_apply_indirection[0] { clk, context_id, /*address=*/op_after_relative[0], /*value=*/rop[0], /*tag=*/rop_tag[0], /*rw=*/precomputed.zero/*(read)*/ } is memory.sel_addressing_indirect[0] { memory.clk, memory.space_id, memory.address, memory.value, memory.tag, memory.rw }; #[INDIRECT_FROM_MEMORY_1] -sel_should_apply_indirection[1] { clk, context_id, /*address=*/op_after_relative[1], /*value=*/rop[1], /*tag=*/rop_tag[1], /*rw=*/precomputed.zero/*(read)*/ } +sel_apply_indirection[1] { clk, context_id, /*address=*/op_after_relative[1], /*value=*/rop[1], /*tag=*/rop_tag[1], /*rw=*/precomputed.zero/*(read)*/ } is memory.sel_addressing_indirect[1] { memory.clk, memory.space_id, memory.address, memory.value, memory.tag, memory.rw }; #[INDIRECT_FROM_MEMORY_2] -sel_should_apply_indirection[2] { clk, context_id, /*address=*/op_after_relative[2], /*value=*/rop[2], /*tag=*/rop_tag[2], /*rw=*/precomputed.zero/*(read)*/ } +sel_apply_indirection[2] { clk, context_id, /*address=*/op_after_relative[2], /*value=*/rop[2], /*tag=*/rop_tag[2], /*rw=*/precomputed.zero/*(read)*/ } is memory.sel_addressing_indirect[2] { memory.clk, memory.space_id, memory.address, memory.value, memory.tag, memory.rw }; #[INDIRECT_FROM_MEMORY_3] -sel_should_apply_indirection[3] { clk, context_id, /*address=*/op_after_relative[3], /*value=*/rop[3], /*tag=*/rop_tag[3], /*rw=*/precomputed.zero/*(read)*/ } +sel_apply_indirection[3] { clk, context_id, /*address=*/op_after_relative[3], /*value=*/rop[3], /*tag=*/rop_tag[3], /*rw=*/precomputed.zero/*(read)*/ } is memory.sel_addressing_indirect[3] { memory.clk, memory.space_id, memory.address, memory.value, memory.tag, memory.rw }; #[INDIRECT_FROM_MEMORY_4] -sel_should_apply_indirection[4] { clk, context_id, /*address=*/op_after_relative[4], /*value=*/rop[4], /*tag=*/rop_tag[4], /*rw=*/precomputed.zero/*(read)*/ } +sel_apply_indirection[4] { clk, context_id, /*address=*/op_after_relative[4], /*value=*/rop[4], /*tag=*/rop_tag[4], /*rw=*/precomputed.zero/*(read)*/ } is memory.sel_addressing_indirect[4] { memory.clk, memory.space_id, memory.address, memory.value, memory.tag, memory.rw }; #[INDIRECT_FROM_MEMORY_5] -sel_should_apply_indirection[5] { clk, context_id, /*address=*/op_after_relative[5], /*value=*/rop[5], /*tag=*/rop_tag[5], /*rw=*/precomputed.zero/*(read)*/ } +sel_apply_indirection[5] { clk, context_id, /*address=*/op_after_relative[5], /*value=*/rop[5], /*tag=*/rop_tag[5], /*rw=*/precomputed.zero/*(read)*/ } is memory.sel_addressing_indirect[5] { memory.clk, memory.space_id, memory.address, memory.value, memory.tag, memory.rw }; #[INDIRECT_FROM_MEMORY_6] -sel_should_apply_indirection[6] { clk, context_id, /*address=*/op_after_relative[6], /*value=*/rop[6], /*tag=*/rop_tag[6], /*rw=*/precomputed.zero/*(read)*/ } +sel_apply_indirection[6] { clk, context_id, /*address=*/op_after_relative[6], /*value=*/rop[6], /*tag=*/rop_tag[6], /*rw=*/precomputed.zero/*(read)*/ } is memory.sel_addressing_indirect[6] { memory.clk, memory.space_id, memory.address, memory.value, memory.tag, memory.rw }; // Otherwise, if indirection is not applied, we propagate the operands from the previous step. #[INDIRECT_PROPAGATION_0] -(1 - sel_should_apply_indirection[0]) * (rop[0] - op_after_relative[0]) = 0; +(1 - sel_apply_indirection[0]) * (rop[0] - op_after_relative[0]) = 0; #[INDIRECT_PROPAGATION_1] -(1 - sel_should_apply_indirection[1]) * (rop[1] - op_after_relative[1]) = 0; +(1 - sel_apply_indirection[1]) * (rop[1] - op_after_relative[1]) = 0; #[INDIRECT_PROPAGATION_2] -(1 - sel_should_apply_indirection[2]) * (rop[2] - op_after_relative[2]) = 0; +(1 - sel_apply_indirection[2]) * (rop[2] - op_after_relative[2]) = 0; #[INDIRECT_PROPAGATION_3] -(1 - sel_should_apply_indirection[3]) * (rop[3] - op_after_relative[3]) = 0; +(1 - sel_apply_indirection[3]) * (rop[3] - op_after_relative[3]) = 0; #[INDIRECT_PROPAGATION_4] -(1 - sel_should_apply_indirection[4]) * (rop[4] - op_after_relative[4]) = 0; +(1 - sel_apply_indirection[4]) * (rop[4] - op_after_relative[4]) = 0; #[INDIRECT_PROPAGATION_5] -(1 - sel_should_apply_indirection[5]) * (rop[5] - op_after_relative[5]) = 0; +(1 - sel_apply_indirection[5]) * (rop[5] - op_after_relative[5]) = 0; #[INDIRECT_PROPAGATION_6] -(1 - sel_should_apply_indirection[6]) * (rop[6] - op_after_relative[6]) = 0; +(1 - sel_apply_indirection[6]) * (rop[6] - op_after_relative[6]) = 0; // Operands after indirect resolution are the resolved_operands rop[i], ... (these are defined in execution.pil). @@ -346,13 +346,13 @@ sel_some_final_check_failed * (1 - sel_some_final_check_failed) = 0; // Each tag takes at most 3 bits (guaranteed by mem lookup!), we can encode all of them in a field. // See https://github.com/AztecProtocol/aztec-packages/blob/next/barretenberg/cpp/pil/vm2/docs/recipes.md#batching-comparison-of-n-bit-numbers. // This diff will be 0 iff all tags are U32. -pol BATCHED_TAGS_DIFF = sel_should_apply_indirection[0] * 2**0 * (rop_tag[0] - constants.MEM_TAG_U32) - + sel_should_apply_indirection[1] * 2**3 * (rop_tag[1] - constants.MEM_TAG_U32) - + sel_should_apply_indirection[2] * 2**6 * (rop_tag[2] - constants.MEM_TAG_U32) - + sel_should_apply_indirection[3] * 2**9 * (rop_tag[3] - constants.MEM_TAG_U32) - + sel_should_apply_indirection[4] * 2**12 * (rop_tag[4] - constants.MEM_TAG_U32) - + sel_should_apply_indirection[5] * 2**15 * (rop_tag[5] - constants.MEM_TAG_U32) - + sel_should_apply_indirection[6] * 2**18 * (rop_tag[6] - constants.MEM_TAG_U32); +pol BATCHED_TAGS_DIFF = sel_apply_indirection[0] * 2**0 * (rop_tag[0] - constants.MEM_TAG_U32) + + sel_apply_indirection[1] * 2**3 * (rop_tag[1] - constants.MEM_TAG_U32) + + sel_apply_indirection[2] * 2**6 * (rop_tag[2] - constants.MEM_TAG_U32) + + sel_apply_indirection[3] * 2**9 * (rop_tag[3] - constants.MEM_TAG_U32) + + sel_apply_indirection[4] * 2**12 * (rop_tag[4] - constants.MEM_TAG_U32) + + sel_apply_indirection[5] * 2**15 * (rop_tag[5] - constants.MEM_TAG_U32) + + sel_apply_indirection[6] * 2**18 * (rop_tag[6] - constants.MEM_TAG_U32); pol commit batched_tags_diff_inv; pol BATCHED_TAGS_DIFF_X = BATCHED_TAGS_DIFF; pol BATCHED_TAGS_DIFF_Y = batched_tags_diff_inv; @@ -385,4 +385,4 @@ ADDRESSING_COLLECTION_EQ = 0; // If addressing should not be resolved, then sel_addressing_error should be 0. #[NO_ADDRESSING_ERROR_IF_NOT_RESOLVING] -(1 - SEL_SHOULD_RESOLVE_ADDRESS) * sel_addressing_error = 0; +(1 - SEL_RESOLVE_ADDRESS) * sel_addressing_error = 0; diff --git a/barretenberg/cpp/pil/vm2/execution/gas.pil b/barretenberg/cpp/pil/vm2/execution/gas.pil index 884b9a17d83b..3949481b3078 100644 --- a/barretenberg/cpp/pil/vm2/execution/gas.pil +++ b/barretenberg/cpp/pil/vm2/execution/gas.pil @@ -13,7 +13,7 @@ include "../context.pil"; // pol commit dynamic_da_gas; (declared here but set in execution.pil) // pol commit dynamic_l2_gas_factor; // pol commit dynamic_da_gas_factor; -// pol commit sel_should_check_gas; +// pol commit sel_check_gas; // pol commit addressing_mode; (from execution.pil #[INSTRUCTION_FETCHING_BODY]) // // Inputs from context.pil: @@ -31,7 +31,7 @@ include "../context.pil"; namespace execution; #[skippable_if] - sel_should_check_gas = 0; // From execution.pil. + sel_check_gas = 0; // From execution.pil. // ==== BASE GAS ==== @@ -41,7 +41,7 @@ namespace execution; pol commit addressing_gas; // 16-bit (follows from compute_addressing_gas() and populated in precomputed.pil) #[ADDRESSING_GAS_READ] - sel_should_check_gas { addressing_mode, addressing_gas } + sel_check_gas { addressing_mode, addressing_gas } in precomputed.sel_addressing_gas { precomputed.idx, precomputed.addressing_gas }; @@ -63,12 +63,12 @@ namespace execution; pol L2_GAS_USED = BASE_L2_GAS + DYNAMIC_L2_GAS_USED; pol DA_GAS_USED = base_da_gas + DYNAMIC_DA_GAS_USED; - pol commit out_of_gas_l2; // @boolean (by lookup into gt when sel_should_check_gas = 1) - pol commit out_of_gas_da; // @boolean (by lookup into gt when sel_should_check_gas = 1) + pol commit out_of_gas_l2; // @boolean (by lookup into gt when sel_check_gas = 1) + pol commit out_of_gas_da; // @boolean (by lookup into gt when sel_check_gas = 1) // Alias Support Lookup: Once we support expression in lookup, we can replace this column by an alias. pol commit total_gas_l2; - sel_should_check_gas * (prev_l2_gas_used + L2_GAS_USED - total_gas_l2) = 0; + sel_check_gas * (prev_l2_gas_used + L2_GAS_USED - total_gas_l2) = 0; // gt gadget requires both inputs to be bounded by 2^128. // prev_l2_gas_used is bounded by l2_gas_limit < 2^32 @@ -78,23 +78,24 @@ namespace execution; // Then total_gas_l2 = prev_l2_gas_used + BASE_L2_GAS + dynamic_l2_gas * dynamic_l2_gas_factor < 2^49 // l2_gas_limit is 32 bits (see at the top of this file). #[IS_OUT_OF_GAS_L2] - sel_should_check_gas { total_gas_l2, l2_gas_limit, out_of_gas_l2 } in gt.sel_gas { gt.input_a, gt.input_b, gt.res }; + sel_check_gas { total_gas_l2, l2_gas_limit, out_of_gas_l2 } in gt.sel_gas { gt.input_a, gt.input_b, gt.res }; // Alias Support Lookup: Once we support expression in lookup, we can replace this column by an alias. pol commit total_gas_da; - sel_should_check_gas * (prev_da_gas_used + DA_GAS_USED - total_gas_da) = 0; + sel_check_gas * (prev_da_gas_used + DA_GAS_USED - total_gas_da) = 0; // gt gadget requires both inputs to be bounded by 2^128. // Same reasoning as for #[IS_OUT_OF_GAS_L2] shows that total_gas_da < 2^49. // da_gas_limit is 32 bits (see at the top of this file). #[IS_OUT_OF_GAS_DA] - sel_should_check_gas { total_gas_da, da_gas_limit, out_of_gas_da } in gt.sel_gas { gt.input_a, gt.input_b, gt.res }; + sel_check_gas { total_gas_da, da_gas_limit, out_of_gas_da } in gt.sel_gas { gt.input_a, gt.input_b, gt.res }; - // sel_out_of_gas == out_of_gas_l2 || out_of_gas_da when `sel_should_check_gas = 1`. - pol commit sel_out_of_gas; // @boolean (by definition, forced to 0 if sel_should_check_gas = 0) + // sel_out_of_gas == out_of_gas_l2 || out_of_gas_da when `sel_check_gas = 1`. + pol commit sel_out_of_gas; // @boolean (by definition, forced to 0 if sel_check_gas = 0) sel_out_of_gas = 1 - (1 - out_of_gas_l2) * (1 - out_of_gas_da); // If we shouldn't check the gas, you shouldn't be able to claim out of gas. // However, we should not make use of `out_of_gas_l2` nor `out_of_gas_da` columns in this case, - // because they are unconstrained if `sel_should_check_gas = 0`. - (1 - sel_should_check_gas) * sel_out_of_gas = 0; + // because they are unconstrained if `sel_check_gas = 0`. + #[NO_OOG_IF_NO_GAS_CHECK] + (1 - sel_check_gas) * sel_out_of_gas = 0; diff --git a/barretenberg/cpp/pil/vm2/execution/registers.pil b/barretenberg/cpp/pil/vm2/execution/registers.pil index 8a8dff1d0f9b..3b2b5128a3ca 100644 --- a/barretenberg/cpp/pil/vm2/execution/registers.pil +++ b/barretenberg/cpp/pil/vm2/execution/registers.pil @@ -17,8 +17,8 @@ namespace execution; // pol commit mem_tag_reg[6]; // // Execution.pil temporality group selectors: -// pol commit sel_should_read_registers; // Register read -// pol commit sel_should_write_registers; // Register write +// pol commit sel_read_registers; // Register read +// pol commit sel_write_registers; // Register write // They are not mutually exclusive and will often be both 1. // // Output: @@ -35,10 +35,10 @@ namespace execution; // We only skip if we don't have to read nor write. // By "SELECTOR DEACTIVATION CASCADE" explained in execution.pil, we have -// `sel_should_read_registers == 0 ==> sel_should_write_registers == 0`. -// This allows to simplify `sel_should_read_registers + sel_should_write_registers = 0`. +// `sel_read_registers == 0 ==> sel_write_registers == 0`. +// This allows to simplify `sel_read_registers + sel_write_registers = 0`. #[skippable_if] -sel_should_read_registers = 0; +sel_read_registers = 0; // Whether we should effectively operate on the register. We operate if // (a) sel_mem_op_reg[i] is a read and we got to the read temporality group, or @@ -47,17 +47,17 @@ sel_should_read_registers = 0; // they are retrieved through #[EXEC_SPEC_READ] from temporality group 2 (which happens earlier). pol commit sel_op_reg_effective[6]; // @boolean (by definition) #[SEL_OP_REG_EFFECTIVE_0] -sel_op_reg_effective[0] = sel_mem_op_reg[0] * (sel_should_read_registers * (1 - rw_reg[0]) + sel_should_write_registers * rw_reg[0]); +sel_op_reg_effective[0] = sel_mem_op_reg[0] * (sel_read_registers * (1 - rw_reg[0]) + sel_write_registers * rw_reg[0]); #[SEL_OP_REG_EFFECTIVE_1] -sel_op_reg_effective[1] = sel_mem_op_reg[1] * (sel_should_read_registers * (1 - rw_reg[1]) + sel_should_write_registers * rw_reg[1]); +sel_op_reg_effective[1] = sel_mem_op_reg[1] * (sel_read_registers * (1 - rw_reg[1]) + sel_write_registers * rw_reg[1]); #[SEL_OP_REG_EFFECTIVE_2] -sel_op_reg_effective[2] = sel_mem_op_reg[2] * (sel_should_read_registers * (1 - rw_reg[2]) + sel_should_write_registers * rw_reg[2]); +sel_op_reg_effective[2] = sel_mem_op_reg[2] * (sel_read_registers * (1 - rw_reg[2]) + sel_write_registers * rw_reg[2]); #[SEL_OP_REG_EFFECTIVE_3] -sel_op_reg_effective[3] = sel_mem_op_reg[3] * (sel_should_read_registers * (1 - rw_reg[3]) + sel_should_write_registers * rw_reg[3]); +sel_op_reg_effective[3] = sel_mem_op_reg[3] * (sel_read_registers * (1 - rw_reg[3]) + sel_write_registers * rw_reg[3]); #[SEL_OP_REG_EFFECTIVE_4] -sel_op_reg_effective[4] = sel_mem_op_reg[4] * (sel_should_read_registers * (1 - rw_reg[4]) + sel_should_write_registers * rw_reg[4]); +sel_op_reg_effective[4] = sel_mem_op_reg[4] * (sel_read_registers * (1 - rw_reg[4]) + sel_write_registers * rw_reg[4]); #[SEL_OP_REG_EFFECTIVE_5] -sel_op_reg_effective[5] = sel_mem_op_reg[5] * (sel_should_read_registers * (1 - rw_reg[5]) + sel_should_write_registers * rw_reg[5]); +sel_op_reg_effective[5] = sel_mem_op_reg[5] * (sel_read_registers * (1 - rw_reg[5]) + sel_write_registers * rw_reg[5]); // Observe that the following permutations span both temporality groups (activated at most once per instruction). // That's why we have to properly activate them with the above selectors, which take into account @@ -98,7 +98,7 @@ pol BATCHED_TAGS_DIFF_REG = sel_tag_check_reg[0] * 2**0 * (mem_tag_reg[0] - exp + sel_tag_check_reg[4] * 2**12 * (mem_tag_reg[4] - expected_tag_reg[4]) + sel_tag_check_reg[5] * 2**15 * (mem_tag_reg[5] - expected_tag_reg[5]); pol commit batched_tags_diff_inv_reg; -pol BATCHED_TAGS_DIFF_X_REG = sel_should_read_registers * BATCHED_TAGS_DIFF_REG; // Forces 0 if we don't read the register. +pol BATCHED_TAGS_DIFF_X_REG = sel_read_registers * BATCHED_TAGS_DIFF_REG; // Forces 0 if we don't read the register. pol BATCHED_TAGS_DIFF_Y_REG = batched_tags_diff_inv_reg; pol BATCHED_TAGS_DIFF_E_REG = 1 - sel_register_read_error; pol BATCHED_TAGS_DIFF_EQ_REG = BATCHED_TAGS_DIFF_X_REG * (BATCHED_TAGS_DIFF_E_REG * (1 - BATCHED_TAGS_DIFF_Y_REG) + BATCHED_TAGS_DIFF_Y_REG) - 1 + BATCHED_TAGS_DIFF_E_REG; diff --git a/barretenberg/cpp/pil/vm2/memory.pil b/barretenberg/cpp/pil/vm2/memory.pil index f85d42e1cb23..ed27382c2dc5 100644 --- a/barretenberg/cpp/pil/vm2/memory.pil +++ b/barretenberg/cpp/pil/vm2/memory.pil @@ -229,7 +229,7 @@ sel_tag_is_ff * (1 - sel_tag_is_ff) = 0; // Trace must be continuous: once sel drops to 0, it stays 0. // Exception: the first row (precomputed.first_row = 1) is always inactive. #[MEM_CONTINUITY] -(1 - precomputed.first_row) * (1 - sel) * sel' = 0; +(1 - precomputed.first_row - sel) * sel' = 0; // Boolean toggle for "not the last active row". Boolean by definition (product of two booleans). #[SEL_RNG_CHK] diff --git a/barretenberg/cpp/pil/vm2/trees/public_data_check.pil b/barretenberg/cpp/pil/vm2/trees/public_data_check.pil index 5dd3592e6efb..97fb4eac2a81 100644 --- a/barretenberg/cpp/pil/vm2/trees/public_data_check.pil +++ b/barretenberg/cpp/pil/vm2/trees/public_data_check.pil @@ -107,7 +107,7 @@ namespace public_data_check; // Next sel=1 implies current sel=1 or first_row=1 // With this constraint, we can only have sel=1 for N rows after the first, where N could be zero. #[TRACE_CONTINUITY] - sel' * (1 - sel) * (1 - precomputed.first_row) = 0; + (1 - sel - precomputed.first_row) * sel' = 0; pol commit not_end; // @boolean (by definition) not_end = sel * sel'; diff --git a/barretenberg/cpp/pil/vm2/trees/public_data_squash.pil b/barretenberg/cpp/pil/vm2/trees/public_data_squash.pil index 6b54fce7d866..76d60cc1e17d 100644 --- a/barretenberg/cpp/pil/vm2/trees/public_data_squash.pil +++ b/barretenberg/cpp/pil/vm2/trees/public_data_squash.pil @@ -58,7 +58,7 @@ namespace public_data_squash; // Next sel=1 implies current sel=1 or first_row=1 // With this constraint, we can only have sel=1 for N rows after the first, where N could be zero. #[TRACE_CONTINUITY] - sel' * (1 - sel) * (1 - precomputed.first_row) = 0; + (1 - sel - precomputed.first_row) * sel' = 0; pol END = sel * (1 - sel'); pol NOT_END = sel * sel'; diff --git a/barretenberg/cpp/pil/vm2/tx.pil b/barretenberg/cpp/pil/vm2/tx.pil index 4b45c3a015a6..0b4b62757ecd 100644 --- a/barretenberg/cpp/pil/vm2/tx.pil +++ b/barretenberg/cpp/pil/vm2/tx.pil @@ -279,12 +279,12 @@ namespace tx; pol commit calldata_size; pol commit calldata_hash; - pol commit should_process_call_request; // @boolean on active rows (follows from definition) - should_process_call_request = (sel - is_padded) * is_public_call_request; + pol commit sel_process_call_request; // @boolean on active rows (follows from definition) + sel_process_call_request = (sel - is_padded) * is_public_call_request; // Read information relating to the public call request from public inputs #[READ_PUBLIC_CALL_REQUEST_PHASE] - should_process_call_request { + sel_process_call_request { read_pi_offset, msg_sender, contract_addr, @@ -302,7 +302,7 @@ namespace tx; // This binds the `calldata hash` with the `context id` of the enqueued call. // In addition, `calldata_size` is "returned back" from calldata_hashing.pil. #[READ_CALLDATA_HASH] - should_process_call_request { + sel_process_call_request { calldata_hash, calldata_size, next_context_id @@ -321,19 +321,19 @@ namespace tx; // Note that `prev_l2_gas_used` and `prev_da_gas_used` are constrained in tx_context.pil. // prev_gas_used_sent_to_enqueued_call = is_teardown ? 0 : prev_gas_used - should_process_call_request * ((0 - prev_l2_gas_used) * is_teardown + prev_l2_gas_used - prev_l2_gas_used_sent_to_enqueued_call) = 0; - should_process_call_request * ((0 - prev_da_gas_used) * is_teardown + prev_da_gas_used - prev_da_gas_used_sent_to_enqueued_call) = 0; + sel_process_call_request * ((0 - prev_l2_gas_used) * is_teardown + prev_l2_gas_used - prev_l2_gas_used_sent_to_enqueued_call) = 0; + sel_process_call_request * ((0 - prev_da_gas_used) * is_teardown + prev_da_gas_used - prev_da_gas_used_sent_to_enqueued_call) = 0; // next_gas_used = is_teardown ? prev_gas_used : next_gas_used_sent_to_enqueued_call // In the teardown phase, next_gas_used_sent_to_enqueued_call is unconstrained on purpose; we don't care about gas usage in teardown. - should_process_call_request * ((prev_l2_gas_used - next_l2_gas_used_sent_to_enqueued_call) * is_teardown + next_l2_gas_used_sent_to_enqueued_call - next_l2_gas_used) = 0; - should_process_call_request * ((prev_da_gas_used - next_da_gas_used_sent_to_enqueued_call) * is_teardown + next_da_gas_used_sent_to_enqueued_call - next_da_gas_used) = 0; + sel_process_call_request * ((prev_l2_gas_used - next_l2_gas_used_sent_to_enqueued_call) * is_teardown + next_l2_gas_used_sent_to_enqueued_call - next_l2_gas_used) = 0; + sel_process_call_request * ((prev_da_gas_used - next_da_gas_used_sent_to_enqueued_call) * is_teardown + next_da_gas_used_sent_to_enqueued_call - next_da_gas_used) = 0; // Public call requests are dispatched to the execution trace. // We match the values to the start of an enqueued call in the execution trace. // Key: In execution, the pair `context_id` and `enqueued_call_start == 1` characterizes a unique row. // Inputs: All other columns are inputs to the enqueued call. #[DISPATCH_EXEC_START] - should_process_call_request { + sel_process_call_request { next_context_id, discard, // Important for security of discarding logic in execution trace. (see discard.pil correctness analysis) msg_sender, @@ -365,7 +365,7 @@ namespace tx; da_gas_limit } is execution.enqueued_call_start { - execution.context_id, // next_context_id must be constrained in the execution trace on enqueued_call_start + execution.context_id, execution.discard, execution.msg_sender, execution.contract_address, @@ -407,7 +407,7 @@ namespace tx; // determined by the context_id's. Nevertheless, the constraint #[INCR_NEXT_CONTEXT_ID] in context.pil prevents // such a re-ordering to happen. #[DISPATCH_EXEC_END] - should_process_call_request { + sel_process_call_request { next_context_id, next_context_id', // The context id of the next row must be the one after the execution of the enqueued call reverted, @@ -490,21 +490,21 @@ namespace tx; public_inputs.sel { precomputed.idx, public_inputs.cols[0] }; // ===== NOTE HASHES ===== - pol commit should_try_note_hash_append; // @boolean (follows from definition) - should_try_note_hash_append = (sel - is_padded) * (sel_revertible_append_note_hash + sel_non_revertible_append_note_hash); + pol commit sel_try_note_hash_append; // @boolean (follows from definition) + sel_try_note_hash_append = (sel - is_padded) * (sel_revertible_append_note_hash + sel_non_revertible_append_note_hash); // If we are at the maximum emitted note hashes, we must revert pol REMAINING_NOTE_HASH_WRITES = constants.MAX_NOTE_HASHES_PER_TX - prev_num_note_hashes_emitted; // Revert if remaining note hashes is 0 #[MAX_NOTE_HASH_WRITES_REACHED] - should_try_note_hash_append * (REMAINING_NOTE_HASH_WRITES * (reverted * (1 - remaining_side_effects_inv) + remaining_side_effects_inv) - 1 + reverted) = 0; + sel_try_note_hash_append * (REMAINING_NOTE_HASH_WRITES * (reverted * (1 - remaining_side_effects_inv) + remaining_side_effects_inv) - 1 + reverted) = 0; // Commited since it's used in the lookup - pol commit should_note_hash_append; // @boolean (follows from definition) - should_note_hash_append = should_try_note_hash_append * (1 - reverted); + pol commit sel_note_hash_append; // @boolean (follows from definition) + sel_note_hash_append = sel_try_note_hash_append * (1 - reverted); #[NOTE_HASH_APPEND] - should_note_hash_append { + sel_note_hash_append { leaf_value, prev_note_hash_tree_size, prev_note_hash_tree_root, @@ -525,14 +525,14 @@ namespace tx; note_hash_tree_check.next_root }; - // If reverted, the next state is unconstrained as `should_note_hash_append = 0`. This is okay since we are going to restore the state at the end of setup or fail proving. + // If reverted, the next state is unconstrained as `sel_note_hash_append = 0`. This is okay since we are going to restore the state at the end of setup or fail proving. // Namely, #[RESTORE_STATE_ON_REVERT] restores the tree state to its value at the end of setup. - should_note_hash_append * (prev_note_hash_tree_size + 1 - next_note_hash_tree_size) = 0; - should_note_hash_append * (prev_num_note_hashes_emitted + 1 - next_num_note_hashes_emitted) = 0; + sel_note_hash_append * (prev_note_hash_tree_size + 1 - next_note_hash_tree_size) = 0; + sel_note_hash_append * (prev_num_note_hashes_emitted + 1 - next_num_note_hashes_emitted) = 0; // ===== NULLIFIERS ===== - pol commit should_try_nullifier_append; // @boolean (follows from definition) - should_try_nullifier_append = (sel - is_padded) * (sel_revertible_append_nullifier + sel_non_revertible_append_nullifier); + pol commit sel_try_nullifier_append; // @boolean (follows from definition) + sel_try_nullifier_append = (sel - is_padded) * (sel_revertible_append_nullifier + sel_non_revertible_append_nullifier); pol commit nullifier_limit_error; // @boolean nullifier_limit_error * (1 - nullifier_limit_error) = 0; @@ -541,27 +541,27 @@ namespace tx; pol REMAINING_NULLIFIER_WRITES = constants.MAX_NULLIFIERS_PER_TX - prev_num_nullifiers_emitted; // Disable the lookup if remaining nullifiers is 0 #[MAX_NULLIFIER_WRITES_REACHED] - should_try_nullifier_append * (REMAINING_NULLIFIER_WRITES * (nullifier_limit_error * (1 - remaining_side_effects_inv) + remaining_side_effects_inv) - 1 + nullifier_limit_error) = 0; + sel_try_nullifier_append * (REMAINING_NULLIFIER_WRITES * (nullifier_limit_error * (1 - remaining_side_effects_inv) + remaining_side_effects_inv) - 1 + nullifier_limit_error) = 0; // If over the limit, reverted=1; else, reverted is constrained by the lookup. - should_try_nullifier_append * nullifier_limit_error * (1 - reverted) = 0; + sel_try_nullifier_append * nullifier_limit_error * (1 - reverted) = 0; - pol commit should_nullifier_append; // @boolean (follows from definition) - should_nullifier_append = should_try_nullifier_append * (1 - nullifier_limit_error); + pol commit sel_nullifier_append; // @boolean (follows from definition) + sel_nullifier_append = sel_try_nullifier_append * (1 - nullifier_limit_error); pol commit write_nullifier_pi_offset; - should_nullifier_append * (constants.AVM_PUBLIC_INPUTS_AVM_ACCUMULATED_DATA_NULLIFIERS_ROW_IDX + prev_num_nullifiers_emitted - write_nullifier_pi_offset) = 0; + sel_nullifier_append * (constants.AVM_PUBLIC_INPUTS_AVM_ACCUMULATED_DATA_NULLIFIERS_ROW_IDX + prev_num_nullifiers_emitted - write_nullifier_pi_offset) = 0; // Lookup constant support: Can be removed when we support constants in lookups. pol commit nullifier_tree_height; - should_nullifier_append * (nullifier_tree_height - constants.NULLIFIER_TREE_HEIGHT) = 0; + sel_nullifier_append * (nullifier_tree_height - constants.NULLIFIER_TREE_HEIGHT) = 0; pol commit nullifier_merkle_separator; - should_nullifier_append * (nullifier_merkle_separator - constants.DOM_SEP__NULLIFIER_MERKLE) = 0; + sel_nullifier_append * (nullifier_merkle_separator - constants.DOM_SEP__NULLIFIER_MERKLE) = 0; // Collisions are disallowed, if the nullifier already exists the transaction is unprovable #[NULLIFIER_APPEND] - should_nullifier_append { + sel_nullifier_append { leaf_value, prev_nullifier_tree_root, precomputed.zero, // Nullifiers emitted in tx trace cannot have existed @@ -585,46 +585,46 @@ namespace tx; indexed_tree_check.sel_silo }; - // If reverted, the next state is unconstrained since `should_nullifier_append = 0`. This is okay since we are going to restore the state at the end of setup. + // If reverted, the next state is unconstrained since `sel_nullifier_append = 0`. This is okay since we are going to restore the state at the end of setup. // Namely, #[RESTORE_STATE_ON_REVERT] restores the tree state to its value at the end of setup. #[NULLIFIER_TREE_SIZE_INCREMENT] - should_nullifier_append * (prev_nullifier_tree_size + 1 - next_nullifier_tree_size) = 0; + sel_nullifier_append * (prev_nullifier_tree_size + 1 - next_nullifier_tree_size) = 0; #[NULLIFIER_EMITTED_COUNT_INCREMENT] - should_nullifier_append * (prev_num_nullifiers_emitted + 1 - next_num_nullifiers_emitted) = 0; + sel_nullifier_append * (prev_num_nullifiers_emitted + 1 - next_num_nullifiers_emitted) = 0; // ===== L2 - L1 Messages ===== - pol commit should_try_l2_l1_msg_append; // @boolean (follows from definition) - should_try_l2_l1_msg_append = (sel - is_padded) * (sel_revertible_append_l2_l1_msg + sel_non_revertible_append_l2_l1_msg); + pol commit sel_try_l2_l1_msg_append; // @boolean (follows from definition) + sel_try_l2_l1_msg_append = (sel - is_padded) * (sel_revertible_append_l2_l1_msg + sel_non_revertible_append_l2_l1_msg); pol commit l2_l1_msg_contract_address; pol commit l2_l1_msg_recipient; pol commit l2_l1_msg_content; #[READ_L2_L1_MSG] - should_try_l2_l1_msg_append { read_pi_offset, l2_l1_msg_recipient, l2_l1_msg_content, l2_l1_msg_contract_address } in + sel_try_l2_l1_msg_append { read_pi_offset, l2_l1_msg_recipient, l2_l1_msg_content, l2_l1_msg_contract_address } in public_inputs.sel { precomputed.idx, public_inputs.cols[0], public_inputs.cols[1], public_inputs.cols[2] }; // If we are at the maximum emitted messages, we must revert pol REMAINING_L2_TO_L1_MSG_WRITES = constants.MAX_L2_TO_L1_MSGS_PER_TX - prev_num_l2_to_l1_messages; // Revert if REMAINING_L2_TO_L1_MSG_WRITES is 0 #[MAX_L2_L1_MSG_WRITES_REACHED] - should_try_l2_l1_msg_append * (REMAINING_L2_TO_L1_MSG_WRITES * (reverted * (1 - remaining_side_effects_inv) + remaining_side_effects_inv) - 1 + reverted) = 0; + sel_try_l2_l1_msg_append * (REMAINING_L2_TO_L1_MSG_WRITES * (reverted * (1 - remaining_side_effects_inv) + remaining_side_effects_inv) - 1 + reverted) = 0; - pol commit should_l2_l1_msg_append; // @boolean (follows from definition) + pol commit sel_l2_l1_msg_append; // @boolean (follows from definition) // A msg emission must be written to PI if it didn't revert and is not discarded. - should_l2_l1_msg_append = should_try_l2_l1_msg_append * (1 - reverted) * (1 - discard); + sel_l2_l1_msg_append = sel_try_l2_l1_msg_append * (1 - reverted) * (1 - discard); // discard is from tx_discard.pil virtual trace - should_l2_l1_msg_append * (constants.AVM_PUBLIC_INPUTS_AVM_ACCUMULATED_DATA_L2_TO_L1_MSGS_ROW_IDX + prev_num_l2_to_l1_messages - write_pi_offset) = 0; + sel_l2_l1_msg_append * (constants.AVM_PUBLIC_INPUTS_AVM_ACCUMULATED_DATA_L2_TO_L1_MSGS_ROW_IDX + prev_num_l2_to_l1_messages - write_pi_offset) = 0; #[WRITE_L2_L1_MSG] - should_l2_l1_msg_append { write_pi_offset, l2_l1_msg_recipient, l2_l1_msg_content, l2_l1_msg_contract_address } in + sel_l2_l1_msg_append { write_pi_offset, l2_l1_msg_recipient, l2_l1_msg_content, l2_l1_msg_contract_address } in public_inputs.sel { precomputed.idx, public_inputs.cols[0], public_inputs.cols[1], public_inputs.cols[2] }; // If reverted, the next count is unconstrained. This is okay since we are going to restore the state to the end of setup or fail proving. // Namely, #[RESTORE_STATE_ON_REVERT] restores the number of L2 to L1 messages to its value at the end of setup. #[UPDATE_NUM_L2_TO_L1_MSGS] - should_try_l2_l1_msg_append * (1 - reverted) * (prev_num_l2_to_l1_messages + 1 - next_num_l2_to_l1_messages) = 0; + sel_try_l2_l1_msg_append * (1 - reverted) * (prev_num_l2_to_l1_messages + 1 - next_num_l2_to_l1_messages) = 0; /*************************************************************************** * Collect Gas Phase diff --git a/barretenberg/cpp/pil/vm2/tx_context.pil b/barretenberg/cpp/pil/vm2/tx_context.pil index de99920d7943..d17074b09cd7 100644 --- a/barretenberg/cpp/pil/vm2/tx_context.pil +++ b/barretenberg/cpp/pil/vm2/tx_context.pil @@ -376,9 +376,9 @@ namespace tx; (1 - SEL_CAN_EMIT_L2_L1_MSG) * (prev_num_l2_to_l1_messages - next_num_l2_to_l1_messages) = 0; #[RETRIEVED_BYTECODES_TREE_ROOT_IMMUTABILITY] - (1 - should_process_call_request) * (prev_retrieved_bytecodes_tree_root - next_retrieved_bytecodes_tree_root) = 0; + (1 - sel_process_call_request) * (prev_retrieved_bytecodes_tree_root - next_retrieved_bytecodes_tree_root) = 0; #[RETRIEVED_BYTECODES_TREE_SIZE_IMMUTABILITY] - (1 - should_process_call_request) * (prev_retrieved_bytecodes_tree_size - next_retrieved_bytecodes_tree_size) = 0; + (1 - sel_process_call_request) * (prev_retrieved_bytecodes_tree_size - next_retrieved_bytecodes_tree_size) = 0; // Padded rows are not allowed to change the state #[NOTE_HASH_ROOT_PADDED_IMMUTABILITY] @@ -412,9 +412,9 @@ namespace tx; is_padded * (prev_num_l2_to_l1_messages - next_num_l2_to_l1_messages) = 0; #[L2_GAS_USED_IMMUTABILITY] - (1 - should_process_call_request) * (prev_l2_gas_used - next_l2_gas_used) = 0; + (1 - sel_process_call_request) * (prev_l2_gas_used - next_l2_gas_used) = 0; #[DA_GAS_USED_IMMUTABILITY] - (1 - should_process_call_request) * (prev_da_gas_used - next_da_gas_used) = 0; + (1 - sel_process_call_request) * (prev_da_gas_used - next_da_gas_used) = 0; // ===== WRITE END COUNTERS TO PI ===== @@ -489,4 +489,4 @@ namespace tx; // We normally propagate the next context id, unless a call is issued, where the execution trace // controls the next row's next context id. #[NEXT_CONTEXT_ID_CONTINUITY] - NOT_LAST_ROW * (1 - should_process_call_request) * (next_context_id' - next_context_id) = 0; + NOT_LAST_ROW * (1 - sel_process_call_request) * (next_context_id' - next_context_id) = 0; diff --git a/barretenberg/cpp/src/barretenberg/avm_fuzzer/harness/external_call.fuzzer.cpp b/barretenberg/cpp/src/barretenberg/avm_fuzzer/harness/external_call.fuzzer.cpp index 2e3919484cca..f70e5ecd2ac0 100644 --- a/barretenberg/cpp/src/barretenberg/avm_fuzzer/harness/external_call.fuzzer.cpp +++ b/barretenberg/cpp/src/barretenberg/avm_fuzzer/harness/external_call.fuzzer.cpp @@ -15,7 +15,9 @@ #include "barretenberg/vm2/simulation/events/execution_event.hpp" #include "barretenberg/vm2/simulation/events/gas_event.hpp" #include "barretenberg/vm2/simulation/gadgets/execution_components.hpp" +#include "barretenberg/vm2/simulation/interfaces/addressing.hpp" #include "barretenberg/vm2/simulation/interfaces/context.hpp" +#include "barretenberg/vm2/simulation/interfaces/gas_tracker.hpp" #include "barretenberg/vm2/simulation/interfaces/memory.hpp" #include "barretenberg/vm2/simulation/lib/instruction_info.hpp" #include "barretenberg/vm2/testing/instruction_builder.hpp" diff --git a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/addressing.test.cpp b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/addressing.test.cpp index dac2ede3db3f..43c832ca1e26 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/addressing.test.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/addressing.test.cpp @@ -25,7 +25,7 @@ using C = Column; using addressing = bb::avm2::addressing; // Across all tests, bear in mind that -// pol SEL_SHOULD_RESOLVE_ADDRESS = sel_bytecode_retrieval_success * sel_instruction_fetching_success; +// pol SEL_RESOLVE_ADDRESS = sel_bytecode_retrieval_success * sel_instruction_fetching_success; TEST(AddressingConstrainingTest, EmptyRow) { @@ -40,7 +40,7 @@ TEST(AddressingConstrainingTest, BaseAddressGating) { // If there are no relative operands, it's ok that sel_do_base_check is 0. TestTraceContainer trace({ { - // These set pol SEL_SHOULD_RESOLVE_ADDRESS. + // These set pol SEL_RESOLVE_ADDRESS. // If this is off the whole subrelation is unconstrained. { C::execution_sel_bytecode_retrieval_success, 1 }, { C::execution_sel_instruction_fetching_success, 1 }, @@ -92,7 +92,7 @@ TEST(AddressingConstrainingTest, BaseAddressTagIsU32) { C::execution_base_address_tag_diff_inv, base_address_tag_diff_inv }, { C::execution_sel_base_address_failure, 0 }, // Selectors that enable the subrelation. - // These set pol SEL_SHOULD_RESOLVE_ADDRESS. + // These set pol SEL_RESOLVE_ADDRESS. { C::execution_sel_bytecode_retrieval_success, 1 }, { C::execution_sel_instruction_fetching_success, 1 }, { C::execution_sel_do_base_check, 1 }, @@ -127,7 +127,7 @@ TEST(AddressingConstrainingTest, BaseAddressTagIsNotU32) { C::execution_base_address_tag_diff_inv, base_address_tag_diff_inv }, { C::execution_sel_base_address_failure, 1 }, // Selectors that enable the subrelation. - // These set pol SEL_SHOULD_RESOLVE_ADDRESS. + // These set pol SEL_RESOLVE_ADDRESS. { C::execution_sel_bytecode_retrieval_success, 1 }, { C::execution_sel_instruction_fetching_success, 1 }, { C::execution_sel_do_base_check, 1 }, @@ -163,7 +163,7 @@ TEST(AddressingConstrainingTest, BaseAddressTagNoCheckImpliesNoError) { C::execution_base_address_tag_diff_inv, base_address_tag_diff_inv }, { C::execution_sel_base_address_failure, 0 }, // Selectors that enable the subrelation. - // These set pol SEL_SHOULD_RESOLVE_ADDRESS. + // These set pol SEL_RESOLVE_ADDRESS. { C::execution_sel_bytecode_retrieval_success, 1 }, { C::execution_sel_instruction_fetching_success, 1 }, { C::execution_sel_do_base_check, 0 }, @@ -181,7 +181,7 @@ TEST(AddressingConstrainingTest, BaseAddressTagNoCheckImpliesNoError) // Therefore the above case that was failing should now pass. trace.set(0, { { - // These set pol SEL_SHOULD_RESOLVE_ADDRESS. + // These set pol SEL_RESOLVE_ADDRESS. { C::execution_sel_bytecode_retrieval_success, 0 }, { C::execution_sel_instruction_fetching_success, 0 }, // @@ -313,7 +313,7 @@ TEST(AddressingConstrainingTest, RelativeAddressPropagationWhenBaseAddressIsInva { C::execution_sel_op_is_relative_wire_4_, 1 }, { C::execution_sel_op_is_relative_wire_5_, 0 }, { C::execution_sel_op_is_relative_wire_6_, 1 }, - // These set pol SEL_SHOULD_RESOLVE_ADDRESS. + // These set pol SEL_RESOLVE_ADDRESS. { C::execution_sel_bytecode_retrieval_success, 1 }, { C::execution_sel_instruction_fetching_success, 1 }, }, @@ -482,7 +482,7 @@ TEST(AddressingConstrainingTest, IndirectReconstructionZeroWhenAddressingDisable { C::execution_addressing_mode, 123456 }, // All sel_op_indirect and sel_op_is_relative are 0. // Selectors that enable the subrelation. - // These set pol SEL_SHOULD_RESOLVE_ADDRESS. + // These set pol SEL_RESOLVE_ADDRESS. { C::execution_sel_bytecode_retrieval_success, 0 }, { C::execution_sel_instruction_fetching_success, 0 }, }, @@ -518,7 +518,7 @@ TEST(AddressingConstrainingTest, IndirectGating) TestTraceContainer trace({ { // Selectors that enable the subrelation. - // These set pol SEL_SHOULD_RESOLVE_ADDRESS. + // These set pol SEL_RESOLVE_ADDRESS. { C::execution_sel_bytecode_retrieval_success, 1 }, { C::execution_sel_instruction_fetching_success, 1 }, // From wire. @@ -546,13 +546,13 @@ TEST(AddressingConstrainingTest, IndirectGating) { C::execution_sel_relative_overflow_5_, 0 }, { C::execution_sel_relative_overflow_6_, 0 }, // Expected. - { C::execution_sel_should_apply_indirection_0_, 0 }, // no indirect bit - { C::execution_sel_should_apply_indirection_1_, 1 }, // indirect - { C::execution_sel_should_apply_indirection_2_, 0 }, // no indirect and relative overflowed - { C::execution_sel_should_apply_indirection_3_, 0 }, // indirect and relative overflowed - { C::execution_sel_should_apply_indirection_4_, 0 }, // no indirect and no relative overflow - { C::execution_sel_should_apply_indirection_5_, 1 }, // indirect and no relative overflow - { C::execution_sel_should_apply_indirection_6_, 0 }, // indirect and no overflow but also not an address + { C::execution_sel_apply_indirection_0_, 0 }, // no indirect bit + { C::execution_sel_apply_indirection_1_, 1 }, // indirect + { C::execution_sel_apply_indirection_2_, 0 }, // no indirect and relative overflowed + { C::execution_sel_apply_indirection_3_, 0 }, // indirect and relative overflowed + { C::execution_sel_apply_indirection_4_, 0 }, // no indirect and no relative overflow + { C::execution_sel_apply_indirection_5_, 1 }, // indirect and no relative overflow + { C::execution_sel_apply_indirection_6_, 0 }, // indirect and no overflow but also not an address }, }); @@ -569,13 +569,13 @@ TEST(AddressingConstrainingTest, IndirectGating) trace.set(0, { { // Opposite of above. - { C::execution_sel_should_apply_indirection_0_, 1 }, - { C::execution_sel_should_apply_indirection_1_, 0 }, - { C::execution_sel_should_apply_indirection_2_, 1 }, - { C::execution_sel_should_apply_indirection_3_, 1 }, - { C::execution_sel_should_apply_indirection_4_, 1 }, - { C::execution_sel_should_apply_indirection_5_, 0 }, - { C::execution_sel_should_apply_indirection_6_, 1 }, + { C::execution_sel_apply_indirection_0_, 1 }, + { C::execution_sel_apply_indirection_1_, 0 }, + { C::execution_sel_apply_indirection_2_, 1 }, + { C::execution_sel_apply_indirection_3_, 1 }, + { C::execution_sel_apply_indirection_4_, 1 }, + { C::execution_sel_apply_indirection_5_, 0 }, + { C::execution_sel_apply_indirection_6_, 1 }, } }); EXPECT_THROW_WITH_MESSAGE(check_relation(trace, addressing::SR_INDIRECT_GATING_0), "INDIRECT_GATING_0"); EXPECT_THROW_WITH_MESSAGE(check_relation(trace, addressing::SR_INDIRECT_GATING_1), "INDIRECT_GATING_1"); @@ -585,7 +585,7 @@ TEST(AddressingConstrainingTest, IndirectGating) EXPECT_THROW_WITH_MESSAGE(check_relation(trace, addressing::SR_INDIRECT_GATING_5), "INDIRECT_GATING_5"); EXPECT_THROW_WITH_MESSAGE(check_relation(trace, addressing::SR_INDIRECT_GATING_6), "INDIRECT_GATING_6"); - // Bits are still constrained if SEL_SHOULD_RESOLVE_ADDRESS is 0. + // Bits are still constrained if SEL_RESOLVE_ADDRESS is 0. // This just simplifies the relation. trace.set(C::execution_sel_bytecode_retrieval_success, /*row=*/0, /*value=*/0); trace.set(C::execution_sel_instruction_fetching_success, /*row=*/0, /*value=*/0); @@ -603,7 +603,7 @@ TEST(AddressingConstrainingTest, IndirectGatingIfBaseAddressIsInvalid) TestTraceContainer trace({ { // Selectors that enable the subrelation. - // These set pol SEL_SHOULD_RESOLVE_ADDRESS. + // These set pol SEL_RESOLVE_ADDRESS. { C::execution_sel_bytecode_retrieval_success, 1 }, { C::execution_sel_instruction_fetching_success, 1 }, // @@ -636,13 +636,13 @@ TEST(AddressingConstrainingTest, IndirectGatingIfBaseAddressIsInvalid) { C::execution_sel_relative_overflow_5_, 0 }, { C::execution_sel_relative_overflow_6_, 0 }, // The are all expected to be 0 because the base address is invalid. - { C::execution_sel_should_apply_indirection_0_, 0 }, - { C::execution_sel_should_apply_indirection_1_, 0 }, - { C::execution_sel_should_apply_indirection_2_, 0 }, - { C::execution_sel_should_apply_indirection_3_, 0 }, - { C::execution_sel_should_apply_indirection_4_, 0 }, - { C::execution_sel_should_apply_indirection_5_, 0 }, - { C::execution_sel_should_apply_indirection_6_, 0 }, + { C::execution_sel_apply_indirection_0_, 0 }, + { C::execution_sel_apply_indirection_1_, 0 }, + { C::execution_sel_apply_indirection_2_, 0 }, + { C::execution_sel_apply_indirection_3_, 0 }, + { C::execution_sel_apply_indirection_4_, 0 }, + { C::execution_sel_apply_indirection_5_, 0 }, + { C::execution_sel_apply_indirection_6_, 0 }, }, }); @@ -659,13 +659,13 @@ TEST(AddressingConstrainingTest, IndirectGatingIfBaseAddressIsInvalid) trace.set(0, { { // Opposite of above. - { C::execution_sel_should_apply_indirection_0_, 1 }, - { C::execution_sel_should_apply_indirection_1_, 1 }, - { C::execution_sel_should_apply_indirection_2_, 1 }, - { C::execution_sel_should_apply_indirection_3_, 1 }, - { C::execution_sel_should_apply_indirection_4_, 1 }, - { C::execution_sel_should_apply_indirection_5_, 1 }, - { C::execution_sel_should_apply_indirection_6_, 1 }, + { C::execution_sel_apply_indirection_0_, 1 }, + { C::execution_sel_apply_indirection_1_, 1 }, + { C::execution_sel_apply_indirection_2_, 1 }, + { C::execution_sel_apply_indirection_3_, 1 }, + { C::execution_sel_apply_indirection_4_, 1 }, + { C::execution_sel_apply_indirection_5_, 1 }, + { C::execution_sel_apply_indirection_6_, 1 }, } }); EXPECT_THROW_WITH_MESSAGE(check_relation(trace, addressing::SR_INDIRECT_GATING_0), "INDIRECT_GATING_0"); EXPECT_THROW_WITH_MESSAGE(check_relation(trace, addressing::SR_INDIRECT_GATING_1), "INDIRECT_GATING_1"); @@ -682,13 +682,13 @@ TEST(AddressingConstrainingTest, IndirectPropagationWhenNoIndirection) // They only constrain that non-indirect operands are propagated from the previous step. TestTraceContainer trace({ { - { C::execution_sel_should_apply_indirection_0_, 0 }, - { C::execution_sel_should_apply_indirection_1_, 1 }, - { C::execution_sel_should_apply_indirection_2_, 0 }, - { C::execution_sel_should_apply_indirection_3_, 1 }, - { C::execution_sel_should_apply_indirection_4_, 0 }, - { C::execution_sel_should_apply_indirection_5_, 1 }, - { C::execution_sel_should_apply_indirection_6_, 0 }, + { C::execution_sel_apply_indirection_0_, 0 }, + { C::execution_sel_apply_indirection_1_, 1 }, + { C::execution_sel_apply_indirection_2_, 0 }, + { C::execution_sel_apply_indirection_3_, 1 }, + { C::execution_sel_apply_indirection_4_, 0 }, + { C::execution_sel_apply_indirection_5_, 1 }, + { C::execution_sel_apply_indirection_6_, 0 }, // From relative step. { C::execution_op_after_relative_0_, 123 }, { C::execution_op_after_relative_1_, 456 }, @@ -706,7 +706,7 @@ TEST(AddressingConstrainingTest, IndirectPropagationWhenNoIndirection) { C::execution_rop_5_, 99003 }, // from mem { C::execution_rop_6_, 192021 }, // Selectors that enable the subrelation. - // These set pol SEL_SHOULD_RESOLVE_ADDRESS. + // These set pol SEL_RESOLVE_ADDRESS. { C::execution_sel_bytecode_retrieval_success, 1 }, { C::execution_sel_instruction_fetching_success, 1 }, }, @@ -721,7 +721,7 @@ TEST(AddressingConstrainingTest, IndirectPropagationWhenNoIndirection) addressing::SR_INDIRECT_PROPAGATION_5, addressing::SR_INDIRECT_PROPAGATION_6); - // These subrelations do not pay attention to SEL_SHOULD_RESOLVE_ADDRESS. + // These subrelations do not pay attention to SEL_RESOLVE_ADDRESS. trace.set(C::execution_sel_bytecode_retrieval_success, /*row=*/0, /*value=*/0); trace.set(C::execution_sel_instruction_fetching_success, /*row=*/0, /*value=*/0); check_relation(trace, @@ -780,13 +780,13 @@ TEST(AddressingConstrainingTest, FinalCheckNoFailure) TestTraceContainer trace({ { // From indirect resolution. - { C::execution_sel_should_apply_indirection_0_, should_apply_indirection[0] }, - { C::execution_sel_should_apply_indirection_1_, should_apply_indirection[1] }, - { C::execution_sel_should_apply_indirection_2_, should_apply_indirection[2] }, - { C::execution_sel_should_apply_indirection_3_, should_apply_indirection[3] }, - { C::execution_sel_should_apply_indirection_4_, should_apply_indirection[4] }, - { C::execution_sel_should_apply_indirection_5_, should_apply_indirection[5] }, - { C::execution_sel_should_apply_indirection_6_, should_apply_indirection[6] }, + { C::execution_sel_apply_indirection_0_, should_apply_indirection[0] }, + { C::execution_sel_apply_indirection_1_, should_apply_indirection[1] }, + { C::execution_sel_apply_indirection_2_, should_apply_indirection[2] }, + { C::execution_sel_apply_indirection_3_, should_apply_indirection[3] }, + { C::execution_sel_apply_indirection_4_, should_apply_indirection[4] }, + { C::execution_sel_apply_indirection_5_, should_apply_indirection[5] }, + { C::execution_sel_apply_indirection_6_, should_apply_indirection[6] }, // From indirection. { C::execution_rop_tag_0_, static_cast(rop_tag[0]) }, // shouldn't matter { C::execution_rop_tag_1_, static_cast(rop_tag[1]) }, // shouldn't matter @@ -830,13 +830,13 @@ TEST(AddressingConstrainingTest, FinalCheckSingleFailure) TestTraceContainer trace({ { // From indirect resolution. - { C::execution_sel_should_apply_indirection_0_, should_apply_indirection[0] }, - { C::execution_sel_should_apply_indirection_1_, should_apply_indirection[1] }, - { C::execution_sel_should_apply_indirection_2_, should_apply_indirection[2] }, - { C::execution_sel_should_apply_indirection_3_, should_apply_indirection[3] }, - { C::execution_sel_should_apply_indirection_4_, should_apply_indirection[4] }, - { C::execution_sel_should_apply_indirection_5_, should_apply_indirection[5] }, - { C::execution_sel_should_apply_indirection_6_, should_apply_indirection[6] }, + { C::execution_sel_apply_indirection_0_, should_apply_indirection[0] }, + { C::execution_sel_apply_indirection_1_, should_apply_indirection[1] }, + { C::execution_sel_apply_indirection_2_, should_apply_indirection[2] }, + { C::execution_sel_apply_indirection_3_, should_apply_indirection[3] }, + { C::execution_sel_apply_indirection_4_, should_apply_indirection[4] }, + { C::execution_sel_apply_indirection_5_, should_apply_indirection[5] }, + { C::execution_sel_apply_indirection_6_, should_apply_indirection[6] }, // From indirection. { C::execution_rop_tag_0_, static_cast(rop_tag[0]) }, // shouldn't matter, not address { C::execution_rop_tag_1_, static_cast(rop_tag[1]) }, // shouldn't matter, not address @@ -883,13 +883,13 @@ TEST(AddressingConstrainingTest, FinalCheckMultipleFailures) TestTraceContainer trace({ { // From indirect resolution. - { C::execution_sel_should_apply_indirection_0_, should_apply_indirection[0] }, - { C::execution_sel_should_apply_indirection_1_, should_apply_indirection[1] }, - { C::execution_sel_should_apply_indirection_2_, should_apply_indirection[2] }, - { C::execution_sel_should_apply_indirection_3_, should_apply_indirection[3] }, - { C::execution_sel_should_apply_indirection_4_, should_apply_indirection[4] }, - { C::execution_sel_should_apply_indirection_5_, should_apply_indirection[5] }, - { C::execution_sel_should_apply_indirection_6_, should_apply_indirection[6] }, + { C::execution_sel_apply_indirection_0_, should_apply_indirection[0] }, + { C::execution_sel_apply_indirection_1_, should_apply_indirection[1] }, + { C::execution_sel_apply_indirection_2_, should_apply_indirection[2] }, + { C::execution_sel_apply_indirection_3_, should_apply_indirection[3] }, + { C::execution_sel_apply_indirection_4_, should_apply_indirection[4] }, + { C::execution_sel_apply_indirection_5_, should_apply_indirection[5] }, + { C::execution_sel_apply_indirection_6_, should_apply_indirection[6] }, // From indirection. { C::execution_rop_tag_0_, static_cast(rop_tag[0]) }, // shouldn't matter, not address { C::execution_rop_tag_1_, static_cast(rop_tag[1]) }, // shouldn't matter, not address diff --git a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/exec_op_id.test.cpp b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/exec_op_id.test.cpp index 555ee7f53ce7..78806ef2e5a4 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/exec_op_id.test.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/exec_op_id.test.cpp @@ -124,7 +124,7 @@ TEST(ExecOpIdConstrainingTest, Decomposition) TestTraceContainer trace({ { { C::execution_sel_exec_dispatch_execution, 1 }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, { C::execution_subtrace_operation_id, OPERATION_IDS.at(i) }, { SELECTOR_COLUMNS.at(i), 1 }, }, @@ -179,7 +179,7 @@ TEST(ExecOpIdConstrainingTest, InteractionWithExecInstructionSpec) // Set the execution opcode for each row. for (size_t i = 0; i < WIRE_OPCODES.size(); i++) { trace.set(C::execution_sel_instruction_fetching_success, static_cast(i + 1), 1); - trace.set(C::execution_sel_should_execute_opcode, static_cast(i + 1), 1); + trace.set(C::execution_sel_execute_opcode, static_cast(i + 1), 1); trace.set(C::execution_sel_exec_dispatch_execution, static_cast(i + 1), 1); trace.set(SELECTOR_COLUMNS.at(i), static_cast(i + 1), 1); trace.set(C::execution_exec_opcode, diff --git a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/execution.test.cpp b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/execution.test.cpp index 90aafdd2613d..eb5e94d1833d 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/execution.test.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/execution.test.cpp @@ -5,8 +5,11 @@ #include "barretenberg/vm2/constraining/flavor_settings.hpp" #include "barretenberg/vm2/constraining/testing/check_relation.hpp" +#include "barretenberg/vm2/generated/relations/addressing.hpp" #include "barretenberg/vm2/generated/relations/execution.hpp" +#include "barretenberg/vm2/generated/relations/gas.hpp" #include "barretenberg/vm2/generated/relations/lookups_context.hpp" +#include "barretenberg/vm2/generated/relations/registers.hpp" #include "barretenberg/vm2/testing/fixtures.hpp" #include "barretenberg/vm2/testing/macros.hpp" #include "barretenberg/vm2/tracegen/execution_trace.hpp" @@ -20,6 +23,9 @@ using tracegen::TestTraceContainer; using FF = AvmFlavorSettings::FF; using C = Column; using execution = bb::avm2::execution; +using addressing = bb::avm2::addressing; +using gas = bb::avm2::gas; +using registers = bb::avm2::registers; TEST(ExecutionConstrainingTest, EmptyRow) { @@ -46,11 +52,15 @@ TEST(ExecutionConstrainingTest, Continuity) {{ C::precomputed_first_row, 1 }}, {{ C::execution_sel, 1 }}, {{ C::execution_sel, 1 }}, - {{ C::execution_sel, 1 }}, + {{ C::execution_sel, 1 }, { C::execution_enqueued_call_end, 1 }}, }); // clang-format on check_relation(trace, execution::SR_TRACE_CONTINUITY); + + // Negative test: remove enqueued call end + trace.set(C::execution_enqueued_call_end, 3, 0); + EXPECT_THROW_WITH_MESSAGE(check_relation(trace, execution::SR_TRACE_CONTINUITY), "TRACE_CONTINUITY"); } TEST(ExecutionConstrainingTest, ContinuityBrokenFirstRow) @@ -60,7 +70,7 @@ TEST(ExecutionConstrainingTest, ContinuityBrokenFirstRow) {{ C::execution_sel, 0 }}, // End of trace! {{ C::execution_sel, 1 }}, {{ C::execution_sel, 1 }}, - {{ C::execution_sel, 1 }}, + {{ C::execution_sel, 1 }, { C::execution_enqueued_call_end, 1 }}, }); // clang-format on @@ -74,7 +84,7 @@ TEST(ExecutionConstrainingTest, ContinuityBrokenInMiddle) {{ C::execution_sel, 1 }}, {{ C::execution_sel, 0 }}, // End of trace! {{ C::execution_sel, 1 }}, - {{ C::execution_sel, 1 }}, + {{ C::execution_sel, 1 }, { C::execution_enqueued_call_end, 1 }}, }); // clang-format on @@ -222,6 +232,99 @@ TEST(ExecutionConstrainingTest, SideEffectStateNotChanged) "NUM_L2_TO_L1_MESSAGES_NOT_CHANGED"); } +TEST(ExecutionConstrainingTest, NoFetchingNoInstrFetchError) +{ + // sel_bytecode_retrieval_success == 0 => sel_instruction_fetching_failure == 0 + TestTraceContainer trace({ + { { C::execution_sel_bytecode_retrieval_success, 0 }, { C::execution_sel_instruction_fetching_failure, 0 } }, + }); + + check_relation(trace, execution::SR_NO_FETCHING_NO_INSTR_FETCH_ERROR); + + // Negative test: sel_bytecode_retrieval_success == 0 but sel_instruction_fetching_failure == 1 + trace.set(C::execution_sel_instruction_fetching_failure, 0, 1); + EXPECT_THROW_WITH_MESSAGE(check_relation(trace, execution::SR_NO_FETCHING_NO_INSTR_FETCH_ERROR), + "NO_FETCHING_NO_INSTR_FETCH_ERROR"); + + // Positive test: sel_bytecode_retrieval_success == 1 allows sel_instruction_fetching_failure == 1 + trace.set(C::execution_sel_bytecode_retrieval_success, 0, 1); + check_relation(trace, execution::SR_NO_FETCHING_NO_INSTR_FETCH_ERROR); +} + +TEST(ExecutionConstrainingTest, NoAddressingErrorIfNotResolving) +{ + // sel_instruction_fetching_success == 0 => sel_addressing_error == 0 + // (SEL_RESOLVE_ADDRESS is an alias for sel_instruction_fetching_success) + TestTraceContainer trace({ + { { C::execution_sel_instruction_fetching_success, 0 }, { C::execution_sel_addressing_error, 0 } }, + }); + + check_relation(trace, addressing::SR_NO_ADDRESSING_ERROR_IF_NOT_RESOLVING); + + // Negative test: sel_instruction_fetching_success == 0 but sel_addressing_error == 1 + trace.set(C::execution_sel_addressing_error, 0, 1); + EXPECT_THROW_WITH_MESSAGE(check_relation(trace, addressing::SR_NO_ADDRESSING_ERROR_IF_NOT_RESOLVING), + "NO_ADDRESSING_ERROR_IF_NOT_RESOLVING"); + + // Positive test: sel_instruction_fetching_success == 1 allows sel_addressing_error == 1 + trace.set(C::execution_sel_instruction_fetching_success, 0, 1); + check_relation(trace, addressing::SR_NO_ADDRESSING_ERROR_IF_NOT_RESOLVING); +} + +TEST(ExecutionConstrainingTest, NoRegisterReadErrorIfNotReading) +{ + // sel_read_registers == 0 => sel_register_read_error == 0 + // Via #[REGISTER_READ_TAG_CHECK]: when sel_read_registers == 0, BATCHED_TAGS_DIFF_X_REG == 0, + // which forces sel_register_read_error == 0. + TestTraceContainer trace({ + { { C::execution_sel_read_registers, 0 }, { C::execution_sel_register_read_error, 0 } }, + }); + + check_relation(trace, registers::SR_REGISTER_READ_TAG_CHECK); + + // Negative test: sel_read_registers == 0 but sel_register_read_error == 1 + trace.set(C::execution_sel_register_read_error, 0, 1); + EXPECT_THROW_WITH_MESSAGE(check_relation(trace, registers::SR_REGISTER_READ_TAG_CHECK), + "REGISTER_READ_TAG_CHECK"); +} + +TEST(ExecutionConstrainingTest, NoOogIfNoGasCheck) +{ + // sel_check_gas == 0 => sel_out_of_gas == 0 + TestTraceContainer trace({ + { { C::execution_sel_check_gas, 0 }, { C::execution_sel_out_of_gas, 0 } }, + }); + + check_relation(trace, gas::SR_NO_OOG_IF_NO_GAS_CHECK); + + // Negative test: sel_check_gas == 0 but sel_out_of_gas == 1 + trace.set(C::execution_sel_out_of_gas, 0, 1); + EXPECT_THROW_WITH_MESSAGE(check_relation(trace, gas::SR_NO_OOG_IF_NO_GAS_CHECK), "NO_OOG_IF_NO_GAS_CHECK"); + + // Positive test: sel_check_gas == 1 allows sel_out_of_gas == 1 + trace.set(C::execution_sel_check_gas, 0, 1); + check_relation(trace, gas::SR_NO_OOG_IF_NO_GAS_CHECK); +} + +TEST(ExecutionConstrainingTest, NoOpcodeErrorIfNotExecuting) +{ + // sel_execute_opcode == 0 => sel_opcode_error == 0 + TestTraceContainer trace({ + { { C::execution_sel_execute_opcode, 0 }, { C::execution_sel_opcode_error, 0 } }, + }); + + check_relation(trace, execution::SR_NO_OPCODE_ERROR_IF_NOT_EXECUTING); + + // Negative test: sel_execute_opcode == 0 but sel_opcode_error == 1 + trace.set(C::execution_sel_opcode_error, 0, 1); + EXPECT_THROW_WITH_MESSAGE(check_relation(trace, execution::SR_NO_OPCODE_ERROR_IF_NOT_EXECUTING), + "NO_OPCODE_ERROR_IF_NOT_EXECUTING"); + + // Positive test: sel_execute_opcode == 1 allows sel_opcode_error == 1 + trace.set(C::execution_sel_execute_opcode, 0, 1); + check_relation(trace, execution::SR_NO_OPCODE_ERROR_IF_NOT_EXECUTING); +} + TEST(ExecutionConstrainingTest, SubtraceIdDecomposition) { using tracegen::get_subtrace_id; @@ -240,7 +343,7 @@ TEST(ExecutionConstrainingTest, SubtraceIdDecomposition) { { { subtrace_selector, 1 }, { C::execution_subtrace_id, subtrace_id }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, } }); } diff --git a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/gas.test.cpp b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/gas.test.cpp index 7120388a1f49..0dfd86b284b8 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/gas.test.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/gas.test.cpp @@ -53,7 +53,7 @@ TEST(GasConstrainingTest, AllSubrelations) uint64_t total_gas_da = prev_da_gas_used + base_da_gas + (dynamic_da_gas * dynamic_da_gas_factor); TestTraceContainer trace({ { - { C::execution_sel_should_check_gas, 1 }, + { C::execution_sel_check_gas, 1 }, // looked up in execution.pil { C::execution_opcode_gas, opcode_l2_gas }, { C::execution_addressing_gas, addressing_gas }, @@ -137,7 +137,7 @@ TEST(GasConstrainingTest, OutOfGasBase) uint64_t total_gas_da = prev_da_gas_used + base_da_gas + (dynamic_da_gas * dynamic_da_gas_factor); TestTraceContainer trace({ { - { C::execution_sel_should_check_gas, 1 }, + { C::execution_sel_check_gas, 1 }, // looked up in execution.pil { C::execution_opcode_gas, opcode_l2_gas }, { C::execution_addressing_gas, addressing_gas }, @@ -215,7 +215,7 @@ TEST(GasConstrainingTest, OutOfGasDynamic) uint64_t total_gas_da = prev_da_gas_used + base_da_gas + (dynamic_da_gas * dynamic_da_gas_factor); TestTraceContainer trace({ { - { C::execution_sel_should_check_gas, 1 }, + { C::execution_sel_check_gas, 1 }, // looked up in execution.pil { C::execution_opcode_gas, opcode_l2_gas }, { C::execution_addressing_gas, addressing_gas }, @@ -276,7 +276,7 @@ TEST(GasConstrainingTest, OutOfGasDynamic) TEST(GasConstrainingTest, NoCheckNoOOG) { TestTraceContainer trace({ { - { C::execution_sel_should_check_gas, 0 }, + { C::execution_sel_check_gas, 0 }, // out { C::execution_out_of_gas_l2, 0 }, { C::execution_out_of_gas_da, 0 }, @@ -328,7 +328,7 @@ TEST(GasConstrainingTest, DynGasFactorToRadix) { C::execution_sel, 1 }, { C::execution_register_1_, radix }, { C::execution_register_2_, num_limbs }, - { C::execution_sel_should_check_gas, 1 }, + { C::execution_sel_check_gas, 1 }, // To Radix BE Dynamic Gas { C::execution_sel_gas_to_radix, 1 }, { C::execution_dyn_gas_id, AVM_DYN_GAS_ID_TORADIX }, @@ -378,7 +378,7 @@ TEST(GasConstrainingTest, DynGasFactorInvalidRadix) { C::execution_sel, 1 }, { C::execution_register_1_, radix }, { C::execution_register_2_, num_limbs }, - { C::execution_sel_should_check_gas, 1 }, + { C::execution_sel_check_gas, 1 }, // To Radix BE Dynamic Gas { C::execution_sel_gas_to_radix, 1 }, { C::execution_dyn_gas_id, AVM_DYN_GAS_ID_TORADIX }, @@ -426,7 +426,7 @@ TEST(GasConstrainingTest, DynGasFactorToRadixInvalidRadixLt2) { C::execution_sel, 1 }, { C::execution_register_1_, radix }, { C::execution_register_2_, num_limbs }, - { C::execution_sel_should_check_gas, 1 }, + { C::execution_sel_check_gas, 1 }, // To Radix BE Dynamic Gas { C::execution_sel_gas_to_radix, 1 }, { C::execution_dyn_gas_id, AVM_DYN_GAS_ID_TORADIX }, diff --git a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/get_env_var.test.cpp b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/get_env_var.test.cpp index 3a63a90363fa..951b620d7af2 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/get_env_var.test.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/get_env_var.test.cpp @@ -259,7 +259,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) { { C::execution_sel, 1 }, { C::execution_contract_address, contract_address }, { C::execution_rop_1_, static_cast(EnvironmentVariable::ADDRESS) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -282,7 +282,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) { { C::execution_sel, 1 }, { C::execution_msg_sender, sender }, { C::execution_rop_1_, static_cast(EnvironmentVariable::SENDER) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -305,7 +305,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) { { C::execution_sel, 1 }, { C::execution_transaction_fee, transaction_fee }, { C::execution_rop_1_, static_cast(EnvironmentVariable::TRANSACTIONFEE) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -327,7 +327,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) // chain id { { C::execution_sel, 1 }, { C::execution_rop_1_, static_cast(EnvironmentVariable::CHAINID) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -349,7 +349,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) // version { { C::execution_sel, 1 }, { C::execution_rop_1_, static_cast(EnvironmentVariable::VERSION) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -371,7 +371,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) // block number { { C::execution_sel, 1 }, { C::execution_rop_1_, static_cast(EnvironmentVariable::BLOCKNUMBER) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -393,7 +393,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) // timestamp { { C::execution_sel, 1 }, { C::execution_rop_1_, static_cast(EnvironmentVariable::TIMESTAMP) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -415,7 +415,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) // fee_per_l2_gas { { C::execution_sel, 1 }, { C::execution_rop_1_, static_cast(EnvironmentVariable::MINFEEPERL2GAS) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -437,7 +437,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) // fee_per_da_gas { { C::execution_sel, 1 }, { C::execution_rop_1_, static_cast(EnvironmentVariable::MINFEEPERDAGAS) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -460,7 +460,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) { { C::execution_sel, 1 }, { C::execution_is_static, is_static_call }, { C::execution_rop_1_, static_cast(EnvironmentVariable::ISSTATICCALL) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -484,7 +484,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) { C::execution_l2_gas_limit, l2_gas_limit }, { C::execution_l2_gas_used, l2_gas_used }, { C::execution_rop_1_, static_cast(EnvironmentVariable::L2GASLEFT) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -508,7 +508,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) { C::execution_da_gas_limit, da_gas_limit }, { C::execution_da_gas_used, da_gas_used }, { C::execution_rop_1_, static_cast(EnvironmentVariable::DAGASLEFT) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -530,7 +530,7 @@ TEST(GetEnvVarConstrainingTest, ComplexTraceWithAllEnumsAndInteractions) // invalid enum { { C::execution_sel, 1 }, { C::execution_rop_1_, 42 }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // Do it! No prior error, although enum will later prove to be invalid. { C::execution_sel_execute_get_env_var, 1 }, // from precomputed table @@ -580,7 +580,7 @@ TEST(GetEnvVarConstrainingTest, NegativeInteractionTests) TestTraceContainer trace({ { { C::execution_sel, 1 }, { C::execution_rop_1_, static_cast(EnvironmentVariable::CHAINID) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // from precomputed table { C::execution_sel_opcode_error, 0 }, // valid enum { C::execution_sel_envvar_pi_lookup_col0, 1 }, @@ -638,7 +638,7 @@ TEST(GetEnvVarConstrainingTest, NegativeInteractionTestsPICol1) TestTraceContainer trace({ { { C::execution_sel, 1 }, { C::execution_rop_1_, static_cast(EnvironmentVariable::MINFEEPERL2GAS) }, - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, // from precomputed table { C::execution_sel_opcode_error, 0 }, // valid enum { C::execution_sel_envvar_pi_lookup_col0, 0 }, diff --git a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/registers.test.cpp b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/registers.test.cpp index b9fa4b6261d4..ab60393ea673 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/registers.test.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/registers.test.cpp @@ -26,8 +26,8 @@ TEST(RegistersConstrainingTest, EffectiveRegOpSelectorNoReadNoWrite) { // This represents the case where we are not reading nor writing. TestTraceContainer trace({ { - { C::execution_sel_should_read_registers, 0 }, - { C::execution_sel_should_write_registers, 0 }, + { C::execution_sel_read_registers, 0 }, + { C::execution_sel_write_registers, 0 }, // Register 0: read, active. { C::execution_sel_mem_op_reg_0_, 1 }, { C::execution_rw_reg_0_, 0 }, @@ -76,8 +76,8 @@ TEST(RegistersConstrainingTest, EffectiveRegOpSelectorOnlyRead) { // This represents the case where we are only reading and failed before the write phase. TestTraceContainer trace({ { - { C::execution_sel_should_read_registers, 1 }, - { C::execution_sel_should_write_registers, 0 }, + { C::execution_sel_read_registers, 1 }, + { C::execution_sel_write_registers, 0 }, // Register 0: read, active. { C::execution_sel_mem_op_reg_0_, 1 }, { C::execution_rw_reg_0_, 0 }, @@ -126,8 +126,8 @@ TEST(RegistersConstrainingTest, EffectiveRegOpSelectorReadThenWrite) { // This represents the case where we are both reading and writing. TestTraceContainer trace({ { - { C::execution_sel_should_read_registers, 1 }, - { C::execution_sel_should_write_registers, 1 }, + { C::execution_sel_read_registers, 1 }, + { C::execution_sel_write_registers, 1 }, // Register 0: read, active. { C::execution_sel_mem_op_reg_0_, 1 }, { C::execution_rw_reg_0_, 0 }, @@ -176,7 +176,7 @@ TEST(RegistersConstrainingTest, TagCheckNoFailure) { TestTraceContainer trace({ { - { C::execution_sel_should_read_registers, 1 }, + { C::execution_sel_read_registers, 1 }, // Reg 0: check U8, is U8. { C::execution_sel_tag_check_reg_0_, 1 }, { C::execution_mem_tag_reg_0_, static_cast(MemoryTag::U8) }, @@ -211,7 +211,7 @@ TEST(RegistersConstrainingTest, TagCheckSingleFailure) TestTraceContainer trace({ { - { C::execution_sel_should_read_registers, 1 }, + { C::execution_sel_read_registers, 1 }, // Reg 0: check U8, is FF -> FAILURE { C::execution_sel_tag_check_reg_0_, 1 }, { C::execution_mem_tag_reg_0_, static_cast(MemoryTag::FF) }, @@ -239,7 +239,7 @@ TEST(RegistersConstrainingTest, TagCheckIgnoresFailureWhenNotReading) { TestTraceContainer trace({ { - { C::execution_sel_should_read_registers, 0 }, + { C::execution_sel_read_registers, 0 }, // Reg 0: check U8, is FF -> FAILURE { C::execution_sel_tag_check_reg_0_, 1 }, { C::execution_mem_tag_reg_0_, static_cast(MemoryTag::FF) }, @@ -265,7 +265,7 @@ TEST(RegistersConstrainingTest, TagCheckMultipleFailures) TestTraceContainer trace({ { - { C::execution_sel_should_read_registers, 1 }, + { C::execution_sel_read_registers, 1 }, // Reg 0: check U8, is FF -> FAILURE { C::execution_sel_tag_check_reg_0_, 1 }, { C::execution_mem_tag_reg_0_, static_cast(MemoryTag::FF) }, diff --git a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/tx.test.cpp b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/tx.test.cpp index 9f4314789753..d4b05701807f 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/tx.test.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/tx.test.cpp @@ -161,7 +161,7 @@ class TxExecutionConstrainingTestHelper : public ::testing::Test { { C::tx_sel_read_phase_length, is_first_call ? 1 : 0 }, // Lookup Precomputed Table Values { C::tx_is_public_call_request, 1 }, - { C::tx_should_process_call_request, 1 }, + { C::tx_sel_process_call_request, 1 }, { C::tx_read_pi_start_offset, AVM_PUBLIC_INPUTS_PUBLIC_SETUP_CALL_REQUESTS_ROW_IDX }, { C::tx_read_pi_offset, read_pi_offset }, { C::tx_read_pi_length_offset, @@ -251,7 +251,7 @@ class TxExecutionConstrainingTestHelper : public ::testing::Test { { C::tx_sel_read_phase_length, is_first_call ? 1 : 0 }, // Lookup Precomputed Table Values { C::tx_is_public_call_request, 1 }, - { C::tx_should_process_call_request, 1 }, + { C::tx_sel_process_call_request, 1 }, { C::tx_read_pi_start_offset, AVM_PUBLIC_INPUTS_PUBLIC_APP_LOGIC_CALL_REQUESTS_ROW_IDX }, { C::tx_read_pi_offset, read_pi_offset }, { C::tx_read_pi_length_offset, @@ -660,7 +660,7 @@ TEST_F(TxExecutionConstrainingTestHelper, CollectFees) trace.set(10, { { - { C::tx_should_process_call_request, 1 }, + { C::tx_sel_process_call_request, 1 }, { C::tx_remaining_phase_counter, 1 }, { C::tx_remaining_phase_inv, 1 }, // Public Input Loaded Values @@ -850,19 +850,24 @@ TEST_F(TxExecutionConstrainingWithCalldataTest, SimpleHandleCalldata) check_all_interactions(trace); } -// Verify that the nullifier state increment is unconditional when should_nullifier_append = 1. +// Verify that the nullifier state increment is unconditional when sel_nullifier_append = 1. // A malicious prover cannot set reverted = 1 to skip the state increment. TEST(TxExecutionConstrainingTest, NegativeNullifierStateIncrementIsUnconditional) { + // #[NULLIFIER_TREE_SIZE_INCREMENT]: sel_nullifier_append * (prev_nullifier_tree_size + 1 - + // next_nullifier_tree_size) = + // 0 + // #[NUM_NULLIFIERS_EMITTED_INCREMENT]: sel_nullifier_append * (prev_num_nullifiers_emitted + 1 - + // next_num_nullifiers_emitted) = 0 TestTraceContainer trace({ { // Row 0 { C::precomputed_first_row, 1 }, }, { - // Row 1: Nullifier append with should_nullifier_append = 1 but state not incremented. + // Row 1: Nullifier append with sel_nullifier_append = 1 but state not incremented. { C::tx_sel, 1 }, - { C::tx_should_nullifier_append, 1 }, + { C::tx_sel_nullifier_append, 1 }, { C::tx_reverted, 1 }, // Prover tries to cheat by setting reverted = 1. { C::tx_prev_nullifier_tree_size, 5 }, { C::tx_next_nullifier_tree_size, 5 }, // Should be 6. diff --git a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/tx_context.test.cpp b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/tx_context.test.cpp index e2b78f33a0b3..f5ad8bad5366 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/tx_context.test.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/constraining/relations/tx_context.test.cpp @@ -190,7 +190,7 @@ TEST(TxContextConstrainingTest, StateMutability) { { C::tx_sel, 1 }, { C::tx_is_public_call_request, 1 }, - { C::tx_should_process_call_request, 1 }, + { C::tx_sel_process_call_request, 1 }, { C::tx_prev_note_hash_tree_root, 1 }, { C::tx_prev_note_hash_tree_size, 2 }, { C::tx_prev_num_note_hashes_emitted, 3 }, @@ -283,7 +283,7 @@ TEST(TxContextConstrainingTest, StateMutability) "L2_TO_L1_MESSAGE_COUNT_IMMUTABILITY"); // Negative test: immutability check on retrieved bytecodes tree - trace.set(C::tx_should_process_call_request, 0, 0); + trace.set(C::tx_sel_process_call_request, 0, 0); EXPECT_THROW_WITH_MESSAGE( check_relation(trace, tx_context::SR_RETRIEVED_BYTECODES_TREE_ROOT_IMMUTABILITY), @@ -538,7 +538,7 @@ TEST(TxContextConstrainingTest, NegativeContextIdChecks) // Row 2 { C::tx_sel, 1 }, { C::tx_next_context_id, 1 }, - { C::tx_should_process_call_request, 1 }, + { C::tx_sel_process_call_request, 1 }, }, { // Row 3 diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/columns.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/columns.hpp index 02576f9622b6..a17ecb8b76d9 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/columns.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/columns.hpp @@ -8,8 +8,8 @@ namespace bb::avm2 { // clang-format off #define AVM2_PRECOMPUTED_ENTITIES_E(e) e precomputed_addressing_gas, e precomputed_bitwise_input_a, e precomputed_bitwise_input_b, e precomputed_bitwise_output_and, e precomputed_bitwise_output_or, e precomputed_bitwise_output_xor, e precomputed_dyn_gas_id, e precomputed_envvar_pi_row_idx, e precomputed_exec_opcode, e precomputed_exec_opcode_base_da_gas, e precomputed_exec_opcode_dynamic_da_gas, e precomputed_exec_opcode_dynamic_l2_gas, e precomputed_exec_opcode_opcode_gas, e precomputed_expected_tag_reg_0_, e precomputed_expected_tag_reg_1_, e precomputed_expected_tag_reg_2_, e precomputed_expected_tag_reg_3_, e precomputed_expected_tag_reg_4_, e precomputed_expected_tag_reg_5_, e precomputed_first_row, e precomputed_idx, e precomputed_instr_size, e precomputed_invalid_envvar_enum, e precomputed_is_address, e precomputed_is_class_id, e precomputed_is_cleanup, e precomputed_is_collect_fee, e precomputed_is_dagasleft, e precomputed_is_deployer, e precomputed_is_init_hash, e precomputed_is_isstaticcall, e precomputed_is_l2gasleft, e precomputed_is_public_call_request, e precomputed_is_revertible, e precomputed_is_sender, e precomputed_is_teardown, e precomputed_is_transactionfee, e precomputed_is_tree_padding, e precomputed_is_valid_member_enum, e precomputed_keccak_round_constant, e precomputed_next_phase_on_revert, e precomputed_opcode_out_of_range, e precomputed_out_tag, e precomputed_p_decomposition_limb, e precomputed_p_decomposition_limb_index, e precomputed_p_decomposition_radix, e precomputed_power_of_2, e precomputed_read_pi_length_offset, e precomputed_read_pi_start_offset, e precomputed_rw_reg_0_, e precomputed_rw_reg_1_, e precomputed_rw_reg_2_, e precomputed_rw_reg_3_, e precomputed_rw_reg_4_, e precomputed_rw_reg_5_, e precomputed_sel_addressing_gas, e precomputed_sel_envvar_pi_lookup_col0, e precomputed_sel_envvar_pi_lookup_col1, e precomputed_sel_exec_spec, e precomputed_sel_has_tag, e precomputed_sel_keccak, e precomputed_sel_mem_op_reg_0_, e precomputed_sel_mem_op_reg_1_, e precomputed_sel_mem_op_reg_2_, e precomputed_sel_mem_op_reg_3_, e precomputed_sel_mem_op_reg_4_, e precomputed_sel_mem_op_reg_5_, e precomputed_sel_mem_tag_out_of_range, e precomputed_sel_non_revertible_append_l2_l1_msg, e precomputed_sel_non_revertible_append_note_hash, e precomputed_sel_non_revertible_append_nullifier, e precomputed_sel_op_dc_0, e precomputed_sel_op_dc_1, e precomputed_sel_op_dc_10, e precomputed_sel_op_dc_11, e precomputed_sel_op_dc_12, e precomputed_sel_op_dc_13, e precomputed_sel_op_dc_14, e precomputed_sel_op_dc_15, e precomputed_sel_op_dc_16, e precomputed_sel_op_dc_2, e precomputed_sel_op_dc_3, e precomputed_sel_op_dc_4, e precomputed_sel_op_dc_5, e precomputed_sel_op_dc_6, e precomputed_sel_op_dc_7, e precomputed_sel_op_dc_8, e precomputed_sel_op_dc_9, e precomputed_sel_op_is_address_0_, e precomputed_sel_op_is_address_1_, e precomputed_sel_op_is_address_2_, e precomputed_sel_op_is_address_3_, e precomputed_sel_op_is_address_4_, e precomputed_sel_op_is_address_5_, e precomputed_sel_op_is_address_6_, e precomputed_sel_p_decomposition, e precomputed_sel_phase, e precomputed_sel_range_16, e precomputed_sel_range_8, e precomputed_sel_revertible_append_l2_l1_msg, e precomputed_sel_revertible_append_note_hash, e precomputed_sel_revertible_append_nullifier, e precomputed_sel_sha256_compression, e precomputed_sel_tag_check_reg_0_, e precomputed_sel_tag_check_reg_1_, e precomputed_sel_tag_check_reg_2_, e precomputed_sel_tag_check_reg_3_, e precomputed_sel_tag_check_reg_4_, e precomputed_sel_tag_check_reg_5_, e precomputed_sel_tag_is_op2, e precomputed_sel_tag_parameters, e precomputed_sel_to_radix_p_limb_counts, e precomputed_sha256_compression_round_constant, e precomputed_subtrace_id, e precomputed_subtrace_operation_id, e precomputed_tag_byte_length, e precomputed_tag_max_bits, e precomputed_tag_max_value, e precomputed_to_radix_num_limbs_for_p, e precomputed_to_radix_safe_limbs, e precomputed_zero, e public_inputs_sel -#define AVM2_WIRE_ENTITIES_E(e) e public_inputs_cols_0_, e public_inputs_cols_1_, e public_inputs_cols_2_, e public_inputs_cols_3_, e address_derivation_address, e address_derivation_address_y, e address_derivation_class_id, e address_derivation_const_four, e address_derivation_const_thirteen, e address_derivation_const_three, e address_derivation_const_two, e address_derivation_deployer_addr, e address_derivation_g1_x, e address_derivation_g1_y, e address_derivation_incoming_viewing_key_x, e address_derivation_incoming_viewing_key_y, e address_derivation_init_hash, e address_derivation_nullifier_key_x, e address_derivation_nullifier_key_y, e address_derivation_outgoing_viewing_key_x, e address_derivation_outgoing_viewing_key_y, e address_derivation_partial_address, e address_derivation_partial_address_domain_separator, e address_derivation_preaddress, e address_derivation_preaddress_domain_separator, e address_derivation_preaddress_public_key_x, e address_derivation_preaddress_public_key_y, e address_derivation_public_keys_hash, e address_derivation_public_keys_hash_domain_separator, e address_derivation_salt, e address_derivation_salted_init_hash, e address_derivation_sel, e address_derivation_tagging_key_x, e address_derivation_tagging_key_y, e alu_a_hi, e alu_a_hi_bits, e alu_a_lo, e alu_a_lo_bits, e alu_ab_diff_inv, e alu_ab_tags_diff_inv, e alu_b_hi, e alu_b_inv, e alu_b_lo, e alu_c_hi, e alu_cf, e alu_constant_64, e alu_gt_input_a, e alu_gt_input_b, e alu_gt_result_c, e alu_helper1, e alu_ia, e alu_ia_tag, e alu_ib, e alu_ib_tag, e alu_ic, e alu_ic_tag, e alu_max_bits, e alu_max_value, e alu_mid, e alu_mid_bits, e alu_op_id, e alu_sel, e alu_sel_ab_tag_mismatch, e alu_sel_decompose_a, e alu_sel_div_0_err, e alu_sel_div_no_err, e alu_sel_err, e alu_sel_ff_gt, e alu_sel_int_gt, e alu_sel_is_ff, e alu_sel_is_u128, e alu_sel_mul_div_u128, e alu_sel_mul_no_err_non_ff, e alu_sel_op_add, e alu_sel_op_div, e alu_sel_op_eq, e alu_sel_op_fdiv, e alu_sel_op_lt, e alu_sel_op_lte, e alu_sel_op_mul, e alu_sel_op_not, e alu_sel_op_shl, e alu_sel_op_shr, e alu_sel_op_sub, e alu_sel_op_truncate, e alu_sel_shift_ops_no_overflow, e alu_sel_tag_err, e alu_sel_trunc_gte_128, e alu_sel_trunc_lt_128, e alu_sel_trunc_non_trivial, e alu_sel_trunc_trivial, e alu_shift_lo_bits, e alu_tag_ff_diff_inv, e alu_tag_u128_diff_inv, e alu_two_pow_shift_lo_bits, e bc_decomposition_bytes_pc_plus_36, e bc_decomposition_bytes_rem_inv, e bc_decomposition_bytes_rem_min_one_inv, e bc_decomposition_bytes_to_read, e bc_decomposition_last_of_contract, e bc_decomposition_next_packed_pc_min_pc_inv, e bc_decomposition_packed_field, e bc_decomposition_sel_packed, e bc_decomposition_sel_packed_read_0_, e bc_decomposition_sel_packed_read_1_, e bc_decomposition_sel_packed_read_2_, e bc_decomposition_sel_windows_eq_remaining, e bc_decomposition_windows_min_remaining_inv, e bc_hashing_end, e bc_hashing_input_len, e bc_hashing_packed_fields_0, e bc_hashing_packed_fields_1, e bc_hashing_packed_fields_2, e bc_hashing_pc_index, e bc_hashing_pc_index_2, e bc_hashing_sel_not_padding_1, e bc_hashing_sel_not_padding_2, e bc_hashing_size_in_bytes, e bc_retrieval_address, e bc_retrieval_artifact_hash, e bc_retrieval_bytecode_id, e bc_retrieval_current_class_id, e bc_retrieval_error, e bc_retrieval_instance_exists, e bc_retrieval_is_new_class, e bc_retrieval_next_retrieved_bytecodes_tree_root, e bc_retrieval_next_retrieved_bytecodes_tree_size, e bc_retrieval_no_remaining_bytecodes, e bc_retrieval_nullifier_tree_root, e bc_retrieval_prev_retrieved_bytecodes_tree_root, e bc_retrieval_prev_retrieved_bytecodes_tree_size, e bc_retrieval_private_functions_root, e bc_retrieval_public_data_tree_root, e bc_retrieval_remaining_bytecodes_inv, e bc_retrieval_retrieved_bytecodes_merkle_separator, e bc_retrieval_retrieved_bytecodes_tree_height, e bc_retrieval_sel, e bc_retrieval_should_retrieve, e bitwise_ctr_min_one_inv, e bitwise_end, e bitwise_err, e bitwise_ia_byte, e bitwise_ib_byte, e bitwise_ic_byte, e bitwise_output_and, e bitwise_output_or, e bitwise_output_xor, e bitwise_sel_and, e bitwise_sel_compute, e bitwise_sel_get_ctr, e bitwise_sel_or, e bitwise_sel_tag_ff_err, e bitwise_sel_tag_mismatch_err, e bitwise_sel_xor, e bitwise_start_keccak, e bitwise_start_sha256, e bitwise_tag_a, e bitwise_tag_a_inv, e bitwise_tag_ab_diff_inv, e bitwise_tag_b, e bitwise_tag_c, e calldata_end, e calldata_hashing_end, e calldata_hashing_index_1_, e calldata_hashing_index_2_, e calldata_hashing_input_0_, e calldata_hashing_input_1_, e calldata_hashing_input_2_, e calldata_hashing_input_len, e calldata_hashing_sel_end_not_empty, e calldata_hashing_sel_not_padding_1, e calldata_hashing_sel_not_padding_2, e calldata_hashing_sel_not_start, e calldata_value, e class_id_derivation_artifact_hash, e class_id_derivation_class_id, e class_id_derivation_const_four, e class_id_derivation_gen_index_contract_class_id, e class_id_derivation_private_functions_root, e class_id_derivation_public_bytecode_commitment, e class_id_derivation_sel, e context_stack_bytecode_id, e context_stack_context_id, e context_stack_contract_address, e context_stack_entered_context_id, e context_stack_internal_call_id, e context_stack_internal_call_return_id, e context_stack_is_static, e context_stack_msg_sender, e context_stack_next_internal_call_id, e context_stack_next_pc, e context_stack_note_hash_tree_root, e context_stack_note_hash_tree_size, e context_stack_nullifier_tree_root, e context_stack_nullifier_tree_size, e context_stack_num_l2_to_l1_messages, e context_stack_num_note_hashes_emitted, e context_stack_num_nullifiers_emitted, e context_stack_num_public_log_fields, e context_stack_parent_calldata_addr, e context_stack_parent_calldata_size, e context_stack_parent_da_gas_limit, e context_stack_parent_da_gas_used, e context_stack_parent_id, e context_stack_parent_l2_gas_limit, e context_stack_parent_l2_gas_used, e context_stack_public_data_tree_root, e context_stack_public_data_tree_size, e context_stack_sel, e context_stack_written_public_data_slots_tree_root, e context_stack_written_public_data_slots_tree_size, e contract_instance_retrieval_address, e contract_instance_retrieval_address_sub_one, e contract_instance_retrieval_current_class_id, e contract_instance_retrieval_deployer_addr, e contract_instance_retrieval_deployer_protocol_contract_address, e contract_instance_retrieval_derived_address, e contract_instance_retrieval_derived_address_pi_index, e contract_instance_retrieval_exists, e contract_instance_retrieval_incoming_viewing_key_x, e contract_instance_retrieval_incoming_viewing_key_y, e contract_instance_retrieval_init_hash, e contract_instance_retrieval_is_protocol_contract, e contract_instance_retrieval_max_protocol_contracts, e contract_instance_retrieval_nullifier_key_x, e contract_instance_retrieval_nullifier_key_y, e contract_instance_retrieval_nullifier_merkle_separator, e contract_instance_retrieval_nullifier_tree_height, e contract_instance_retrieval_nullifier_tree_root, e contract_instance_retrieval_original_class_id, e contract_instance_retrieval_outgoing_viewing_key_x, e contract_instance_retrieval_outgoing_viewing_key_y, e contract_instance_retrieval_protocol_contract_derived_address_inv, e contract_instance_retrieval_public_data_tree_root, e contract_instance_retrieval_salt, e contract_instance_retrieval_sel, e contract_instance_retrieval_should_check_for_update, e contract_instance_retrieval_should_check_nullifier, e contract_instance_retrieval_siloing_separator, e contract_instance_retrieval_tagging_key_x, e contract_instance_retrieval_tagging_key_y, e data_copy_cd_copy_col_read, e data_copy_clamped_read_index_upper_bound, e data_copy_dst_out_of_range_err, e data_copy_end, e data_copy_is_top_level, e data_copy_mem_size, e data_copy_offset, e data_copy_offset_plus_size, e data_copy_offset_plus_size_is_gt, e data_copy_parent_id_inv, e data_copy_read_addr_plus_one, e data_copy_read_addr_upper_bound, e data_copy_reads_left_inv, e data_copy_sel_cd_copy_start, e data_copy_sel_has_reads, e data_copy_sel_mem_read, e data_copy_sel_mem_write, e data_copy_sel_rd_copy_start, e data_copy_sel_write_count_is_zero, e data_copy_src_addr, e data_copy_src_data_size, e data_copy_src_reads_exceed_mem, e data_copy_start_no_err, e data_copy_tag, e data_copy_value, e data_copy_write_addr_upper_bound, e data_copy_write_count_minus_one_inv, e data_copy_write_count_zero_inv, e ecc_add_mem_dst_addr_0_, e ecc_add_mem_dst_addr_1_, e ecc_add_mem_dst_addr_2_, e ecc_add_mem_err, e ecc_add_mem_execution_clk, e ecc_add_mem_max_mem_addr, e ecc_add_mem_p_is_inf, e ecc_add_mem_p_is_on_curve_eqn, e ecc_add_mem_p_is_on_curve_eqn_inv, e ecc_add_mem_p_x, e ecc_add_mem_p_x_n, e ecc_add_mem_p_y, e ecc_add_mem_p_y_n, e ecc_add_mem_q_is_inf, e ecc_add_mem_q_is_on_curve_eqn, e ecc_add_mem_q_is_on_curve_eqn_inv, e ecc_add_mem_q_x, e ecc_add_mem_q_x_n, e ecc_add_mem_q_y, e ecc_add_mem_q_y_n, e ecc_add_mem_res_is_inf, e ecc_add_mem_res_x, e ecc_add_mem_res_y, e ecc_add_mem_sel, e ecc_add_mem_sel_dst_out_of_range_err, e ecc_add_mem_sel_p_not_on_curve_err, e ecc_add_mem_sel_q_not_on_curve_err, e ecc_add_mem_sel_should_exec, e ecc_add_mem_space_id, e ecc_add_op, e ecc_double_op, e ecc_inv_2_p_y, e ecc_inv_x_diff, e ecc_inv_y_diff, e ecc_lambda, e ecc_p_is_inf, e ecc_p_x, e ecc_p_y, e ecc_q_is_inf, e ecc_q_x, e ecc_q_y, e ecc_r_is_inf, e ecc_r_x, e ecc_r_y, e ecc_result_infinity, e ecc_sel, e ecc_use_computed_result, e ecc_x_match, e ecc_y_match, e emit_public_log_discard, e emit_public_log_end, e emit_public_log_end_log_address_upper_bound, e emit_public_log_error, e emit_public_log_error_too_many_log_fields, e emit_public_log_expected_next_log_fields, e emit_public_log_is_static, e emit_public_log_log_size, e emit_public_log_max_mem_size, e emit_public_log_max_public_logs_payload_length, e emit_public_log_next_num_public_log_fields, e emit_public_log_prev_num_public_log_fields, e emit_public_log_public_inputs_value, e emit_public_log_remaining_rows_inv, e emit_public_log_sel_read_memory, e emit_public_log_tag, e emit_public_log_tag_inv, e emit_public_log_value, e execution_addressing_error_collection_inv, e execution_addressing_gas, e execution_addressing_mode, e execution_base_address_tag, e execution_base_address_tag_diff_inv, e execution_base_address_val, e execution_base_da_gas, e execution_batched_tags_diff_inv, e execution_batched_tags_diff_inv_reg, e execution_da_gas_left, e execution_da_gas_used, e execution_dying_context_diff_inv, e execution_dying_context_id_inv, e execution_dyn_gas_id, e execution_dynamic_da_gas, e execution_dynamic_da_gas_factor, e execution_dynamic_l2_gas, e execution_dynamic_l2_gas_factor, e execution_enqueued_call_end, e execution_envvar_pi_row_idx, e execution_exec_opcode, e execution_expected_tag_reg_0_, e execution_expected_tag_reg_1_, e execution_expected_tag_reg_2_, e execution_expected_tag_reg_3_, e execution_expected_tag_reg_4_, e execution_expected_tag_reg_5_, e execution_has_parent_ctx, e execution_highest_address, e execution_instr_size, e execution_internal_call_return_id_inv, e execution_is_address, e execution_is_da_gas_left_gt_allocated, e execution_is_dagasleft, e execution_is_dying_context, e execution_is_isstaticcall, e execution_is_l2_gas_left_gt_allocated, e execution_is_l2gasleft, e execution_is_parent_id_inv, e execution_is_sender, e execution_is_transactionfee, e execution_l1_to_l2_msg_leaf_in_range, e execution_l1_to_l2_msg_tree_leaf_count, e execution_l2_gas_left, e execution_l2_gas_used, e execution_max_data_writes_reached, e execution_max_eth_address_value, e execution_mem_tag_reg_0_, e execution_mem_tag_reg_1_, e execution_mem_tag_reg_2_, e execution_mem_tag_reg_3_, e execution_mem_tag_reg_4_, e execution_mem_tag_reg_5_, e execution_nested_failure, e execution_nested_return, e execution_next_pc, e execution_note_hash_leaf_in_range, e execution_note_hash_tree_leaf_count, e execution_note_hash_tree_root, e execution_note_hash_tree_size, e execution_nullifier_merkle_separator, e execution_nullifier_pi_offset, e execution_nullifier_siloing_separator, e execution_nullifier_tree_height, e execution_nullifier_tree_root, e execution_nullifier_tree_size, e execution_num_l2_to_l1_messages, e execution_num_note_hashes_emitted, e execution_num_nullifiers_emitted, e execution_num_p_limbs, e execution_num_public_log_fields, e execution_num_relative_operands_inv, e execution_op_0_, e execution_op_1_, e execution_op_2_, e execution_op_3_, e execution_op_4_, e execution_op_5_, e execution_op_6_, e execution_op_after_relative_0_, e execution_op_after_relative_1_, e execution_op_after_relative_2_, e execution_op_after_relative_3_, e execution_op_after_relative_4_, e execution_op_after_relative_5_, e execution_op_after_relative_6_, e execution_opcode_gas, e execution_out_of_gas_da, e execution_out_of_gas_l2, e execution_public_data_tree_root, e execution_public_data_tree_size, e execution_public_inputs_index, e execution_register_0_, e execution_register_1_, e execution_register_2_, e execution_register_3_, e execution_register_4_, e execution_register_5_, e execution_remaining_data_writes_inv, e execution_remaining_l2_to_l1_msgs_inv, e execution_remaining_note_hashes_inv, e execution_remaining_nullifiers_inv, e execution_retrieved_bytecodes_tree_root, e execution_retrieved_bytecodes_tree_size, e execution_rop_0_, e execution_rop_1_, e execution_rop_2_, e execution_rop_3_, e execution_rop_4_, e execution_rop_5_, e execution_rop_6_, e execution_rop_tag_0_, e execution_rop_tag_1_, e execution_rop_tag_2_, e execution_rop_tag_3_, e execution_rop_tag_4_, e execution_rop_tag_5_, e execution_rop_tag_6_, e execution_rw_reg_0_, e execution_rw_reg_1_, e execution_rw_reg_2_, e execution_rw_reg_3_, e execution_rw_reg_4_, e execution_rw_reg_5_, e execution_sel_addressing_error, e execution_sel_base_address_failure, e execution_sel_bytecode_retrieval_failure, e execution_sel_bytecode_retrieval_success, e execution_sel_do_base_check, e execution_sel_enter_call, e execution_sel_envvar_pi_lookup_col0, e execution_sel_envvar_pi_lookup_col1, e execution_sel_error, e execution_sel_exec_dispatch_alu, e execution_sel_exec_dispatch_bitwise, e execution_sel_exec_dispatch_calldata_copy, e execution_sel_exec_dispatch_cast, e execution_sel_exec_dispatch_ecc_add, e execution_sel_exec_dispatch_emit_public_log, e execution_sel_exec_dispatch_execution, e execution_sel_exec_dispatch_get_contract_instance, e execution_sel_exec_dispatch_keccakf1600, e execution_sel_exec_dispatch_poseidon2_perm, e execution_sel_exec_dispatch_returndata_copy, e execution_sel_exec_dispatch_set, e execution_sel_exec_dispatch_sha256_compression, e execution_sel_exec_dispatch_to_radix, e execution_sel_execute_call, e execution_sel_execute_debug_log, e execution_sel_execute_emit_notehash, e execution_sel_execute_emit_nullifier, e execution_sel_execute_get_env_var, e execution_sel_execute_internal_call, e execution_sel_execute_internal_return, e execution_sel_execute_jump, e execution_sel_execute_jumpi, e execution_sel_execute_l1_to_l2_message_exists, e execution_sel_execute_mov, e execution_sel_execute_notehash_exists, e execution_sel_execute_nullifier_exists, e execution_sel_execute_return, e execution_sel_execute_returndata_size, e execution_sel_execute_revert, e execution_sel_execute_send_l2_to_l1_msg, e execution_sel_execute_sload, e execution_sel_execute_sstore, e execution_sel_execute_static_call, e execution_sel_execute_success_copy, e execution_sel_exit_call, e execution_sel_failure, e execution_sel_gas_bitwise, e execution_sel_gas_calldata_copy, e execution_sel_gas_emit_public_log, e execution_sel_gas_returndata_copy, e execution_sel_gas_sstore, e execution_sel_gas_to_radix, e execution_sel_instruction_fetching_failure, e execution_sel_instruction_fetching_success, e execution_sel_l2_to_l1_msg_limit_error, e execution_sel_lookup_num_p_limbs, e execution_sel_mem_op_reg_0_, e execution_sel_mem_op_reg_1_, e execution_sel_mem_op_reg_2_, e execution_sel_mem_op_reg_3_, e execution_sel_mem_op_reg_4_, e execution_sel_mem_op_reg_5_, e execution_sel_op_do_overflow_check_0_, e execution_sel_op_do_overflow_check_1_, e execution_sel_op_do_overflow_check_2_, e execution_sel_op_do_overflow_check_3_, e execution_sel_op_do_overflow_check_4_, e execution_sel_op_do_overflow_check_5_, e execution_sel_op_do_overflow_check_6_, e execution_sel_op_is_address_0_, e execution_sel_op_is_address_1_, e execution_sel_op_is_address_2_, e execution_sel_op_is_address_3_, e execution_sel_op_is_address_4_, e execution_sel_op_is_address_5_, e execution_sel_op_is_address_6_, e execution_sel_op_is_indirect_wire_0_, e execution_sel_op_is_indirect_wire_1_, e execution_sel_op_is_indirect_wire_2_, e execution_sel_op_is_indirect_wire_3_, e execution_sel_op_is_indirect_wire_4_, e execution_sel_op_is_indirect_wire_5_, e execution_sel_op_is_indirect_wire_6_, e execution_sel_op_is_indirect_wire_7_, e execution_sel_op_is_relative_wire_0_, e execution_sel_op_is_relative_wire_1_, e execution_sel_op_is_relative_wire_2_, e execution_sel_op_is_relative_wire_3_, e execution_sel_op_is_relative_wire_4_, e execution_sel_op_is_relative_wire_5_, e execution_sel_op_is_relative_wire_6_, e execution_sel_op_is_relative_wire_7_, e execution_sel_op_reg_effective_0_, e execution_sel_op_reg_effective_1_, e execution_sel_op_reg_effective_2_, e execution_sel_op_reg_effective_3_, e execution_sel_op_reg_effective_4_, e execution_sel_op_reg_effective_5_, e execution_sel_opcode_error, e execution_sel_out_of_gas, e execution_sel_radix_gt_256, e execution_sel_reached_max_note_hashes, e execution_sel_reached_max_nullifiers, e execution_sel_read_unwind_call_stack, e execution_sel_register_read_error, e execution_sel_relative_overflow_0_, e execution_sel_relative_overflow_1_, e execution_sel_relative_overflow_2_, e execution_sel_relative_overflow_3_, e execution_sel_relative_overflow_4_, e execution_sel_relative_overflow_5_, e execution_sel_relative_overflow_6_, e execution_sel_should_apply_indirection_0_, e execution_sel_should_apply_indirection_1_, e execution_sel_should_apply_indirection_2_, e execution_sel_should_apply_indirection_3_, e execution_sel_should_apply_indirection_4_, e execution_sel_should_apply_indirection_5_, e execution_sel_should_apply_indirection_6_, e execution_sel_should_check_gas, e execution_sel_should_execute_opcode, e execution_sel_should_read_registers, e execution_sel_should_write_registers, e execution_sel_some_final_check_failed, e execution_sel_tag_check_reg_0_, e execution_sel_tag_check_reg_1_, e execution_sel_tag_check_reg_2_, e execution_sel_tag_check_reg_3_, e execution_sel_tag_check_reg_4_, e execution_sel_tag_check_reg_5_, e execution_sel_too_large_recipient_error, e execution_sel_use_num_limbs, e execution_sel_write_l2_to_l1_msg, e execution_sel_write_note_hash, e execution_sel_write_nullifier, e execution_sel_write_public_data, e execution_subtrace_id, e execution_subtrace_operation_id, e execution_total_gas_da, e execution_total_gas_l2, e execution_two_five_six, e execution_value_from_pi, e execution_written_public_data_slots_tree_root, e execution_written_public_data_slots_tree_size, e execution_written_slots_merkle_separator, e execution_written_slots_tree_height, e execution_written_slots_tree_siloing_separator, e ff_gt_a, e ff_gt_b, e ff_gt_borrow, e ff_gt_constant_128, e ff_gt_end, e ff_gt_p_a_borrow, e ff_gt_p_b_borrow, e ff_gt_res_hi, e ff_gt_res_lo, e ff_gt_result, e get_contract_instance_clk, e get_contract_instance_contract_address, e get_contract_instance_dst_offset, e get_contract_instance_dst_offset_diff_max_inv, e get_contract_instance_exists_tag, e get_contract_instance_instance_exists, e get_contract_instance_is_class_id, e get_contract_instance_is_deployer, e get_contract_instance_is_init_hash, e get_contract_instance_is_valid_member_enum, e get_contract_instance_is_valid_writes_in_bounds, e get_contract_instance_member_enum, e get_contract_instance_member_tag, e get_contract_instance_member_write_offset, e get_contract_instance_nullifier_tree_root, e get_contract_instance_public_data_tree_root, e get_contract_instance_retrieved_class_id, e get_contract_instance_retrieved_deployer_addr, e get_contract_instance_retrieved_init_hash, e get_contract_instance_sel, e get_contract_instance_sel_error, e get_contract_instance_selected_member, e get_contract_instance_space_id, e gt_abs_diff, e gt_input_a, e gt_input_b, e gt_num_bits, e gt_res, e gt_sel, e gt_sel_addressing, e gt_sel_alu, e gt_sel_gas, e gt_sel_others, e gt_sel_sha256, e indexed_tree_check_address, e indexed_tree_check_const_three, e indexed_tree_check_discard, e indexed_tree_check_exists, e indexed_tree_check_intermediate_root, e indexed_tree_check_low_leaf_hash, e indexed_tree_check_low_leaf_index, e indexed_tree_check_low_leaf_next_index, e indexed_tree_check_low_leaf_next_value, e indexed_tree_check_low_leaf_value, e indexed_tree_check_merkle_hash_separator, e indexed_tree_check_new_leaf_hash, e indexed_tree_check_next_value_inv, e indexed_tree_check_next_value_is_nonzero, e indexed_tree_check_not_exists, e indexed_tree_check_public_inputs_index, e indexed_tree_check_root, e indexed_tree_check_sel, e indexed_tree_check_sel_insert, e indexed_tree_check_sel_silo, e indexed_tree_check_sel_write_to_public_inputs, e indexed_tree_check_siloed_value, e indexed_tree_check_siloing_separator, e indexed_tree_check_tree_height, e indexed_tree_check_tree_size_after_write, e indexed_tree_check_tree_size_before_write, e indexed_tree_check_updated_low_leaf_hash, e indexed_tree_check_updated_low_leaf_next_index, e indexed_tree_check_updated_low_leaf_next_value, e indexed_tree_check_value, e indexed_tree_check_value_low_leaf_value_diff_inv, e indexed_tree_check_write, e indexed_tree_check_write_root, e instr_fetching_addressing_mode, e instr_fetching_bd0, e instr_fetching_bd1, e instr_fetching_bd10, e instr_fetching_bd11, e instr_fetching_bd12, e instr_fetching_bd13, e instr_fetching_bd14, e instr_fetching_bd15, e instr_fetching_bd16, e instr_fetching_bd17, e instr_fetching_bd18, e instr_fetching_bd19, e instr_fetching_bd2, e instr_fetching_bd20, e instr_fetching_bd21, e instr_fetching_bd22, e instr_fetching_bd23, e instr_fetching_bd24, e instr_fetching_bd25, e instr_fetching_bd26, e instr_fetching_bd27, e instr_fetching_bd28, e instr_fetching_bd29, e instr_fetching_bd3, e instr_fetching_bd30, e instr_fetching_bd31, e instr_fetching_bd32, e instr_fetching_bd33, e instr_fetching_bd34, e instr_fetching_bd35, e instr_fetching_bd36, e instr_fetching_bd4, e instr_fetching_bd5, e instr_fetching_bd6, e instr_fetching_bd7, e instr_fetching_bd8, e instr_fetching_bd9, e instr_fetching_bytecode_id, e instr_fetching_bytecode_size, e instr_fetching_bytes_to_read, e instr_fetching_exec_opcode, e instr_fetching_instr_abs_diff, e instr_fetching_instr_out_of_range, e instr_fetching_instr_size, e instr_fetching_op1, e instr_fetching_op2, e instr_fetching_op3, e instr_fetching_op4, e instr_fetching_op5, e instr_fetching_op6, e instr_fetching_op7, e instr_fetching_opcode_out_of_range, e instr_fetching_pc, e instr_fetching_pc_abs_diff, e instr_fetching_pc_out_of_range, e instr_fetching_pc_size_in_bits, e instr_fetching_sel, e instr_fetching_sel_has_tag, e instr_fetching_sel_op_dc_0, e instr_fetching_sel_op_dc_1, e instr_fetching_sel_op_dc_10, e instr_fetching_sel_op_dc_11, e instr_fetching_sel_op_dc_12, e instr_fetching_sel_op_dc_13, e instr_fetching_sel_op_dc_14, e instr_fetching_sel_op_dc_15, e instr_fetching_sel_op_dc_16, e instr_fetching_sel_op_dc_2, e instr_fetching_sel_op_dc_3, e instr_fetching_sel_op_dc_4, e instr_fetching_sel_op_dc_5, e instr_fetching_sel_op_dc_6, e instr_fetching_sel_op_dc_7, e instr_fetching_sel_op_dc_8, e instr_fetching_sel_op_dc_9, e instr_fetching_sel_parsing_err, e instr_fetching_sel_pc_in_range, e instr_fetching_sel_tag_is_op2, e instr_fetching_tag_out_of_range, e instr_fetching_tag_value, e internal_call_stack_call_id, e internal_call_stack_context_id, e internal_call_stack_entered_call_id, e internal_call_stack_return_call_id, e internal_call_stack_return_pc, e internal_call_stack_sel, e keccak_memory_ctr_end, e keccak_memory_end, e keccak_memory_single_tag_error, e keccak_memory_state_size_min_ctr_inv, e keccak_memory_tag, e keccak_memory_tag_min_u64_inv, e keccak_memory_val_24_, e keccakf1600_bitwise_and_op_id, e keccakf1600_bitwise_xor_op_id, e keccakf1600_dst_out_of_range_error, e keccakf1600_end, e keccakf1600_error, e keccakf1600_highest_slice_address, e keccakf1600_rot_64_min_len_01, e keccakf1600_rot_64_min_len_03, e keccakf1600_rot_64_min_len_11, e keccakf1600_rot_64_min_len_13, e keccakf1600_rot_64_min_len_20, e keccakf1600_rot_64_min_len_22, e keccakf1600_rot_64_min_len_24, e keccakf1600_rot_64_min_len_31, e keccakf1600_rot_64_min_len_34, e keccakf1600_rot_64_min_len_42, e keccakf1600_rot_len_02, e keccakf1600_rot_len_04, e keccakf1600_rot_len_10, e keccakf1600_rot_len_12, e keccakf1600_rot_len_14, e keccakf1600_rot_len_21, e keccakf1600_rot_len_23, e keccakf1600_rot_len_30, e keccakf1600_rot_len_32, e keccakf1600_rot_len_33, e keccakf1600_rot_len_40, e keccakf1600_rot_len_41, e keccakf1600_rot_len_43, e keccakf1600_rot_len_44, e keccakf1600_round_cst, e keccakf1600_sel_slice_read, e keccakf1600_sel_slice_write, e keccakf1600_src_addr, e keccakf1600_src_out_of_range_error, e keccakf1600_state_chi_00, e keccakf1600_state_chi_01, e keccakf1600_state_chi_02, e keccakf1600_state_chi_03, e keccakf1600_state_chi_04, e keccakf1600_state_chi_10, e keccakf1600_state_chi_11, e keccakf1600_state_chi_12, e keccakf1600_state_chi_13, e keccakf1600_state_chi_14, e keccakf1600_state_chi_20, e keccakf1600_state_chi_21, e keccakf1600_state_chi_22, e keccakf1600_state_chi_23, e keccakf1600_state_chi_24, e keccakf1600_state_chi_30, e keccakf1600_state_chi_31, e keccakf1600_state_chi_32, e keccakf1600_state_chi_33, e keccakf1600_state_chi_34, e keccakf1600_state_chi_40, e keccakf1600_state_chi_41, e keccakf1600_state_chi_42, e keccakf1600_state_chi_43, e keccakf1600_state_chi_44, e keccakf1600_state_iota_00, e keccakf1600_state_pi_and_00, e keccakf1600_state_pi_and_01, e keccakf1600_state_pi_and_02, e keccakf1600_state_pi_and_03, e keccakf1600_state_pi_and_04, e keccakf1600_state_pi_and_10, e keccakf1600_state_pi_and_11, e keccakf1600_state_pi_and_12, e keccakf1600_state_pi_and_13, e keccakf1600_state_pi_and_14, e keccakf1600_state_pi_and_20, e keccakf1600_state_pi_and_21, e keccakf1600_state_pi_and_22, e keccakf1600_state_pi_and_23, e keccakf1600_state_pi_and_24, e keccakf1600_state_pi_and_30, e keccakf1600_state_pi_and_31, e keccakf1600_state_pi_and_32, e keccakf1600_state_pi_and_33, e keccakf1600_state_pi_and_34, e keccakf1600_state_pi_and_40, e keccakf1600_state_pi_and_41, e keccakf1600_state_pi_and_42, e keccakf1600_state_pi_and_43, e keccakf1600_state_pi_and_44, e keccakf1600_state_pi_not_00, e keccakf1600_state_pi_not_01, e keccakf1600_state_pi_not_02, e keccakf1600_state_pi_not_03, e keccakf1600_state_pi_not_04, e keccakf1600_state_pi_not_10, e keccakf1600_state_pi_not_11, e keccakf1600_state_pi_not_12, e keccakf1600_state_pi_not_13, e keccakf1600_state_pi_not_14, e keccakf1600_state_pi_not_20, e keccakf1600_state_pi_not_21, e keccakf1600_state_pi_not_22, e keccakf1600_state_pi_not_23, e keccakf1600_state_pi_not_24, e keccakf1600_state_pi_not_30, e keccakf1600_state_pi_not_31, e keccakf1600_state_pi_not_32, e keccakf1600_state_pi_not_33, e keccakf1600_state_pi_not_34, e keccakf1600_state_pi_not_40, e keccakf1600_state_pi_not_41, e keccakf1600_state_pi_not_42, e keccakf1600_state_pi_not_43, e keccakf1600_state_pi_not_44, e keccakf1600_state_rho_01, e keccakf1600_state_rho_02, e keccakf1600_state_rho_03, e keccakf1600_state_rho_04, e keccakf1600_state_rho_10, e keccakf1600_state_rho_11, e keccakf1600_state_rho_12, e keccakf1600_state_rho_13, e keccakf1600_state_rho_14, e keccakf1600_state_rho_20, e keccakf1600_state_rho_21, e keccakf1600_state_rho_22, e keccakf1600_state_rho_23, e keccakf1600_state_rho_24, e keccakf1600_state_rho_30, e keccakf1600_state_rho_31, e keccakf1600_state_rho_32, e keccakf1600_state_rho_33, e keccakf1600_state_rho_34, e keccakf1600_state_rho_40, e keccakf1600_state_rho_41, e keccakf1600_state_rho_42, e keccakf1600_state_rho_43, e keccakf1600_state_rho_44, e keccakf1600_state_theta_00, e keccakf1600_state_theta_01, e keccakf1600_state_theta_02, e keccakf1600_state_theta_03, e keccakf1600_state_theta_04, e keccakf1600_state_theta_10, e keccakf1600_state_theta_11, e keccakf1600_state_theta_12, e keccakf1600_state_theta_13, e keccakf1600_state_theta_14, e keccakf1600_state_theta_20, e keccakf1600_state_theta_21, e keccakf1600_state_theta_22, e keccakf1600_state_theta_23, e keccakf1600_state_theta_24, e keccakf1600_state_theta_30, e keccakf1600_state_theta_31, e keccakf1600_state_theta_32, e keccakf1600_state_theta_33, e keccakf1600_state_theta_34, e keccakf1600_state_theta_40, e keccakf1600_state_theta_41, e keccakf1600_state_theta_42, e keccakf1600_state_theta_43, e keccakf1600_state_theta_44, e keccakf1600_state_theta_hi_02, e keccakf1600_state_theta_hi_04, e keccakf1600_state_theta_hi_10, e keccakf1600_state_theta_hi_12, e keccakf1600_state_theta_hi_14, e keccakf1600_state_theta_hi_21, e keccakf1600_state_theta_hi_23, e keccakf1600_state_theta_hi_30, e keccakf1600_state_theta_hi_32, e keccakf1600_state_theta_hi_33, e keccakf1600_state_theta_hi_40, e keccakf1600_state_theta_hi_41, e keccakf1600_state_theta_hi_43, e keccakf1600_state_theta_hi_44, e keccakf1600_state_theta_low_01, e keccakf1600_state_theta_low_03, e keccakf1600_state_theta_low_11, e keccakf1600_state_theta_low_13, e keccakf1600_state_theta_low_20, e keccakf1600_state_theta_low_22, e keccakf1600_state_theta_low_24, e keccakf1600_state_theta_low_31, e keccakf1600_state_theta_low_34, e keccakf1600_state_theta_low_42, e keccakf1600_tag_error, e keccakf1600_tag_u64, e keccakf1600_theta_combined_xor_0, e keccakf1600_theta_combined_xor_1, e keccakf1600_theta_combined_xor_2, e keccakf1600_theta_combined_xor_3, e keccakf1600_theta_combined_xor_4, e keccakf1600_theta_xor_01, e keccakf1600_theta_xor_02, e keccakf1600_theta_xor_03, e keccakf1600_theta_xor_11, e keccakf1600_theta_xor_12, e keccakf1600_theta_xor_13, e keccakf1600_theta_xor_21, e keccakf1600_theta_xor_22, e keccakf1600_theta_xor_23, e keccakf1600_theta_xor_31, e keccakf1600_theta_xor_32, e keccakf1600_theta_xor_33, e keccakf1600_theta_xor_41, e keccakf1600_theta_xor_42, e keccakf1600_theta_xor_43, e keccakf1600_theta_xor_row_0, e keccakf1600_theta_xor_row_1, e keccakf1600_theta_xor_row_2, e keccakf1600_theta_xor_row_3, e keccakf1600_theta_xor_row_4, e keccakf1600_theta_xor_row_msb_0, e keccakf1600_theta_xor_row_msb_1, e keccakf1600_theta_xor_row_msb_2, e keccakf1600_theta_xor_row_msb_3, e keccakf1600_theta_xor_row_msb_4, e keccakf1600_theta_xor_row_rotl1_0, e keccakf1600_theta_xor_row_rotl1_1, e keccakf1600_theta_xor_row_rotl1_2, e keccakf1600_theta_xor_row_rotl1_3, e keccakf1600_theta_xor_row_rotl1_4, e l1_to_l2_message_tree_check_exists, e l1_to_l2_message_tree_check_l1_to_l2_message_tree_height, e l1_to_l2_message_tree_check_leaf_index, e l1_to_l2_message_tree_check_leaf_value, e l1_to_l2_message_tree_check_leaf_value_msg_hash_diff_inv, e l1_to_l2_message_tree_check_merkle_hash_separator, e l1_to_l2_message_tree_check_msg_hash, e l1_to_l2_message_tree_check_root, e l1_to_l2_message_tree_check_sel, e memory_diff, e memory_glob_addr_diff_inv, e memory_last_access, e memory_limb_0_, e memory_limb_1_, e memory_limb_2_, e memory_max_bits, e memory_sel_addressing_base, e memory_sel_addressing_indirect_0_, e memory_sel_addressing_indirect_1_, e memory_sel_addressing_indirect_2_, e memory_sel_addressing_indirect_3_, e memory_sel_addressing_indirect_4_, e memory_sel_addressing_indirect_5_, e memory_sel_addressing_indirect_6_, e memory_sel_data_copy_read, e memory_sel_data_copy_write, e memory_sel_ecc_write_0_, e memory_sel_ecc_write_1_, e memory_sel_ecc_write_2_, e memory_sel_get_contract_instance_exists_write, e memory_sel_get_contract_instance_member_write, e memory_sel_keccak, e memory_sel_poseidon2_read_0_, e memory_sel_poseidon2_read_1_, e memory_sel_poseidon2_read_2_, e memory_sel_poseidon2_read_3_, e memory_sel_poseidon2_write_0_, e memory_sel_poseidon2_write_1_, e memory_sel_poseidon2_write_2_, e memory_sel_poseidon2_write_3_, e memory_sel_public_log_read, e memory_sel_register_op_0_, e memory_sel_register_op_1_, e memory_sel_register_op_2_, e memory_sel_register_op_3_, e memory_sel_register_op_4_, e memory_sel_register_op_5_, e memory_sel_rng_chk, e memory_sel_rng_write, e memory_sel_sha256_op_0_, e memory_sel_sha256_op_1_, e memory_sel_sha256_op_2_, e memory_sel_sha256_op_3_, e memory_sel_sha256_op_4_, e memory_sel_sha256_op_5_, e memory_sel_sha256_op_6_, e memory_sel_sha256_op_7_, e memory_sel_sha256_read, e memory_sel_tag_is_ff, e memory_sel_to_radix_write, e memory_tag_ff_diff_inv, e merkle_check_const_three, e merkle_check_end, e merkle_check_index_is_even, e merkle_check_path_len_min_one_inv, e merkle_check_read_left_node, e merkle_check_read_output_hash, e merkle_check_read_right_node, e merkle_check_sibling, e merkle_check_write_left_node, e merkle_check_write_output_hash, e merkle_check_write_right_node, e note_hash_tree_check_address, e note_hash_tree_check_const_three, e note_hash_tree_check_discard, e note_hash_tree_check_exists, e note_hash_tree_check_first_nullifier, e note_hash_tree_check_first_nullifier_pi_index, e note_hash_tree_check_leaf_index, e note_hash_tree_check_merkle_hash_separator, e note_hash_tree_check_next_leaf_value, e note_hash_tree_check_next_root, e note_hash_tree_check_nonce, e note_hash_tree_check_nonce_separator, e note_hash_tree_check_note_hash, e note_hash_tree_check_note_hash_index, e note_hash_tree_check_note_hash_tree_height, e note_hash_tree_check_prev_leaf_value, e note_hash_tree_check_prev_leaf_value_unique_note_hash_diff_inv, e note_hash_tree_check_prev_root, e note_hash_tree_check_public_inputs_index, e note_hash_tree_check_sel, e note_hash_tree_check_sel_silo, e note_hash_tree_check_sel_unique, e note_hash_tree_check_sel_write_to_public_inputs, e note_hash_tree_check_siloed_note_hash, e note_hash_tree_check_siloing_separator, e note_hash_tree_check_unique_note_hash, e note_hash_tree_check_unique_note_hash_separator, e note_hash_tree_check_write, e poseidon2_hash_b_0, e poseidon2_hash_b_1, e poseidon2_hash_b_2, e poseidon2_hash_b_3, e poseidon2_hash_end, e poseidon2_hash_input_len, e poseidon2_hash_num_perm_rounds_rem_min_one_inv, e poseidon2_hash_padding, e poseidon2_perm_B_10_0, e poseidon2_perm_B_10_1, e poseidon2_perm_B_10_2, e poseidon2_perm_B_10_3, e poseidon2_perm_B_11_0, e poseidon2_perm_B_11_1, e poseidon2_perm_B_11_2, e poseidon2_perm_B_11_3, e poseidon2_perm_B_12_0, e poseidon2_perm_B_12_1, e poseidon2_perm_B_12_2, e poseidon2_perm_B_12_3, e poseidon2_perm_B_13_0, e poseidon2_perm_B_13_1, e poseidon2_perm_B_13_2, e poseidon2_perm_B_13_3, e poseidon2_perm_B_14_0, e poseidon2_perm_B_14_1, e poseidon2_perm_B_14_2, e poseidon2_perm_B_14_3, e poseidon2_perm_B_15_0, e poseidon2_perm_B_15_1, e poseidon2_perm_B_15_2, e poseidon2_perm_B_15_3, e poseidon2_perm_B_16_0, e poseidon2_perm_B_16_1, e poseidon2_perm_B_16_2, e poseidon2_perm_B_16_3, e poseidon2_perm_B_17_0, e poseidon2_perm_B_17_1, e poseidon2_perm_B_17_2, e poseidon2_perm_B_17_3, e poseidon2_perm_B_18_0, e poseidon2_perm_B_18_1, e poseidon2_perm_B_18_2, e poseidon2_perm_B_18_3, e poseidon2_perm_B_19_0, e poseidon2_perm_B_19_1, e poseidon2_perm_B_19_2, e poseidon2_perm_B_19_3, e poseidon2_perm_B_20_0, e poseidon2_perm_B_20_1, e poseidon2_perm_B_20_2, e poseidon2_perm_B_20_3, e poseidon2_perm_B_21_0, e poseidon2_perm_B_21_1, e poseidon2_perm_B_21_2, e poseidon2_perm_B_21_3, e poseidon2_perm_B_22_0, e poseidon2_perm_B_22_1, e poseidon2_perm_B_22_2, e poseidon2_perm_B_22_3, e poseidon2_perm_B_23_0, e poseidon2_perm_B_23_1, e poseidon2_perm_B_23_2, e poseidon2_perm_B_23_3, e poseidon2_perm_B_24_0, e poseidon2_perm_B_24_1, e poseidon2_perm_B_24_2, e poseidon2_perm_B_24_3, e poseidon2_perm_B_25_0, e poseidon2_perm_B_25_1, e poseidon2_perm_B_25_2, e poseidon2_perm_B_25_3, e poseidon2_perm_B_26_0, e poseidon2_perm_B_26_1, e poseidon2_perm_B_26_2, e poseidon2_perm_B_26_3, e poseidon2_perm_B_27_0, e poseidon2_perm_B_27_1, e poseidon2_perm_B_27_2, e poseidon2_perm_B_27_3, e poseidon2_perm_B_28_0, e poseidon2_perm_B_28_1, e poseidon2_perm_B_28_2, e poseidon2_perm_B_28_3, e poseidon2_perm_B_29_0, e poseidon2_perm_B_29_1, e poseidon2_perm_B_29_2, e poseidon2_perm_B_29_3, e poseidon2_perm_B_30_0, e poseidon2_perm_B_30_1, e poseidon2_perm_B_30_2, e poseidon2_perm_B_30_3, e poseidon2_perm_B_31_0, e poseidon2_perm_B_31_1, e poseidon2_perm_B_31_2, e poseidon2_perm_B_31_3, e poseidon2_perm_B_32_0, e poseidon2_perm_B_32_1, e poseidon2_perm_B_32_2, e poseidon2_perm_B_32_3, e poseidon2_perm_B_33_0, e poseidon2_perm_B_33_1, e poseidon2_perm_B_33_2, e poseidon2_perm_B_33_3, e poseidon2_perm_B_34_0, e poseidon2_perm_B_34_1, e poseidon2_perm_B_34_2, e poseidon2_perm_B_34_3, e poseidon2_perm_B_35_0, e poseidon2_perm_B_35_1, e poseidon2_perm_B_35_2, e poseidon2_perm_B_35_3, e poseidon2_perm_B_36_0, e poseidon2_perm_B_36_1, e poseidon2_perm_B_36_2, e poseidon2_perm_B_36_3, e poseidon2_perm_B_37_0, e poseidon2_perm_B_37_1, e poseidon2_perm_B_37_2, e poseidon2_perm_B_37_3, e poseidon2_perm_B_38_0, e poseidon2_perm_B_38_1, e poseidon2_perm_B_38_2, e poseidon2_perm_B_38_3, e poseidon2_perm_B_39_0, e poseidon2_perm_B_39_1, e poseidon2_perm_B_39_2, e poseidon2_perm_B_39_3, e poseidon2_perm_B_40_0, e poseidon2_perm_B_40_1, e poseidon2_perm_B_40_2, e poseidon2_perm_B_40_3, e poseidon2_perm_B_41_0, e poseidon2_perm_B_41_1, e poseidon2_perm_B_41_2, e poseidon2_perm_B_41_3, e poseidon2_perm_B_42_0, e poseidon2_perm_B_42_1, e poseidon2_perm_B_42_2, e poseidon2_perm_B_42_3, e poseidon2_perm_B_43_0, e poseidon2_perm_B_43_1, e poseidon2_perm_B_43_2, e poseidon2_perm_B_43_3, e poseidon2_perm_B_44_0, e poseidon2_perm_B_44_1, e poseidon2_perm_B_44_2, e poseidon2_perm_B_44_3, e poseidon2_perm_B_45_0, e poseidon2_perm_B_45_1, e poseidon2_perm_B_45_2, e poseidon2_perm_B_45_3, e poseidon2_perm_B_46_0, e poseidon2_perm_B_46_1, e poseidon2_perm_B_46_2, e poseidon2_perm_B_46_3, e poseidon2_perm_B_47_0, e poseidon2_perm_B_47_1, e poseidon2_perm_B_47_2, e poseidon2_perm_B_47_3, e poseidon2_perm_B_48_0, e poseidon2_perm_B_48_1, e poseidon2_perm_B_48_2, e poseidon2_perm_B_48_3, e poseidon2_perm_B_49_0, e poseidon2_perm_B_49_1, e poseidon2_perm_B_49_2, e poseidon2_perm_B_49_3, e poseidon2_perm_B_4_0, e poseidon2_perm_B_4_1, e poseidon2_perm_B_4_2, e poseidon2_perm_B_4_3, e poseidon2_perm_B_50_0, e poseidon2_perm_B_50_1, e poseidon2_perm_B_50_2, e poseidon2_perm_B_50_3, e poseidon2_perm_B_51_0, e poseidon2_perm_B_51_1, e poseidon2_perm_B_51_2, e poseidon2_perm_B_51_3, e poseidon2_perm_B_52_0, e poseidon2_perm_B_52_1, e poseidon2_perm_B_52_2, e poseidon2_perm_B_52_3, e poseidon2_perm_B_53_0, e poseidon2_perm_B_53_1, e poseidon2_perm_B_53_2, e poseidon2_perm_B_53_3, e poseidon2_perm_B_54_0, e poseidon2_perm_B_54_1, e poseidon2_perm_B_54_2, e poseidon2_perm_B_54_3, e poseidon2_perm_B_55_0, e poseidon2_perm_B_55_1, e poseidon2_perm_B_55_2, e poseidon2_perm_B_55_3, e poseidon2_perm_B_56_0, e poseidon2_perm_B_56_1, e poseidon2_perm_B_56_2, e poseidon2_perm_B_56_3, e poseidon2_perm_B_57_0, e poseidon2_perm_B_57_1, e poseidon2_perm_B_57_2, e poseidon2_perm_B_57_3, e poseidon2_perm_B_58_0, e poseidon2_perm_B_58_1, e poseidon2_perm_B_58_2, e poseidon2_perm_B_58_3, e poseidon2_perm_B_59_0, e poseidon2_perm_B_59_1, e poseidon2_perm_B_59_2, e poseidon2_perm_B_59_3, e poseidon2_perm_B_5_0, e poseidon2_perm_B_5_1, e poseidon2_perm_B_5_2, e poseidon2_perm_B_5_3, e poseidon2_perm_B_6_0, e poseidon2_perm_B_6_1, e poseidon2_perm_B_6_2, e poseidon2_perm_B_6_3, e poseidon2_perm_B_7_0, e poseidon2_perm_B_7_1, e poseidon2_perm_B_7_2, e poseidon2_perm_B_7_3, e poseidon2_perm_B_8_0, e poseidon2_perm_B_8_1, e poseidon2_perm_B_8_2, e poseidon2_perm_B_8_3, e poseidon2_perm_B_9_0, e poseidon2_perm_B_9_1, e poseidon2_perm_B_9_2, e poseidon2_perm_B_9_3, e poseidon2_perm_EXT_LAYER_4, e poseidon2_perm_EXT_LAYER_5, e poseidon2_perm_EXT_LAYER_6, e poseidon2_perm_EXT_LAYER_7, e poseidon2_perm_T_0_4, e poseidon2_perm_T_0_5, e poseidon2_perm_T_0_6, e poseidon2_perm_T_0_7, e poseidon2_perm_T_1_4, e poseidon2_perm_T_1_5, e poseidon2_perm_T_1_6, e poseidon2_perm_T_1_7, e poseidon2_perm_T_2_4, e poseidon2_perm_T_2_5, e poseidon2_perm_T_2_6, e poseidon2_perm_T_2_7, e poseidon2_perm_T_3_4, e poseidon2_perm_T_3_5, e poseidon2_perm_T_3_6, e poseidon2_perm_T_3_7, e poseidon2_perm_T_60_4, e poseidon2_perm_T_60_5, e poseidon2_perm_T_60_6, e poseidon2_perm_T_60_7, e poseidon2_perm_T_61_4, e poseidon2_perm_T_61_5, e poseidon2_perm_T_61_6, e poseidon2_perm_T_61_7, e poseidon2_perm_T_62_4, e poseidon2_perm_T_62_5, e poseidon2_perm_T_62_6, e poseidon2_perm_T_62_7, e poseidon2_perm_T_63_4, e poseidon2_perm_T_63_5, e poseidon2_perm_T_63_6, e poseidon2_perm_T_63_7, e poseidon2_perm_a_0, e poseidon2_perm_a_1, e poseidon2_perm_a_2, e poseidon2_perm_a_3, e poseidon2_perm_b_0, e poseidon2_perm_b_1, e poseidon2_perm_b_2, e poseidon2_perm_b_3, e poseidon2_perm_mem_batch_tag_inv, e poseidon2_perm_mem_err, e poseidon2_perm_mem_execution_clk, e poseidon2_perm_mem_input_0_, e poseidon2_perm_mem_input_1_, e poseidon2_perm_mem_input_2_, e poseidon2_perm_mem_input_3_, e poseidon2_perm_mem_input_tag_0_, e poseidon2_perm_mem_input_tag_1_, e poseidon2_perm_mem_input_tag_2_, e poseidon2_perm_mem_input_tag_3_, e poseidon2_perm_mem_max_mem_addr, e poseidon2_perm_mem_output_0_, e poseidon2_perm_mem_output_1_, e poseidon2_perm_mem_output_2_, e poseidon2_perm_mem_output_3_, e poseidon2_perm_mem_read_address_0_, e poseidon2_perm_mem_read_address_1_, e poseidon2_perm_mem_read_address_2_, e poseidon2_perm_mem_read_address_3_, e poseidon2_perm_mem_sel, e poseidon2_perm_mem_sel_dst_out_of_range_err, e poseidon2_perm_mem_sel_invalid_tag_err, e poseidon2_perm_mem_sel_should_exec, e poseidon2_perm_mem_sel_should_read_mem, e poseidon2_perm_mem_sel_src_out_of_range_err, e poseidon2_perm_mem_space_id, e poseidon2_perm_mem_write_address_0_, e poseidon2_perm_mem_write_address_1_, e poseidon2_perm_mem_write_address_2_, e poseidon2_perm_mem_write_address_3_, e poseidon2_perm_sel, e public_data_check_address, e public_data_check_clk_diff_hi, e public_data_check_clk_diff_lo, e public_data_check_const_four, e public_data_check_const_three, e public_data_check_discard, e public_data_check_end, e public_data_check_final_value, e public_data_check_intermediate_root, e public_data_check_leaf_not_exists, e public_data_check_leaf_slot, e public_data_check_leaf_slot_low_leaf_slot_diff_inv, e public_data_check_length_pi_idx, e public_data_check_low_leaf_hash, e public_data_check_low_leaf_index, e public_data_check_low_leaf_next_index, e public_data_check_low_leaf_next_slot, e public_data_check_low_leaf_slot, e public_data_check_low_leaf_value, e public_data_check_merkle_hash_separator, e public_data_check_new_leaf_hash, e public_data_check_next_slot_inv, e public_data_check_next_slot_is_nonzero, e public_data_check_non_discarded_write, e public_data_check_non_protocol_write, e public_data_check_not_end, e public_data_check_protocol_write, e public_data_check_public_data_writes_length, e public_data_check_root, e public_data_check_sel_write_to_public_inputs, e public_data_check_should_insert, e public_data_check_siloing_separator, e public_data_check_slot, e public_data_check_tree_height, e public_data_check_tree_size_after_write, e public_data_check_tree_size_before_write, e public_data_check_updated_low_leaf_hash, e public_data_check_updated_low_leaf_next_index, e public_data_check_updated_low_leaf_next_slot, e public_data_check_updated_low_leaf_value, e public_data_check_value, e public_data_check_write, e public_data_check_write_root, e public_data_squash_check_clock, e public_data_squash_clk_diff_hi, e public_data_squash_clk_diff_lo, e public_data_squash_leaf_slot_increase, e public_data_squash_value, e range_check_dyn_diff, e range_check_dyn_rng_chk_bits, e range_check_dyn_rng_chk_pow_2, e range_check_is_lte_u112, e range_check_is_lte_u128, e range_check_is_lte_u16, e range_check_is_lte_u32, e range_check_is_lte_u48, e range_check_is_lte_u64, e range_check_is_lte_u80, e range_check_is_lte_u96, e range_check_rng_chk_bits, e range_check_sel, e range_check_sel_alu, e range_check_sel_gt, e range_check_sel_keccak, e range_check_sel_memory, e range_check_sel_r0_16_bit_rng_lookup, e range_check_sel_r1_16_bit_rng_lookup, e range_check_sel_r2_16_bit_rng_lookup, e range_check_sel_r3_16_bit_rng_lookup, e range_check_sel_r4_16_bit_rng_lookup, e range_check_sel_r5_16_bit_rng_lookup, e range_check_sel_r6_16_bit_rng_lookup, e range_check_u16_r0, e range_check_u16_r1, e range_check_u16_r2, e range_check_u16_r3, e range_check_u16_r4, e range_check_u16_r5, e range_check_u16_r6, e range_check_u16_r7, e range_check_value, e scalar_mul_bit, e scalar_mul_const_two, e scalar_mul_end, e scalar_mul_sel_not_end, e scalar_mul_should_add, e sha256_a_and_b, e sha256_a_and_b_xor_a_and_c, e sha256_a_and_c, e sha256_a_rotr_13, e sha256_a_rotr_2, e sha256_a_rotr_22, e sha256_a_rotr_2_xor_a_rotr_13, e sha256_and_op_id, e sha256_b_and_c, e sha256_batch_tag_inv, e sha256_ch, e sha256_computed_w_lhs, e sha256_computed_w_rhs, e sha256_e_and_f, e sha256_e_rotr_11, e sha256_e_rotr_25, e sha256_e_rotr_6, e sha256_e_rotr_6_xor_e_rotr_11, e sha256_end, e sha256_err, e sha256_input, e sha256_input_rounds_rem_inv, e sha256_input_tag, e sha256_input_tag_diff_inv, e sha256_last, e sha256_lhs_w_10, e sha256_lhs_w_3, e sha256_maj, e sha256_max_input_addr, e sha256_max_mem_addr, e sha256_max_output_addr, e sha256_max_state_addr, e sha256_mem_out_of_range_err, e sha256_memory_address_0_, e sha256_memory_address_1_, e sha256_memory_address_2_, e sha256_memory_address_3_, e sha256_memory_address_4_, e sha256_memory_address_5_, e sha256_memory_address_6_, e sha256_memory_address_7_, e sha256_memory_register_0_, e sha256_memory_register_1_, e sha256_memory_register_2_, e sha256_memory_register_3_, e sha256_memory_register_4_, e sha256_memory_register_5_, e sha256_memory_register_6_, e sha256_memory_register_7_, e sha256_memory_tag_0_, e sha256_memory_tag_1_, e sha256_memory_tag_2_, e sha256_memory_tag_3_, e sha256_memory_tag_4_, e sha256_memory_tag_5_, e sha256_memory_tag_6_, e sha256_memory_tag_7_, e sha256_next_a_lhs, e sha256_next_a_rhs, e sha256_next_e_lhs, e sha256_next_e_rhs, e sha256_not_e, e sha256_not_e_and_g, e sha256_output_a_lhs, e sha256_output_a_rhs, e sha256_output_b_lhs, e sha256_output_b_rhs, e sha256_output_c_lhs, e sha256_output_c_rhs, e sha256_output_d_lhs, e sha256_output_d_rhs, e sha256_output_e_lhs, e sha256_output_e_rhs, e sha256_output_f_lhs, e sha256_output_f_rhs, e sha256_output_g_lhs, e sha256_output_g_rhs, e sha256_output_h_lhs, e sha256_output_h_rhs, e sha256_perform_round, e sha256_rhs_a_13, e sha256_rhs_a_2, e sha256_rhs_a_22, e sha256_rhs_e_11, e sha256_rhs_e_25, e sha256_rhs_e_6, e sha256_rhs_w_10, e sha256_rhs_w_17, e sha256_rhs_w_18, e sha256_rhs_w_19, e sha256_rhs_w_3, e sha256_rhs_w_7, e sha256_round_constant, e sha256_round_count, e sha256_rounds_remaining_inv, e sha256_rw, e sha256_s_0, e sha256_s_1, e sha256_sel_compute_w, e sha256_sel_input_out_of_range_err, e sha256_sel_invalid_input_row_tag_err, e sha256_sel_invalid_state_tag_err, e sha256_sel_is_input_round, e sha256_sel_mem_state_or_output, e sha256_sel_output_out_of_range_err, e sha256_sel_read_input_from_memory, e sha256_sel_state_out_of_range_err, e sha256_state_addr, e sha256_two_pow_10, e sha256_two_pow_11, e sha256_two_pow_13, e sha256_two_pow_17, e sha256_two_pow_18, e sha256_two_pow_19, e sha256_two_pow_2, e sha256_two_pow_22, e sha256_two_pow_25, e sha256_two_pow_3, e sha256_two_pow_32, e sha256_two_pow_6, e sha256_two_pow_7, e sha256_u32_tag, e sha256_w, e sha256_w_15_rotr_18, e sha256_w_15_rotr_7, e sha256_w_15_rotr_7_xor_w_15_rotr_18, e sha256_w_2_rotr_17, e sha256_w_2_rotr_17_xor_w_2_rotr_19, e sha256_w_2_rotr_19, e sha256_w_s_0, e sha256_w_s_1, e sha256_xor_op_id, e to_radix_end, e to_radix_found, e to_radix_is_unsafe_limb, e to_radix_limb_p_diff, e to_radix_limb_radix_diff, e to_radix_mem_err, e to_radix_mem_input_validation_error, e to_radix_mem_last, e to_radix_mem_limb_index_to_lookup, e to_radix_mem_limb_value, e to_radix_mem_max_mem_size, e to_radix_mem_num_limbs_inv, e to_radix_mem_num_limbs_minus_one_inv, e to_radix_mem_output_tag, e to_radix_mem_radix_min_two_inv, e to_radix_mem_sel_dst_out_of_range_err, e to_radix_mem_sel_invalid_bitwise_radix, e to_radix_mem_sel_num_limbs_is_zero, e to_radix_mem_sel_radix_eq_2, e to_radix_mem_sel_radix_gt_256_err, e to_radix_mem_sel_radix_lt_2_err, e to_radix_mem_sel_value_is_zero, e to_radix_mem_two, e to_radix_mem_two_five_six, e to_radix_mem_value_found, e to_radix_mem_value_inv, e to_radix_mem_write_addr_upper_bound, e to_radix_p_limb, e to_radix_rem_inverse, e to_radix_safety_diff_inverse, e tx_array_length_l2_to_l1_messages_pi_offset, e tx_array_length_note_hashes_pi_offset, e tx_array_length_nullifiers_pi_offset, e tx_calldata_hash, e tx_calldata_size, e tx_const_three, e tx_contract_addr, e tx_dom_sep_public_storage_map_slot, e tx_effective_fee_per_da_gas, e tx_effective_fee_per_l2_gas, e tx_end_phase, e tx_fee_juice_balance_slot, e tx_fee_juice_balances_slot_constant, e tx_fee_juice_contract_address, e tx_fee_payer, e tx_fee_payer_balance, e tx_fee_payer_new_balance, e tx_fee_payer_pi_offset, e tx_fields_length_public_logs_pi_offset, e tx_gas_limit_pi_offset, e tx_gas_used_pi_offset, e tx_is_cleanup, e tx_is_collect_fee, e tx_is_padded, e tx_is_public_call_request, e tx_is_static, e tx_is_tree_insert_phase, e tx_is_tree_padding, e tx_l1_l2_pi_offset, e tx_l2_l1_msg_content, e tx_l2_l1_msg_contract_address, e tx_l2_l1_msg_recipient, e tx_leaf_value, e tx_msg_sender, e tx_next_da_gas_used, e tx_next_da_gas_used_sent_to_enqueued_call, e tx_next_l2_gas_used, e tx_next_l2_gas_used_sent_to_enqueued_call, e tx_next_note_hash_tree_root, e tx_next_note_hash_tree_size, e tx_next_nullifier_tree_root, e tx_next_nullifier_tree_size, e tx_next_num_l2_to_l1_messages, e tx_next_num_note_hashes_emitted, e tx_next_num_nullifiers_emitted, e tx_next_num_public_log_fields, e tx_next_phase_on_revert, e tx_next_public_data_tree_root, e tx_next_public_data_tree_size, e tx_next_retrieved_bytecodes_tree_root, e tx_next_retrieved_bytecodes_tree_size, e tx_next_written_public_data_slots_tree_root, e tx_next_written_public_data_slots_tree_size, e tx_note_hash_pi_offset, e tx_nullifier_limit_error, e tx_nullifier_merkle_separator, e tx_nullifier_pi_offset, e tx_nullifier_tree_height, e tx_prev_da_gas_used_sent_to_enqueued_call, e tx_prev_l2_gas_used_sent_to_enqueued_call, e tx_public_data_pi_offset, e tx_read_pi_length_offset, e tx_read_pi_start_offset, e tx_remaining_phase_inv, e tx_remaining_phase_minus_one_inv, e tx_remaining_side_effects_inv, e tx_reverted_pi_offset, e tx_sel_non_revertible_append_l2_l1_msg, e tx_sel_non_revertible_append_note_hash, e tx_sel_non_revertible_append_nullifier, e tx_sel_read_phase_length, e tx_sel_read_trees_and_gas_used, e tx_sel_revertible_append_l2_l1_msg, e tx_sel_revertible_append_note_hash, e tx_sel_revertible_append_nullifier, e tx_setup_phase_value, e tx_should_l2_l1_msg_append, e tx_should_note_hash_append, e tx_should_nullifier_append, e tx_should_process_call_request, e tx_should_read_gas_limit, e tx_should_try_l2_l1_msg_append, e tx_should_try_note_hash_append, e tx_should_try_nullifier_append, e tx_uint32_max, e tx_write_nullifier_pi_offset, e tx_write_pi_offset, e update_check_address, e update_check_const_three, e update_check_contract_instance_registry_address, e update_check_current_class_id, e update_check_delayed_public_mutable_hash_slot, e update_check_delayed_public_mutable_slot, e update_check_dom_sep_public_storage_map_slot, e update_check_hash_not_zero, e update_check_original_class_id, e update_check_public_data_tree_root, e update_check_sel, e update_check_timestamp, e update_check_timestamp_is_lt_timestamp_of_change, e update_check_timestamp_of_change, e update_check_timestamp_of_change_bit_size, e update_check_timestamp_pi_offset, e update_check_update_hash, e update_check_update_hash_inv, e update_check_update_hi_metadata, e update_check_update_hi_metadata_bit_size, e update_check_update_post_class_id_is_zero, e update_check_update_post_class_inv, e update_check_update_pre_class_id_is_zero, e update_check_update_pre_class_inv, e update_check_update_preimage_metadata, e update_check_update_preimage_post_class_id, e update_check_update_preimage_pre_class_id, e update_check_updated_class_ids_slot, e lookup_range_check_dyn_rng_chk_pow_2_counts, e lookup_range_check_dyn_diff_is_u16_counts, e lookup_range_check_r0_is_u16_counts, e lookup_range_check_r1_is_u16_counts, e lookup_range_check_r2_is_u16_counts, e lookup_range_check_r3_is_u16_counts, e lookup_range_check_r4_is_u16_counts, e lookup_range_check_r5_is_u16_counts, e lookup_range_check_r6_is_u16_counts, e lookup_range_check_r7_is_u16_counts, e lookup_ff_gt_a_lo_range_counts, e lookup_ff_gt_a_hi_range_counts, e lookup_gt_gt_range_counts, e lookup_alu_tag_max_bits_value_counts, e lookup_alu_range_check_decomposition_a_lo_counts, e lookup_alu_range_check_decomposition_a_hi_counts, e lookup_alu_range_check_decomposition_b_lo_counts, e lookup_alu_range_check_decomposition_b_hi_counts, e lookup_alu_range_check_mul_c_hi_counts, e lookup_alu_range_check_div_remainder_counts, e lookup_alu_ff_gt_counts, e lookup_alu_int_gt_counts, e lookup_alu_shifts_two_pow_counts, e lookup_alu_large_trunc_canonical_dec_counts, e lookup_alu_range_check_trunc_mid_counts, e lookup_bitwise_integral_tag_length_counts, e lookup_bitwise_byte_operations_counts, e lookup_memory_range_check_limb_0_counts, e lookup_memory_range_check_limb_1_counts, e lookup_memory_range_check_limb_2_counts, e lookup_memory_tag_max_bits_counts, e lookup_memory_range_check_write_tagged_value_counts, e lookup_keccakf1600_theta_xor_01_counts, e lookup_keccakf1600_theta_xor_02_counts, e lookup_keccakf1600_theta_xor_03_counts, e lookup_keccakf1600_theta_xor_row_0_counts, e lookup_keccakf1600_theta_xor_11_counts, e lookup_keccakf1600_theta_xor_12_counts, e lookup_keccakf1600_theta_xor_13_counts, e lookup_keccakf1600_theta_xor_row_1_counts, e lookup_keccakf1600_theta_xor_21_counts, e lookup_keccakf1600_theta_xor_22_counts, e lookup_keccakf1600_theta_xor_23_counts, e lookup_keccakf1600_theta_xor_row_2_counts, e lookup_keccakf1600_theta_xor_31_counts, e lookup_keccakf1600_theta_xor_32_counts, e lookup_keccakf1600_theta_xor_33_counts, e lookup_keccakf1600_theta_xor_row_3_counts, e lookup_keccakf1600_theta_xor_41_counts, e lookup_keccakf1600_theta_xor_42_counts, e lookup_keccakf1600_theta_xor_43_counts, e lookup_keccakf1600_theta_xor_row_4_counts, e lookup_keccakf1600_theta_combined_xor_0_counts, e lookup_keccakf1600_theta_combined_xor_1_counts, e lookup_keccakf1600_theta_combined_xor_2_counts, e lookup_keccakf1600_theta_combined_xor_3_counts, e lookup_keccakf1600_theta_combined_xor_4_counts, e lookup_keccakf1600_state_theta_00_counts, e lookup_keccakf1600_state_theta_01_counts, e lookup_keccakf1600_state_theta_02_counts, e lookup_keccakf1600_state_theta_03_counts, e lookup_keccakf1600_state_theta_04_counts, e lookup_keccakf1600_state_theta_10_counts, e lookup_keccakf1600_state_theta_11_counts, e lookup_keccakf1600_state_theta_12_counts, e lookup_keccakf1600_state_theta_13_counts, e lookup_keccakf1600_state_theta_14_counts, e lookup_keccakf1600_state_theta_20_counts, e lookup_keccakf1600_state_theta_21_counts, e lookup_keccakf1600_state_theta_22_counts, e lookup_keccakf1600_state_theta_23_counts, e lookup_keccakf1600_state_theta_24_counts, e lookup_keccakf1600_state_theta_30_counts, e lookup_keccakf1600_state_theta_31_counts, e lookup_keccakf1600_state_theta_32_counts, e lookup_keccakf1600_state_theta_33_counts, e lookup_keccakf1600_state_theta_34_counts, e lookup_keccakf1600_state_theta_40_counts, e lookup_keccakf1600_state_theta_41_counts, e lookup_keccakf1600_state_theta_42_counts, e lookup_keccakf1600_state_theta_43_counts, e lookup_keccakf1600_state_theta_44_counts, e lookup_keccakf1600_theta_limb_02_range_counts, e lookup_keccakf1600_theta_limb_04_range_counts, e lookup_keccakf1600_theta_limb_10_range_counts, e lookup_keccakf1600_theta_limb_12_range_counts, e lookup_keccakf1600_theta_limb_14_range_counts, e lookup_keccakf1600_theta_limb_21_range_counts, e lookup_keccakf1600_theta_limb_23_range_counts, e lookup_keccakf1600_theta_limb_30_range_counts, e lookup_keccakf1600_theta_limb_32_range_counts, e lookup_keccakf1600_theta_limb_33_range_counts, e lookup_keccakf1600_theta_limb_40_range_counts, e lookup_keccakf1600_theta_limb_41_range_counts, e lookup_keccakf1600_theta_limb_43_range_counts, e lookup_keccakf1600_theta_limb_44_range_counts, e lookup_keccakf1600_theta_limb_01_range_counts, e lookup_keccakf1600_theta_limb_03_range_counts, e lookup_keccakf1600_theta_limb_11_range_counts, e lookup_keccakf1600_theta_limb_13_range_counts, e lookup_keccakf1600_theta_limb_20_range_counts, e lookup_keccakf1600_theta_limb_22_range_counts, e lookup_keccakf1600_theta_limb_24_range_counts, e lookup_keccakf1600_theta_limb_31_range_counts, e lookup_keccakf1600_theta_limb_34_range_counts, e lookup_keccakf1600_theta_limb_42_range_counts, e lookup_keccakf1600_state_pi_and_00_counts, e lookup_keccakf1600_state_pi_and_01_counts, e lookup_keccakf1600_state_pi_and_02_counts, e lookup_keccakf1600_state_pi_and_03_counts, e lookup_keccakf1600_state_pi_and_04_counts, e lookup_keccakf1600_state_pi_and_10_counts, e lookup_keccakf1600_state_pi_and_11_counts, e lookup_keccakf1600_state_pi_and_12_counts, e lookup_keccakf1600_state_pi_and_13_counts, e lookup_keccakf1600_state_pi_and_14_counts, e lookup_keccakf1600_state_pi_and_20_counts, e lookup_keccakf1600_state_pi_and_21_counts, e lookup_keccakf1600_state_pi_and_22_counts, e lookup_keccakf1600_state_pi_and_23_counts, e lookup_keccakf1600_state_pi_and_24_counts, e lookup_keccakf1600_state_pi_and_30_counts, e lookup_keccakf1600_state_pi_and_31_counts, e lookup_keccakf1600_state_pi_and_32_counts, e lookup_keccakf1600_state_pi_and_33_counts, e lookup_keccakf1600_state_pi_and_34_counts, e lookup_keccakf1600_state_pi_and_40_counts, e lookup_keccakf1600_state_pi_and_41_counts, e lookup_keccakf1600_state_pi_and_42_counts, e lookup_keccakf1600_state_pi_and_43_counts, e lookup_keccakf1600_state_pi_and_44_counts, e lookup_keccakf1600_state_chi_00_counts, e lookup_keccakf1600_state_chi_01_counts, e lookup_keccakf1600_state_chi_02_counts, e lookup_keccakf1600_state_chi_03_counts, e lookup_keccakf1600_state_chi_04_counts, e lookup_keccakf1600_state_chi_10_counts, e lookup_keccakf1600_state_chi_11_counts, e lookup_keccakf1600_state_chi_12_counts, e lookup_keccakf1600_state_chi_13_counts, e lookup_keccakf1600_state_chi_14_counts, e lookup_keccakf1600_state_chi_20_counts, e lookup_keccakf1600_state_chi_21_counts, e lookup_keccakf1600_state_chi_22_counts, e lookup_keccakf1600_state_chi_23_counts, e lookup_keccakf1600_state_chi_24_counts, e lookup_keccakf1600_state_chi_30_counts, e lookup_keccakf1600_state_chi_31_counts, e lookup_keccakf1600_state_chi_32_counts, e lookup_keccakf1600_state_chi_33_counts, e lookup_keccakf1600_state_chi_34_counts, e lookup_keccakf1600_state_chi_40_counts, e lookup_keccakf1600_state_chi_41_counts, e lookup_keccakf1600_state_chi_42_counts, e lookup_keccakf1600_state_chi_43_counts, e lookup_keccakf1600_state_chi_44_counts, e lookup_keccakf1600_round_cst_counts, e lookup_keccakf1600_state_iota_00_counts, e lookup_keccakf1600_src_out_of_range_toggle_counts, e lookup_keccakf1600_dst_out_of_range_toggle_counts, e lookup_sha256_range_comp_w_lhs_counts, e lookup_sha256_range_comp_w_rhs_counts, e lookup_sha256_range_rhs_w_7_counts, e lookup_sha256_range_rhs_w_18_counts, e lookup_sha256_range_rhs_w_3_counts, e lookup_sha256_w_s_0_xor_0_counts, e lookup_sha256_w_s_0_xor_1_counts, e lookup_sha256_range_rhs_w_17_counts, e lookup_sha256_range_rhs_w_19_counts, e lookup_sha256_range_rhs_w_10_counts, e lookup_sha256_w_s_1_xor_0_counts, e lookup_sha256_w_s_1_xor_1_counts, e lookup_sha256_range_rhs_e_6_counts, e lookup_sha256_range_rhs_e_11_counts, e lookup_sha256_range_rhs_e_25_counts, e lookup_sha256_s_1_xor_0_counts, e lookup_sha256_s_1_xor_1_counts, e lookup_sha256_ch_and_0_counts, e lookup_sha256_ch_and_1_counts, e lookup_sha256_ch_xor_counts, e lookup_sha256_round_constant_counts, e lookup_sha256_range_rhs_a_2_counts, e lookup_sha256_range_rhs_a_13_counts, e lookup_sha256_range_rhs_a_22_counts, e lookup_sha256_s_0_xor_0_counts, e lookup_sha256_s_0_xor_1_counts, e lookup_sha256_maj_and_0_counts, e lookup_sha256_maj_and_1_counts, e lookup_sha256_maj_and_2_counts, e lookup_sha256_maj_xor_0_counts, e lookup_sha256_maj_xor_1_counts, e lookup_sha256_range_comp_next_a_lhs_counts, e lookup_sha256_range_comp_next_a_rhs_counts, e lookup_sha256_range_comp_next_e_lhs_counts, e lookup_sha256_range_comp_next_e_rhs_counts, e lookup_sha256_range_comp_a_rhs_counts, e lookup_sha256_range_comp_b_rhs_counts, e lookup_sha256_range_comp_c_rhs_counts, e lookup_sha256_range_comp_d_rhs_counts, e lookup_sha256_range_comp_e_rhs_counts, e lookup_sha256_range_comp_f_rhs_counts, e lookup_sha256_range_comp_g_rhs_counts, e lookup_sha256_range_comp_h_rhs_counts, e lookup_sha256_mem_check_state_addr_in_range_counts, e lookup_sha256_mem_check_input_addr_in_range_counts, e lookup_sha256_mem_check_output_addr_in_range_counts, e lookup_ecc_mem_check_dst_addr_in_range_counts, e lookup_ecc_mem_input_output_ecc_add_counts, e lookup_poseidon2_mem_check_src_addr_in_range_counts, e lookup_poseidon2_mem_check_dst_addr_in_range_counts, e lookup_poseidon2_mem_input_output_poseidon2_perm_counts, e lookup_to_radix_limb_range_counts, e lookup_to_radix_limb_less_than_radix_range_counts, e lookup_to_radix_fetch_safe_limbs_counts, e lookup_to_radix_fetch_p_limb_counts, e lookup_to_radix_limb_p_diff_range_counts, e lookup_scalar_mul_to_radix_counts, e lookup_scalar_mul_double_counts, e lookup_scalar_mul_add_counts, e lookup_to_radix_mem_check_dst_addr_in_range_counts, e lookup_to_radix_mem_check_radix_lt_2_counts, e lookup_to_radix_mem_check_radix_gt_256_counts, e lookup_to_radix_mem_input_output_to_radix_counts, e lookup_internal_call_unwind_call_stack_counts, e lookup_context_ctx_stack_rollback_counts, e lookup_context_ctx_stack_return_counts, e lookup_data_copy_offset_plus_size_is_gt_data_size_counts, e lookup_data_copy_check_src_addr_in_range_counts, e lookup_data_copy_check_dst_addr_in_range_counts, e lookup_data_copy_sel_has_reads_counts, e lookup_data_copy_col_read_counts, e lookup_addressing_relative_overflow_result_0_counts, e lookup_addressing_relative_overflow_result_1_counts, e lookup_addressing_relative_overflow_result_2_counts, e lookup_addressing_relative_overflow_result_3_counts, e lookup_addressing_relative_overflow_result_4_counts, e lookup_addressing_relative_overflow_result_5_counts, e lookup_addressing_relative_overflow_result_6_counts, e lookup_gas_addressing_gas_read_counts, e lookup_gas_is_out_of_gas_l2_counts, e lookup_gas_is_out_of_gas_da_counts, e lookup_poseidon2_hash_poseidon2_perm_counts, e lookup_merkle_check_merkle_poseidon2_read_counts, e lookup_merkle_check_merkle_poseidon2_write_counts, e lookup_indexed_tree_check_silo_poseidon2_counts, e lookup_indexed_tree_check_low_leaf_value_validation_counts, e lookup_indexed_tree_check_low_leaf_next_value_validation_counts, e lookup_indexed_tree_check_low_leaf_poseidon2_counts, e lookup_indexed_tree_check_updated_low_leaf_poseidon2_counts, e lookup_indexed_tree_check_low_leaf_merkle_check_counts, e lookup_indexed_tree_check_new_leaf_poseidon2_counts, e lookup_indexed_tree_check_new_leaf_merkle_check_counts, e lookup_indexed_tree_check_write_value_to_public_inputs_counts, e lookup_public_data_squash_leaf_slot_increase_ff_gt_counts, e lookup_public_data_squash_clk_diff_range_lo_counts, e lookup_public_data_squash_clk_diff_range_hi_counts, e lookup_public_data_check_clk_diff_range_lo_counts, e lookup_public_data_check_clk_diff_range_hi_counts, e lookup_public_data_check_silo_poseidon2_counts, e lookup_public_data_check_low_leaf_slot_validation_counts, e lookup_public_data_check_low_leaf_next_slot_validation_counts, e lookup_public_data_check_low_leaf_poseidon2_0_counts, e lookup_public_data_check_low_leaf_poseidon2_1_counts, e lookup_public_data_check_updated_low_leaf_poseidon2_0_counts, e lookup_public_data_check_updated_low_leaf_poseidon2_1_counts, e lookup_public_data_check_low_leaf_merkle_check_counts, e lookup_public_data_check_new_leaf_poseidon2_0_counts, e lookup_public_data_check_new_leaf_poseidon2_1_counts, e lookup_public_data_check_new_leaf_merkle_check_counts, e lookup_public_data_check_write_public_data_to_public_inputs_counts, e lookup_public_data_check_write_writes_length_to_public_inputs_counts, e lookup_l1_to_l2_message_tree_check_merkle_check_counts, e lookup_address_derivation_salted_initialization_hash_poseidon2_0_counts, e lookup_address_derivation_salted_initialization_hash_poseidon2_1_counts, e lookup_address_derivation_partial_address_poseidon2_counts, e lookup_address_derivation_public_keys_hash_poseidon2_0_counts, e lookup_address_derivation_public_keys_hash_poseidon2_1_counts, e lookup_address_derivation_public_keys_hash_poseidon2_2_counts, e lookup_address_derivation_public_keys_hash_poseidon2_3_counts, e lookup_address_derivation_public_keys_hash_poseidon2_4_counts, e lookup_address_derivation_preaddress_poseidon2_counts, e lookup_address_derivation_preaddress_scalar_mul_counts, e lookup_address_derivation_address_ecadd_counts, e lookup_bc_decomposition_bytes_are_bytes_counts, e lookup_bc_hashing_poseidon2_hash_counts, e lookup_update_check_timestamp_from_public_inputs_counts, e lookup_update_check_delayed_public_mutable_slot_poseidon2_counts, e lookup_update_check_update_hash_public_data_read_counts, e lookup_update_check_update_hash_poseidon2_counts, e lookup_update_check_update_hi_metadata_range_counts, e lookup_update_check_update_lo_metadata_range_counts, e lookup_update_check_timestamp_is_lt_timestamp_of_change_counts, e lookup_contract_instance_retrieval_check_protocol_address_range_counts, e lookup_contract_instance_retrieval_read_derived_address_from_public_inputs_counts, e lookup_contract_instance_retrieval_deployment_nullifier_read_counts, e lookup_contract_instance_retrieval_address_derivation_counts, e lookup_contract_instance_retrieval_update_check_counts, e lookup_class_id_derivation_class_id_poseidon2_0_counts, e lookup_class_id_derivation_class_id_poseidon2_1_counts, e lookup_bc_retrieval_contract_instance_retrieval_counts, e lookup_bc_retrieval_class_id_derivation_counts, e lookup_bc_retrieval_is_new_class_check_counts, e lookup_bc_retrieval_retrieved_bytecodes_insertion_counts, e lookup_instr_fetching_pc_abs_diff_positive_counts, e lookup_instr_fetching_instr_abs_diff_positive_counts, e lookup_instr_fetching_tag_value_validation_counts, e lookup_instr_fetching_bytecode_size_from_bc_dec_counts, e lookup_instr_fetching_bytes_from_bc_dec_counts, e lookup_instr_fetching_wire_instruction_info_counts, e lookup_get_env_var_precomputed_info_counts, e lookup_get_env_var_read_from_public_inputs_col0_counts, e lookup_get_env_var_read_from_public_inputs_col1_counts, e lookup_get_contract_instance_precomputed_info_counts, e lookup_get_contract_instance_contract_instance_retrieval_counts, e lookup_external_call_is_l2_gas_left_gt_allocated_counts, e lookup_external_call_is_da_gas_left_gt_allocated_counts, e lookup_sload_storage_read_counts, e lookup_sstore_record_written_storage_slot_counts, e lookup_note_hash_tree_check_silo_poseidon2_counts, e lookup_note_hash_tree_check_read_first_nullifier_counts, e lookup_note_hash_tree_check_nonce_computation_poseidon2_counts, e lookup_note_hash_tree_check_unique_note_hash_poseidon2_counts, e lookup_note_hash_tree_check_merkle_check_counts, e lookup_note_hash_tree_check_write_note_hash_to_public_inputs_counts, e lookup_notehash_exists_note_hash_leaf_index_in_range_counts, e lookup_notehash_exists_note_hash_read_counts, e lookup_emit_notehash_notehash_tree_write_counts, e lookup_l1_to_l2_message_exists_l1_to_l2_msg_leaf_index_in_range_counts, e lookup_l1_to_l2_message_exists_l1_to_l2_msg_read_counts, e lookup_nullifier_exists_nullifier_exists_check_counts, e lookup_emit_nullifier_write_nullifier_counts, e lookup_emit_public_log_check_memory_out_of_bounds_counts, e lookup_emit_public_log_check_log_fields_count_counts, e lookup_emit_public_log_write_data_to_public_inputs_counts, e lookup_send_l2_to_l1_msg_recipient_check_counts, e lookup_send_l2_to_l1_msg_write_l2_to_l1_msg_counts, e lookup_execution_bytecode_retrieval_result_counts, e lookup_execution_instruction_fetching_result_counts, e lookup_execution_instruction_fetching_body_counts, e lookup_execution_exec_spec_read_counts, e lookup_execution_dyn_l2_factor_bitwise_counts, e lookup_execution_check_radix_gt_256_counts, e lookup_execution_get_p_limbs_counts, e lookup_execution_get_max_limbs_counts, e lookup_execution_check_written_storage_slot_counts, e lookup_execution_dispatch_to_alu_counts, e lookup_execution_dispatch_to_bitwise_counts, e lookup_execution_dispatch_to_cast_counts, e lookup_execution_dispatch_to_set_counts, e lookup_calldata_hashing_get_calldata_field_0_counts, e lookup_calldata_hashing_get_calldata_field_1_counts, e lookup_calldata_hashing_get_calldata_field_2_counts, e lookup_calldata_hashing_poseidon2_hash_counts, e lookup_tx_context_public_inputs_note_hash_tree_counts, e lookup_tx_context_public_inputs_nullifier_tree_counts, e lookup_tx_context_public_inputs_public_data_tree_counts, e lookup_tx_context_public_inputs_l1_l2_tree_counts, e lookup_tx_context_public_inputs_gas_used_counts, e lookup_tx_context_public_inputs_read_gas_limit_counts, e lookup_tx_context_public_inputs_read_reverted_counts, e lookup_tx_context_restore_state_on_revert_counts, e lookup_tx_context_public_inputs_write_note_hash_count_counts, e lookup_tx_context_public_inputs_write_nullifier_count_counts, e lookup_tx_context_public_inputs_write_l2_to_l1_message_count_counts, e lookup_tx_context_public_inputs_write_public_log_count_counts, e lookup_tx_read_phase_spec_counts, e lookup_tx_read_phase_length_counts, e lookup_tx_read_public_call_request_phase_counts, e lookup_tx_read_tree_insert_value_counts, e lookup_tx_note_hash_append_counts, e lookup_tx_nullifier_append_counts, e lookup_tx_read_l2_l1_msg_counts, e lookup_tx_write_l2_l1_msg_counts, e lookup_tx_read_effective_fee_public_inputs_counts, e lookup_tx_read_fee_payer_public_inputs_counts, e lookup_tx_balance_slot_poseidon2_counts, e lookup_tx_balance_read_counts, e lookup_tx_balance_validation_counts, e lookup_tx_write_fee_public_inputs_counts, e bc_decomposition_bytes, e bc_decomposition_bytes_pc_plus_1, e bc_decomposition_bytes_pc_plus_10, e bc_decomposition_bytes_pc_plus_11, e bc_decomposition_bytes_pc_plus_12, e bc_decomposition_bytes_pc_plus_13, e bc_decomposition_bytes_pc_plus_14, e bc_decomposition_bytes_pc_plus_15, e bc_decomposition_bytes_pc_plus_16, e bc_decomposition_bytes_pc_plus_17, e bc_decomposition_bytes_pc_plus_18, e bc_decomposition_bytes_pc_plus_19, e bc_decomposition_bytes_pc_plus_2, e bc_decomposition_bytes_pc_plus_20, e bc_decomposition_bytes_pc_plus_21, e bc_decomposition_bytes_pc_plus_22, e bc_decomposition_bytes_pc_plus_23, e bc_decomposition_bytes_pc_plus_24, e bc_decomposition_bytes_pc_plus_25, e bc_decomposition_bytes_pc_plus_26, e bc_decomposition_bytes_pc_plus_27, e bc_decomposition_bytes_pc_plus_28, e bc_decomposition_bytes_pc_plus_29, e bc_decomposition_bytes_pc_plus_3, e bc_decomposition_bytes_pc_plus_30, e bc_decomposition_bytes_pc_plus_31, e bc_decomposition_bytes_pc_plus_32, e bc_decomposition_bytes_pc_plus_33, e bc_decomposition_bytes_pc_plus_34, e bc_decomposition_bytes_pc_plus_35, e bc_decomposition_bytes_pc_plus_4, e bc_decomposition_bytes_pc_plus_5, e bc_decomposition_bytes_pc_plus_6, e bc_decomposition_bytes_pc_plus_7, e bc_decomposition_bytes_pc_plus_8, e bc_decomposition_bytes_pc_plus_9, e bc_decomposition_bytes_remaining, e bc_decomposition_id, e bc_decomposition_next_packed_pc, e bc_decomposition_pc, e bc_decomposition_sel, e bc_decomposition_sel_windows_gt_remaining, e bc_decomposition_start, e bc_hashing_bytecode_id, e bc_hashing_padding, e bc_hashing_pc_index_1, e bc_hashing_rounds_rem, e bc_hashing_sel, e bc_hashing_sel_not_start, e bc_hashing_start, e bitwise_acc_ia, e bitwise_acc_ib, e bitwise_acc_ic, e bitwise_ctr, e bitwise_op_id, e bitwise_sel, e bitwise_start, e calldata_context_id, e calldata_hashing_calldata_size, e calldata_hashing_context_id, e calldata_hashing_index_0_, e calldata_hashing_output_hash, e calldata_hashing_rounds_rem, e calldata_hashing_sel, e calldata_hashing_start, e calldata_index, e calldata_sel, e data_copy_clk, e data_copy_copy_size, e data_copy_dst_addr, e data_copy_dst_context_id, e data_copy_padding, e data_copy_read_addr, e data_copy_reads_left, e data_copy_sel, e data_copy_sel_cd_copy, e data_copy_src_context_id, e data_copy_start, e emit_public_log_contract_address, e emit_public_log_correct_tag, e emit_public_log_error_out_of_bounds, e emit_public_log_error_tag_mismatch, e emit_public_log_execution_clk, e emit_public_log_is_write_contract_address, e emit_public_log_is_write_memory_value, e emit_public_log_log_address, e emit_public_log_public_inputs_index, e emit_public_log_remaining_rows, e emit_public_log_seen_wrong_tag, e emit_public_log_sel, e emit_public_log_sel_write_to_public_inputs, e emit_public_log_space_id, e emit_public_log_start, e execution_bytecode_id, e execution_clk, e execution_context_id, e execution_contract_address, e execution_da_gas_limit, e execution_discard, e execution_dying_context_id, e execution_enqueued_call_start, e execution_internal_call_id, e execution_internal_call_return_id, e execution_is_static, e execution_l1_l2_tree_root, e execution_l2_gas_limit, e execution_last_child_id, e execution_last_child_returndata_addr, e execution_last_child_returndata_size, e execution_last_child_success, e execution_msg_sender, e execution_next_context_id, e execution_next_internal_call_id, e execution_parent_calldata_addr, e execution_parent_calldata_size, e execution_parent_da_gas_limit, e execution_parent_da_gas_used, e execution_parent_id, e execution_parent_l2_gas_limit, e execution_parent_l2_gas_used, e execution_pc, e execution_prev_da_gas_used, e execution_prev_l2_gas_used, e execution_prev_note_hash_tree_root, e execution_prev_note_hash_tree_size, e execution_prev_nullifier_tree_root, e execution_prev_nullifier_tree_size, e execution_prev_num_l2_to_l1_messages, e execution_prev_num_note_hashes_emitted, e execution_prev_num_nullifiers_emitted, e execution_prev_num_public_log_fields, e execution_prev_public_data_tree_root, e execution_prev_public_data_tree_size, e execution_prev_retrieved_bytecodes_tree_root, e execution_prev_retrieved_bytecodes_tree_size, e execution_prev_written_public_data_slots_tree_root, e execution_prev_written_public_data_slots_tree_size, e execution_sel, e execution_sel_first_row_in_context, e execution_transaction_fee, e ff_gt_a_hi, e ff_gt_a_lo, e ff_gt_b_hi, e ff_gt_b_lo, e ff_gt_cmp_rng_ctr, e ff_gt_p_sub_a_hi, e ff_gt_p_sub_a_lo, e ff_gt_p_sub_b_hi, e ff_gt_p_sub_b_lo, e ff_gt_sel, e ff_gt_sel_dec, e ff_gt_sel_gt, e keccak_memory_addr, e keccak_memory_clk, e keccak_memory_ctr, e keccak_memory_rw, e keccak_memory_sel, e keccak_memory_space_id, e keccak_memory_start_read, e keccak_memory_start_write, e keccak_memory_tag_error, e keccak_memory_val_0_, e keccak_memory_val_10_, e keccak_memory_val_11_, e keccak_memory_val_12_, e keccak_memory_val_13_, e keccak_memory_val_14_, e keccak_memory_val_15_, e keccak_memory_val_16_, e keccak_memory_val_17_, e keccak_memory_val_18_, e keccak_memory_val_19_, e keccak_memory_val_1_, e keccak_memory_val_20_, e keccak_memory_val_21_, e keccak_memory_val_22_, e keccak_memory_val_23_, e keccak_memory_val_2_, e keccak_memory_val_3_, e keccak_memory_val_4_, e keccak_memory_val_5_, e keccak_memory_val_6_, e keccak_memory_val_7_, e keccak_memory_val_8_, e keccak_memory_val_9_, e keccakf1600_clk, e keccakf1600_dst_addr, e keccakf1600_round, e keccakf1600_sel, e keccakf1600_sel_no_error, e keccakf1600_space_id, e keccakf1600_start, e keccakf1600_state_in_00, e keccakf1600_state_in_01, e keccakf1600_state_in_02, e keccakf1600_state_in_03, e keccakf1600_state_in_04, e keccakf1600_state_in_10, e keccakf1600_state_in_11, e keccakf1600_state_in_12, e keccakf1600_state_in_13, e keccakf1600_state_in_14, e keccakf1600_state_in_20, e keccakf1600_state_in_21, e keccakf1600_state_in_22, e keccakf1600_state_in_23, e keccakf1600_state_in_24, e keccakf1600_state_in_30, e keccakf1600_state_in_31, e keccakf1600_state_in_32, e keccakf1600_state_in_33, e keccakf1600_state_in_34, e keccakf1600_state_in_40, e keccakf1600_state_in_41, e keccakf1600_state_in_42, e keccakf1600_state_in_43, e keccakf1600_state_in_44, e memory_address, e memory_clk, e memory_rw, e memory_sel, e memory_space_id, e memory_tag, e memory_value, e merkle_check_index, e merkle_check_merkle_hash_separator, e merkle_check_path_len, e merkle_check_read_node, e merkle_check_read_root, e merkle_check_sel, e merkle_check_start, e merkle_check_write, e merkle_check_write_node, e merkle_check_write_root, e poseidon2_hash_a_0, e poseidon2_hash_a_1, e poseidon2_hash_a_2, e poseidon2_hash_a_3, e poseidon2_hash_input_0, e poseidon2_hash_input_1, e poseidon2_hash_input_2, e poseidon2_hash_num_perm_rounds_rem, e poseidon2_hash_output, e poseidon2_hash_sel, e poseidon2_hash_start, e public_data_check_clk, e public_data_check_sel, e public_data_check_write_idx, e public_data_squash_clk, e public_data_squash_final_value, e public_data_squash_leaf_slot, e public_data_squash_sel, e public_data_squash_write_to_public_inputs, e scalar_mul_bit_idx, e scalar_mul_point_inf, e scalar_mul_point_x, e scalar_mul_point_y, e scalar_mul_res_inf, e scalar_mul_res_x, e scalar_mul_res_y, e scalar_mul_scalar, e scalar_mul_sel, e scalar_mul_start, e scalar_mul_temp_inf, e scalar_mul_temp_x, e scalar_mul_temp_y, e sha256_a, e sha256_b, e sha256_c, e sha256_d, e sha256_e, e sha256_execution_clk, e sha256_f, e sha256_g, e sha256_h, e sha256_helper_w0, e sha256_helper_w1, e sha256_helper_w10, e sha256_helper_w11, e sha256_helper_w12, e sha256_helper_w13, e sha256_helper_w14, e sha256_helper_w15, e sha256_helper_w2, e sha256_helper_w3, e sha256_helper_w4, e sha256_helper_w5, e sha256_helper_w6, e sha256_helper_w7, e sha256_helper_w8, e sha256_helper_w9, e sha256_init_a, e sha256_init_b, e sha256_init_c, e sha256_init_d, e sha256_init_e, e sha256_init_f, e sha256_init_g, e sha256_init_h, e sha256_input_addr, e sha256_input_rounds_rem, e sha256_output_addr, e sha256_rounds_remaining, e sha256_sel, e sha256_sel_invalid_input_tag_err, e sha256_space_id, e sha256_start, e to_radix_acc, e to_radix_acc_under_p, e to_radix_limb, e to_radix_limb_eq_p, e to_radix_limb_index, e to_radix_limb_lt_p, e to_radix_mem_dst_addr, e to_radix_mem_execution_clk, e to_radix_mem_is_output_bits, e to_radix_mem_num_limbs, e to_radix_mem_radix, e to_radix_mem_sel, e to_radix_mem_sel_should_decompose, e to_radix_mem_sel_should_write_mem, e to_radix_mem_space_id, e to_radix_mem_start, e to_radix_mem_value_to_decompose, e to_radix_not_padding_limb, e to_radix_power, e to_radix_radix, e to_radix_safe_limbs, e to_radix_sel, e to_radix_start, e to_radix_value, e tx_da_gas_limit, e tx_discard, e tx_fee, e tx_is_revertible, e tx_is_teardown, e tx_l1_l2_tree_root, e tx_l1_l2_tree_size, e tx_l2_gas_limit, e tx_next_context_id, e tx_phase_value, e tx_prev_da_gas_used, e tx_prev_l2_gas_used, e tx_prev_note_hash_tree_root, e tx_prev_note_hash_tree_size, e tx_prev_nullifier_tree_root, e tx_prev_nullifier_tree_size, e tx_prev_num_l2_to_l1_messages, e tx_prev_num_note_hashes_emitted, e tx_prev_num_nullifiers_emitted, e tx_prev_num_public_log_fields, e tx_prev_public_data_tree_root, e tx_prev_public_data_tree_size, e tx_prev_retrieved_bytecodes_tree_root, e tx_prev_retrieved_bytecodes_tree_size, e tx_prev_written_public_data_slots_tree_root, e tx_prev_written_public_data_slots_tree_size, e tx_read_pi_offset, e tx_remaining_phase_counter, e tx_reverted, e tx_sel, e tx_start_phase, e tx_start_tx, e tx_tx_reverted -#define AVM2_DERIVED_WITNESS_ENTITIES_E(e) e perm_keccak_memory_slice_to_mem_inv, e perm_keccakf1600_read_to_slice_inv, e perm_keccakf1600_write_to_slice_inv, e perm_sha256_mem_mem_op_0_inv, e perm_sha256_mem_mem_op_1_inv, e perm_sha256_mem_mem_op_2_inv, e perm_sha256_mem_mem_op_3_inv, e perm_sha256_mem_mem_op_4_inv, e perm_sha256_mem_mem_op_5_inv, e perm_sha256_mem_mem_op_6_inv, e perm_sha256_mem_mem_op_7_inv, e perm_sha256_mem_mem_input_read_inv, e perm_ecc_mem_write_mem_0_inv, e perm_ecc_mem_write_mem_1_inv, e perm_ecc_mem_write_mem_2_inv, e perm_poseidon2_mem_pos_read_mem_0_inv, e perm_poseidon2_mem_pos_read_mem_1_inv, e perm_poseidon2_mem_pos_read_mem_2_inv, e perm_poseidon2_mem_pos_read_mem_3_inv, e perm_poseidon2_mem_pos_write_mem_0_inv, e perm_poseidon2_mem_pos_write_mem_1_inv, e perm_poseidon2_mem_pos_write_mem_2_inv, e perm_poseidon2_mem_pos_write_mem_3_inv, e perm_to_radix_mem_write_mem_inv, e perm_internal_call_push_call_stack_inv, e perm_context_ctx_stack_call_inv, e perm_data_copy_mem_write_inv, e perm_data_copy_mem_read_inv, e perm_addressing_base_address_from_memory_inv, e perm_addressing_indirect_from_memory_0_inv, e perm_addressing_indirect_from_memory_1_inv, e perm_addressing_indirect_from_memory_2_inv, e perm_addressing_indirect_from_memory_3_inv, e perm_addressing_indirect_from_memory_4_inv, e perm_addressing_indirect_from_memory_5_inv, e perm_addressing_indirect_from_memory_6_inv, e perm_registers_mem_op_0_inv, e perm_registers_mem_op_1_inv, e perm_registers_mem_op_2_inv, e perm_registers_mem_op_3_inv, e perm_registers_mem_op_4_inv, e perm_registers_mem_op_5_inv, e perm_public_data_check_squashing_inv, e perm_bc_hashing_bytecode_length_bytes_inv, e perm_bc_hashing_get_packed_field_0_inv, e perm_bc_hashing_get_packed_field_1_inv, e perm_bc_hashing_get_packed_field_2_inv, e perm_get_contract_instance_mem_write_contract_instance_exists_inv, e perm_get_contract_instance_mem_write_contract_instance_member_inv, e perm_sstore_storage_write_inv, e perm_emit_public_log_read_mem_inv, e perm_execution_dispatch_to_cd_copy_inv, e perm_execution_dispatch_to_rd_copy_inv, e perm_execution_dispatch_to_get_contract_instance_inv, e perm_execution_dispatch_to_emit_public_log_inv, e perm_execution_dispatch_to_poseidon2_perm_inv, e perm_execution_dispatch_to_sha256_compression_inv, e perm_execution_dispatch_to_keccakf1600_inv, e perm_execution_dispatch_to_ecc_add_inv, e perm_execution_dispatch_to_to_radix_inv, e perm_calldata_hashing_check_final_size_inv, e perm_tx_read_calldata_hash_inv, e perm_tx_dispatch_exec_start_inv, e perm_tx_dispatch_exec_end_inv, e perm_tx_balance_update_inv, e lookup_range_check_dyn_rng_chk_pow_2_inv, e lookup_range_check_dyn_diff_is_u16_inv, e lookup_range_check_r0_is_u16_inv, e lookup_range_check_r1_is_u16_inv, e lookup_range_check_r2_is_u16_inv, e lookup_range_check_r3_is_u16_inv, e lookup_range_check_r4_is_u16_inv, e lookup_range_check_r5_is_u16_inv, e lookup_range_check_r6_is_u16_inv, e lookup_range_check_r7_is_u16_inv, e lookup_ff_gt_a_lo_range_inv, e lookup_ff_gt_a_hi_range_inv, e lookup_gt_gt_range_inv, e lookup_alu_tag_max_bits_value_inv, e lookup_alu_range_check_decomposition_a_lo_inv, e lookup_alu_range_check_decomposition_a_hi_inv, e lookup_alu_range_check_decomposition_b_lo_inv, e lookup_alu_range_check_decomposition_b_hi_inv, e lookup_alu_range_check_mul_c_hi_inv, e lookup_alu_range_check_div_remainder_inv, e lookup_alu_ff_gt_inv, e lookup_alu_int_gt_inv, e lookup_alu_shifts_two_pow_inv, e lookup_alu_large_trunc_canonical_dec_inv, e lookup_alu_range_check_trunc_mid_inv, e lookup_bitwise_integral_tag_length_inv, e lookup_bitwise_byte_operations_inv, e lookup_memory_range_check_limb_0_inv, e lookup_memory_range_check_limb_1_inv, e lookup_memory_range_check_limb_2_inv, e lookup_memory_tag_max_bits_inv, e lookup_memory_range_check_write_tagged_value_inv, e lookup_keccakf1600_theta_xor_01_inv, e lookup_keccakf1600_theta_xor_02_inv, e lookup_keccakf1600_theta_xor_03_inv, e lookup_keccakf1600_theta_xor_row_0_inv, e lookup_keccakf1600_theta_xor_11_inv, e lookup_keccakf1600_theta_xor_12_inv, e lookup_keccakf1600_theta_xor_13_inv, e lookup_keccakf1600_theta_xor_row_1_inv, e lookup_keccakf1600_theta_xor_21_inv, e lookup_keccakf1600_theta_xor_22_inv, e lookup_keccakf1600_theta_xor_23_inv, e lookup_keccakf1600_theta_xor_row_2_inv, e lookup_keccakf1600_theta_xor_31_inv, e lookup_keccakf1600_theta_xor_32_inv, e lookup_keccakf1600_theta_xor_33_inv, e lookup_keccakf1600_theta_xor_row_3_inv, e lookup_keccakf1600_theta_xor_41_inv, e lookup_keccakf1600_theta_xor_42_inv, e lookup_keccakf1600_theta_xor_43_inv, e lookup_keccakf1600_theta_xor_row_4_inv, e lookup_keccakf1600_theta_combined_xor_0_inv, e lookup_keccakf1600_theta_combined_xor_1_inv, e lookup_keccakf1600_theta_combined_xor_2_inv, e lookup_keccakf1600_theta_combined_xor_3_inv, e lookup_keccakf1600_theta_combined_xor_4_inv, e lookup_keccakf1600_state_theta_00_inv, e lookup_keccakf1600_state_theta_01_inv, e lookup_keccakf1600_state_theta_02_inv, e lookup_keccakf1600_state_theta_03_inv, e lookup_keccakf1600_state_theta_04_inv, e lookup_keccakf1600_state_theta_10_inv, e lookup_keccakf1600_state_theta_11_inv, e lookup_keccakf1600_state_theta_12_inv, e lookup_keccakf1600_state_theta_13_inv, e lookup_keccakf1600_state_theta_14_inv, e lookup_keccakf1600_state_theta_20_inv, e lookup_keccakf1600_state_theta_21_inv, e lookup_keccakf1600_state_theta_22_inv, e lookup_keccakf1600_state_theta_23_inv, e lookup_keccakf1600_state_theta_24_inv, e lookup_keccakf1600_state_theta_30_inv, e lookup_keccakf1600_state_theta_31_inv, e lookup_keccakf1600_state_theta_32_inv, e lookup_keccakf1600_state_theta_33_inv, e lookup_keccakf1600_state_theta_34_inv, e lookup_keccakf1600_state_theta_40_inv, e lookup_keccakf1600_state_theta_41_inv, e lookup_keccakf1600_state_theta_42_inv, e lookup_keccakf1600_state_theta_43_inv, e lookup_keccakf1600_state_theta_44_inv, e lookup_keccakf1600_theta_limb_02_range_inv, e lookup_keccakf1600_theta_limb_04_range_inv, e lookup_keccakf1600_theta_limb_10_range_inv, e lookup_keccakf1600_theta_limb_12_range_inv, e lookup_keccakf1600_theta_limb_14_range_inv, e lookup_keccakf1600_theta_limb_21_range_inv, e lookup_keccakf1600_theta_limb_23_range_inv, e lookup_keccakf1600_theta_limb_30_range_inv, e lookup_keccakf1600_theta_limb_32_range_inv, e lookup_keccakf1600_theta_limb_33_range_inv, e lookup_keccakf1600_theta_limb_40_range_inv, e lookup_keccakf1600_theta_limb_41_range_inv, e lookup_keccakf1600_theta_limb_43_range_inv, e lookup_keccakf1600_theta_limb_44_range_inv, e lookup_keccakf1600_theta_limb_01_range_inv, e lookup_keccakf1600_theta_limb_03_range_inv, e lookup_keccakf1600_theta_limb_11_range_inv, e lookup_keccakf1600_theta_limb_13_range_inv, e lookup_keccakf1600_theta_limb_20_range_inv, e lookup_keccakf1600_theta_limb_22_range_inv, e lookup_keccakf1600_theta_limb_24_range_inv, e lookup_keccakf1600_theta_limb_31_range_inv, e lookup_keccakf1600_theta_limb_34_range_inv, e lookup_keccakf1600_theta_limb_42_range_inv, e lookup_keccakf1600_state_pi_and_00_inv, e lookup_keccakf1600_state_pi_and_01_inv, e lookup_keccakf1600_state_pi_and_02_inv, e lookup_keccakf1600_state_pi_and_03_inv, e lookup_keccakf1600_state_pi_and_04_inv, e lookup_keccakf1600_state_pi_and_10_inv, e lookup_keccakf1600_state_pi_and_11_inv, e lookup_keccakf1600_state_pi_and_12_inv, e lookup_keccakf1600_state_pi_and_13_inv, e lookup_keccakf1600_state_pi_and_14_inv, e lookup_keccakf1600_state_pi_and_20_inv, e lookup_keccakf1600_state_pi_and_21_inv, e lookup_keccakf1600_state_pi_and_22_inv, e lookup_keccakf1600_state_pi_and_23_inv, e lookup_keccakf1600_state_pi_and_24_inv, e lookup_keccakf1600_state_pi_and_30_inv, e lookup_keccakf1600_state_pi_and_31_inv, e lookup_keccakf1600_state_pi_and_32_inv, e lookup_keccakf1600_state_pi_and_33_inv, e lookup_keccakf1600_state_pi_and_34_inv, e lookup_keccakf1600_state_pi_and_40_inv, e lookup_keccakf1600_state_pi_and_41_inv, e lookup_keccakf1600_state_pi_and_42_inv, e lookup_keccakf1600_state_pi_and_43_inv, e lookup_keccakf1600_state_pi_and_44_inv, e lookup_keccakf1600_state_chi_00_inv, e lookup_keccakf1600_state_chi_01_inv, e lookup_keccakf1600_state_chi_02_inv, e lookup_keccakf1600_state_chi_03_inv, e lookup_keccakf1600_state_chi_04_inv, e lookup_keccakf1600_state_chi_10_inv, e lookup_keccakf1600_state_chi_11_inv, e lookup_keccakf1600_state_chi_12_inv, e lookup_keccakf1600_state_chi_13_inv, e lookup_keccakf1600_state_chi_14_inv, e lookup_keccakf1600_state_chi_20_inv, e lookup_keccakf1600_state_chi_21_inv, e lookup_keccakf1600_state_chi_22_inv, e lookup_keccakf1600_state_chi_23_inv, e lookup_keccakf1600_state_chi_24_inv, e lookup_keccakf1600_state_chi_30_inv, e lookup_keccakf1600_state_chi_31_inv, e lookup_keccakf1600_state_chi_32_inv, e lookup_keccakf1600_state_chi_33_inv, e lookup_keccakf1600_state_chi_34_inv, e lookup_keccakf1600_state_chi_40_inv, e lookup_keccakf1600_state_chi_41_inv, e lookup_keccakf1600_state_chi_42_inv, e lookup_keccakf1600_state_chi_43_inv, e lookup_keccakf1600_state_chi_44_inv, e lookup_keccakf1600_round_cst_inv, e lookup_keccakf1600_state_iota_00_inv, e lookup_keccakf1600_src_out_of_range_toggle_inv, e lookup_keccakf1600_dst_out_of_range_toggle_inv, e lookup_sha256_range_comp_w_lhs_inv, e lookup_sha256_range_comp_w_rhs_inv, e lookup_sha256_range_rhs_w_7_inv, e lookup_sha256_range_rhs_w_18_inv, e lookup_sha256_range_rhs_w_3_inv, e lookup_sha256_w_s_0_xor_0_inv, e lookup_sha256_w_s_0_xor_1_inv, e lookup_sha256_range_rhs_w_17_inv, e lookup_sha256_range_rhs_w_19_inv, e lookup_sha256_range_rhs_w_10_inv, e lookup_sha256_w_s_1_xor_0_inv, e lookup_sha256_w_s_1_xor_1_inv, e lookup_sha256_range_rhs_e_6_inv, e lookup_sha256_range_rhs_e_11_inv, e lookup_sha256_range_rhs_e_25_inv, e lookup_sha256_s_1_xor_0_inv, e lookup_sha256_s_1_xor_1_inv, e lookup_sha256_ch_and_0_inv, e lookup_sha256_ch_and_1_inv, e lookup_sha256_ch_xor_inv, e lookup_sha256_round_constant_inv, e lookup_sha256_range_rhs_a_2_inv, e lookup_sha256_range_rhs_a_13_inv, e lookup_sha256_range_rhs_a_22_inv, e lookup_sha256_s_0_xor_0_inv, e lookup_sha256_s_0_xor_1_inv, e lookup_sha256_maj_and_0_inv, e lookup_sha256_maj_and_1_inv, e lookup_sha256_maj_and_2_inv, e lookup_sha256_maj_xor_0_inv, e lookup_sha256_maj_xor_1_inv, e lookup_sha256_range_comp_next_a_lhs_inv, e lookup_sha256_range_comp_next_a_rhs_inv, e lookup_sha256_range_comp_next_e_lhs_inv, e lookup_sha256_range_comp_next_e_rhs_inv, e lookup_sha256_range_comp_a_rhs_inv, e lookup_sha256_range_comp_b_rhs_inv, e lookup_sha256_range_comp_c_rhs_inv, e lookup_sha256_range_comp_d_rhs_inv, e lookup_sha256_range_comp_e_rhs_inv, e lookup_sha256_range_comp_f_rhs_inv, e lookup_sha256_range_comp_g_rhs_inv, e lookup_sha256_range_comp_h_rhs_inv, e lookup_sha256_mem_check_state_addr_in_range_inv, e lookup_sha256_mem_check_input_addr_in_range_inv, e lookup_sha256_mem_check_output_addr_in_range_inv, e lookup_ecc_mem_check_dst_addr_in_range_inv, e lookup_ecc_mem_input_output_ecc_add_inv, e lookup_poseidon2_mem_check_src_addr_in_range_inv, e lookup_poseidon2_mem_check_dst_addr_in_range_inv, e lookup_poseidon2_mem_input_output_poseidon2_perm_inv, e lookup_to_radix_limb_range_inv, e lookup_to_radix_limb_less_than_radix_range_inv, e lookup_to_radix_fetch_safe_limbs_inv, e lookup_to_radix_fetch_p_limb_inv, e lookup_to_radix_limb_p_diff_range_inv, e lookup_scalar_mul_to_radix_inv, e lookup_scalar_mul_double_inv, e lookup_scalar_mul_add_inv, e lookup_to_radix_mem_check_dst_addr_in_range_inv, e lookup_to_radix_mem_check_radix_lt_2_inv, e lookup_to_radix_mem_check_radix_gt_256_inv, e lookup_to_radix_mem_input_output_to_radix_inv, e lookup_internal_call_unwind_call_stack_inv, e lookup_context_ctx_stack_rollback_inv, e lookup_context_ctx_stack_return_inv, e lookup_data_copy_offset_plus_size_is_gt_data_size_inv, e lookup_data_copy_check_src_addr_in_range_inv, e lookup_data_copy_check_dst_addr_in_range_inv, e lookup_data_copy_sel_has_reads_inv, e lookup_data_copy_col_read_inv, e lookup_addressing_relative_overflow_result_0_inv, e lookup_addressing_relative_overflow_result_1_inv, e lookup_addressing_relative_overflow_result_2_inv, e lookup_addressing_relative_overflow_result_3_inv, e lookup_addressing_relative_overflow_result_4_inv, e lookup_addressing_relative_overflow_result_5_inv, e lookup_addressing_relative_overflow_result_6_inv, e lookup_gas_addressing_gas_read_inv, e lookup_gas_is_out_of_gas_l2_inv, e lookup_gas_is_out_of_gas_da_inv, e lookup_poseidon2_hash_poseidon2_perm_inv, e lookup_merkle_check_merkle_poseidon2_read_inv, e lookup_merkle_check_merkle_poseidon2_write_inv, e lookup_indexed_tree_check_silo_poseidon2_inv, e lookup_indexed_tree_check_low_leaf_value_validation_inv, e lookup_indexed_tree_check_low_leaf_next_value_validation_inv, e lookup_indexed_tree_check_low_leaf_poseidon2_inv, e lookup_indexed_tree_check_updated_low_leaf_poseidon2_inv, e lookup_indexed_tree_check_low_leaf_merkle_check_inv, e lookup_indexed_tree_check_new_leaf_poseidon2_inv, e lookup_indexed_tree_check_new_leaf_merkle_check_inv, e lookup_indexed_tree_check_write_value_to_public_inputs_inv, e lookup_public_data_squash_leaf_slot_increase_ff_gt_inv, e lookup_public_data_squash_clk_diff_range_lo_inv, e lookup_public_data_squash_clk_diff_range_hi_inv, e lookup_public_data_check_clk_diff_range_lo_inv, e lookup_public_data_check_clk_diff_range_hi_inv, e lookup_public_data_check_silo_poseidon2_inv, e lookup_public_data_check_low_leaf_slot_validation_inv, e lookup_public_data_check_low_leaf_next_slot_validation_inv, e lookup_public_data_check_low_leaf_poseidon2_0_inv, e lookup_public_data_check_low_leaf_poseidon2_1_inv, e lookup_public_data_check_updated_low_leaf_poseidon2_0_inv, e lookup_public_data_check_updated_low_leaf_poseidon2_1_inv, e lookup_public_data_check_low_leaf_merkle_check_inv, e lookup_public_data_check_new_leaf_poseidon2_0_inv, e lookup_public_data_check_new_leaf_poseidon2_1_inv, e lookup_public_data_check_new_leaf_merkle_check_inv, e lookup_public_data_check_write_public_data_to_public_inputs_inv, e lookup_public_data_check_write_writes_length_to_public_inputs_inv, e lookup_l1_to_l2_message_tree_check_merkle_check_inv, e lookup_address_derivation_salted_initialization_hash_poseidon2_0_inv, e lookup_address_derivation_salted_initialization_hash_poseidon2_1_inv, e lookup_address_derivation_partial_address_poseidon2_inv, e lookup_address_derivation_public_keys_hash_poseidon2_0_inv, e lookup_address_derivation_public_keys_hash_poseidon2_1_inv, e lookup_address_derivation_public_keys_hash_poseidon2_2_inv, e lookup_address_derivation_public_keys_hash_poseidon2_3_inv, e lookup_address_derivation_public_keys_hash_poseidon2_4_inv, e lookup_address_derivation_preaddress_poseidon2_inv, e lookup_address_derivation_preaddress_scalar_mul_inv, e lookup_address_derivation_address_ecadd_inv, e lookup_bc_decomposition_bytes_are_bytes_inv, e lookup_bc_hashing_poseidon2_hash_inv, e lookup_update_check_timestamp_from_public_inputs_inv, e lookup_update_check_delayed_public_mutable_slot_poseidon2_inv, e lookup_update_check_update_hash_public_data_read_inv, e lookup_update_check_update_hash_poseidon2_inv, e lookup_update_check_update_hi_metadata_range_inv, e lookup_update_check_update_lo_metadata_range_inv, e lookup_update_check_timestamp_is_lt_timestamp_of_change_inv, e lookup_contract_instance_retrieval_check_protocol_address_range_inv, e lookup_contract_instance_retrieval_read_derived_address_from_public_inputs_inv, e lookup_contract_instance_retrieval_deployment_nullifier_read_inv, e lookup_contract_instance_retrieval_address_derivation_inv, e lookup_contract_instance_retrieval_update_check_inv, e lookup_class_id_derivation_class_id_poseidon2_0_inv, e lookup_class_id_derivation_class_id_poseidon2_1_inv, e lookup_bc_retrieval_contract_instance_retrieval_inv, e lookup_bc_retrieval_class_id_derivation_inv, e lookup_bc_retrieval_is_new_class_check_inv, e lookup_bc_retrieval_retrieved_bytecodes_insertion_inv, e lookup_instr_fetching_pc_abs_diff_positive_inv, e lookup_instr_fetching_instr_abs_diff_positive_inv, e lookup_instr_fetching_tag_value_validation_inv, e lookup_instr_fetching_bytecode_size_from_bc_dec_inv, e lookup_instr_fetching_bytes_from_bc_dec_inv, e lookup_instr_fetching_wire_instruction_info_inv, e lookup_get_env_var_precomputed_info_inv, e lookup_get_env_var_read_from_public_inputs_col0_inv, e lookup_get_env_var_read_from_public_inputs_col1_inv, e lookup_get_contract_instance_precomputed_info_inv, e lookup_get_contract_instance_contract_instance_retrieval_inv, e lookup_external_call_is_l2_gas_left_gt_allocated_inv, e lookup_external_call_is_da_gas_left_gt_allocated_inv, e lookup_sload_storage_read_inv, e lookup_sstore_record_written_storage_slot_inv, e lookup_note_hash_tree_check_silo_poseidon2_inv, e lookup_note_hash_tree_check_read_first_nullifier_inv, e lookup_note_hash_tree_check_nonce_computation_poseidon2_inv, e lookup_note_hash_tree_check_unique_note_hash_poseidon2_inv, e lookup_note_hash_tree_check_merkle_check_inv, e lookup_note_hash_tree_check_write_note_hash_to_public_inputs_inv, e lookup_notehash_exists_note_hash_leaf_index_in_range_inv, e lookup_notehash_exists_note_hash_read_inv, e lookup_emit_notehash_notehash_tree_write_inv, e lookup_l1_to_l2_message_exists_l1_to_l2_msg_leaf_index_in_range_inv, e lookup_l1_to_l2_message_exists_l1_to_l2_msg_read_inv, e lookup_nullifier_exists_nullifier_exists_check_inv, e lookup_emit_nullifier_write_nullifier_inv, e lookup_emit_public_log_check_memory_out_of_bounds_inv, e lookup_emit_public_log_check_log_fields_count_inv, e lookup_emit_public_log_write_data_to_public_inputs_inv, e lookup_send_l2_to_l1_msg_recipient_check_inv, e lookup_send_l2_to_l1_msg_write_l2_to_l1_msg_inv, e lookup_execution_bytecode_retrieval_result_inv, e lookup_execution_instruction_fetching_result_inv, e lookup_execution_instruction_fetching_body_inv, e lookup_execution_exec_spec_read_inv, e lookup_execution_dyn_l2_factor_bitwise_inv, e lookup_execution_check_radix_gt_256_inv, e lookup_execution_get_p_limbs_inv, e lookup_execution_get_max_limbs_inv, e lookup_execution_check_written_storage_slot_inv, e lookup_execution_dispatch_to_alu_inv, e lookup_execution_dispatch_to_bitwise_inv, e lookup_execution_dispatch_to_cast_inv, e lookup_execution_dispatch_to_set_inv, e lookup_calldata_hashing_get_calldata_field_0_inv, e lookup_calldata_hashing_get_calldata_field_1_inv, e lookup_calldata_hashing_get_calldata_field_2_inv, e lookup_calldata_hashing_poseidon2_hash_inv, e lookup_tx_context_public_inputs_note_hash_tree_inv, e lookup_tx_context_public_inputs_nullifier_tree_inv, e lookup_tx_context_public_inputs_public_data_tree_inv, e lookup_tx_context_public_inputs_l1_l2_tree_inv, e lookup_tx_context_public_inputs_gas_used_inv, e lookup_tx_context_public_inputs_read_gas_limit_inv, e lookup_tx_context_public_inputs_read_reverted_inv, e lookup_tx_context_restore_state_on_revert_inv, e lookup_tx_context_public_inputs_write_note_hash_count_inv, e lookup_tx_context_public_inputs_write_nullifier_count_inv, e lookup_tx_context_public_inputs_write_l2_to_l1_message_count_inv, e lookup_tx_context_public_inputs_write_public_log_count_inv, e lookup_tx_read_phase_spec_inv, e lookup_tx_read_phase_length_inv, e lookup_tx_read_public_call_request_phase_inv, e lookup_tx_read_tree_insert_value_inv, e lookup_tx_note_hash_append_inv, e lookup_tx_nullifier_append_inv, e lookup_tx_read_l2_l1_msg_inv, e lookup_tx_write_l2_l1_msg_inv, e lookup_tx_read_effective_fee_public_inputs_inv, e lookup_tx_read_fee_payer_public_inputs_inv, e lookup_tx_balance_slot_poseidon2_inv, e lookup_tx_balance_read_inv, e lookup_tx_balance_validation_inv, e lookup_tx_write_fee_public_inputs_inv +#define AVM2_WIRE_ENTITIES_E(e) e public_inputs_cols_0_, e public_inputs_cols_1_, e public_inputs_cols_2_, e public_inputs_cols_3_, e address_derivation_address, e address_derivation_address_y, e address_derivation_class_id, e address_derivation_const_four, e address_derivation_const_thirteen, e address_derivation_const_three, e address_derivation_const_two, e address_derivation_deployer_addr, e address_derivation_g1_x, e address_derivation_g1_y, e address_derivation_incoming_viewing_key_x, e address_derivation_incoming_viewing_key_y, e address_derivation_init_hash, e address_derivation_nullifier_key_x, e address_derivation_nullifier_key_y, e address_derivation_outgoing_viewing_key_x, e address_derivation_outgoing_viewing_key_y, e address_derivation_partial_address, e address_derivation_partial_address_domain_separator, e address_derivation_preaddress, e address_derivation_preaddress_domain_separator, e address_derivation_preaddress_public_key_x, e address_derivation_preaddress_public_key_y, e address_derivation_public_keys_hash, e address_derivation_public_keys_hash_domain_separator, e address_derivation_salt, e address_derivation_salted_init_hash, e address_derivation_sel, e address_derivation_tagging_key_x, e address_derivation_tagging_key_y, e alu_a_hi, e alu_a_hi_bits, e alu_a_lo, e alu_a_lo_bits, e alu_ab_diff_inv, e alu_ab_tags_diff_inv, e alu_b_hi, e alu_b_inv, e alu_b_lo, e alu_c_hi, e alu_cf, e alu_constant_64, e alu_gt_input_a, e alu_gt_input_b, e alu_gt_result_c, e alu_helper1, e alu_ia, e alu_ia_tag, e alu_ib, e alu_ib_tag, e alu_ic, e alu_ic_tag, e alu_max_bits, e alu_max_value, e alu_mid, e alu_mid_bits, e alu_op_id, e alu_sel, e alu_sel_ab_tag_mismatch, e alu_sel_decompose_a, e alu_sel_div_0_err, e alu_sel_div_no_err, e alu_sel_err, e alu_sel_ff_gt, e alu_sel_int_gt, e alu_sel_is_ff, e alu_sel_is_u128, e alu_sel_mul_div_u128, e alu_sel_mul_no_err_non_ff, e alu_sel_op_add, e alu_sel_op_div, e alu_sel_op_eq, e alu_sel_op_fdiv, e alu_sel_op_lt, e alu_sel_op_lte, e alu_sel_op_mul, e alu_sel_op_not, e alu_sel_op_shl, e alu_sel_op_shr, e alu_sel_op_sub, e alu_sel_op_truncate, e alu_sel_shift_ops_no_overflow, e alu_sel_tag_err, e alu_sel_trunc_gte_128, e alu_sel_trunc_lt_128, e alu_sel_trunc_non_trivial, e alu_sel_trunc_trivial, e alu_shift_lo_bits, e alu_tag_ff_diff_inv, e alu_tag_u128_diff_inv, e alu_two_pow_shift_lo_bits, e bc_decomposition_bytes_pc_plus_36, e bc_decomposition_bytes_rem_inv, e bc_decomposition_bytes_rem_min_one_inv, e bc_decomposition_bytes_to_read, e bc_decomposition_last_of_contract, e bc_decomposition_next_packed_pc_min_pc_inv, e bc_decomposition_packed_field, e bc_decomposition_sel_packed, e bc_decomposition_sel_packed_read_0_, e bc_decomposition_sel_packed_read_1_, e bc_decomposition_sel_packed_read_2_, e bc_decomposition_sel_windows_eq_remaining, e bc_decomposition_windows_min_remaining_inv, e bc_hashing_end, e bc_hashing_input_len, e bc_hashing_packed_fields_0, e bc_hashing_packed_fields_1, e bc_hashing_packed_fields_2, e bc_hashing_pc_index, e bc_hashing_pc_index_2, e bc_hashing_sel_not_padding_1, e bc_hashing_sel_not_padding_2, e bc_hashing_size_in_bytes, e bc_retrieval_address, e bc_retrieval_artifact_hash, e bc_retrieval_bytecode_id, e bc_retrieval_current_class_id, e bc_retrieval_error, e bc_retrieval_instance_exists, e bc_retrieval_is_new_class, e bc_retrieval_next_retrieved_bytecodes_tree_root, e bc_retrieval_next_retrieved_bytecodes_tree_size, e bc_retrieval_no_remaining_bytecodes, e bc_retrieval_nullifier_tree_root, e bc_retrieval_prev_retrieved_bytecodes_tree_root, e bc_retrieval_prev_retrieved_bytecodes_tree_size, e bc_retrieval_private_functions_root, e bc_retrieval_public_data_tree_root, e bc_retrieval_remaining_bytecodes_inv, e bc_retrieval_retrieved_bytecodes_merkle_separator, e bc_retrieval_retrieved_bytecodes_tree_height, e bc_retrieval_sel, e bc_retrieval_should_retrieve, e bitwise_ctr_min_one_inv, e bitwise_end, e bitwise_err, e bitwise_ia_byte, e bitwise_ib_byte, e bitwise_ic_byte, e bitwise_output_and, e bitwise_output_or, e bitwise_output_xor, e bitwise_sel_and, e bitwise_sel_compute, e bitwise_sel_get_ctr, e bitwise_sel_or, e bitwise_sel_tag_ff_err, e bitwise_sel_tag_mismatch_err, e bitwise_sel_xor, e bitwise_start_keccak, e bitwise_start_sha256, e bitwise_tag_a, e bitwise_tag_a_inv, e bitwise_tag_ab_diff_inv, e bitwise_tag_b, e bitwise_tag_c, e calldata_end, e calldata_hashing_end, e calldata_hashing_index_1_, e calldata_hashing_index_2_, e calldata_hashing_input_0_, e calldata_hashing_input_1_, e calldata_hashing_input_2_, e calldata_hashing_input_len, e calldata_hashing_sel_end_not_empty, e calldata_hashing_sel_not_padding_1, e calldata_hashing_sel_not_padding_2, e calldata_hashing_sel_not_start, e calldata_value, e class_id_derivation_artifact_hash, e class_id_derivation_class_id, e class_id_derivation_const_four, e class_id_derivation_gen_index_contract_class_id, e class_id_derivation_private_functions_root, e class_id_derivation_public_bytecode_commitment, e class_id_derivation_sel, e context_stack_bytecode_id, e context_stack_context_id, e context_stack_contract_address, e context_stack_entered_context_id, e context_stack_internal_call_id, e context_stack_internal_call_return_id, e context_stack_is_static, e context_stack_msg_sender, e context_stack_next_internal_call_id, e context_stack_next_pc, e context_stack_note_hash_tree_root, e context_stack_note_hash_tree_size, e context_stack_nullifier_tree_root, e context_stack_nullifier_tree_size, e context_stack_num_l2_to_l1_messages, e context_stack_num_note_hashes_emitted, e context_stack_num_nullifiers_emitted, e context_stack_num_public_log_fields, e context_stack_parent_calldata_addr, e context_stack_parent_calldata_size, e context_stack_parent_da_gas_limit, e context_stack_parent_da_gas_used, e context_stack_parent_id, e context_stack_parent_l2_gas_limit, e context_stack_parent_l2_gas_used, e context_stack_public_data_tree_root, e context_stack_public_data_tree_size, e context_stack_sel, e context_stack_written_public_data_slots_tree_root, e context_stack_written_public_data_slots_tree_size, e contract_instance_retrieval_address, e contract_instance_retrieval_address_sub_one, e contract_instance_retrieval_current_class_id, e contract_instance_retrieval_deployer_addr, e contract_instance_retrieval_deployer_protocol_contract_address, e contract_instance_retrieval_derived_address, e contract_instance_retrieval_derived_address_pi_index, e contract_instance_retrieval_exists, e contract_instance_retrieval_incoming_viewing_key_x, e contract_instance_retrieval_incoming_viewing_key_y, e contract_instance_retrieval_init_hash, e contract_instance_retrieval_is_protocol_contract, e contract_instance_retrieval_max_protocol_contracts, e contract_instance_retrieval_nullifier_key_x, e contract_instance_retrieval_nullifier_key_y, e contract_instance_retrieval_nullifier_merkle_separator, e contract_instance_retrieval_nullifier_tree_height, e contract_instance_retrieval_nullifier_tree_root, e contract_instance_retrieval_original_class_id, e contract_instance_retrieval_outgoing_viewing_key_x, e contract_instance_retrieval_outgoing_viewing_key_y, e contract_instance_retrieval_protocol_contract_derived_address_inv, e contract_instance_retrieval_public_data_tree_root, e contract_instance_retrieval_salt, e contract_instance_retrieval_sel, e contract_instance_retrieval_should_check_for_update, e contract_instance_retrieval_should_check_nullifier, e contract_instance_retrieval_siloing_separator, e contract_instance_retrieval_tagging_key_x, e contract_instance_retrieval_tagging_key_y, e data_copy_cd_copy_col_read, e data_copy_clamped_read_index_upper_bound, e data_copy_dst_out_of_range_err, e data_copy_end, e data_copy_is_top_level, e data_copy_mem_size, e data_copy_offset, e data_copy_offset_plus_size, e data_copy_offset_plus_size_is_gt, e data_copy_parent_id_inv, e data_copy_read_addr_plus_one, e data_copy_read_addr_upper_bound, e data_copy_reads_left_inv, e data_copy_sel_cd_copy_start, e data_copy_sel_has_reads, e data_copy_sel_mem_read, e data_copy_sel_mem_write, e data_copy_sel_rd_copy_start, e data_copy_sel_write_count_is_zero, e data_copy_src_addr, e data_copy_src_data_size, e data_copy_src_reads_exceed_mem, e data_copy_start_no_err, e data_copy_tag, e data_copy_value, e data_copy_write_addr_upper_bound, e data_copy_write_count_minus_one_inv, e data_copy_write_count_zero_inv, e ecc_add_mem_dst_addr_0_, e ecc_add_mem_dst_addr_1_, e ecc_add_mem_dst_addr_2_, e ecc_add_mem_err, e ecc_add_mem_execution_clk, e ecc_add_mem_max_mem_addr, e ecc_add_mem_p_is_inf, e ecc_add_mem_p_is_on_curve_eqn, e ecc_add_mem_p_is_on_curve_eqn_inv, e ecc_add_mem_p_x, e ecc_add_mem_p_x_n, e ecc_add_mem_p_y, e ecc_add_mem_p_y_n, e ecc_add_mem_q_is_inf, e ecc_add_mem_q_is_on_curve_eqn, e ecc_add_mem_q_is_on_curve_eqn_inv, e ecc_add_mem_q_x, e ecc_add_mem_q_x_n, e ecc_add_mem_q_y, e ecc_add_mem_q_y_n, e ecc_add_mem_res_is_inf, e ecc_add_mem_res_x, e ecc_add_mem_res_y, e ecc_add_mem_sel, e ecc_add_mem_sel_dst_out_of_range_err, e ecc_add_mem_sel_p_not_on_curve_err, e ecc_add_mem_sel_q_not_on_curve_err, e ecc_add_mem_sel_should_exec, e ecc_add_mem_space_id, e ecc_add_op, e ecc_double_op, e ecc_inv_2_p_y, e ecc_inv_x_diff, e ecc_inv_y_diff, e ecc_lambda, e ecc_p_is_inf, e ecc_p_x, e ecc_p_y, e ecc_q_is_inf, e ecc_q_x, e ecc_q_y, e ecc_r_is_inf, e ecc_r_x, e ecc_r_y, e ecc_result_infinity, e ecc_sel, e ecc_use_computed_result, e ecc_x_match, e ecc_y_match, e emit_public_log_discard, e emit_public_log_end, e emit_public_log_end_log_address_upper_bound, e emit_public_log_error, e emit_public_log_error_too_many_log_fields, e emit_public_log_expected_next_log_fields, e emit_public_log_is_static, e emit_public_log_log_size, e emit_public_log_max_mem_size, e emit_public_log_max_public_logs_payload_length, e emit_public_log_next_num_public_log_fields, e emit_public_log_prev_num_public_log_fields, e emit_public_log_public_inputs_value, e emit_public_log_remaining_rows_inv, e emit_public_log_sel_read_memory, e emit_public_log_tag, e emit_public_log_tag_inv, e emit_public_log_value, e execution_addressing_error_collection_inv, e execution_addressing_gas, e execution_addressing_mode, e execution_base_address_tag, e execution_base_address_tag_diff_inv, e execution_base_address_val, e execution_base_da_gas, e execution_batched_tags_diff_inv, e execution_batched_tags_diff_inv_reg, e execution_da_gas_left, e execution_da_gas_used, e execution_dying_context_diff_inv, e execution_dying_context_id_inv, e execution_dyn_gas_id, e execution_dynamic_da_gas, e execution_dynamic_da_gas_factor, e execution_dynamic_l2_gas, e execution_dynamic_l2_gas_factor, e execution_enqueued_call_end, e execution_envvar_pi_row_idx, e execution_exec_opcode, e execution_expected_tag_reg_0_, e execution_expected_tag_reg_1_, e execution_expected_tag_reg_2_, e execution_expected_tag_reg_3_, e execution_expected_tag_reg_4_, e execution_expected_tag_reg_5_, e execution_has_parent_ctx, e execution_highest_address, e execution_instr_size, e execution_internal_call_return_id_inv, e execution_is_address, e execution_is_da_gas_left_gt_allocated, e execution_is_dagasleft, e execution_is_dying_context, e execution_is_isstaticcall, e execution_is_l2_gas_left_gt_allocated, e execution_is_l2gasleft, e execution_is_parent_id_inv, e execution_is_sender, e execution_is_transactionfee, e execution_l1_to_l2_msg_leaf_in_range, e execution_l1_to_l2_msg_tree_leaf_count, e execution_l2_gas_left, e execution_l2_gas_used, e execution_max_data_writes_reached, e execution_max_eth_address_value, e execution_mem_tag_reg_0_, e execution_mem_tag_reg_1_, e execution_mem_tag_reg_2_, e execution_mem_tag_reg_3_, e execution_mem_tag_reg_4_, e execution_mem_tag_reg_5_, e execution_nested_failure, e execution_nested_return, e execution_next_pc, e execution_note_hash_leaf_in_range, e execution_note_hash_tree_leaf_count, e execution_note_hash_tree_root, e execution_note_hash_tree_size, e execution_nullifier_merkle_separator, e execution_nullifier_pi_offset, e execution_nullifier_siloing_separator, e execution_nullifier_tree_height, e execution_nullifier_tree_root, e execution_nullifier_tree_size, e execution_num_l2_to_l1_messages, e execution_num_note_hashes_emitted, e execution_num_nullifiers_emitted, e execution_num_p_limbs, e execution_num_public_log_fields, e execution_num_relative_operands_inv, e execution_op_0_, e execution_op_1_, e execution_op_2_, e execution_op_3_, e execution_op_4_, e execution_op_5_, e execution_op_6_, e execution_op_after_relative_0_, e execution_op_after_relative_1_, e execution_op_after_relative_2_, e execution_op_after_relative_3_, e execution_op_after_relative_4_, e execution_op_after_relative_5_, e execution_op_after_relative_6_, e execution_opcode_gas, e execution_out_of_gas_da, e execution_out_of_gas_l2, e execution_public_data_tree_root, e execution_public_data_tree_size, e execution_public_inputs_index, e execution_register_0_, e execution_register_1_, e execution_register_2_, e execution_register_3_, e execution_register_4_, e execution_register_5_, e execution_remaining_data_writes_inv, e execution_remaining_l2_to_l1_msgs_inv, e execution_remaining_note_hashes_inv, e execution_remaining_nullifiers_inv, e execution_retrieved_bytecodes_tree_root, e execution_retrieved_bytecodes_tree_size, e execution_rop_0_, e execution_rop_1_, e execution_rop_2_, e execution_rop_3_, e execution_rop_4_, e execution_rop_5_, e execution_rop_6_, e execution_rop_tag_0_, e execution_rop_tag_1_, e execution_rop_tag_2_, e execution_rop_tag_3_, e execution_rop_tag_4_, e execution_rop_tag_5_, e execution_rop_tag_6_, e execution_rw_reg_0_, e execution_rw_reg_1_, e execution_rw_reg_2_, e execution_rw_reg_3_, e execution_rw_reg_4_, e execution_rw_reg_5_, e execution_sel_addressing_error, e execution_sel_apply_indirection_0_, e execution_sel_apply_indirection_1_, e execution_sel_apply_indirection_2_, e execution_sel_apply_indirection_3_, e execution_sel_apply_indirection_4_, e execution_sel_apply_indirection_5_, e execution_sel_apply_indirection_6_, e execution_sel_base_address_failure, e execution_sel_bytecode_retrieval_failure, e execution_sel_bytecode_retrieval_success, e execution_sel_check_gas, e execution_sel_do_base_check, e execution_sel_enter_call, e execution_sel_envvar_pi_lookup_col0, e execution_sel_envvar_pi_lookup_col1, e execution_sel_error, e execution_sel_exec_dispatch_alu, e execution_sel_exec_dispatch_bitwise, e execution_sel_exec_dispatch_calldata_copy, e execution_sel_exec_dispatch_cast, e execution_sel_exec_dispatch_ecc_add, e execution_sel_exec_dispatch_emit_public_log, e execution_sel_exec_dispatch_execution, e execution_sel_exec_dispatch_get_contract_instance, e execution_sel_exec_dispatch_keccakf1600, e execution_sel_exec_dispatch_poseidon2_perm, e execution_sel_exec_dispatch_returndata_copy, e execution_sel_exec_dispatch_set, e execution_sel_exec_dispatch_sha256_compression, e execution_sel_exec_dispatch_to_radix, e execution_sel_execute_call, e execution_sel_execute_debug_log, e execution_sel_execute_emit_notehash, e execution_sel_execute_emit_nullifier, e execution_sel_execute_get_env_var, e execution_sel_execute_internal_call, e execution_sel_execute_internal_return, e execution_sel_execute_jump, e execution_sel_execute_jumpi, e execution_sel_execute_l1_to_l2_message_exists, e execution_sel_execute_mov, e execution_sel_execute_notehash_exists, e execution_sel_execute_nullifier_exists, e execution_sel_execute_opcode, e execution_sel_execute_return, e execution_sel_execute_returndata_size, e execution_sel_execute_revert, e execution_sel_execute_send_l2_to_l1_msg, e execution_sel_execute_sload, e execution_sel_execute_sstore, e execution_sel_execute_static_call, e execution_sel_execute_success_copy, e execution_sel_exit_call, e execution_sel_failure, e execution_sel_gas_bitwise, e execution_sel_gas_calldata_copy, e execution_sel_gas_emit_public_log, e execution_sel_gas_returndata_copy, e execution_sel_gas_sstore, e execution_sel_gas_to_radix, e execution_sel_instruction_fetching_failure, e execution_sel_instruction_fetching_success, e execution_sel_l2_to_l1_msg_limit_error, e execution_sel_lookup_num_p_limbs, e execution_sel_mem_op_reg_0_, e execution_sel_mem_op_reg_1_, e execution_sel_mem_op_reg_2_, e execution_sel_mem_op_reg_3_, e execution_sel_mem_op_reg_4_, e execution_sel_mem_op_reg_5_, e execution_sel_op_do_overflow_check_0_, e execution_sel_op_do_overflow_check_1_, e execution_sel_op_do_overflow_check_2_, e execution_sel_op_do_overflow_check_3_, e execution_sel_op_do_overflow_check_4_, e execution_sel_op_do_overflow_check_5_, e execution_sel_op_do_overflow_check_6_, e execution_sel_op_is_address_0_, e execution_sel_op_is_address_1_, e execution_sel_op_is_address_2_, e execution_sel_op_is_address_3_, e execution_sel_op_is_address_4_, e execution_sel_op_is_address_5_, e execution_sel_op_is_address_6_, e execution_sel_op_is_indirect_wire_0_, e execution_sel_op_is_indirect_wire_1_, e execution_sel_op_is_indirect_wire_2_, e execution_sel_op_is_indirect_wire_3_, e execution_sel_op_is_indirect_wire_4_, e execution_sel_op_is_indirect_wire_5_, e execution_sel_op_is_indirect_wire_6_, e execution_sel_op_is_indirect_wire_7_, e execution_sel_op_is_relative_wire_0_, e execution_sel_op_is_relative_wire_1_, e execution_sel_op_is_relative_wire_2_, e execution_sel_op_is_relative_wire_3_, e execution_sel_op_is_relative_wire_4_, e execution_sel_op_is_relative_wire_5_, e execution_sel_op_is_relative_wire_6_, e execution_sel_op_is_relative_wire_7_, e execution_sel_op_reg_effective_0_, e execution_sel_op_reg_effective_1_, e execution_sel_op_reg_effective_2_, e execution_sel_op_reg_effective_3_, e execution_sel_op_reg_effective_4_, e execution_sel_op_reg_effective_5_, e execution_sel_opcode_error, e execution_sel_out_of_gas, e execution_sel_radix_gt_256, e execution_sel_reached_max_note_hashes, e execution_sel_reached_max_nullifiers, e execution_sel_read_registers, e execution_sel_read_unwind_call_stack, e execution_sel_register_read_error, e execution_sel_relative_overflow_0_, e execution_sel_relative_overflow_1_, e execution_sel_relative_overflow_2_, e execution_sel_relative_overflow_3_, e execution_sel_relative_overflow_4_, e execution_sel_relative_overflow_5_, e execution_sel_relative_overflow_6_, e execution_sel_some_final_check_failed, e execution_sel_tag_check_reg_0_, e execution_sel_tag_check_reg_1_, e execution_sel_tag_check_reg_2_, e execution_sel_tag_check_reg_3_, e execution_sel_tag_check_reg_4_, e execution_sel_tag_check_reg_5_, e execution_sel_too_large_recipient_error, e execution_sel_use_num_limbs, e execution_sel_write_l2_to_l1_msg, e execution_sel_write_note_hash, e execution_sel_write_nullifier, e execution_sel_write_public_data, e execution_sel_write_registers, e execution_subtrace_id, e execution_subtrace_operation_id, e execution_total_gas_da, e execution_total_gas_l2, e execution_two_five_six, e execution_value_from_pi, e execution_written_public_data_slots_tree_root, e execution_written_public_data_slots_tree_size, e execution_written_slots_merkle_separator, e execution_written_slots_tree_height, e execution_written_slots_tree_siloing_separator, e ff_gt_a, e ff_gt_b, e ff_gt_borrow, e ff_gt_constant_128, e ff_gt_end, e ff_gt_p_a_borrow, e ff_gt_p_b_borrow, e ff_gt_res_hi, e ff_gt_res_lo, e ff_gt_result, e get_contract_instance_clk, e get_contract_instance_contract_address, e get_contract_instance_dst_offset, e get_contract_instance_dst_offset_diff_max_inv, e get_contract_instance_exists_tag, e get_contract_instance_instance_exists, e get_contract_instance_is_class_id, e get_contract_instance_is_deployer, e get_contract_instance_is_init_hash, e get_contract_instance_is_valid_member_enum, e get_contract_instance_is_valid_writes_in_bounds, e get_contract_instance_member_enum, e get_contract_instance_member_tag, e get_contract_instance_member_write_offset, e get_contract_instance_nullifier_tree_root, e get_contract_instance_public_data_tree_root, e get_contract_instance_retrieved_class_id, e get_contract_instance_retrieved_deployer_addr, e get_contract_instance_retrieved_init_hash, e get_contract_instance_sel, e get_contract_instance_sel_error, e get_contract_instance_selected_member, e get_contract_instance_space_id, e gt_abs_diff, e gt_input_a, e gt_input_b, e gt_num_bits, e gt_res, e gt_sel, e gt_sel_addressing, e gt_sel_alu, e gt_sel_gas, e gt_sel_others, e gt_sel_sha256, e indexed_tree_check_address, e indexed_tree_check_const_three, e indexed_tree_check_discard, e indexed_tree_check_exists, e indexed_tree_check_intermediate_root, e indexed_tree_check_low_leaf_hash, e indexed_tree_check_low_leaf_index, e indexed_tree_check_low_leaf_next_index, e indexed_tree_check_low_leaf_next_value, e indexed_tree_check_low_leaf_value, e indexed_tree_check_merkle_hash_separator, e indexed_tree_check_new_leaf_hash, e indexed_tree_check_next_value_inv, e indexed_tree_check_next_value_is_nonzero, e indexed_tree_check_not_exists, e indexed_tree_check_public_inputs_index, e indexed_tree_check_root, e indexed_tree_check_sel, e indexed_tree_check_sel_insert, e indexed_tree_check_sel_silo, e indexed_tree_check_sel_write_to_public_inputs, e indexed_tree_check_siloed_value, e indexed_tree_check_siloing_separator, e indexed_tree_check_tree_height, e indexed_tree_check_tree_size_after_write, e indexed_tree_check_tree_size_before_write, e indexed_tree_check_updated_low_leaf_hash, e indexed_tree_check_updated_low_leaf_next_index, e indexed_tree_check_updated_low_leaf_next_value, e indexed_tree_check_value, e indexed_tree_check_value_low_leaf_value_diff_inv, e indexed_tree_check_write, e indexed_tree_check_write_root, e instr_fetching_addressing_mode, e instr_fetching_bd0, e instr_fetching_bd1, e instr_fetching_bd10, e instr_fetching_bd11, e instr_fetching_bd12, e instr_fetching_bd13, e instr_fetching_bd14, e instr_fetching_bd15, e instr_fetching_bd16, e instr_fetching_bd17, e instr_fetching_bd18, e instr_fetching_bd19, e instr_fetching_bd2, e instr_fetching_bd20, e instr_fetching_bd21, e instr_fetching_bd22, e instr_fetching_bd23, e instr_fetching_bd24, e instr_fetching_bd25, e instr_fetching_bd26, e instr_fetching_bd27, e instr_fetching_bd28, e instr_fetching_bd29, e instr_fetching_bd3, e instr_fetching_bd30, e instr_fetching_bd31, e instr_fetching_bd32, e instr_fetching_bd33, e instr_fetching_bd34, e instr_fetching_bd35, e instr_fetching_bd36, e instr_fetching_bd4, e instr_fetching_bd5, e instr_fetching_bd6, e instr_fetching_bd7, e instr_fetching_bd8, e instr_fetching_bd9, e instr_fetching_bytecode_id, e instr_fetching_bytecode_size, e instr_fetching_bytes_to_read, e instr_fetching_exec_opcode, e instr_fetching_instr_abs_diff, e instr_fetching_instr_out_of_range, e instr_fetching_instr_size, e instr_fetching_op1, e instr_fetching_op2, e instr_fetching_op3, e instr_fetching_op4, e instr_fetching_op5, e instr_fetching_op6, e instr_fetching_op7, e instr_fetching_opcode_out_of_range, e instr_fetching_pc, e instr_fetching_pc_abs_diff, e instr_fetching_pc_out_of_range, e instr_fetching_pc_size_in_bits, e instr_fetching_sel, e instr_fetching_sel_has_tag, e instr_fetching_sel_op_dc_0, e instr_fetching_sel_op_dc_1, e instr_fetching_sel_op_dc_10, e instr_fetching_sel_op_dc_11, e instr_fetching_sel_op_dc_12, e instr_fetching_sel_op_dc_13, e instr_fetching_sel_op_dc_14, e instr_fetching_sel_op_dc_15, e instr_fetching_sel_op_dc_16, e instr_fetching_sel_op_dc_2, e instr_fetching_sel_op_dc_3, e instr_fetching_sel_op_dc_4, e instr_fetching_sel_op_dc_5, e instr_fetching_sel_op_dc_6, e instr_fetching_sel_op_dc_7, e instr_fetching_sel_op_dc_8, e instr_fetching_sel_op_dc_9, e instr_fetching_sel_parsing_err, e instr_fetching_sel_pc_in_range, e instr_fetching_sel_tag_is_op2, e instr_fetching_tag_out_of_range, e instr_fetching_tag_value, e internal_call_stack_call_id, e internal_call_stack_context_id, e internal_call_stack_entered_call_id, e internal_call_stack_return_call_id, e internal_call_stack_return_pc, e internal_call_stack_sel, e keccak_memory_ctr_end, e keccak_memory_end, e keccak_memory_single_tag_error, e keccak_memory_state_size_min_ctr_inv, e keccak_memory_tag, e keccak_memory_tag_min_u64_inv, e keccak_memory_val_24_, e keccakf1600_bitwise_and_op_id, e keccakf1600_bitwise_xor_op_id, e keccakf1600_dst_out_of_range_error, e keccakf1600_end, e keccakf1600_error, e keccakf1600_highest_slice_address, e keccakf1600_rot_64_min_len_01, e keccakf1600_rot_64_min_len_03, e keccakf1600_rot_64_min_len_11, e keccakf1600_rot_64_min_len_13, e keccakf1600_rot_64_min_len_20, e keccakf1600_rot_64_min_len_22, e keccakf1600_rot_64_min_len_24, e keccakf1600_rot_64_min_len_31, e keccakf1600_rot_64_min_len_34, e keccakf1600_rot_64_min_len_42, e keccakf1600_rot_len_02, e keccakf1600_rot_len_04, e keccakf1600_rot_len_10, e keccakf1600_rot_len_12, e keccakf1600_rot_len_14, e keccakf1600_rot_len_21, e keccakf1600_rot_len_23, e keccakf1600_rot_len_30, e keccakf1600_rot_len_32, e keccakf1600_rot_len_33, e keccakf1600_rot_len_40, e keccakf1600_rot_len_41, e keccakf1600_rot_len_43, e keccakf1600_rot_len_44, e keccakf1600_round_cst, e keccakf1600_sel_slice_read, e keccakf1600_sel_slice_write, e keccakf1600_src_addr, e keccakf1600_src_out_of_range_error, e keccakf1600_state_chi_00, e keccakf1600_state_chi_01, e keccakf1600_state_chi_02, e keccakf1600_state_chi_03, e keccakf1600_state_chi_04, e keccakf1600_state_chi_10, e keccakf1600_state_chi_11, e keccakf1600_state_chi_12, e keccakf1600_state_chi_13, e keccakf1600_state_chi_14, e keccakf1600_state_chi_20, e keccakf1600_state_chi_21, e keccakf1600_state_chi_22, e keccakf1600_state_chi_23, e keccakf1600_state_chi_24, e keccakf1600_state_chi_30, e keccakf1600_state_chi_31, e keccakf1600_state_chi_32, e keccakf1600_state_chi_33, e keccakf1600_state_chi_34, e keccakf1600_state_chi_40, e keccakf1600_state_chi_41, e keccakf1600_state_chi_42, e keccakf1600_state_chi_43, e keccakf1600_state_chi_44, e keccakf1600_state_iota_00, e keccakf1600_state_pi_and_00, e keccakf1600_state_pi_and_01, e keccakf1600_state_pi_and_02, e keccakf1600_state_pi_and_03, e keccakf1600_state_pi_and_04, e keccakf1600_state_pi_and_10, e keccakf1600_state_pi_and_11, e keccakf1600_state_pi_and_12, e keccakf1600_state_pi_and_13, e keccakf1600_state_pi_and_14, e keccakf1600_state_pi_and_20, e keccakf1600_state_pi_and_21, e keccakf1600_state_pi_and_22, e keccakf1600_state_pi_and_23, e keccakf1600_state_pi_and_24, e keccakf1600_state_pi_and_30, e keccakf1600_state_pi_and_31, e keccakf1600_state_pi_and_32, e keccakf1600_state_pi_and_33, e keccakf1600_state_pi_and_34, e keccakf1600_state_pi_and_40, e keccakf1600_state_pi_and_41, e keccakf1600_state_pi_and_42, e keccakf1600_state_pi_and_43, e keccakf1600_state_pi_and_44, e keccakf1600_state_pi_not_00, e keccakf1600_state_pi_not_01, e keccakf1600_state_pi_not_02, e keccakf1600_state_pi_not_03, e keccakf1600_state_pi_not_04, e keccakf1600_state_pi_not_10, e keccakf1600_state_pi_not_11, e keccakf1600_state_pi_not_12, e keccakf1600_state_pi_not_13, e keccakf1600_state_pi_not_14, e keccakf1600_state_pi_not_20, e keccakf1600_state_pi_not_21, e keccakf1600_state_pi_not_22, e keccakf1600_state_pi_not_23, e keccakf1600_state_pi_not_24, e keccakf1600_state_pi_not_30, e keccakf1600_state_pi_not_31, e keccakf1600_state_pi_not_32, e keccakf1600_state_pi_not_33, e keccakf1600_state_pi_not_34, e keccakf1600_state_pi_not_40, e keccakf1600_state_pi_not_41, e keccakf1600_state_pi_not_42, e keccakf1600_state_pi_not_43, e keccakf1600_state_pi_not_44, e keccakf1600_state_rho_01, e keccakf1600_state_rho_02, e keccakf1600_state_rho_03, e keccakf1600_state_rho_04, e keccakf1600_state_rho_10, e keccakf1600_state_rho_11, e keccakf1600_state_rho_12, e keccakf1600_state_rho_13, e keccakf1600_state_rho_14, e keccakf1600_state_rho_20, e keccakf1600_state_rho_21, e keccakf1600_state_rho_22, e keccakf1600_state_rho_23, e keccakf1600_state_rho_24, e keccakf1600_state_rho_30, e keccakf1600_state_rho_31, e keccakf1600_state_rho_32, e keccakf1600_state_rho_33, e keccakf1600_state_rho_34, e keccakf1600_state_rho_40, e keccakf1600_state_rho_41, e keccakf1600_state_rho_42, e keccakf1600_state_rho_43, e keccakf1600_state_rho_44, e keccakf1600_state_theta_00, e keccakf1600_state_theta_01, e keccakf1600_state_theta_02, e keccakf1600_state_theta_03, e keccakf1600_state_theta_04, e keccakf1600_state_theta_10, e keccakf1600_state_theta_11, e keccakf1600_state_theta_12, e keccakf1600_state_theta_13, e keccakf1600_state_theta_14, e keccakf1600_state_theta_20, e keccakf1600_state_theta_21, e keccakf1600_state_theta_22, e keccakf1600_state_theta_23, e keccakf1600_state_theta_24, e keccakf1600_state_theta_30, e keccakf1600_state_theta_31, e keccakf1600_state_theta_32, e keccakf1600_state_theta_33, e keccakf1600_state_theta_34, e keccakf1600_state_theta_40, e keccakf1600_state_theta_41, e keccakf1600_state_theta_42, e keccakf1600_state_theta_43, e keccakf1600_state_theta_44, e keccakf1600_state_theta_hi_02, e keccakf1600_state_theta_hi_04, e keccakf1600_state_theta_hi_10, e keccakf1600_state_theta_hi_12, e keccakf1600_state_theta_hi_14, e keccakf1600_state_theta_hi_21, e keccakf1600_state_theta_hi_23, e keccakf1600_state_theta_hi_30, e keccakf1600_state_theta_hi_32, e keccakf1600_state_theta_hi_33, e keccakf1600_state_theta_hi_40, e keccakf1600_state_theta_hi_41, e keccakf1600_state_theta_hi_43, e keccakf1600_state_theta_hi_44, e keccakf1600_state_theta_low_01, e keccakf1600_state_theta_low_03, e keccakf1600_state_theta_low_11, e keccakf1600_state_theta_low_13, e keccakf1600_state_theta_low_20, e keccakf1600_state_theta_low_22, e keccakf1600_state_theta_low_24, e keccakf1600_state_theta_low_31, e keccakf1600_state_theta_low_34, e keccakf1600_state_theta_low_42, e keccakf1600_tag_error, e keccakf1600_tag_u64, e keccakf1600_theta_combined_xor_0, e keccakf1600_theta_combined_xor_1, e keccakf1600_theta_combined_xor_2, e keccakf1600_theta_combined_xor_3, e keccakf1600_theta_combined_xor_4, e keccakf1600_theta_xor_01, e keccakf1600_theta_xor_02, e keccakf1600_theta_xor_03, e keccakf1600_theta_xor_11, e keccakf1600_theta_xor_12, e keccakf1600_theta_xor_13, e keccakf1600_theta_xor_21, e keccakf1600_theta_xor_22, e keccakf1600_theta_xor_23, e keccakf1600_theta_xor_31, e keccakf1600_theta_xor_32, e keccakf1600_theta_xor_33, e keccakf1600_theta_xor_41, e keccakf1600_theta_xor_42, e keccakf1600_theta_xor_43, e keccakf1600_theta_xor_row_0, e keccakf1600_theta_xor_row_1, e keccakf1600_theta_xor_row_2, e keccakf1600_theta_xor_row_3, e keccakf1600_theta_xor_row_4, e keccakf1600_theta_xor_row_msb_0, e keccakf1600_theta_xor_row_msb_1, e keccakf1600_theta_xor_row_msb_2, e keccakf1600_theta_xor_row_msb_3, e keccakf1600_theta_xor_row_msb_4, e keccakf1600_theta_xor_row_rotl1_0, e keccakf1600_theta_xor_row_rotl1_1, e keccakf1600_theta_xor_row_rotl1_2, e keccakf1600_theta_xor_row_rotl1_3, e keccakf1600_theta_xor_row_rotl1_4, e l1_to_l2_message_tree_check_exists, e l1_to_l2_message_tree_check_l1_to_l2_message_tree_height, e l1_to_l2_message_tree_check_leaf_index, e l1_to_l2_message_tree_check_leaf_value, e l1_to_l2_message_tree_check_leaf_value_msg_hash_diff_inv, e l1_to_l2_message_tree_check_merkle_hash_separator, e l1_to_l2_message_tree_check_msg_hash, e l1_to_l2_message_tree_check_root, e l1_to_l2_message_tree_check_sel, e memory_diff, e memory_glob_addr_diff_inv, e memory_last_access, e memory_limb_0_, e memory_limb_1_, e memory_limb_2_, e memory_max_bits, e memory_sel_addressing_base, e memory_sel_addressing_indirect_0_, e memory_sel_addressing_indirect_1_, e memory_sel_addressing_indirect_2_, e memory_sel_addressing_indirect_3_, e memory_sel_addressing_indirect_4_, e memory_sel_addressing_indirect_5_, e memory_sel_addressing_indirect_6_, e memory_sel_data_copy_read, e memory_sel_data_copy_write, e memory_sel_ecc_write_0_, e memory_sel_ecc_write_1_, e memory_sel_ecc_write_2_, e memory_sel_get_contract_instance_exists_write, e memory_sel_get_contract_instance_member_write, e memory_sel_keccak, e memory_sel_poseidon2_read_0_, e memory_sel_poseidon2_read_1_, e memory_sel_poseidon2_read_2_, e memory_sel_poseidon2_read_3_, e memory_sel_poseidon2_write_0_, e memory_sel_poseidon2_write_1_, e memory_sel_poseidon2_write_2_, e memory_sel_poseidon2_write_3_, e memory_sel_public_log_read, e memory_sel_register_op_0_, e memory_sel_register_op_1_, e memory_sel_register_op_2_, e memory_sel_register_op_3_, e memory_sel_register_op_4_, e memory_sel_register_op_5_, e memory_sel_rng_chk, e memory_sel_rng_write, e memory_sel_sha256_op_0_, e memory_sel_sha256_op_1_, e memory_sel_sha256_op_2_, e memory_sel_sha256_op_3_, e memory_sel_sha256_op_4_, e memory_sel_sha256_op_5_, e memory_sel_sha256_op_6_, e memory_sel_sha256_op_7_, e memory_sel_sha256_read, e memory_sel_tag_is_ff, e memory_sel_to_radix_write, e memory_tag_ff_diff_inv, e merkle_check_const_three, e merkle_check_end, e merkle_check_index_is_even, e merkle_check_path_len_min_one_inv, e merkle_check_read_left_node, e merkle_check_read_output_hash, e merkle_check_read_right_node, e merkle_check_sibling, e merkle_check_write_left_node, e merkle_check_write_output_hash, e merkle_check_write_right_node, e note_hash_tree_check_address, e note_hash_tree_check_const_three, e note_hash_tree_check_discard, e note_hash_tree_check_exists, e note_hash_tree_check_first_nullifier, e note_hash_tree_check_first_nullifier_pi_index, e note_hash_tree_check_leaf_index, e note_hash_tree_check_merkle_hash_separator, e note_hash_tree_check_next_leaf_value, e note_hash_tree_check_next_root, e note_hash_tree_check_nonce, e note_hash_tree_check_nonce_separator, e note_hash_tree_check_note_hash, e note_hash_tree_check_note_hash_index, e note_hash_tree_check_note_hash_tree_height, e note_hash_tree_check_prev_leaf_value, e note_hash_tree_check_prev_leaf_value_unique_note_hash_diff_inv, e note_hash_tree_check_prev_root, e note_hash_tree_check_public_inputs_index, e note_hash_tree_check_sel, e note_hash_tree_check_sel_silo, e note_hash_tree_check_sel_unique, e note_hash_tree_check_sel_write_to_public_inputs, e note_hash_tree_check_siloed_note_hash, e note_hash_tree_check_siloing_separator, e note_hash_tree_check_unique_note_hash, e note_hash_tree_check_unique_note_hash_separator, e note_hash_tree_check_write, e poseidon2_hash_b_0, e poseidon2_hash_b_1, e poseidon2_hash_b_2, e poseidon2_hash_b_3, e poseidon2_hash_end, e poseidon2_hash_input_len, e poseidon2_hash_num_perm_rounds_rem_min_one_inv, e poseidon2_hash_padding, e poseidon2_perm_B_10_0, e poseidon2_perm_B_10_1, e poseidon2_perm_B_10_2, e poseidon2_perm_B_10_3, e poseidon2_perm_B_11_0, e poseidon2_perm_B_11_1, e poseidon2_perm_B_11_2, e poseidon2_perm_B_11_3, e poseidon2_perm_B_12_0, e poseidon2_perm_B_12_1, e poseidon2_perm_B_12_2, e poseidon2_perm_B_12_3, e poseidon2_perm_B_13_0, e poseidon2_perm_B_13_1, e poseidon2_perm_B_13_2, e poseidon2_perm_B_13_3, e poseidon2_perm_B_14_0, e poseidon2_perm_B_14_1, e poseidon2_perm_B_14_2, e poseidon2_perm_B_14_3, e poseidon2_perm_B_15_0, e poseidon2_perm_B_15_1, e poseidon2_perm_B_15_2, e poseidon2_perm_B_15_3, e poseidon2_perm_B_16_0, e poseidon2_perm_B_16_1, e poseidon2_perm_B_16_2, e poseidon2_perm_B_16_3, e poseidon2_perm_B_17_0, e poseidon2_perm_B_17_1, e poseidon2_perm_B_17_2, e poseidon2_perm_B_17_3, e poseidon2_perm_B_18_0, e poseidon2_perm_B_18_1, e poseidon2_perm_B_18_2, e poseidon2_perm_B_18_3, e poseidon2_perm_B_19_0, e poseidon2_perm_B_19_1, e poseidon2_perm_B_19_2, e poseidon2_perm_B_19_3, e poseidon2_perm_B_20_0, e poseidon2_perm_B_20_1, e poseidon2_perm_B_20_2, e poseidon2_perm_B_20_3, e poseidon2_perm_B_21_0, e poseidon2_perm_B_21_1, e poseidon2_perm_B_21_2, e poseidon2_perm_B_21_3, e poseidon2_perm_B_22_0, e poseidon2_perm_B_22_1, e poseidon2_perm_B_22_2, e poseidon2_perm_B_22_3, e poseidon2_perm_B_23_0, e poseidon2_perm_B_23_1, e poseidon2_perm_B_23_2, e poseidon2_perm_B_23_3, e poseidon2_perm_B_24_0, e poseidon2_perm_B_24_1, e poseidon2_perm_B_24_2, e poseidon2_perm_B_24_3, e poseidon2_perm_B_25_0, e poseidon2_perm_B_25_1, e poseidon2_perm_B_25_2, e poseidon2_perm_B_25_3, e poseidon2_perm_B_26_0, e poseidon2_perm_B_26_1, e poseidon2_perm_B_26_2, e poseidon2_perm_B_26_3, e poseidon2_perm_B_27_0, e poseidon2_perm_B_27_1, e poseidon2_perm_B_27_2, e poseidon2_perm_B_27_3, e poseidon2_perm_B_28_0, e poseidon2_perm_B_28_1, e poseidon2_perm_B_28_2, e poseidon2_perm_B_28_3, e poseidon2_perm_B_29_0, e poseidon2_perm_B_29_1, e poseidon2_perm_B_29_2, e poseidon2_perm_B_29_3, e poseidon2_perm_B_30_0, e poseidon2_perm_B_30_1, e poseidon2_perm_B_30_2, e poseidon2_perm_B_30_3, e poseidon2_perm_B_31_0, e poseidon2_perm_B_31_1, e poseidon2_perm_B_31_2, e poseidon2_perm_B_31_3, e poseidon2_perm_B_32_0, e poseidon2_perm_B_32_1, e poseidon2_perm_B_32_2, e poseidon2_perm_B_32_3, e poseidon2_perm_B_33_0, e poseidon2_perm_B_33_1, e poseidon2_perm_B_33_2, e poseidon2_perm_B_33_3, e poseidon2_perm_B_34_0, e poseidon2_perm_B_34_1, e poseidon2_perm_B_34_2, e poseidon2_perm_B_34_3, e poseidon2_perm_B_35_0, e poseidon2_perm_B_35_1, e poseidon2_perm_B_35_2, e poseidon2_perm_B_35_3, e poseidon2_perm_B_36_0, e poseidon2_perm_B_36_1, e poseidon2_perm_B_36_2, e poseidon2_perm_B_36_3, e poseidon2_perm_B_37_0, e poseidon2_perm_B_37_1, e poseidon2_perm_B_37_2, e poseidon2_perm_B_37_3, e poseidon2_perm_B_38_0, e poseidon2_perm_B_38_1, e poseidon2_perm_B_38_2, e poseidon2_perm_B_38_3, e poseidon2_perm_B_39_0, e poseidon2_perm_B_39_1, e poseidon2_perm_B_39_2, e poseidon2_perm_B_39_3, e poseidon2_perm_B_40_0, e poseidon2_perm_B_40_1, e poseidon2_perm_B_40_2, e poseidon2_perm_B_40_3, e poseidon2_perm_B_41_0, e poseidon2_perm_B_41_1, e poseidon2_perm_B_41_2, e poseidon2_perm_B_41_3, e poseidon2_perm_B_42_0, e poseidon2_perm_B_42_1, e poseidon2_perm_B_42_2, e poseidon2_perm_B_42_3, e poseidon2_perm_B_43_0, e poseidon2_perm_B_43_1, e poseidon2_perm_B_43_2, e poseidon2_perm_B_43_3, e poseidon2_perm_B_44_0, e poseidon2_perm_B_44_1, e poseidon2_perm_B_44_2, e poseidon2_perm_B_44_3, e poseidon2_perm_B_45_0, e poseidon2_perm_B_45_1, e poseidon2_perm_B_45_2, e poseidon2_perm_B_45_3, e poseidon2_perm_B_46_0, e poseidon2_perm_B_46_1, e poseidon2_perm_B_46_2, e poseidon2_perm_B_46_3, e poseidon2_perm_B_47_0, e poseidon2_perm_B_47_1, e poseidon2_perm_B_47_2, e poseidon2_perm_B_47_3, e poseidon2_perm_B_48_0, e poseidon2_perm_B_48_1, e poseidon2_perm_B_48_2, e poseidon2_perm_B_48_3, e poseidon2_perm_B_49_0, e poseidon2_perm_B_49_1, e poseidon2_perm_B_49_2, e poseidon2_perm_B_49_3, e poseidon2_perm_B_4_0, e poseidon2_perm_B_4_1, e poseidon2_perm_B_4_2, e poseidon2_perm_B_4_3, e poseidon2_perm_B_50_0, e poseidon2_perm_B_50_1, e poseidon2_perm_B_50_2, e poseidon2_perm_B_50_3, e poseidon2_perm_B_51_0, e poseidon2_perm_B_51_1, e poseidon2_perm_B_51_2, e poseidon2_perm_B_51_3, e poseidon2_perm_B_52_0, e poseidon2_perm_B_52_1, e poseidon2_perm_B_52_2, e poseidon2_perm_B_52_3, e poseidon2_perm_B_53_0, e poseidon2_perm_B_53_1, e poseidon2_perm_B_53_2, e poseidon2_perm_B_53_3, e poseidon2_perm_B_54_0, e poseidon2_perm_B_54_1, e poseidon2_perm_B_54_2, e poseidon2_perm_B_54_3, e poseidon2_perm_B_55_0, e poseidon2_perm_B_55_1, e poseidon2_perm_B_55_2, e poseidon2_perm_B_55_3, e poseidon2_perm_B_56_0, e poseidon2_perm_B_56_1, e poseidon2_perm_B_56_2, e poseidon2_perm_B_56_3, e poseidon2_perm_B_57_0, e poseidon2_perm_B_57_1, e poseidon2_perm_B_57_2, e poseidon2_perm_B_57_3, e poseidon2_perm_B_58_0, e poseidon2_perm_B_58_1, e poseidon2_perm_B_58_2, e poseidon2_perm_B_58_3, e poseidon2_perm_B_59_0, e poseidon2_perm_B_59_1, e poseidon2_perm_B_59_2, e poseidon2_perm_B_59_3, e poseidon2_perm_B_5_0, e poseidon2_perm_B_5_1, e poseidon2_perm_B_5_2, e poseidon2_perm_B_5_3, e poseidon2_perm_B_6_0, e poseidon2_perm_B_6_1, e poseidon2_perm_B_6_2, e poseidon2_perm_B_6_3, e poseidon2_perm_B_7_0, e poseidon2_perm_B_7_1, e poseidon2_perm_B_7_2, e poseidon2_perm_B_7_3, e poseidon2_perm_B_8_0, e poseidon2_perm_B_8_1, e poseidon2_perm_B_8_2, e poseidon2_perm_B_8_3, e poseidon2_perm_B_9_0, e poseidon2_perm_B_9_1, e poseidon2_perm_B_9_2, e poseidon2_perm_B_9_3, e poseidon2_perm_EXT_LAYER_4, e poseidon2_perm_EXT_LAYER_5, e poseidon2_perm_EXT_LAYER_6, e poseidon2_perm_EXT_LAYER_7, e poseidon2_perm_T_0_4, e poseidon2_perm_T_0_5, e poseidon2_perm_T_0_6, e poseidon2_perm_T_0_7, e poseidon2_perm_T_1_4, e poseidon2_perm_T_1_5, e poseidon2_perm_T_1_6, e poseidon2_perm_T_1_7, e poseidon2_perm_T_2_4, e poseidon2_perm_T_2_5, e poseidon2_perm_T_2_6, e poseidon2_perm_T_2_7, e poseidon2_perm_T_3_4, e poseidon2_perm_T_3_5, e poseidon2_perm_T_3_6, e poseidon2_perm_T_3_7, e poseidon2_perm_T_60_4, e poseidon2_perm_T_60_5, e poseidon2_perm_T_60_6, e poseidon2_perm_T_60_7, e poseidon2_perm_T_61_4, e poseidon2_perm_T_61_5, e poseidon2_perm_T_61_6, e poseidon2_perm_T_61_7, e poseidon2_perm_T_62_4, e poseidon2_perm_T_62_5, e poseidon2_perm_T_62_6, e poseidon2_perm_T_62_7, e poseidon2_perm_T_63_4, e poseidon2_perm_T_63_5, e poseidon2_perm_T_63_6, e poseidon2_perm_T_63_7, e poseidon2_perm_a_0, e poseidon2_perm_a_1, e poseidon2_perm_a_2, e poseidon2_perm_a_3, e poseidon2_perm_b_0, e poseidon2_perm_b_1, e poseidon2_perm_b_2, e poseidon2_perm_b_3, e poseidon2_perm_mem_batch_tag_inv, e poseidon2_perm_mem_err, e poseidon2_perm_mem_execution_clk, e poseidon2_perm_mem_input_0_, e poseidon2_perm_mem_input_1_, e poseidon2_perm_mem_input_2_, e poseidon2_perm_mem_input_3_, e poseidon2_perm_mem_input_tag_0_, e poseidon2_perm_mem_input_tag_1_, e poseidon2_perm_mem_input_tag_2_, e poseidon2_perm_mem_input_tag_3_, e poseidon2_perm_mem_max_mem_addr, e poseidon2_perm_mem_output_0_, e poseidon2_perm_mem_output_1_, e poseidon2_perm_mem_output_2_, e poseidon2_perm_mem_output_3_, e poseidon2_perm_mem_read_address_0_, e poseidon2_perm_mem_read_address_1_, e poseidon2_perm_mem_read_address_2_, e poseidon2_perm_mem_read_address_3_, e poseidon2_perm_mem_sel, e poseidon2_perm_mem_sel_dst_out_of_range_err, e poseidon2_perm_mem_sel_invalid_tag_err, e poseidon2_perm_mem_sel_should_exec, e poseidon2_perm_mem_sel_should_read_mem, e poseidon2_perm_mem_sel_src_out_of_range_err, e poseidon2_perm_mem_space_id, e poseidon2_perm_mem_write_address_0_, e poseidon2_perm_mem_write_address_1_, e poseidon2_perm_mem_write_address_2_, e poseidon2_perm_mem_write_address_3_, e poseidon2_perm_sel, e public_data_check_address, e public_data_check_clk_diff_hi, e public_data_check_clk_diff_lo, e public_data_check_const_four, e public_data_check_const_three, e public_data_check_discard, e public_data_check_end, e public_data_check_final_value, e public_data_check_intermediate_root, e public_data_check_leaf_not_exists, e public_data_check_leaf_slot, e public_data_check_leaf_slot_low_leaf_slot_diff_inv, e public_data_check_length_pi_idx, e public_data_check_low_leaf_hash, e public_data_check_low_leaf_index, e public_data_check_low_leaf_next_index, e public_data_check_low_leaf_next_slot, e public_data_check_low_leaf_slot, e public_data_check_low_leaf_value, e public_data_check_merkle_hash_separator, e public_data_check_new_leaf_hash, e public_data_check_next_slot_inv, e public_data_check_next_slot_is_nonzero, e public_data_check_non_discarded_write, e public_data_check_non_protocol_write, e public_data_check_not_end, e public_data_check_protocol_write, e public_data_check_public_data_writes_length, e public_data_check_root, e public_data_check_sel_write_to_public_inputs, e public_data_check_should_insert, e public_data_check_siloing_separator, e public_data_check_slot, e public_data_check_tree_height, e public_data_check_tree_size_after_write, e public_data_check_tree_size_before_write, e public_data_check_updated_low_leaf_hash, e public_data_check_updated_low_leaf_next_index, e public_data_check_updated_low_leaf_next_slot, e public_data_check_updated_low_leaf_value, e public_data_check_value, e public_data_check_write, e public_data_check_write_root, e public_data_squash_check_clock, e public_data_squash_clk_diff_hi, e public_data_squash_clk_diff_lo, e public_data_squash_leaf_slot_increase, e public_data_squash_value, e range_check_dyn_diff, e range_check_dyn_rng_chk_bits, e range_check_dyn_rng_chk_pow_2, e range_check_is_lte_u112, e range_check_is_lte_u128, e range_check_is_lte_u16, e range_check_is_lte_u32, e range_check_is_lte_u48, e range_check_is_lte_u64, e range_check_is_lte_u80, e range_check_is_lte_u96, e range_check_rng_chk_bits, e range_check_sel, e range_check_sel_alu, e range_check_sel_gt, e range_check_sel_keccak, e range_check_sel_memory, e range_check_sel_r0_16_bit_rng_lookup, e range_check_sel_r1_16_bit_rng_lookup, e range_check_sel_r2_16_bit_rng_lookup, e range_check_sel_r3_16_bit_rng_lookup, e range_check_sel_r4_16_bit_rng_lookup, e range_check_sel_r5_16_bit_rng_lookup, e range_check_sel_r6_16_bit_rng_lookup, e range_check_u16_r0, e range_check_u16_r1, e range_check_u16_r2, e range_check_u16_r3, e range_check_u16_r4, e range_check_u16_r5, e range_check_u16_r6, e range_check_u16_r7, e range_check_value, e scalar_mul_bit, e scalar_mul_const_two, e scalar_mul_end, e scalar_mul_sel_not_end, e scalar_mul_should_add, e sha256_a_and_b, e sha256_a_and_b_xor_a_and_c, e sha256_a_and_c, e sha256_a_rotr_13, e sha256_a_rotr_2, e sha256_a_rotr_22, e sha256_a_rotr_2_xor_a_rotr_13, e sha256_and_op_id, e sha256_b_and_c, e sha256_batch_tag_inv, e sha256_ch, e sha256_computed_w_lhs, e sha256_computed_w_rhs, e sha256_e_and_f, e sha256_e_rotr_11, e sha256_e_rotr_25, e sha256_e_rotr_6, e sha256_e_rotr_6_xor_e_rotr_11, e sha256_end, e sha256_err, e sha256_input, e sha256_input_rounds_rem_inv, e sha256_input_tag, e sha256_input_tag_diff_inv, e sha256_last, e sha256_lhs_w_10, e sha256_lhs_w_3, e sha256_maj, e sha256_max_input_addr, e sha256_max_mem_addr, e sha256_max_output_addr, e sha256_max_state_addr, e sha256_mem_out_of_range_err, e sha256_memory_address_0_, e sha256_memory_address_1_, e sha256_memory_address_2_, e sha256_memory_address_3_, e sha256_memory_address_4_, e sha256_memory_address_5_, e sha256_memory_address_6_, e sha256_memory_address_7_, e sha256_memory_register_0_, e sha256_memory_register_1_, e sha256_memory_register_2_, e sha256_memory_register_3_, e sha256_memory_register_4_, e sha256_memory_register_5_, e sha256_memory_register_6_, e sha256_memory_register_7_, e sha256_memory_tag_0_, e sha256_memory_tag_1_, e sha256_memory_tag_2_, e sha256_memory_tag_3_, e sha256_memory_tag_4_, e sha256_memory_tag_5_, e sha256_memory_tag_6_, e sha256_memory_tag_7_, e sha256_next_a_lhs, e sha256_next_a_rhs, e sha256_next_e_lhs, e sha256_next_e_rhs, e sha256_not_e, e sha256_not_e_and_g, e sha256_output_a_lhs, e sha256_output_a_rhs, e sha256_output_b_lhs, e sha256_output_b_rhs, e sha256_output_c_lhs, e sha256_output_c_rhs, e sha256_output_d_lhs, e sha256_output_d_rhs, e sha256_output_e_lhs, e sha256_output_e_rhs, e sha256_output_f_lhs, e sha256_output_f_rhs, e sha256_output_g_lhs, e sha256_output_g_rhs, e sha256_output_h_lhs, e sha256_output_h_rhs, e sha256_perform_round, e sha256_rhs_a_13, e sha256_rhs_a_2, e sha256_rhs_a_22, e sha256_rhs_e_11, e sha256_rhs_e_25, e sha256_rhs_e_6, e sha256_rhs_w_10, e sha256_rhs_w_17, e sha256_rhs_w_18, e sha256_rhs_w_19, e sha256_rhs_w_3, e sha256_rhs_w_7, e sha256_round_constant, e sha256_round_count, e sha256_rounds_remaining_inv, e sha256_rw, e sha256_s_0, e sha256_s_1, e sha256_sel_compute_w, e sha256_sel_input_out_of_range_err, e sha256_sel_invalid_input_row_tag_err, e sha256_sel_invalid_state_tag_err, e sha256_sel_is_input_round, e sha256_sel_mem_state_or_output, e sha256_sel_output_out_of_range_err, e sha256_sel_read_input_from_memory, e sha256_sel_state_out_of_range_err, e sha256_state_addr, e sha256_two_pow_10, e sha256_two_pow_11, e sha256_two_pow_13, e sha256_two_pow_17, e sha256_two_pow_18, e sha256_two_pow_19, e sha256_two_pow_2, e sha256_two_pow_22, e sha256_two_pow_25, e sha256_two_pow_3, e sha256_two_pow_32, e sha256_two_pow_6, e sha256_two_pow_7, e sha256_u32_tag, e sha256_w, e sha256_w_15_rotr_18, e sha256_w_15_rotr_7, e sha256_w_15_rotr_7_xor_w_15_rotr_18, e sha256_w_2_rotr_17, e sha256_w_2_rotr_17_xor_w_2_rotr_19, e sha256_w_2_rotr_19, e sha256_w_s_0, e sha256_w_s_1, e sha256_xor_op_id, e to_radix_end, e to_radix_found, e to_radix_is_unsafe_limb, e to_radix_limb_p_diff, e to_radix_limb_radix_diff, e to_radix_mem_err, e to_radix_mem_input_validation_error, e to_radix_mem_last, e to_radix_mem_limb_index_to_lookup, e to_radix_mem_limb_value, e to_radix_mem_max_mem_size, e to_radix_mem_num_limbs_inv, e to_radix_mem_num_limbs_minus_one_inv, e to_radix_mem_output_tag, e to_radix_mem_radix_min_two_inv, e to_radix_mem_sel_dst_out_of_range_err, e to_radix_mem_sel_invalid_bitwise_radix, e to_radix_mem_sel_num_limbs_is_zero, e to_radix_mem_sel_radix_eq_2, e to_radix_mem_sel_radix_gt_256_err, e to_radix_mem_sel_radix_lt_2_err, e to_radix_mem_sel_value_is_zero, e to_radix_mem_two, e to_radix_mem_two_five_six, e to_radix_mem_value_found, e to_radix_mem_value_inv, e to_radix_mem_write_addr_upper_bound, e to_radix_p_limb, e to_radix_rem_inverse, e to_radix_safety_diff_inverse, e tx_array_length_l2_to_l1_messages_pi_offset, e tx_array_length_note_hashes_pi_offset, e tx_array_length_nullifiers_pi_offset, e tx_calldata_hash, e tx_calldata_size, e tx_const_three, e tx_contract_addr, e tx_dom_sep_public_storage_map_slot, e tx_effective_fee_per_da_gas, e tx_effective_fee_per_l2_gas, e tx_end_phase, e tx_fee_juice_balance_slot, e tx_fee_juice_balances_slot_constant, e tx_fee_juice_contract_address, e tx_fee_payer, e tx_fee_payer_balance, e tx_fee_payer_new_balance, e tx_fee_payer_pi_offset, e tx_fields_length_public_logs_pi_offset, e tx_gas_limit_pi_offset, e tx_gas_used_pi_offset, e tx_is_cleanup, e tx_is_collect_fee, e tx_is_padded, e tx_is_public_call_request, e tx_is_static, e tx_is_tree_insert_phase, e tx_is_tree_padding, e tx_l1_l2_pi_offset, e tx_l2_l1_msg_content, e tx_l2_l1_msg_contract_address, e tx_l2_l1_msg_recipient, e tx_leaf_value, e tx_msg_sender, e tx_next_da_gas_used, e tx_next_da_gas_used_sent_to_enqueued_call, e tx_next_l2_gas_used, e tx_next_l2_gas_used_sent_to_enqueued_call, e tx_next_note_hash_tree_root, e tx_next_note_hash_tree_size, e tx_next_nullifier_tree_root, e tx_next_nullifier_tree_size, e tx_next_num_l2_to_l1_messages, e tx_next_num_note_hashes_emitted, e tx_next_num_nullifiers_emitted, e tx_next_num_public_log_fields, e tx_next_phase_on_revert, e tx_next_public_data_tree_root, e tx_next_public_data_tree_size, e tx_next_retrieved_bytecodes_tree_root, e tx_next_retrieved_bytecodes_tree_size, e tx_next_written_public_data_slots_tree_root, e tx_next_written_public_data_slots_tree_size, e tx_note_hash_pi_offset, e tx_nullifier_limit_error, e tx_nullifier_merkle_separator, e tx_nullifier_pi_offset, e tx_nullifier_tree_height, e tx_prev_da_gas_used_sent_to_enqueued_call, e tx_prev_l2_gas_used_sent_to_enqueued_call, e tx_public_data_pi_offset, e tx_read_pi_length_offset, e tx_read_pi_start_offset, e tx_remaining_phase_inv, e tx_remaining_phase_minus_one_inv, e tx_remaining_side_effects_inv, e tx_reverted_pi_offset, e tx_sel_l2_l1_msg_append, e tx_sel_non_revertible_append_l2_l1_msg, e tx_sel_non_revertible_append_note_hash, e tx_sel_non_revertible_append_nullifier, e tx_sel_note_hash_append, e tx_sel_nullifier_append, e tx_sel_process_call_request, e tx_sel_read_phase_length, e tx_sel_read_trees_and_gas_used, e tx_sel_revertible_append_l2_l1_msg, e tx_sel_revertible_append_note_hash, e tx_sel_revertible_append_nullifier, e tx_sel_try_l2_l1_msg_append, e tx_sel_try_note_hash_append, e tx_sel_try_nullifier_append, e tx_setup_phase_value, e tx_should_read_gas_limit, e tx_uint32_max, e tx_write_nullifier_pi_offset, e tx_write_pi_offset, e update_check_address, e update_check_const_three, e update_check_contract_instance_registry_address, e update_check_current_class_id, e update_check_delayed_public_mutable_hash_slot, e update_check_delayed_public_mutable_slot, e update_check_dom_sep_public_storage_map_slot, e update_check_hash_not_zero, e update_check_original_class_id, e update_check_public_data_tree_root, e update_check_sel, e update_check_timestamp, e update_check_timestamp_is_lt_timestamp_of_change, e update_check_timestamp_of_change, e update_check_timestamp_of_change_bit_size, e update_check_timestamp_pi_offset, e update_check_update_hash, e update_check_update_hash_inv, e update_check_update_hi_metadata, e update_check_update_hi_metadata_bit_size, e update_check_update_post_class_id_is_zero, e update_check_update_post_class_inv, e update_check_update_pre_class_id_is_zero, e update_check_update_pre_class_inv, e update_check_update_preimage_metadata, e update_check_update_preimage_post_class_id, e update_check_update_preimage_pre_class_id, e update_check_updated_class_ids_slot, e lookup_range_check_dyn_rng_chk_pow_2_counts, e lookup_range_check_dyn_diff_is_u16_counts, e lookup_range_check_r0_is_u16_counts, e lookup_range_check_r1_is_u16_counts, e lookup_range_check_r2_is_u16_counts, e lookup_range_check_r3_is_u16_counts, e lookup_range_check_r4_is_u16_counts, e lookup_range_check_r5_is_u16_counts, e lookup_range_check_r6_is_u16_counts, e lookup_range_check_r7_is_u16_counts, e lookup_ff_gt_a_lo_range_counts, e lookup_ff_gt_a_hi_range_counts, e lookup_gt_gt_range_counts, e lookup_alu_tag_max_bits_value_counts, e lookup_alu_range_check_decomposition_a_lo_counts, e lookup_alu_range_check_decomposition_a_hi_counts, e lookup_alu_range_check_decomposition_b_lo_counts, e lookup_alu_range_check_decomposition_b_hi_counts, e lookup_alu_range_check_mul_c_hi_counts, e lookup_alu_range_check_div_remainder_counts, e lookup_alu_ff_gt_counts, e lookup_alu_int_gt_counts, e lookup_alu_shifts_two_pow_counts, e lookup_alu_large_trunc_canonical_dec_counts, e lookup_alu_range_check_trunc_mid_counts, e lookup_bitwise_integral_tag_length_counts, e lookup_bitwise_byte_operations_counts, e lookup_memory_range_check_limb_0_counts, e lookup_memory_range_check_limb_1_counts, e lookup_memory_range_check_limb_2_counts, e lookup_memory_tag_max_bits_counts, e lookup_memory_range_check_write_tagged_value_counts, e lookup_data_copy_offset_plus_size_is_gt_data_size_counts, e lookup_data_copy_check_src_addr_in_range_counts, e lookup_data_copy_check_dst_addr_in_range_counts, e lookup_data_copy_sel_has_reads_counts, e lookup_data_copy_col_read_counts, e lookup_ecc_mem_check_dst_addr_in_range_counts, e lookup_ecc_mem_input_output_ecc_add_counts, e lookup_keccakf1600_theta_xor_01_counts, e lookup_keccakf1600_theta_xor_02_counts, e lookup_keccakf1600_theta_xor_03_counts, e lookup_keccakf1600_theta_xor_row_0_counts, e lookup_keccakf1600_theta_xor_11_counts, e lookup_keccakf1600_theta_xor_12_counts, e lookup_keccakf1600_theta_xor_13_counts, e lookup_keccakf1600_theta_xor_row_1_counts, e lookup_keccakf1600_theta_xor_21_counts, e lookup_keccakf1600_theta_xor_22_counts, e lookup_keccakf1600_theta_xor_23_counts, e lookup_keccakf1600_theta_xor_row_2_counts, e lookup_keccakf1600_theta_xor_31_counts, e lookup_keccakf1600_theta_xor_32_counts, e lookup_keccakf1600_theta_xor_33_counts, e lookup_keccakf1600_theta_xor_row_3_counts, e lookup_keccakf1600_theta_xor_41_counts, e lookup_keccakf1600_theta_xor_42_counts, e lookup_keccakf1600_theta_xor_43_counts, e lookup_keccakf1600_theta_xor_row_4_counts, e lookup_keccakf1600_theta_combined_xor_0_counts, e lookup_keccakf1600_theta_combined_xor_1_counts, e lookup_keccakf1600_theta_combined_xor_2_counts, e lookup_keccakf1600_theta_combined_xor_3_counts, e lookup_keccakf1600_theta_combined_xor_4_counts, e lookup_keccakf1600_state_theta_00_counts, e lookup_keccakf1600_state_theta_01_counts, e lookup_keccakf1600_state_theta_02_counts, e lookup_keccakf1600_state_theta_03_counts, e lookup_keccakf1600_state_theta_04_counts, e lookup_keccakf1600_state_theta_10_counts, e lookup_keccakf1600_state_theta_11_counts, e lookup_keccakf1600_state_theta_12_counts, e lookup_keccakf1600_state_theta_13_counts, e lookup_keccakf1600_state_theta_14_counts, e lookup_keccakf1600_state_theta_20_counts, e lookup_keccakf1600_state_theta_21_counts, e lookup_keccakf1600_state_theta_22_counts, e lookup_keccakf1600_state_theta_23_counts, e lookup_keccakf1600_state_theta_24_counts, e lookup_keccakf1600_state_theta_30_counts, e lookup_keccakf1600_state_theta_31_counts, e lookup_keccakf1600_state_theta_32_counts, e lookup_keccakf1600_state_theta_33_counts, e lookup_keccakf1600_state_theta_34_counts, e lookup_keccakf1600_state_theta_40_counts, e lookup_keccakf1600_state_theta_41_counts, e lookup_keccakf1600_state_theta_42_counts, e lookup_keccakf1600_state_theta_43_counts, e lookup_keccakf1600_state_theta_44_counts, e lookup_keccakf1600_theta_limb_02_range_counts, e lookup_keccakf1600_theta_limb_04_range_counts, e lookup_keccakf1600_theta_limb_10_range_counts, e lookup_keccakf1600_theta_limb_12_range_counts, e lookup_keccakf1600_theta_limb_14_range_counts, e lookup_keccakf1600_theta_limb_21_range_counts, e lookup_keccakf1600_theta_limb_23_range_counts, e lookup_keccakf1600_theta_limb_30_range_counts, e lookup_keccakf1600_theta_limb_32_range_counts, e lookup_keccakf1600_theta_limb_33_range_counts, e lookup_keccakf1600_theta_limb_40_range_counts, e lookup_keccakf1600_theta_limb_41_range_counts, e lookup_keccakf1600_theta_limb_43_range_counts, e lookup_keccakf1600_theta_limb_44_range_counts, e lookup_keccakf1600_theta_limb_01_range_counts, e lookup_keccakf1600_theta_limb_03_range_counts, e lookup_keccakf1600_theta_limb_11_range_counts, e lookup_keccakf1600_theta_limb_13_range_counts, e lookup_keccakf1600_theta_limb_20_range_counts, e lookup_keccakf1600_theta_limb_22_range_counts, e lookup_keccakf1600_theta_limb_24_range_counts, e lookup_keccakf1600_theta_limb_31_range_counts, e lookup_keccakf1600_theta_limb_34_range_counts, e lookup_keccakf1600_theta_limb_42_range_counts, e lookup_keccakf1600_state_pi_and_00_counts, e lookup_keccakf1600_state_pi_and_01_counts, e lookup_keccakf1600_state_pi_and_02_counts, e lookup_keccakf1600_state_pi_and_03_counts, e lookup_keccakf1600_state_pi_and_04_counts, e lookup_keccakf1600_state_pi_and_10_counts, e lookup_keccakf1600_state_pi_and_11_counts, e lookup_keccakf1600_state_pi_and_12_counts, e lookup_keccakf1600_state_pi_and_13_counts, e lookup_keccakf1600_state_pi_and_14_counts, e lookup_keccakf1600_state_pi_and_20_counts, e lookup_keccakf1600_state_pi_and_21_counts, e lookup_keccakf1600_state_pi_and_22_counts, e lookup_keccakf1600_state_pi_and_23_counts, e lookup_keccakf1600_state_pi_and_24_counts, e lookup_keccakf1600_state_pi_and_30_counts, e lookup_keccakf1600_state_pi_and_31_counts, e lookup_keccakf1600_state_pi_and_32_counts, e lookup_keccakf1600_state_pi_and_33_counts, e lookup_keccakf1600_state_pi_and_34_counts, e lookup_keccakf1600_state_pi_and_40_counts, e lookup_keccakf1600_state_pi_and_41_counts, e lookup_keccakf1600_state_pi_and_42_counts, e lookup_keccakf1600_state_pi_and_43_counts, e lookup_keccakf1600_state_pi_and_44_counts, e lookup_keccakf1600_state_chi_00_counts, e lookup_keccakf1600_state_chi_01_counts, e lookup_keccakf1600_state_chi_02_counts, e lookup_keccakf1600_state_chi_03_counts, e lookup_keccakf1600_state_chi_04_counts, e lookup_keccakf1600_state_chi_10_counts, e lookup_keccakf1600_state_chi_11_counts, e lookup_keccakf1600_state_chi_12_counts, e lookup_keccakf1600_state_chi_13_counts, e lookup_keccakf1600_state_chi_14_counts, e lookup_keccakf1600_state_chi_20_counts, e lookup_keccakf1600_state_chi_21_counts, e lookup_keccakf1600_state_chi_22_counts, e lookup_keccakf1600_state_chi_23_counts, e lookup_keccakf1600_state_chi_24_counts, e lookup_keccakf1600_state_chi_30_counts, e lookup_keccakf1600_state_chi_31_counts, e lookup_keccakf1600_state_chi_32_counts, e lookup_keccakf1600_state_chi_33_counts, e lookup_keccakf1600_state_chi_34_counts, e lookup_keccakf1600_state_chi_40_counts, e lookup_keccakf1600_state_chi_41_counts, e lookup_keccakf1600_state_chi_42_counts, e lookup_keccakf1600_state_chi_43_counts, e lookup_keccakf1600_state_chi_44_counts, e lookup_keccakf1600_round_cst_counts, e lookup_keccakf1600_state_iota_00_counts, e lookup_keccakf1600_src_out_of_range_toggle_counts, e lookup_keccakf1600_dst_out_of_range_toggle_counts, e lookup_poseidon2_mem_check_src_addr_in_range_counts, e lookup_poseidon2_mem_check_dst_addr_in_range_counts, e lookup_poseidon2_mem_input_output_poseidon2_perm_counts, e lookup_to_radix_limb_range_counts, e lookup_to_radix_limb_less_than_radix_range_counts, e lookup_to_radix_fetch_safe_limbs_counts, e lookup_to_radix_fetch_p_limb_counts, e lookup_to_radix_limb_p_diff_range_counts, e lookup_scalar_mul_to_radix_counts, e lookup_scalar_mul_double_counts, e lookup_scalar_mul_add_counts, e lookup_sha256_range_comp_w_lhs_counts, e lookup_sha256_range_comp_w_rhs_counts, e lookup_sha256_range_rhs_w_7_counts, e lookup_sha256_range_rhs_w_18_counts, e lookup_sha256_range_rhs_w_3_counts, e lookup_sha256_w_s_0_xor_0_counts, e lookup_sha256_w_s_0_xor_1_counts, e lookup_sha256_range_rhs_w_17_counts, e lookup_sha256_range_rhs_w_19_counts, e lookup_sha256_range_rhs_w_10_counts, e lookup_sha256_w_s_1_xor_0_counts, e lookup_sha256_w_s_1_xor_1_counts, e lookup_sha256_range_rhs_e_6_counts, e lookup_sha256_range_rhs_e_11_counts, e lookup_sha256_range_rhs_e_25_counts, e lookup_sha256_s_1_xor_0_counts, e lookup_sha256_s_1_xor_1_counts, e lookup_sha256_ch_and_0_counts, e lookup_sha256_ch_and_1_counts, e lookup_sha256_ch_xor_counts, e lookup_sha256_round_constant_counts, e lookup_sha256_range_rhs_a_2_counts, e lookup_sha256_range_rhs_a_13_counts, e lookup_sha256_range_rhs_a_22_counts, e lookup_sha256_s_0_xor_0_counts, e lookup_sha256_s_0_xor_1_counts, e lookup_sha256_maj_and_0_counts, e lookup_sha256_maj_and_1_counts, e lookup_sha256_maj_and_2_counts, e lookup_sha256_maj_xor_0_counts, e lookup_sha256_maj_xor_1_counts, e lookup_sha256_range_comp_next_a_lhs_counts, e lookup_sha256_range_comp_next_a_rhs_counts, e lookup_sha256_range_comp_next_e_lhs_counts, e lookup_sha256_range_comp_next_e_rhs_counts, e lookup_sha256_range_comp_a_rhs_counts, e lookup_sha256_range_comp_b_rhs_counts, e lookup_sha256_range_comp_c_rhs_counts, e lookup_sha256_range_comp_d_rhs_counts, e lookup_sha256_range_comp_e_rhs_counts, e lookup_sha256_range_comp_f_rhs_counts, e lookup_sha256_range_comp_g_rhs_counts, e lookup_sha256_range_comp_h_rhs_counts, e lookup_sha256_mem_check_state_addr_in_range_counts, e lookup_sha256_mem_check_input_addr_in_range_counts, e lookup_sha256_mem_check_output_addr_in_range_counts, e lookup_to_radix_mem_check_dst_addr_in_range_counts, e lookup_to_radix_mem_check_radix_lt_2_counts, e lookup_to_radix_mem_check_radix_gt_256_counts, e lookup_to_radix_mem_input_output_to_radix_counts, e lookup_poseidon2_hash_poseidon2_perm_counts, e lookup_address_derivation_salted_initialization_hash_poseidon2_0_counts, e lookup_address_derivation_salted_initialization_hash_poseidon2_1_counts, e lookup_address_derivation_partial_address_poseidon2_counts, e lookup_address_derivation_public_keys_hash_poseidon2_0_counts, e lookup_address_derivation_public_keys_hash_poseidon2_1_counts, e lookup_address_derivation_public_keys_hash_poseidon2_2_counts, e lookup_address_derivation_public_keys_hash_poseidon2_3_counts, e lookup_address_derivation_public_keys_hash_poseidon2_4_counts, e lookup_address_derivation_preaddress_poseidon2_counts, e lookup_address_derivation_preaddress_scalar_mul_counts, e lookup_address_derivation_address_ecadd_counts, e lookup_bc_decomposition_bytes_are_bytes_counts, e lookup_bc_hashing_poseidon2_hash_counts, e lookup_merkle_check_merkle_poseidon2_read_counts, e lookup_merkle_check_merkle_poseidon2_write_counts, e lookup_indexed_tree_check_silo_poseidon2_counts, e lookup_indexed_tree_check_low_leaf_value_validation_counts, e lookup_indexed_tree_check_low_leaf_next_value_validation_counts, e lookup_indexed_tree_check_low_leaf_poseidon2_counts, e lookup_indexed_tree_check_updated_low_leaf_poseidon2_counts, e lookup_indexed_tree_check_low_leaf_merkle_check_counts, e lookup_indexed_tree_check_new_leaf_poseidon2_counts, e lookup_indexed_tree_check_new_leaf_merkle_check_counts, e lookup_indexed_tree_check_write_value_to_public_inputs_counts, e lookup_public_data_squash_leaf_slot_increase_ff_gt_counts, e lookup_public_data_squash_clk_diff_range_lo_counts, e lookup_public_data_squash_clk_diff_range_hi_counts, e lookup_public_data_check_clk_diff_range_lo_counts, e lookup_public_data_check_clk_diff_range_hi_counts, e lookup_public_data_check_silo_poseidon2_counts, e lookup_public_data_check_low_leaf_slot_validation_counts, e lookup_public_data_check_low_leaf_next_slot_validation_counts, e lookup_public_data_check_low_leaf_poseidon2_0_counts, e lookup_public_data_check_low_leaf_poseidon2_1_counts, e lookup_public_data_check_updated_low_leaf_poseidon2_0_counts, e lookup_public_data_check_updated_low_leaf_poseidon2_1_counts, e lookup_public_data_check_low_leaf_merkle_check_counts, e lookup_public_data_check_new_leaf_poseidon2_0_counts, e lookup_public_data_check_new_leaf_poseidon2_1_counts, e lookup_public_data_check_new_leaf_merkle_check_counts, e lookup_public_data_check_write_public_data_to_public_inputs_counts, e lookup_public_data_check_write_writes_length_to_public_inputs_counts, e lookup_update_check_timestamp_from_public_inputs_counts, e lookup_update_check_delayed_public_mutable_slot_poseidon2_counts, e lookup_update_check_update_hash_public_data_read_counts, e lookup_update_check_update_hash_poseidon2_counts, e lookup_update_check_update_hi_metadata_range_counts, e lookup_update_check_update_lo_metadata_range_counts, e lookup_update_check_timestamp_is_lt_timestamp_of_change_counts, e lookup_contract_instance_retrieval_check_protocol_address_range_counts, e lookup_contract_instance_retrieval_read_derived_address_from_public_inputs_counts, e lookup_contract_instance_retrieval_deployment_nullifier_read_counts, e lookup_contract_instance_retrieval_address_derivation_counts, e lookup_contract_instance_retrieval_update_check_counts, e lookup_class_id_derivation_class_id_poseidon2_0_counts, e lookup_class_id_derivation_class_id_poseidon2_1_counts, e lookup_bc_retrieval_contract_instance_retrieval_counts, e lookup_bc_retrieval_class_id_derivation_counts, e lookup_bc_retrieval_is_new_class_check_counts, e lookup_bc_retrieval_retrieved_bytecodes_insertion_counts, e lookup_instr_fetching_pc_abs_diff_positive_counts, e lookup_instr_fetching_instr_abs_diff_positive_counts, e lookup_instr_fetching_tag_value_validation_counts, e lookup_instr_fetching_bytecode_size_from_bc_dec_counts, e lookup_instr_fetching_bytes_from_bc_dec_counts, e lookup_instr_fetching_wire_instruction_info_counts, e lookup_emit_public_log_check_memory_out_of_bounds_counts, e lookup_emit_public_log_check_log_fields_count_counts, e lookup_emit_public_log_write_data_to_public_inputs_counts, e lookup_get_contract_instance_precomputed_info_counts, e lookup_get_contract_instance_contract_instance_retrieval_counts, e lookup_l1_to_l2_message_tree_check_merkle_check_counts, e lookup_internal_call_unwind_call_stack_counts, e lookup_context_ctx_stack_rollback_counts, e lookup_context_ctx_stack_return_counts, e lookup_addressing_relative_overflow_result_0_counts, e lookup_addressing_relative_overflow_result_1_counts, e lookup_addressing_relative_overflow_result_2_counts, e lookup_addressing_relative_overflow_result_3_counts, e lookup_addressing_relative_overflow_result_4_counts, e lookup_addressing_relative_overflow_result_5_counts, e lookup_addressing_relative_overflow_result_6_counts, e lookup_gas_addressing_gas_read_counts, e lookup_gas_is_out_of_gas_l2_counts, e lookup_gas_is_out_of_gas_da_counts, e lookup_note_hash_tree_check_silo_poseidon2_counts, e lookup_note_hash_tree_check_read_first_nullifier_counts, e lookup_note_hash_tree_check_nonce_computation_poseidon2_counts, e lookup_note_hash_tree_check_unique_note_hash_poseidon2_counts, e lookup_note_hash_tree_check_merkle_check_counts, e lookup_note_hash_tree_check_write_note_hash_to_public_inputs_counts, e lookup_emit_notehash_notehash_tree_write_counts, e lookup_emit_nullifier_write_nullifier_counts, e lookup_external_call_is_l2_gas_left_gt_allocated_counts, e lookup_external_call_is_da_gas_left_gt_allocated_counts, e lookup_get_env_var_precomputed_info_counts, e lookup_get_env_var_read_from_public_inputs_col0_counts, e lookup_get_env_var_read_from_public_inputs_col1_counts, e lookup_l1_to_l2_message_exists_l1_to_l2_msg_leaf_index_in_range_counts, e lookup_l1_to_l2_message_exists_l1_to_l2_msg_read_counts, e lookup_notehash_exists_note_hash_leaf_index_in_range_counts, e lookup_notehash_exists_note_hash_read_counts, e lookup_nullifier_exists_nullifier_exists_check_counts, e lookup_send_l2_to_l1_msg_recipient_check_counts, e lookup_send_l2_to_l1_msg_write_l2_to_l1_msg_counts, e lookup_sload_storage_read_counts, e lookup_sstore_record_written_storage_slot_counts, e lookup_execution_bytecode_retrieval_result_counts, e lookup_execution_instruction_fetching_result_counts, e lookup_execution_instruction_fetching_body_counts, e lookup_execution_exec_spec_read_counts, e lookup_execution_dyn_l2_factor_bitwise_counts, e lookup_execution_check_radix_gt_256_counts, e lookup_execution_get_p_limbs_counts, e lookup_execution_get_max_limbs_counts, e lookup_execution_check_written_storage_slot_counts, e lookup_execution_dispatch_to_alu_counts, e lookup_execution_dispatch_to_bitwise_counts, e lookup_execution_dispatch_to_cast_counts, e lookup_execution_dispatch_to_set_counts, e lookup_calldata_hashing_get_calldata_field_0_counts, e lookup_calldata_hashing_get_calldata_field_1_counts, e lookup_calldata_hashing_get_calldata_field_2_counts, e lookup_calldata_hashing_poseidon2_hash_counts, e lookup_tx_context_public_inputs_note_hash_tree_counts, e lookup_tx_context_public_inputs_nullifier_tree_counts, e lookup_tx_context_public_inputs_public_data_tree_counts, e lookup_tx_context_public_inputs_l1_l2_tree_counts, e lookup_tx_context_public_inputs_gas_used_counts, e lookup_tx_context_public_inputs_read_gas_limit_counts, e lookup_tx_context_public_inputs_read_reverted_counts, e lookup_tx_context_restore_state_on_revert_counts, e lookup_tx_context_public_inputs_write_note_hash_count_counts, e lookup_tx_context_public_inputs_write_nullifier_count_counts, e lookup_tx_context_public_inputs_write_l2_to_l1_message_count_counts, e lookup_tx_context_public_inputs_write_public_log_count_counts, e lookup_tx_read_phase_spec_counts, e lookup_tx_read_phase_length_counts, e lookup_tx_read_public_call_request_phase_counts, e lookup_tx_read_tree_insert_value_counts, e lookup_tx_note_hash_append_counts, e lookup_tx_nullifier_append_counts, e lookup_tx_read_l2_l1_msg_counts, e lookup_tx_write_l2_l1_msg_counts, e lookup_tx_read_effective_fee_public_inputs_counts, e lookup_tx_read_fee_payer_public_inputs_counts, e lookup_tx_balance_slot_poseidon2_counts, e lookup_tx_balance_read_counts, e lookup_tx_balance_validation_counts, e lookup_tx_write_fee_public_inputs_counts, e bc_decomposition_bytes, e bc_decomposition_bytes_pc_plus_1, e bc_decomposition_bytes_pc_plus_10, e bc_decomposition_bytes_pc_plus_11, e bc_decomposition_bytes_pc_plus_12, e bc_decomposition_bytes_pc_plus_13, e bc_decomposition_bytes_pc_plus_14, e bc_decomposition_bytes_pc_plus_15, e bc_decomposition_bytes_pc_plus_16, e bc_decomposition_bytes_pc_plus_17, e bc_decomposition_bytes_pc_plus_18, e bc_decomposition_bytes_pc_plus_19, e bc_decomposition_bytes_pc_plus_2, e bc_decomposition_bytes_pc_plus_20, e bc_decomposition_bytes_pc_plus_21, e bc_decomposition_bytes_pc_plus_22, e bc_decomposition_bytes_pc_plus_23, e bc_decomposition_bytes_pc_plus_24, e bc_decomposition_bytes_pc_plus_25, e bc_decomposition_bytes_pc_plus_26, e bc_decomposition_bytes_pc_plus_27, e bc_decomposition_bytes_pc_plus_28, e bc_decomposition_bytes_pc_plus_29, e bc_decomposition_bytes_pc_plus_3, e bc_decomposition_bytes_pc_plus_30, e bc_decomposition_bytes_pc_plus_31, e bc_decomposition_bytes_pc_plus_32, e bc_decomposition_bytes_pc_plus_33, e bc_decomposition_bytes_pc_plus_34, e bc_decomposition_bytes_pc_plus_35, e bc_decomposition_bytes_pc_plus_4, e bc_decomposition_bytes_pc_plus_5, e bc_decomposition_bytes_pc_plus_6, e bc_decomposition_bytes_pc_plus_7, e bc_decomposition_bytes_pc_plus_8, e bc_decomposition_bytes_pc_plus_9, e bc_decomposition_bytes_remaining, e bc_decomposition_id, e bc_decomposition_next_packed_pc, e bc_decomposition_pc, e bc_decomposition_sel, e bc_decomposition_sel_windows_gt_remaining, e bc_decomposition_start, e bc_hashing_bytecode_id, e bc_hashing_padding, e bc_hashing_pc_index_1, e bc_hashing_rounds_rem, e bc_hashing_sel, e bc_hashing_sel_not_start, e bc_hashing_start, e bitwise_acc_ia, e bitwise_acc_ib, e bitwise_acc_ic, e bitwise_ctr, e bitwise_op_id, e bitwise_sel, e bitwise_start, e calldata_context_id, e calldata_hashing_calldata_size, e calldata_hashing_context_id, e calldata_hashing_index_0_, e calldata_hashing_output_hash, e calldata_hashing_rounds_rem, e calldata_hashing_sel, e calldata_hashing_start, e calldata_index, e calldata_sel, e data_copy_clk, e data_copy_copy_size, e data_copy_dst_addr, e data_copy_dst_context_id, e data_copy_padding, e data_copy_read_addr, e data_copy_reads_left, e data_copy_sel, e data_copy_sel_cd_copy, e data_copy_src_context_id, e data_copy_start, e emit_public_log_contract_address, e emit_public_log_correct_tag, e emit_public_log_error_out_of_bounds, e emit_public_log_error_tag_mismatch, e emit_public_log_execution_clk, e emit_public_log_is_write_contract_address, e emit_public_log_is_write_memory_value, e emit_public_log_log_address, e emit_public_log_public_inputs_index, e emit_public_log_remaining_rows, e emit_public_log_seen_wrong_tag, e emit_public_log_sel, e emit_public_log_sel_write_to_public_inputs, e emit_public_log_space_id, e emit_public_log_start, e execution_bytecode_id, e execution_clk, e execution_context_id, e execution_contract_address, e execution_da_gas_limit, e execution_discard, e execution_dying_context_id, e execution_enqueued_call_start, e execution_internal_call_id, e execution_internal_call_return_id, e execution_is_static, e execution_l1_l2_tree_root, e execution_l2_gas_limit, e execution_last_child_id, e execution_last_child_returndata_addr, e execution_last_child_returndata_size, e execution_last_child_success, e execution_msg_sender, e execution_next_context_id, e execution_next_internal_call_id, e execution_parent_calldata_addr, e execution_parent_calldata_size, e execution_parent_da_gas_limit, e execution_parent_da_gas_used, e execution_parent_id, e execution_parent_l2_gas_limit, e execution_parent_l2_gas_used, e execution_pc, e execution_prev_da_gas_used, e execution_prev_l2_gas_used, e execution_prev_note_hash_tree_root, e execution_prev_note_hash_tree_size, e execution_prev_nullifier_tree_root, e execution_prev_nullifier_tree_size, e execution_prev_num_l2_to_l1_messages, e execution_prev_num_note_hashes_emitted, e execution_prev_num_nullifiers_emitted, e execution_prev_num_public_log_fields, e execution_prev_public_data_tree_root, e execution_prev_public_data_tree_size, e execution_prev_retrieved_bytecodes_tree_root, e execution_prev_retrieved_bytecodes_tree_size, e execution_prev_written_public_data_slots_tree_root, e execution_prev_written_public_data_slots_tree_size, e execution_sel, e execution_sel_first_row_in_context, e execution_transaction_fee, e ff_gt_a_hi, e ff_gt_a_lo, e ff_gt_b_hi, e ff_gt_b_lo, e ff_gt_cmp_rng_ctr, e ff_gt_p_sub_a_hi, e ff_gt_p_sub_a_lo, e ff_gt_p_sub_b_hi, e ff_gt_p_sub_b_lo, e ff_gt_sel, e ff_gt_sel_dec, e ff_gt_sel_gt, e keccak_memory_addr, e keccak_memory_clk, e keccak_memory_ctr, e keccak_memory_rw, e keccak_memory_sel, e keccak_memory_space_id, e keccak_memory_start_read, e keccak_memory_start_write, e keccak_memory_tag_error, e keccak_memory_val_0_, e keccak_memory_val_10_, e keccak_memory_val_11_, e keccak_memory_val_12_, e keccak_memory_val_13_, e keccak_memory_val_14_, e keccak_memory_val_15_, e keccak_memory_val_16_, e keccak_memory_val_17_, e keccak_memory_val_18_, e keccak_memory_val_19_, e keccak_memory_val_1_, e keccak_memory_val_20_, e keccak_memory_val_21_, e keccak_memory_val_22_, e keccak_memory_val_23_, e keccak_memory_val_2_, e keccak_memory_val_3_, e keccak_memory_val_4_, e keccak_memory_val_5_, e keccak_memory_val_6_, e keccak_memory_val_7_, e keccak_memory_val_8_, e keccak_memory_val_9_, e keccakf1600_clk, e keccakf1600_dst_addr, e keccakf1600_round, e keccakf1600_sel, e keccakf1600_sel_no_error, e keccakf1600_space_id, e keccakf1600_start, e keccakf1600_state_in_00, e keccakf1600_state_in_01, e keccakf1600_state_in_02, e keccakf1600_state_in_03, e keccakf1600_state_in_04, e keccakf1600_state_in_10, e keccakf1600_state_in_11, e keccakf1600_state_in_12, e keccakf1600_state_in_13, e keccakf1600_state_in_14, e keccakf1600_state_in_20, e keccakf1600_state_in_21, e keccakf1600_state_in_22, e keccakf1600_state_in_23, e keccakf1600_state_in_24, e keccakf1600_state_in_30, e keccakf1600_state_in_31, e keccakf1600_state_in_32, e keccakf1600_state_in_33, e keccakf1600_state_in_34, e keccakf1600_state_in_40, e keccakf1600_state_in_41, e keccakf1600_state_in_42, e keccakf1600_state_in_43, e keccakf1600_state_in_44, e memory_address, e memory_clk, e memory_rw, e memory_sel, e memory_space_id, e memory_tag, e memory_value, e merkle_check_index, e merkle_check_merkle_hash_separator, e merkle_check_path_len, e merkle_check_read_node, e merkle_check_read_root, e merkle_check_sel, e merkle_check_start, e merkle_check_write, e merkle_check_write_node, e merkle_check_write_root, e poseidon2_hash_a_0, e poseidon2_hash_a_1, e poseidon2_hash_a_2, e poseidon2_hash_a_3, e poseidon2_hash_input_0, e poseidon2_hash_input_1, e poseidon2_hash_input_2, e poseidon2_hash_num_perm_rounds_rem, e poseidon2_hash_output, e poseidon2_hash_sel, e poseidon2_hash_start, e public_data_check_clk, e public_data_check_sel, e public_data_check_write_idx, e public_data_squash_clk, e public_data_squash_final_value, e public_data_squash_leaf_slot, e public_data_squash_sel, e public_data_squash_write_to_public_inputs, e scalar_mul_bit_idx, e scalar_mul_point_inf, e scalar_mul_point_x, e scalar_mul_point_y, e scalar_mul_res_inf, e scalar_mul_res_x, e scalar_mul_res_y, e scalar_mul_scalar, e scalar_mul_sel, e scalar_mul_start, e scalar_mul_temp_inf, e scalar_mul_temp_x, e scalar_mul_temp_y, e sha256_a, e sha256_b, e sha256_c, e sha256_d, e sha256_e, e sha256_execution_clk, e sha256_f, e sha256_g, e sha256_h, e sha256_helper_w0, e sha256_helper_w1, e sha256_helper_w10, e sha256_helper_w11, e sha256_helper_w12, e sha256_helper_w13, e sha256_helper_w14, e sha256_helper_w15, e sha256_helper_w2, e sha256_helper_w3, e sha256_helper_w4, e sha256_helper_w5, e sha256_helper_w6, e sha256_helper_w7, e sha256_helper_w8, e sha256_helper_w9, e sha256_init_a, e sha256_init_b, e sha256_init_c, e sha256_init_d, e sha256_init_e, e sha256_init_f, e sha256_init_g, e sha256_init_h, e sha256_input_addr, e sha256_input_rounds_rem, e sha256_output_addr, e sha256_rounds_remaining, e sha256_sel, e sha256_sel_invalid_input_tag_err, e sha256_space_id, e sha256_start, e to_radix_acc, e to_radix_acc_under_p, e to_radix_limb, e to_radix_limb_eq_p, e to_radix_limb_index, e to_radix_limb_lt_p, e to_radix_mem_dst_addr, e to_radix_mem_execution_clk, e to_radix_mem_is_output_bits, e to_radix_mem_num_limbs, e to_radix_mem_radix, e to_radix_mem_sel, e to_radix_mem_sel_should_decompose, e to_radix_mem_sel_should_write_mem, e to_radix_mem_space_id, e to_radix_mem_start, e to_radix_mem_value_to_decompose, e to_radix_not_padding_limb, e to_radix_power, e to_radix_radix, e to_radix_safe_limbs, e to_radix_sel, e to_radix_start, e to_radix_value, e tx_da_gas_limit, e tx_discard, e tx_fee, e tx_is_revertible, e tx_is_teardown, e tx_l1_l2_tree_root, e tx_l1_l2_tree_size, e tx_l2_gas_limit, e tx_next_context_id, e tx_phase_value, e tx_prev_da_gas_used, e tx_prev_l2_gas_used, e tx_prev_note_hash_tree_root, e tx_prev_note_hash_tree_size, e tx_prev_nullifier_tree_root, e tx_prev_nullifier_tree_size, e tx_prev_num_l2_to_l1_messages, e tx_prev_num_note_hashes_emitted, e tx_prev_num_nullifiers_emitted, e tx_prev_num_public_log_fields, e tx_prev_public_data_tree_root, e tx_prev_public_data_tree_size, e tx_prev_retrieved_bytecodes_tree_root, e tx_prev_retrieved_bytecodes_tree_size, e tx_prev_written_public_data_slots_tree_root, e tx_prev_written_public_data_slots_tree_size, e tx_read_pi_offset, e tx_remaining_phase_counter, e tx_reverted, e tx_sel, e tx_start_phase, e tx_start_tx, e tx_tx_reverted +#define AVM2_DERIVED_WITNESS_ENTITIES_E(e) e perm_data_copy_mem_write_inv, e perm_data_copy_mem_read_inv, e perm_ecc_mem_write_mem_0_inv, e perm_ecc_mem_write_mem_1_inv, e perm_ecc_mem_write_mem_2_inv, e perm_keccak_memory_slice_to_mem_inv, e perm_keccakf1600_read_to_slice_inv, e perm_keccakf1600_write_to_slice_inv, e perm_poseidon2_mem_pos_read_mem_0_inv, e perm_poseidon2_mem_pos_read_mem_1_inv, e perm_poseidon2_mem_pos_read_mem_2_inv, e perm_poseidon2_mem_pos_read_mem_3_inv, e perm_poseidon2_mem_pos_write_mem_0_inv, e perm_poseidon2_mem_pos_write_mem_1_inv, e perm_poseidon2_mem_pos_write_mem_2_inv, e perm_poseidon2_mem_pos_write_mem_3_inv, e perm_sha256_mem_mem_op_0_inv, e perm_sha256_mem_mem_op_1_inv, e perm_sha256_mem_mem_op_2_inv, e perm_sha256_mem_mem_op_3_inv, e perm_sha256_mem_mem_op_4_inv, e perm_sha256_mem_mem_op_5_inv, e perm_sha256_mem_mem_op_6_inv, e perm_sha256_mem_mem_op_7_inv, e perm_sha256_mem_mem_input_read_inv, e perm_to_radix_mem_write_mem_inv, e perm_bc_hashing_bytecode_length_bytes_inv, e perm_bc_hashing_get_packed_field_0_inv, e perm_bc_hashing_get_packed_field_1_inv, e perm_bc_hashing_get_packed_field_2_inv, e perm_public_data_check_squashing_inv, e perm_emit_public_log_read_mem_inv, e perm_get_contract_instance_mem_write_contract_instance_exists_inv, e perm_get_contract_instance_mem_write_contract_instance_member_inv, e perm_internal_call_push_call_stack_inv, e perm_context_ctx_stack_call_inv, e perm_addressing_base_address_from_memory_inv, e perm_addressing_indirect_from_memory_0_inv, e perm_addressing_indirect_from_memory_1_inv, e perm_addressing_indirect_from_memory_2_inv, e perm_addressing_indirect_from_memory_3_inv, e perm_addressing_indirect_from_memory_4_inv, e perm_addressing_indirect_from_memory_5_inv, e perm_addressing_indirect_from_memory_6_inv, e perm_registers_mem_op_0_inv, e perm_registers_mem_op_1_inv, e perm_registers_mem_op_2_inv, e perm_registers_mem_op_3_inv, e perm_registers_mem_op_4_inv, e perm_registers_mem_op_5_inv, e perm_sstore_storage_write_inv, e perm_execution_dispatch_to_cd_copy_inv, e perm_execution_dispatch_to_rd_copy_inv, e perm_execution_dispatch_to_get_contract_instance_inv, e perm_execution_dispatch_to_emit_public_log_inv, e perm_execution_dispatch_to_poseidon2_perm_inv, e perm_execution_dispatch_to_sha256_compression_inv, e perm_execution_dispatch_to_keccakf1600_inv, e perm_execution_dispatch_to_ecc_add_inv, e perm_execution_dispatch_to_to_radix_inv, e perm_calldata_hashing_check_final_size_inv, e perm_tx_read_calldata_hash_inv, e perm_tx_dispatch_exec_start_inv, e perm_tx_dispatch_exec_end_inv, e perm_tx_balance_update_inv, e lookup_range_check_dyn_rng_chk_pow_2_inv, e lookup_range_check_dyn_diff_is_u16_inv, e lookup_range_check_r0_is_u16_inv, e lookup_range_check_r1_is_u16_inv, e lookup_range_check_r2_is_u16_inv, e lookup_range_check_r3_is_u16_inv, e lookup_range_check_r4_is_u16_inv, e lookup_range_check_r5_is_u16_inv, e lookup_range_check_r6_is_u16_inv, e lookup_range_check_r7_is_u16_inv, e lookup_ff_gt_a_lo_range_inv, e lookup_ff_gt_a_hi_range_inv, e lookup_gt_gt_range_inv, e lookup_alu_tag_max_bits_value_inv, e lookup_alu_range_check_decomposition_a_lo_inv, e lookup_alu_range_check_decomposition_a_hi_inv, e lookup_alu_range_check_decomposition_b_lo_inv, e lookup_alu_range_check_decomposition_b_hi_inv, e lookup_alu_range_check_mul_c_hi_inv, e lookup_alu_range_check_div_remainder_inv, e lookup_alu_ff_gt_inv, e lookup_alu_int_gt_inv, e lookup_alu_shifts_two_pow_inv, e lookup_alu_large_trunc_canonical_dec_inv, e lookup_alu_range_check_trunc_mid_inv, e lookup_bitwise_integral_tag_length_inv, e lookup_bitwise_byte_operations_inv, e lookup_memory_range_check_limb_0_inv, e lookup_memory_range_check_limb_1_inv, e lookup_memory_range_check_limb_2_inv, e lookup_memory_tag_max_bits_inv, e lookup_memory_range_check_write_tagged_value_inv, e lookup_data_copy_offset_plus_size_is_gt_data_size_inv, e lookup_data_copy_check_src_addr_in_range_inv, e lookup_data_copy_check_dst_addr_in_range_inv, e lookup_data_copy_sel_has_reads_inv, e lookup_data_copy_col_read_inv, e lookup_ecc_mem_check_dst_addr_in_range_inv, e lookup_ecc_mem_input_output_ecc_add_inv, e lookup_keccakf1600_theta_xor_01_inv, e lookup_keccakf1600_theta_xor_02_inv, e lookup_keccakf1600_theta_xor_03_inv, e lookup_keccakf1600_theta_xor_row_0_inv, e lookup_keccakf1600_theta_xor_11_inv, e lookup_keccakf1600_theta_xor_12_inv, e lookup_keccakf1600_theta_xor_13_inv, e lookup_keccakf1600_theta_xor_row_1_inv, e lookup_keccakf1600_theta_xor_21_inv, e lookup_keccakf1600_theta_xor_22_inv, e lookup_keccakf1600_theta_xor_23_inv, e lookup_keccakf1600_theta_xor_row_2_inv, e lookup_keccakf1600_theta_xor_31_inv, e lookup_keccakf1600_theta_xor_32_inv, e lookup_keccakf1600_theta_xor_33_inv, e lookup_keccakf1600_theta_xor_row_3_inv, e lookup_keccakf1600_theta_xor_41_inv, e lookup_keccakf1600_theta_xor_42_inv, e lookup_keccakf1600_theta_xor_43_inv, e lookup_keccakf1600_theta_xor_row_4_inv, e lookup_keccakf1600_theta_combined_xor_0_inv, e lookup_keccakf1600_theta_combined_xor_1_inv, e lookup_keccakf1600_theta_combined_xor_2_inv, e lookup_keccakf1600_theta_combined_xor_3_inv, e lookup_keccakf1600_theta_combined_xor_4_inv, e lookup_keccakf1600_state_theta_00_inv, e lookup_keccakf1600_state_theta_01_inv, e lookup_keccakf1600_state_theta_02_inv, e lookup_keccakf1600_state_theta_03_inv, e lookup_keccakf1600_state_theta_04_inv, e lookup_keccakf1600_state_theta_10_inv, e lookup_keccakf1600_state_theta_11_inv, e lookup_keccakf1600_state_theta_12_inv, e lookup_keccakf1600_state_theta_13_inv, e lookup_keccakf1600_state_theta_14_inv, e lookup_keccakf1600_state_theta_20_inv, e lookup_keccakf1600_state_theta_21_inv, e lookup_keccakf1600_state_theta_22_inv, e lookup_keccakf1600_state_theta_23_inv, e lookup_keccakf1600_state_theta_24_inv, e lookup_keccakf1600_state_theta_30_inv, e lookup_keccakf1600_state_theta_31_inv, e lookup_keccakf1600_state_theta_32_inv, e lookup_keccakf1600_state_theta_33_inv, e lookup_keccakf1600_state_theta_34_inv, e lookup_keccakf1600_state_theta_40_inv, e lookup_keccakf1600_state_theta_41_inv, e lookup_keccakf1600_state_theta_42_inv, e lookup_keccakf1600_state_theta_43_inv, e lookup_keccakf1600_state_theta_44_inv, e lookup_keccakf1600_theta_limb_02_range_inv, e lookup_keccakf1600_theta_limb_04_range_inv, e lookup_keccakf1600_theta_limb_10_range_inv, e lookup_keccakf1600_theta_limb_12_range_inv, e lookup_keccakf1600_theta_limb_14_range_inv, e lookup_keccakf1600_theta_limb_21_range_inv, e lookup_keccakf1600_theta_limb_23_range_inv, e lookup_keccakf1600_theta_limb_30_range_inv, e lookup_keccakf1600_theta_limb_32_range_inv, e lookup_keccakf1600_theta_limb_33_range_inv, e lookup_keccakf1600_theta_limb_40_range_inv, e lookup_keccakf1600_theta_limb_41_range_inv, e lookup_keccakf1600_theta_limb_43_range_inv, e lookup_keccakf1600_theta_limb_44_range_inv, e lookup_keccakf1600_theta_limb_01_range_inv, e lookup_keccakf1600_theta_limb_03_range_inv, e lookup_keccakf1600_theta_limb_11_range_inv, e lookup_keccakf1600_theta_limb_13_range_inv, e lookup_keccakf1600_theta_limb_20_range_inv, e lookup_keccakf1600_theta_limb_22_range_inv, e lookup_keccakf1600_theta_limb_24_range_inv, e lookup_keccakf1600_theta_limb_31_range_inv, e lookup_keccakf1600_theta_limb_34_range_inv, e lookup_keccakf1600_theta_limb_42_range_inv, e lookup_keccakf1600_state_pi_and_00_inv, e lookup_keccakf1600_state_pi_and_01_inv, e lookup_keccakf1600_state_pi_and_02_inv, e lookup_keccakf1600_state_pi_and_03_inv, e lookup_keccakf1600_state_pi_and_04_inv, e lookup_keccakf1600_state_pi_and_10_inv, e lookup_keccakf1600_state_pi_and_11_inv, e lookup_keccakf1600_state_pi_and_12_inv, e lookup_keccakf1600_state_pi_and_13_inv, e lookup_keccakf1600_state_pi_and_14_inv, e lookup_keccakf1600_state_pi_and_20_inv, e lookup_keccakf1600_state_pi_and_21_inv, e lookup_keccakf1600_state_pi_and_22_inv, e lookup_keccakf1600_state_pi_and_23_inv, e lookup_keccakf1600_state_pi_and_24_inv, e lookup_keccakf1600_state_pi_and_30_inv, e lookup_keccakf1600_state_pi_and_31_inv, e lookup_keccakf1600_state_pi_and_32_inv, e lookup_keccakf1600_state_pi_and_33_inv, e lookup_keccakf1600_state_pi_and_34_inv, e lookup_keccakf1600_state_pi_and_40_inv, e lookup_keccakf1600_state_pi_and_41_inv, e lookup_keccakf1600_state_pi_and_42_inv, e lookup_keccakf1600_state_pi_and_43_inv, e lookup_keccakf1600_state_pi_and_44_inv, e lookup_keccakf1600_state_chi_00_inv, e lookup_keccakf1600_state_chi_01_inv, e lookup_keccakf1600_state_chi_02_inv, e lookup_keccakf1600_state_chi_03_inv, e lookup_keccakf1600_state_chi_04_inv, e lookup_keccakf1600_state_chi_10_inv, e lookup_keccakf1600_state_chi_11_inv, e lookup_keccakf1600_state_chi_12_inv, e lookup_keccakf1600_state_chi_13_inv, e lookup_keccakf1600_state_chi_14_inv, e lookup_keccakf1600_state_chi_20_inv, e lookup_keccakf1600_state_chi_21_inv, e lookup_keccakf1600_state_chi_22_inv, e lookup_keccakf1600_state_chi_23_inv, e lookup_keccakf1600_state_chi_24_inv, e lookup_keccakf1600_state_chi_30_inv, e lookup_keccakf1600_state_chi_31_inv, e lookup_keccakf1600_state_chi_32_inv, e lookup_keccakf1600_state_chi_33_inv, e lookup_keccakf1600_state_chi_34_inv, e lookup_keccakf1600_state_chi_40_inv, e lookup_keccakf1600_state_chi_41_inv, e lookup_keccakf1600_state_chi_42_inv, e lookup_keccakf1600_state_chi_43_inv, e lookup_keccakf1600_state_chi_44_inv, e lookup_keccakf1600_round_cst_inv, e lookup_keccakf1600_state_iota_00_inv, e lookup_keccakf1600_src_out_of_range_toggle_inv, e lookup_keccakf1600_dst_out_of_range_toggle_inv, e lookup_poseidon2_mem_check_src_addr_in_range_inv, e lookup_poseidon2_mem_check_dst_addr_in_range_inv, e lookup_poseidon2_mem_input_output_poseidon2_perm_inv, e lookup_to_radix_limb_range_inv, e lookup_to_radix_limb_less_than_radix_range_inv, e lookup_to_radix_fetch_safe_limbs_inv, e lookup_to_radix_fetch_p_limb_inv, e lookup_to_radix_limb_p_diff_range_inv, e lookup_scalar_mul_to_radix_inv, e lookup_scalar_mul_double_inv, e lookup_scalar_mul_add_inv, e lookup_sha256_range_comp_w_lhs_inv, e lookup_sha256_range_comp_w_rhs_inv, e lookup_sha256_range_rhs_w_7_inv, e lookup_sha256_range_rhs_w_18_inv, e lookup_sha256_range_rhs_w_3_inv, e lookup_sha256_w_s_0_xor_0_inv, e lookup_sha256_w_s_0_xor_1_inv, e lookup_sha256_range_rhs_w_17_inv, e lookup_sha256_range_rhs_w_19_inv, e lookup_sha256_range_rhs_w_10_inv, e lookup_sha256_w_s_1_xor_0_inv, e lookup_sha256_w_s_1_xor_1_inv, e lookup_sha256_range_rhs_e_6_inv, e lookup_sha256_range_rhs_e_11_inv, e lookup_sha256_range_rhs_e_25_inv, e lookup_sha256_s_1_xor_0_inv, e lookup_sha256_s_1_xor_1_inv, e lookup_sha256_ch_and_0_inv, e lookup_sha256_ch_and_1_inv, e lookup_sha256_ch_xor_inv, e lookup_sha256_round_constant_inv, e lookup_sha256_range_rhs_a_2_inv, e lookup_sha256_range_rhs_a_13_inv, e lookup_sha256_range_rhs_a_22_inv, e lookup_sha256_s_0_xor_0_inv, e lookup_sha256_s_0_xor_1_inv, e lookup_sha256_maj_and_0_inv, e lookup_sha256_maj_and_1_inv, e lookup_sha256_maj_and_2_inv, e lookup_sha256_maj_xor_0_inv, e lookup_sha256_maj_xor_1_inv, e lookup_sha256_range_comp_next_a_lhs_inv, e lookup_sha256_range_comp_next_a_rhs_inv, e lookup_sha256_range_comp_next_e_lhs_inv, e lookup_sha256_range_comp_next_e_rhs_inv, e lookup_sha256_range_comp_a_rhs_inv, e lookup_sha256_range_comp_b_rhs_inv, e lookup_sha256_range_comp_c_rhs_inv, e lookup_sha256_range_comp_d_rhs_inv, e lookup_sha256_range_comp_e_rhs_inv, e lookup_sha256_range_comp_f_rhs_inv, e lookup_sha256_range_comp_g_rhs_inv, e lookup_sha256_range_comp_h_rhs_inv, e lookup_sha256_mem_check_state_addr_in_range_inv, e lookup_sha256_mem_check_input_addr_in_range_inv, e lookup_sha256_mem_check_output_addr_in_range_inv, e lookup_to_radix_mem_check_dst_addr_in_range_inv, e lookup_to_radix_mem_check_radix_lt_2_inv, e lookup_to_radix_mem_check_radix_gt_256_inv, e lookup_to_radix_mem_input_output_to_radix_inv, e lookup_poseidon2_hash_poseidon2_perm_inv, e lookup_address_derivation_salted_initialization_hash_poseidon2_0_inv, e lookup_address_derivation_salted_initialization_hash_poseidon2_1_inv, e lookup_address_derivation_partial_address_poseidon2_inv, e lookup_address_derivation_public_keys_hash_poseidon2_0_inv, e lookup_address_derivation_public_keys_hash_poseidon2_1_inv, e lookup_address_derivation_public_keys_hash_poseidon2_2_inv, e lookup_address_derivation_public_keys_hash_poseidon2_3_inv, e lookup_address_derivation_public_keys_hash_poseidon2_4_inv, e lookup_address_derivation_preaddress_poseidon2_inv, e lookup_address_derivation_preaddress_scalar_mul_inv, e lookup_address_derivation_address_ecadd_inv, e lookup_bc_decomposition_bytes_are_bytes_inv, e lookup_bc_hashing_poseidon2_hash_inv, e lookup_merkle_check_merkle_poseidon2_read_inv, e lookup_merkle_check_merkle_poseidon2_write_inv, e lookup_indexed_tree_check_silo_poseidon2_inv, e lookup_indexed_tree_check_low_leaf_value_validation_inv, e lookup_indexed_tree_check_low_leaf_next_value_validation_inv, e lookup_indexed_tree_check_low_leaf_poseidon2_inv, e lookup_indexed_tree_check_updated_low_leaf_poseidon2_inv, e lookup_indexed_tree_check_low_leaf_merkle_check_inv, e lookup_indexed_tree_check_new_leaf_poseidon2_inv, e lookup_indexed_tree_check_new_leaf_merkle_check_inv, e lookup_indexed_tree_check_write_value_to_public_inputs_inv, e lookup_public_data_squash_leaf_slot_increase_ff_gt_inv, e lookup_public_data_squash_clk_diff_range_lo_inv, e lookup_public_data_squash_clk_diff_range_hi_inv, e lookup_public_data_check_clk_diff_range_lo_inv, e lookup_public_data_check_clk_diff_range_hi_inv, e lookup_public_data_check_silo_poseidon2_inv, e lookup_public_data_check_low_leaf_slot_validation_inv, e lookup_public_data_check_low_leaf_next_slot_validation_inv, e lookup_public_data_check_low_leaf_poseidon2_0_inv, e lookup_public_data_check_low_leaf_poseidon2_1_inv, e lookup_public_data_check_updated_low_leaf_poseidon2_0_inv, e lookup_public_data_check_updated_low_leaf_poseidon2_1_inv, e lookup_public_data_check_low_leaf_merkle_check_inv, e lookup_public_data_check_new_leaf_poseidon2_0_inv, e lookup_public_data_check_new_leaf_poseidon2_1_inv, e lookup_public_data_check_new_leaf_merkle_check_inv, e lookup_public_data_check_write_public_data_to_public_inputs_inv, e lookup_public_data_check_write_writes_length_to_public_inputs_inv, e lookup_update_check_timestamp_from_public_inputs_inv, e lookup_update_check_delayed_public_mutable_slot_poseidon2_inv, e lookup_update_check_update_hash_public_data_read_inv, e lookup_update_check_update_hash_poseidon2_inv, e lookup_update_check_update_hi_metadata_range_inv, e lookup_update_check_update_lo_metadata_range_inv, e lookup_update_check_timestamp_is_lt_timestamp_of_change_inv, e lookup_contract_instance_retrieval_check_protocol_address_range_inv, e lookup_contract_instance_retrieval_read_derived_address_from_public_inputs_inv, e lookup_contract_instance_retrieval_deployment_nullifier_read_inv, e lookup_contract_instance_retrieval_address_derivation_inv, e lookup_contract_instance_retrieval_update_check_inv, e lookup_class_id_derivation_class_id_poseidon2_0_inv, e lookup_class_id_derivation_class_id_poseidon2_1_inv, e lookup_bc_retrieval_contract_instance_retrieval_inv, e lookup_bc_retrieval_class_id_derivation_inv, e lookup_bc_retrieval_is_new_class_check_inv, e lookup_bc_retrieval_retrieved_bytecodes_insertion_inv, e lookup_instr_fetching_pc_abs_diff_positive_inv, e lookup_instr_fetching_instr_abs_diff_positive_inv, e lookup_instr_fetching_tag_value_validation_inv, e lookup_instr_fetching_bytecode_size_from_bc_dec_inv, e lookup_instr_fetching_bytes_from_bc_dec_inv, e lookup_instr_fetching_wire_instruction_info_inv, e lookup_emit_public_log_check_memory_out_of_bounds_inv, e lookup_emit_public_log_check_log_fields_count_inv, e lookup_emit_public_log_write_data_to_public_inputs_inv, e lookup_get_contract_instance_precomputed_info_inv, e lookup_get_contract_instance_contract_instance_retrieval_inv, e lookup_l1_to_l2_message_tree_check_merkle_check_inv, e lookup_internal_call_unwind_call_stack_inv, e lookup_context_ctx_stack_rollback_inv, e lookup_context_ctx_stack_return_inv, e lookup_addressing_relative_overflow_result_0_inv, e lookup_addressing_relative_overflow_result_1_inv, e lookup_addressing_relative_overflow_result_2_inv, e lookup_addressing_relative_overflow_result_3_inv, e lookup_addressing_relative_overflow_result_4_inv, e lookup_addressing_relative_overflow_result_5_inv, e lookup_addressing_relative_overflow_result_6_inv, e lookup_gas_addressing_gas_read_inv, e lookup_gas_is_out_of_gas_l2_inv, e lookup_gas_is_out_of_gas_da_inv, e lookup_note_hash_tree_check_silo_poseidon2_inv, e lookup_note_hash_tree_check_read_first_nullifier_inv, e lookup_note_hash_tree_check_nonce_computation_poseidon2_inv, e lookup_note_hash_tree_check_unique_note_hash_poseidon2_inv, e lookup_note_hash_tree_check_merkle_check_inv, e lookup_note_hash_tree_check_write_note_hash_to_public_inputs_inv, e lookup_emit_notehash_notehash_tree_write_inv, e lookup_emit_nullifier_write_nullifier_inv, e lookup_external_call_is_l2_gas_left_gt_allocated_inv, e lookup_external_call_is_da_gas_left_gt_allocated_inv, e lookup_get_env_var_precomputed_info_inv, e lookup_get_env_var_read_from_public_inputs_col0_inv, e lookup_get_env_var_read_from_public_inputs_col1_inv, e lookup_l1_to_l2_message_exists_l1_to_l2_msg_leaf_index_in_range_inv, e lookup_l1_to_l2_message_exists_l1_to_l2_msg_read_inv, e lookup_notehash_exists_note_hash_leaf_index_in_range_inv, e lookup_notehash_exists_note_hash_read_inv, e lookup_nullifier_exists_nullifier_exists_check_inv, e lookup_send_l2_to_l1_msg_recipient_check_inv, e lookup_send_l2_to_l1_msg_write_l2_to_l1_msg_inv, e lookup_sload_storage_read_inv, e lookup_sstore_record_written_storage_slot_inv, e lookup_execution_bytecode_retrieval_result_inv, e lookup_execution_instruction_fetching_result_inv, e lookup_execution_instruction_fetching_body_inv, e lookup_execution_exec_spec_read_inv, e lookup_execution_dyn_l2_factor_bitwise_inv, e lookup_execution_check_radix_gt_256_inv, e lookup_execution_get_p_limbs_inv, e lookup_execution_get_max_limbs_inv, e lookup_execution_check_written_storage_slot_inv, e lookup_execution_dispatch_to_alu_inv, e lookup_execution_dispatch_to_bitwise_inv, e lookup_execution_dispatch_to_cast_inv, e lookup_execution_dispatch_to_set_inv, e lookup_calldata_hashing_get_calldata_field_0_inv, e lookup_calldata_hashing_get_calldata_field_1_inv, e lookup_calldata_hashing_get_calldata_field_2_inv, e lookup_calldata_hashing_poseidon2_hash_inv, e lookup_tx_context_public_inputs_note_hash_tree_inv, e lookup_tx_context_public_inputs_nullifier_tree_inv, e lookup_tx_context_public_inputs_public_data_tree_inv, e lookup_tx_context_public_inputs_l1_l2_tree_inv, e lookup_tx_context_public_inputs_gas_used_inv, e lookup_tx_context_public_inputs_read_gas_limit_inv, e lookup_tx_context_public_inputs_read_reverted_inv, e lookup_tx_context_restore_state_on_revert_inv, e lookup_tx_context_public_inputs_write_note_hash_count_inv, e lookup_tx_context_public_inputs_write_nullifier_count_inv, e lookup_tx_context_public_inputs_write_l2_to_l1_message_count_inv, e lookup_tx_context_public_inputs_write_public_log_count_inv, e lookup_tx_read_phase_spec_inv, e lookup_tx_read_phase_length_inv, e lookup_tx_read_public_call_request_phase_inv, e lookup_tx_read_tree_insert_value_inv, e lookup_tx_note_hash_append_inv, e lookup_tx_nullifier_append_inv, e lookup_tx_read_l2_l1_msg_inv, e lookup_tx_write_l2_l1_msg_inv, e lookup_tx_read_effective_fee_public_inputs_inv, e lookup_tx_read_fee_payer_public_inputs_inv, e lookup_tx_balance_slot_poseidon2_inv, e lookup_tx_balance_read_inv, e lookup_tx_balance_validation_inv, e lookup_tx_write_fee_public_inputs_inv #define AVM2_SHIFTED_ENTITIES_E(e) e bc_decomposition_bytes_shift, e bc_decomposition_bytes_pc_plus_1_shift, e bc_decomposition_bytes_pc_plus_10_shift, e bc_decomposition_bytes_pc_plus_11_shift, e bc_decomposition_bytes_pc_plus_12_shift, e bc_decomposition_bytes_pc_plus_13_shift, e bc_decomposition_bytes_pc_plus_14_shift, e bc_decomposition_bytes_pc_plus_15_shift, e bc_decomposition_bytes_pc_plus_16_shift, e bc_decomposition_bytes_pc_plus_17_shift, e bc_decomposition_bytes_pc_plus_18_shift, e bc_decomposition_bytes_pc_plus_19_shift, e bc_decomposition_bytes_pc_plus_2_shift, e bc_decomposition_bytes_pc_plus_20_shift, e bc_decomposition_bytes_pc_plus_21_shift, e bc_decomposition_bytes_pc_plus_22_shift, e bc_decomposition_bytes_pc_plus_23_shift, e bc_decomposition_bytes_pc_plus_24_shift, e bc_decomposition_bytes_pc_plus_25_shift, e bc_decomposition_bytes_pc_plus_26_shift, e bc_decomposition_bytes_pc_plus_27_shift, e bc_decomposition_bytes_pc_plus_28_shift, e bc_decomposition_bytes_pc_plus_29_shift, e bc_decomposition_bytes_pc_plus_3_shift, e bc_decomposition_bytes_pc_plus_30_shift, e bc_decomposition_bytes_pc_plus_31_shift, e bc_decomposition_bytes_pc_plus_32_shift, e bc_decomposition_bytes_pc_plus_33_shift, e bc_decomposition_bytes_pc_plus_34_shift, e bc_decomposition_bytes_pc_plus_35_shift, e bc_decomposition_bytes_pc_plus_4_shift, e bc_decomposition_bytes_pc_plus_5_shift, e bc_decomposition_bytes_pc_plus_6_shift, e bc_decomposition_bytes_pc_plus_7_shift, e bc_decomposition_bytes_pc_plus_8_shift, e bc_decomposition_bytes_pc_plus_9_shift, e bc_decomposition_bytes_remaining_shift, e bc_decomposition_id_shift, e bc_decomposition_next_packed_pc_shift, e bc_decomposition_pc_shift, e bc_decomposition_sel_shift, e bc_decomposition_sel_windows_gt_remaining_shift, e bc_decomposition_start_shift, e bc_hashing_bytecode_id_shift, e bc_hashing_padding_shift, e bc_hashing_pc_index_1_shift, e bc_hashing_rounds_rem_shift, e bc_hashing_sel_shift, e bc_hashing_sel_not_start_shift, e bc_hashing_start_shift, e bitwise_acc_ia_shift, e bitwise_acc_ib_shift, e bitwise_acc_ic_shift, e bitwise_ctr_shift, e bitwise_op_id_shift, e bitwise_sel_shift, e bitwise_start_shift, e calldata_context_id_shift, e calldata_hashing_calldata_size_shift, e calldata_hashing_context_id_shift, e calldata_hashing_index_0__shift, e calldata_hashing_output_hash_shift, e calldata_hashing_rounds_rem_shift, e calldata_hashing_sel_shift, e calldata_hashing_start_shift, e calldata_index_shift, e calldata_sel_shift, e data_copy_clk_shift, e data_copy_copy_size_shift, e data_copy_dst_addr_shift, e data_copy_dst_context_id_shift, e data_copy_padding_shift, e data_copy_read_addr_shift, e data_copy_reads_left_shift, e data_copy_sel_shift, e data_copy_sel_cd_copy_shift, e data_copy_src_context_id_shift, e data_copy_start_shift, e emit_public_log_contract_address_shift, e emit_public_log_correct_tag_shift, e emit_public_log_error_out_of_bounds_shift, e emit_public_log_error_tag_mismatch_shift, e emit_public_log_execution_clk_shift, e emit_public_log_is_write_contract_address_shift, e emit_public_log_is_write_memory_value_shift, e emit_public_log_log_address_shift, e emit_public_log_public_inputs_index_shift, e emit_public_log_remaining_rows_shift, e emit_public_log_seen_wrong_tag_shift, e emit_public_log_sel_shift, e emit_public_log_sel_write_to_public_inputs_shift, e emit_public_log_space_id_shift, e emit_public_log_start_shift, e execution_bytecode_id_shift, e execution_clk_shift, e execution_context_id_shift, e execution_contract_address_shift, e execution_da_gas_limit_shift, e execution_discard_shift, e execution_dying_context_id_shift, e execution_enqueued_call_start_shift, e execution_internal_call_id_shift, e execution_internal_call_return_id_shift, e execution_is_static_shift, e execution_l1_l2_tree_root_shift, e execution_l2_gas_limit_shift, e execution_last_child_id_shift, e execution_last_child_returndata_addr_shift, e execution_last_child_returndata_size_shift, e execution_last_child_success_shift, e execution_msg_sender_shift, e execution_next_context_id_shift, e execution_next_internal_call_id_shift, e execution_parent_calldata_addr_shift, e execution_parent_calldata_size_shift, e execution_parent_da_gas_limit_shift, e execution_parent_da_gas_used_shift, e execution_parent_id_shift, e execution_parent_l2_gas_limit_shift, e execution_parent_l2_gas_used_shift, e execution_pc_shift, e execution_prev_da_gas_used_shift, e execution_prev_l2_gas_used_shift, e execution_prev_note_hash_tree_root_shift, e execution_prev_note_hash_tree_size_shift, e execution_prev_nullifier_tree_root_shift, e execution_prev_nullifier_tree_size_shift, e execution_prev_num_l2_to_l1_messages_shift, e execution_prev_num_note_hashes_emitted_shift, e execution_prev_num_nullifiers_emitted_shift, e execution_prev_num_public_log_fields_shift, e execution_prev_public_data_tree_root_shift, e execution_prev_public_data_tree_size_shift, e execution_prev_retrieved_bytecodes_tree_root_shift, e execution_prev_retrieved_bytecodes_tree_size_shift, e execution_prev_written_public_data_slots_tree_root_shift, e execution_prev_written_public_data_slots_tree_size_shift, e execution_sel_shift, e execution_sel_first_row_in_context_shift, e execution_transaction_fee_shift, e ff_gt_a_hi_shift, e ff_gt_a_lo_shift, e ff_gt_b_hi_shift, e ff_gt_b_lo_shift, e ff_gt_cmp_rng_ctr_shift, e ff_gt_p_sub_a_hi_shift, e ff_gt_p_sub_a_lo_shift, e ff_gt_p_sub_b_hi_shift, e ff_gt_p_sub_b_lo_shift, e ff_gt_sel_shift, e ff_gt_sel_dec_shift, e ff_gt_sel_gt_shift, e keccak_memory_addr_shift, e keccak_memory_clk_shift, e keccak_memory_ctr_shift, e keccak_memory_rw_shift, e keccak_memory_sel_shift, e keccak_memory_space_id_shift, e keccak_memory_start_read_shift, e keccak_memory_start_write_shift, e keccak_memory_tag_error_shift, e keccak_memory_val_0__shift, e keccak_memory_val_10__shift, e keccak_memory_val_11__shift, e keccak_memory_val_12__shift, e keccak_memory_val_13__shift, e keccak_memory_val_14__shift, e keccak_memory_val_15__shift, e keccak_memory_val_16__shift, e keccak_memory_val_17__shift, e keccak_memory_val_18__shift, e keccak_memory_val_19__shift, e keccak_memory_val_1__shift, e keccak_memory_val_20__shift, e keccak_memory_val_21__shift, e keccak_memory_val_22__shift, e keccak_memory_val_23__shift, e keccak_memory_val_2__shift, e keccak_memory_val_3__shift, e keccak_memory_val_4__shift, e keccak_memory_val_5__shift, e keccak_memory_val_6__shift, e keccak_memory_val_7__shift, e keccak_memory_val_8__shift, e keccak_memory_val_9__shift, e keccakf1600_clk_shift, e keccakf1600_dst_addr_shift, e keccakf1600_round_shift, e keccakf1600_sel_shift, e keccakf1600_sel_no_error_shift, e keccakf1600_space_id_shift, e keccakf1600_start_shift, e keccakf1600_state_in_00_shift, e keccakf1600_state_in_01_shift, e keccakf1600_state_in_02_shift, e keccakf1600_state_in_03_shift, e keccakf1600_state_in_04_shift, e keccakf1600_state_in_10_shift, e keccakf1600_state_in_11_shift, e keccakf1600_state_in_12_shift, e keccakf1600_state_in_13_shift, e keccakf1600_state_in_14_shift, e keccakf1600_state_in_20_shift, e keccakf1600_state_in_21_shift, e keccakf1600_state_in_22_shift, e keccakf1600_state_in_23_shift, e keccakf1600_state_in_24_shift, e keccakf1600_state_in_30_shift, e keccakf1600_state_in_31_shift, e keccakf1600_state_in_32_shift, e keccakf1600_state_in_33_shift, e keccakf1600_state_in_34_shift, e keccakf1600_state_in_40_shift, e keccakf1600_state_in_41_shift, e keccakf1600_state_in_42_shift, e keccakf1600_state_in_43_shift, e keccakf1600_state_in_44_shift, e memory_address_shift, e memory_clk_shift, e memory_rw_shift, e memory_sel_shift, e memory_space_id_shift, e memory_tag_shift, e memory_value_shift, e merkle_check_index_shift, e merkle_check_merkle_hash_separator_shift, e merkle_check_path_len_shift, e merkle_check_read_node_shift, e merkle_check_read_root_shift, e merkle_check_sel_shift, e merkle_check_start_shift, e merkle_check_write_shift, e merkle_check_write_node_shift, e merkle_check_write_root_shift, e poseidon2_hash_a_0_shift, e poseidon2_hash_a_1_shift, e poseidon2_hash_a_2_shift, e poseidon2_hash_a_3_shift, e poseidon2_hash_input_0_shift, e poseidon2_hash_input_1_shift, e poseidon2_hash_input_2_shift, e poseidon2_hash_num_perm_rounds_rem_shift, e poseidon2_hash_output_shift, e poseidon2_hash_sel_shift, e poseidon2_hash_start_shift, e public_data_check_clk_shift, e public_data_check_sel_shift, e public_data_check_write_idx_shift, e public_data_squash_clk_shift, e public_data_squash_final_value_shift, e public_data_squash_leaf_slot_shift, e public_data_squash_sel_shift, e public_data_squash_write_to_public_inputs_shift, e scalar_mul_bit_idx_shift, e scalar_mul_point_inf_shift, e scalar_mul_point_x_shift, e scalar_mul_point_y_shift, e scalar_mul_res_inf_shift, e scalar_mul_res_x_shift, e scalar_mul_res_y_shift, e scalar_mul_scalar_shift, e scalar_mul_sel_shift, e scalar_mul_start_shift, e scalar_mul_temp_inf_shift, e scalar_mul_temp_x_shift, e scalar_mul_temp_y_shift, e sha256_a_shift, e sha256_b_shift, e sha256_c_shift, e sha256_d_shift, e sha256_e_shift, e sha256_execution_clk_shift, e sha256_f_shift, e sha256_g_shift, e sha256_h_shift, e sha256_helper_w0_shift, e sha256_helper_w1_shift, e sha256_helper_w10_shift, e sha256_helper_w11_shift, e sha256_helper_w12_shift, e sha256_helper_w13_shift, e sha256_helper_w14_shift, e sha256_helper_w15_shift, e sha256_helper_w2_shift, e sha256_helper_w3_shift, e sha256_helper_w4_shift, e sha256_helper_w5_shift, e sha256_helper_w6_shift, e sha256_helper_w7_shift, e sha256_helper_w8_shift, e sha256_helper_w9_shift, e sha256_init_a_shift, e sha256_init_b_shift, e sha256_init_c_shift, e sha256_init_d_shift, e sha256_init_e_shift, e sha256_init_f_shift, e sha256_init_g_shift, e sha256_init_h_shift, e sha256_input_addr_shift, e sha256_input_rounds_rem_shift, e sha256_output_addr_shift, e sha256_rounds_remaining_shift, e sha256_sel_shift, e sha256_sel_invalid_input_tag_err_shift, e sha256_space_id_shift, e sha256_start_shift, e to_radix_acc_shift, e to_radix_acc_under_p_shift, e to_radix_limb_shift, e to_radix_limb_eq_p_shift, e to_radix_limb_index_shift, e to_radix_limb_lt_p_shift, e to_radix_mem_dst_addr_shift, e to_radix_mem_execution_clk_shift, e to_radix_mem_is_output_bits_shift, e to_radix_mem_num_limbs_shift, e to_radix_mem_radix_shift, e to_radix_mem_sel_shift, e to_radix_mem_sel_should_decompose_shift, e to_radix_mem_sel_should_write_mem_shift, e to_radix_mem_space_id_shift, e to_radix_mem_start_shift, e to_radix_mem_value_to_decompose_shift, e to_radix_not_padding_limb_shift, e to_radix_power_shift, e to_radix_radix_shift, e to_radix_safe_limbs_shift, e to_radix_sel_shift, e to_radix_start_shift, e to_radix_value_shift, e tx_da_gas_limit_shift, e tx_discard_shift, e tx_fee_shift, e tx_is_revertible_shift, e tx_is_teardown_shift, e tx_l1_l2_tree_root_shift, e tx_l1_l2_tree_size_shift, e tx_l2_gas_limit_shift, e tx_next_context_id_shift, e tx_phase_value_shift, e tx_prev_da_gas_used_shift, e tx_prev_l2_gas_used_shift, e tx_prev_note_hash_tree_root_shift, e tx_prev_note_hash_tree_size_shift, e tx_prev_nullifier_tree_root_shift, e tx_prev_nullifier_tree_size_shift, e tx_prev_num_l2_to_l1_messages_shift, e tx_prev_num_note_hashes_emitted_shift, e tx_prev_num_nullifiers_emitted_shift, e tx_prev_num_public_log_fields_shift, e tx_prev_public_data_tree_root_shift, e tx_prev_public_data_tree_size_shift, e tx_prev_retrieved_bytecodes_tree_root_shift, e tx_prev_retrieved_bytecodes_tree_size_shift, e tx_prev_written_public_data_slots_tree_root_shift, e tx_prev_written_public_data_slots_tree_size_shift, e tx_read_pi_offset_shift, e tx_remaining_phase_counter_shift, e tx_reverted_shift, e tx_sel_shift, e tx_start_phase_shift, e tx_start_tx_shift, e tx_tx_reverted_shift #define AVM2_TO_BE_SHIFTED_E(e) e bc_decomposition_bytes, e bc_decomposition_bytes_pc_plus_1, e bc_decomposition_bytes_pc_plus_10, e bc_decomposition_bytes_pc_plus_11, e bc_decomposition_bytes_pc_plus_12, e bc_decomposition_bytes_pc_plus_13, e bc_decomposition_bytes_pc_plus_14, e bc_decomposition_bytes_pc_plus_15, e bc_decomposition_bytes_pc_plus_16, e bc_decomposition_bytes_pc_plus_17, e bc_decomposition_bytes_pc_plus_18, e bc_decomposition_bytes_pc_plus_19, e bc_decomposition_bytes_pc_plus_2, e bc_decomposition_bytes_pc_plus_20, e bc_decomposition_bytes_pc_plus_21, e bc_decomposition_bytes_pc_plus_22, e bc_decomposition_bytes_pc_plus_23, e bc_decomposition_bytes_pc_plus_24, e bc_decomposition_bytes_pc_plus_25, e bc_decomposition_bytes_pc_plus_26, e bc_decomposition_bytes_pc_plus_27, e bc_decomposition_bytes_pc_plus_28, e bc_decomposition_bytes_pc_plus_29, e bc_decomposition_bytes_pc_plus_3, e bc_decomposition_bytes_pc_plus_30, e bc_decomposition_bytes_pc_plus_31, e bc_decomposition_bytes_pc_plus_32, e bc_decomposition_bytes_pc_plus_33, e bc_decomposition_bytes_pc_plus_34, e bc_decomposition_bytes_pc_plus_35, e bc_decomposition_bytes_pc_plus_4, e bc_decomposition_bytes_pc_plus_5, e bc_decomposition_bytes_pc_plus_6, e bc_decomposition_bytes_pc_plus_7, e bc_decomposition_bytes_pc_plus_8, e bc_decomposition_bytes_pc_plus_9, e bc_decomposition_bytes_remaining, e bc_decomposition_id, e bc_decomposition_next_packed_pc, e bc_decomposition_pc, e bc_decomposition_sel, e bc_decomposition_sel_windows_gt_remaining, e bc_decomposition_start, e bc_hashing_bytecode_id, e bc_hashing_padding, e bc_hashing_pc_index_1, e bc_hashing_rounds_rem, e bc_hashing_sel, e bc_hashing_sel_not_start, e bc_hashing_start, e bitwise_acc_ia, e bitwise_acc_ib, e bitwise_acc_ic, e bitwise_ctr, e bitwise_op_id, e bitwise_sel, e bitwise_start, e calldata_context_id, e calldata_hashing_calldata_size, e calldata_hashing_context_id, e calldata_hashing_index_0_, e calldata_hashing_output_hash, e calldata_hashing_rounds_rem, e calldata_hashing_sel, e calldata_hashing_start, e calldata_index, e calldata_sel, e data_copy_clk, e data_copy_copy_size, e data_copy_dst_addr, e data_copy_dst_context_id, e data_copy_padding, e data_copy_read_addr, e data_copy_reads_left, e data_copy_sel, e data_copy_sel_cd_copy, e data_copy_src_context_id, e data_copy_start, e emit_public_log_contract_address, e emit_public_log_correct_tag, e emit_public_log_error_out_of_bounds, e emit_public_log_error_tag_mismatch, e emit_public_log_execution_clk, e emit_public_log_is_write_contract_address, e emit_public_log_is_write_memory_value, e emit_public_log_log_address, e emit_public_log_public_inputs_index, e emit_public_log_remaining_rows, e emit_public_log_seen_wrong_tag, e emit_public_log_sel, e emit_public_log_sel_write_to_public_inputs, e emit_public_log_space_id, e emit_public_log_start, e execution_bytecode_id, e execution_clk, e execution_context_id, e execution_contract_address, e execution_da_gas_limit, e execution_discard, e execution_dying_context_id, e execution_enqueued_call_start, e execution_internal_call_id, e execution_internal_call_return_id, e execution_is_static, e execution_l1_l2_tree_root, e execution_l2_gas_limit, e execution_last_child_id, e execution_last_child_returndata_addr, e execution_last_child_returndata_size, e execution_last_child_success, e execution_msg_sender, e execution_next_context_id, e execution_next_internal_call_id, e execution_parent_calldata_addr, e execution_parent_calldata_size, e execution_parent_da_gas_limit, e execution_parent_da_gas_used, e execution_parent_id, e execution_parent_l2_gas_limit, e execution_parent_l2_gas_used, e execution_pc, e execution_prev_da_gas_used, e execution_prev_l2_gas_used, e execution_prev_note_hash_tree_root, e execution_prev_note_hash_tree_size, e execution_prev_nullifier_tree_root, e execution_prev_nullifier_tree_size, e execution_prev_num_l2_to_l1_messages, e execution_prev_num_note_hashes_emitted, e execution_prev_num_nullifiers_emitted, e execution_prev_num_public_log_fields, e execution_prev_public_data_tree_root, e execution_prev_public_data_tree_size, e execution_prev_retrieved_bytecodes_tree_root, e execution_prev_retrieved_bytecodes_tree_size, e execution_prev_written_public_data_slots_tree_root, e execution_prev_written_public_data_slots_tree_size, e execution_sel, e execution_sel_first_row_in_context, e execution_transaction_fee, e ff_gt_a_hi, e ff_gt_a_lo, e ff_gt_b_hi, e ff_gt_b_lo, e ff_gt_cmp_rng_ctr, e ff_gt_p_sub_a_hi, e ff_gt_p_sub_a_lo, e ff_gt_p_sub_b_hi, e ff_gt_p_sub_b_lo, e ff_gt_sel, e ff_gt_sel_dec, e ff_gt_sel_gt, e keccak_memory_addr, e keccak_memory_clk, e keccak_memory_ctr, e keccak_memory_rw, e keccak_memory_sel, e keccak_memory_space_id, e keccak_memory_start_read, e keccak_memory_start_write, e keccak_memory_tag_error, e keccak_memory_val_0_, e keccak_memory_val_10_, e keccak_memory_val_11_, e keccak_memory_val_12_, e keccak_memory_val_13_, e keccak_memory_val_14_, e keccak_memory_val_15_, e keccak_memory_val_16_, e keccak_memory_val_17_, e keccak_memory_val_18_, e keccak_memory_val_19_, e keccak_memory_val_1_, e keccak_memory_val_20_, e keccak_memory_val_21_, e keccak_memory_val_22_, e keccak_memory_val_23_, e keccak_memory_val_2_, e keccak_memory_val_3_, e keccak_memory_val_4_, e keccak_memory_val_5_, e keccak_memory_val_6_, e keccak_memory_val_7_, e keccak_memory_val_8_, e keccak_memory_val_9_, e keccakf1600_clk, e keccakf1600_dst_addr, e keccakf1600_round, e keccakf1600_sel, e keccakf1600_sel_no_error, e keccakf1600_space_id, e keccakf1600_start, e keccakf1600_state_in_00, e keccakf1600_state_in_01, e keccakf1600_state_in_02, e keccakf1600_state_in_03, e keccakf1600_state_in_04, e keccakf1600_state_in_10, e keccakf1600_state_in_11, e keccakf1600_state_in_12, e keccakf1600_state_in_13, e keccakf1600_state_in_14, e keccakf1600_state_in_20, e keccakf1600_state_in_21, e keccakf1600_state_in_22, e keccakf1600_state_in_23, e keccakf1600_state_in_24, e keccakf1600_state_in_30, e keccakf1600_state_in_31, e keccakf1600_state_in_32, e keccakf1600_state_in_33, e keccakf1600_state_in_34, e keccakf1600_state_in_40, e keccakf1600_state_in_41, e keccakf1600_state_in_42, e keccakf1600_state_in_43, e keccakf1600_state_in_44, e memory_address, e memory_clk, e memory_rw, e memory_sel, e memory_space_id, e memory_tag, e memory_value, e merkle_check_index, e merkle_check_merkle_hash_separator, e merkle_check_path_len, e merkle_check_read_node, e merkle_check_read_root, e merkle_check_sel, e merkle_check_start, e merkle_check_write, e merkle_check_write_node, e merkle_check_write_root, e poseidon2_hash_a_0, e poseidon2_hash_a_1, e poseidon2_hash_a_2, e poseidon2_hash_a_3, e poseidon2_hash_input_0, e poseidon2_hash_input_1, e poseidon2_hash_input_2, e poseidon2_hash_num_perm_rounds_rem, e poseidon2_hash_output, e poseidon2_hash_sel, e poseidon2_hash_start, e public_data_check_clk, e public_data_check_sel, e public_data_check_write_idx, e public_data_squash_clk, e public_data_squash_final_value, e public_data_squash_leaf_slot, e public_data_squash_sel, e public_data_squash_write_to_public_inputs, e scalar_mul_bit_idx, e scalar_mul_point_inf, e scalar_mul_point_x, e scalar_mul_point_y, e scalar_mul_res_inf, e scalar_mul_res_x, e scalar_mul_res_y, e scalar_mul_scalar, e scalar_mul_sel, e scalar_mul_start, e scalar_mul_temp_inf, e scalar_mul_temp_x, e scalar_mul_temp_y, e sha256_a, e sha256_b, e sha256_c, e sha256_d, e sha256_e, e sha256_execution_clk, e sha256_f, e sha256_g, e sha256_h, e sha256_helper_w0, e sha256_helper_w1, e sha256_helper_w10, e sha256_helper_w11, e sha256_helper_w12, e sha256_helper_w13, e sha256_helper_w14, e sha256_helper_w15, e sha256_helper_w2, e sha256_helper_w3, e sha256_helper_w4, e sha256_helper_w5, e sha256_helper_w6, e sha256_helper_w7, e sha256_helper_w8, e sha256_helper_w9, e sha256_init_a, e sha256_init_b, e sha256_init_c, e sha256_init_d, e sha256_init_e, e sha256_init_f, e sha256_init_g, e sha256_init_h, e sha256_input_addr, e sha256_input_rounds_rem, e sha256_output_addr, e sha256_rounds_remaining, e sha256_sel, e sha256_sel_invalid_input_tag_err, e sha256_space_id, e sha256_start, e to_radix_acc, e to_radix_acc_under_p, e to_radix_limb, e to_radix_limb_eq_p, e to_radix_limb_index, e to_radix_limb_lt_p, e to_radix_mem_dst_addr, e to_radix_mem_execution_clk, e to_radix_mem_is_output_bits, e to_radix_mem_num_limbs, e to_radix_mem_radix, e to_radix_mem_sel, e to_radix_mem_sel_should_decompose, e to_radix_mem_sel_should_write_mem, e to_radix_mem_space_id, e to_radix_mem_start, e to_radix_mem_value_to_decompose, e to_radix_not_padding_limb, e to_radix_power, e to_radix_radix, e to_radix_safe_limbs, e to_radix_sel, e to_radix_start, e to_radix_value, e tx_da_gas_limit, e tx_discard, e tx_fee, e tx_is_revertible, e tx_is_teardown, e tx_l1_l2_tree_root, e tx_l1_l2_tree_size, e tx_l2_gas_limit, e tx_next_context_id, e tx_phase_value, e tx_prev_da_gas_used, e tx_prev_l2_gas_used, e tx_prev_note_hash_tree_root, e tx_prev_note_hash_tree_size, e tx_prev_nullifier_tree_root, e tx_prev_nullifier_tree_size, e tx_prev_num_l2_to_l1_messages, e tx_prev_num_note_hashes_emitted, e tx_prev_num_nullifiers_emitted, e tx_prev_num_public_log_fields, e tx_prev_public_data_tree_root, e tx_prev_public_data_tree_size, e tx_prev_retrieved_bytecodes_tree_root, e tx_prev_retrieved_bytecodes_tree_size, e tx_prev_written_public_data_slots_tree_root, e tx_prev_written_public_data_slots_tree_size, e tx_read_pi_offset, e tx_remaining_phase_counter, e tx_reverted, e tx_sel, e tx_start_phase, e tx_start_tx, e tx_tx_reverted #define AVM2_ALL_ENTITIES_E(e) AVM2_PRECOMPUTED_ENTITIES_E(e), AVM2_WIRE_ENTITIES_E(e), AVM2_DERIVED_WITNESS_ENTITIES_E(e), AVM2_SHIFTED_ENTITIES_E(e) diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/addressing.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/addressing.hpp index 8a2838bae64c..f7b636d1cc49 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/addressing.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/addressing.hpp @@ -23,9 +23,9 @@ template class addressingImpl { { using C = ColumnAndShifts; - const auto execution_SEL_SHOULD_RESOLVE_ADDRESS = in.get(C::execution_sel_instruction_fetching_success); + const auto execution_SEL_RESOLVE_ADDRESS = in.get(C::execution_sel_instruction_fetching_success); - return (execution_SEL_SHOULD_RESOLVE_ADDRESS).is_zero(); + return (execution_SEL_RESOLVE_ADDRESS).is_zero(); } template diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/addressing_impl.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/addressing_impl.hpp index afe5c6a13d17..bbe12c3eb53a 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/addressing_impl.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/addressing_impl.hpp @@ -59,19 +59,19 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, const auto execution_BASE_CHECK_E = (FF(1) - in.get(C::execution_sel_base_address_failure)); const auto execution_RELATIVE_RESOLUTION_FILTER = (FF(1) - in.get(C::execution_sel_base_address_failure)) * in.get(C::execution_base_address_val); - const auto execution_BATCHED_TAGS_DIFF = in.get(C::execution_sel_should_apply_indirection_0_) * FF(1) * + const auto execution_BATCHED_TAGS_DIFF = in.get(C::execution_sel_apply_indirection_0_) * FF(1) * (in.get(C::execution_rop_tag_0_) - constants_MEM_TAG_U32) + - in.get(C::execution_sel_should_apply_indirection_1_) * FF(8) * + in.get(C::execution_sel_apply_indirection_1_) * FF(8) * (in.get(C::execution_rop_tag_1_) - constants_MEM_TAG_U32) + - in.get(C::execution_sel_should_apply_indirection_2_) * FF(64) * + in.get(C::execution_sel_apply_indirection_2_) * FF(64) * (in.get(C::execution_rop_tag_2_) - constants_MEM_TAG_U32) + - in.get(C::execution_sel_should_apply_indirection_3_) * FF(512) * + in.get(C::execution_sel_apply_indirection_3_) * FF(512) * (in.get(C::execution_rop_tag_3_) - constants_MEM_TAG_U32) + - in.get(C::execution_sel_should_apply_indirection_4_) * FF(4096) * + in.get(C::execution_sel_apply_indirection_4_) * FF(4096) * (in.get(C::execution_rop_tag_4_) - constants_MEM_TAG_U32) + - in.get(C::execution_sel_should_apply_indirection_5_) * FF(32768) * + in.get(C::execution_sel_apply_indirection_5_) * FF(32768) * (in.get(C::execution_rop_tag_5_) - constants_MEM_TAG_U32) + - in.get(C::execution_sel_should_apply_indirection_6_) * FF(262144) * + in.get(C::execution_sel_apply_indirection_6_) * FF(262144) * (in.get(C::execution_rop_tag_6_) - constants_MEM_TAG_U32); const auto execution_BATCHED_TAGS_DIFF_X = execution_BATCHED_TAGS_DIFF; const auto execution_BATCHED_TAGS_DIFF_Y = in.get(C::execution_batched_tags_diff_inv); @@ -96,7 +96,7 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, execution_ADDRESSING_COLLECTION_Y) - FF(1)) + execution_ADDRESSING_COLLECTION_E; - const auto execution_SEL_SHOULD_RESOLVE_ADDRESS = in.get(C::execution_sel_instruction_fetching_success); + const auto execution_SEL_RESOLVE_ADDRESS = in.get(C::execution_sel_instruction_fetching_success); { using View = typename std::tuple_element_t<0, ContainerOverSubrelations>::View; @@ -196,24 +196,23 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, } { // ADDRESSING_MODE_RECONSTRUCTION using View = typename std::tuple_element_t<16, ContainerOverSubrelations>::View; - auto tmp = - (CView(execution_SEL_SHOULD_RESOLVE_ADDRESS) * static_cast(in.get(C::execution_addressing_mode)) - - (FF(1) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_0_)) + - FF(2) * static_cast(in.get(C::execution_sel_op_is_relative_wire_0_)) + - FF(4) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_1_)) + - FF(8) * static_cast(in.get(C::execution_sel_op_is_relative_wire_1_)) + - FF(16) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_2_)) + - FF(32) * static_cast(in.get(C::execution_sel_op_is_relative_wire_2_)) + - FF(64) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_3_)) + - FF(128) * static_cast(in.get(C::execution_sel_op_is_relative_wire_3_)) + - FF(256) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_4_)) + - FF(512) * static_cast(in.get(C::execution_sel_op_is_relative_wire_4_)) + - FF(1024) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_5_)) + - FF(2048) * static_cast(in.get(C::execution_sel_op_is_relative_wire_5_)) + - FF(4096) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_6_)) + - FF(8192) * static_cast(in.get(C::execution_sel_op_is_relative_wire_6_)) + - FF(16384) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_7_)) + - FF(32768) * static_cast(in.get(C::execution_sel_op_is_relative_wire_7_)))); + auto tmp = (CView(execution_SEL_RESOLVE_ADDRESS) * static_cast(in.get(C::execution_addressing_mode)) - + (FF(1) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_0_)) + + FF(2) * static_cast(in.get(C::execution_sel_op_is_relative_wire_0_)) + + FF(4) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_1_)) + + FF(8) * static_cast(in.get(C::execution_sel_op_is_relative_wire_1_)) + + FF(16) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_2_)) + + FF(32) * static_cast(in.get(C::execution_sel_op_is_relative_wire_2_)) + + FF(64) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_3_)) + + FF(128) * static_cast(in.get(C::execution_sel_op_is_relative_wire_3_)) + + FF(256) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_4_)) + + FF(512) * static_cast(in.get(C::execution_sel_op_is_relative_wire_4_)) + + FF(1024) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_5_)) + + FF(2048) * static_cast(in.get(C::execution_sel_op_is_relative_wire_5_)) + + FF(4096) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_6_)) + + FF(8192) * static_cast(in.get(C::execution_sel_op_is_relative_wire_6_)) + + FF(16384) * static_cast(in.get(C::execution_sel_op_is_indirect_wire_7_)) + + FF(32768) * static_cast(in.get(C::execution_sel_op_is_relative_wire_7_)))); std::get<16>(evals) += (tmp * scaling_factor); } { @@ -395,13 +394,13 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, } { using View = typename std::tuple_element_t<42, ContainerOverSubrelations>::View; - auto tmp = CView(execution_SEL_SHOULD_RESOLVE_ADDRESS) * + auto tmp = CView(execution_SEL_RESOLVE_ADDRESS) * (static_cast(in.get(C::execution_highest_address)) - CView(constants_AVM_HIGHEST_MEM_ADDRESS)); std::get<42>(evals) += (tmp * scaling_factor); } { // INDIRECT_GATING_0 using View = typename std::tuple_element_t<43, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_should_apply_indirection_0_)) - + auto tmp = (static_cast(in.get(C::execution_sel_apply_indirection_0_)) - CView(execution_SEL_OP_IS_INDIRECT_EFFECTIVE_0_) * ((FF(1) - static_cast(in.get(C::execution_sel_relative_overflow_0_))) - static_cast(in.get(C::execution_sel_base_address_failure)))); @@ -409,7 +408,7 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, } { // INDIRECT_GATING_1 using View = typename std::tuple_element_t<44, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_should_apply_indirection_1_)) - + auto tmp = (static_cast(in.get(C::execution_sel_apply_indirection_1_)) - CView(execution_SEL_OP_IS_INDIRECT_EFFECTIVE_1_) * ((FF(1) - static_cast(in.get(C::execution_sel_relative_overflow_1_))) - static_cast(in.get(C::execution_sel_base_address_failure)))); @@ -417,7 +416,7 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, } { // INDIRECT_GATING_2 using View = typename std::tuple_element_t<45, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_should_apply_indirection_2_)) - + auto tmp = (static_cast(in.get(C::execution_sel_apply_indirection_2_)) - CView(execution_SEL_OP_IS_INDIRECT_EFFECTIVE_2_) * ((FF(1) - static_cast(in.get(C::execution_sel_relative_overflow_2_))) - static_cast(in.get(C::execution_sel_base_address_failure)))); @@ -425,7 +424,7 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, } { // INDIRECT_GATING_3 using View = typename std::tuple_element_t<46, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_should_apply_indirection_3_)) - + auto tmp = (static_cast(in.get(C::execution_sel_apply_indirection_3_)) - CView(execution_SEL_OP_IS_INDIRECT_EFFECTIVE_3_) * ((FF(1) - static_cast(in.get(C::execution_sel_relative_overflow_3_))) - static_cast(in.get(C::execution_sel_base_address_failure)))); @@ -433,7 +432,7 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, } { // INDIRECT_GATING_4 using View = typename std::tuple_element_t<47, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_should_apply_indirection_4_)) - + auto tmp = (static_cast(in.get(C::execution_sel_apply_indirection_4_)) - CView(execution_SEL_OP_IS_INDIRECT_EFFECTIVE_4_) * ((FF(1) - static_cast(in.get(C::execution_sel_relative_overflow_4_))) - static_cast(in.get(C::execution_sel_base_address_failure)))); @@ -441,7 +440,7 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, } { // INDIRECT_GATING_5 using View = typename std::tuple_element_t<48, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_should_apply_indirection_5_)) - + auto tmp = (static_cast(in.get(C::execution_sel_apply_indirection_5_)) - CView(execution_SEL_OP_IS_INDIRECT_EFFECTIVE_5_) * ((FF(1) - static_cast(in.get(C::execution_sel_relative_overflow_5_))) - static_cast(in.get(C::execution_sel_base_address_failure)))); @@ -449,7 +448,7 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, } { // INDIRECT_GATING_6 using View = typename std::tuple_element_t<49, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_should_apply_indirection_6_)) - + auto tmp = (static_cast(in.get(C::execution_sel_apply_indirection_6_)) - CView(execution_SEL_OP_IS_INDIRECT_EFFECTIVE_6_) * ((FF(1) - static_cast(in.get(C::execution_sel_relative_overflow_6_))) - static_cast(in.get(C::execution_sel_base_address_failure)))); @@ -457,49 +456,49 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, } { // INDIRECT_PROPAGATION_0 using View = typename std::tuple_element_t<50, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_should_apply_indirection_0_))) * + auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_apply_indirection_0_))) * (static_cast(in.get(C::execution_rop_0_)) - static_cast(in.get(C::execution_op_after_relative_0_))); std::get<50>(evals) += (tmp * scaling_factor); } { // INDIRECT_PROPAGATION_1 using View = typename std::tuple_element_t<51, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_should_apply_indirection_1_))) * + auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_apply_indirection_1_))) * (static_cast(in.get(C::execution_rop_1_)) - static_cast(in.get(C::execution_op_after_relative_1_))); std::get<51>(evals) += (tmp * scaling_factor); } { // INDIRECT_PROPAGATION_2 using View = typename std::tuple_element_t<52, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_should_apply_indirection_2_))) * + auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_apply_indirection_2_))) * (static_cast(in.get(C::execution_rop_2_)) - static_cast(in.get(C::execution_op_after_relative_2_))); std::get<52>(evals) += (tmp * scaling_factor); } { // INDIRECT_PROPAGATION_3 using View = typename std::tuple_element_t<53, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_should_apply_indirection_3_))) * + auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_apply_indirection_3_))) * (static_cast(in.get(C::execution_rop_3_)) - static_cast(in.get(C::execution_op_after_relative_3_))); std::get<53>(evals) += (tmp * scaling_factor); } { // INDIRECT_PROPAGATION_4 using View = typename std::tuple_element_t<54, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_should_apply_indirection_4_))) * + auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_apply_indirection_4_))) * (static_cast(in.get(C::execution_rop_4_)) - static_cast(in.get(C::execution_op_after_relative_4_))); std::get<54>(evals) += (tmp * scaling_factor); } { // INDIRECT_PROPAGATION_5 using View = typename std::tuple_element_t<55, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_should_apply_indirection_5_))) * + auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_apply_indirection_5_))) * (static_cast(in.get(C::execution_rop_5_)) - static_cast(in.get(C::execution_op_after_relative_5_))); std::get<55>(evals) += (tmp * scaling_factor); } { // INDIRECT_PROPAGATION_6 using View = typename std::tuple_element_t<56, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_should_apply_indirection_6_))) * + auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_apply_indirection_6_))) * (static_cast(in.get(C::execution_rop_6_)) - static_cast(in.get(C::execution_op_after_relative_6_))); std::get<56>(evals) += (tmp * scaling_factor); @@ -528,7 +527,7 @@ void addressingImpl::accumulate(ContainerOverSubrelations& evals, } { // NO_ADDRESSING_ERROR_IF_NOT_RESOLVING using View = typename std::tuple_element_t<61, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - CView(execution_SEL_SHOULD_RESOLVE_ADDRESS)) * + auto tmp = (FF(1) - CView(execution_SEL_RESOLVE_ADDRESS)) * static_cast(in.get(C::execution_sel_addressing_error)); std::get<61>(evals) += (tmp * scaling_factor); } diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/execution.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/execution.hpp index 1762a5cc9b4b..90880ec6d2c7 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/execution.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/execution.hpp @@ -15,9 +15,9 @@ template class executionImpl { using FF = FF_; static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { - 3, 3, 3, 2, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 2, 3, 3, 3, 3, 3, 3, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 4, 4, 3, 3, 3, 3, 3, 3, 3, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, - 3, 3, 3, 3, 3, 4, 5, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 2 + 3, 3, 3, 3, 3, 3, 4, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, 2 }; template inline static bool skip(const AllEntities& in) @@ -45,7 +45,7 @@ template class execution : public Relation> { static constexpr size_t SR_EXEC_CLK_INIT = 5; static constexpr size_t SR_EXEC_CLK_CONTINUITY = 6; static constexpr size_t SR_BYTECODE_RETRIEVAL_NO_FAILURE = 7; - static constexpr size_t SR_NO_FETCHING_NO_INSTR_FETCH_ERROR = 10; + static constexpr size_t SR_NO_FETCHING_NO_INSTR_FETCH_ERROR = 9; static constexpr size_t SR_DYN_GAS_ID_DECOMPOSITION = 19; static constexpr size_t SR_NUM_P_LIMBS_CEIL = 22; static constexpr size_t SR_DYN_L2_FACTOR_TO_RADIX_BE = 23; @@ -76,6 +76,7 @@ template class execution : public Relation> { static constexpr size_t SR_RETRIEVED_BYTECODES_TREE_ROOT_NOT_CHANGED = 89; static constexpr size_t SR_RETRIEVED_BYTECODES_TREE_SIZE_NOT_CHANGED = 90; static constexpr size_t SR_INFALLIBLE_OPCODES_SUCCESS = 92; + static constexpr size_t SR_NO_OPCODE_ERROR_IF_NOT_EXECUTING = 93; static std::string get_subrelation_label(size_t index) { @@ -154,6 +155,8 @@ template class execution : public Relation> { return "RETRIEVED_BYTECODES_TREE_SIZE_NOT_CHANGED"; case SR_INFALLIBLE_OPCODES_SUCCESS: return "INFALLIBLE_OPCODES_SUCCESS"; + case SR_NO_OPCODE_ERROR_IF_NOT_EXECUTING: + return "NO_OPCODE_ERROR_IF_NOT_EXECUTING"; } return std::to_string(index); } diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/execution_impl.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/execution_impl.hpp index 2c64849e9d6c..d27f6fa676d6 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/execution_impl.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/execution_impl.hpp @@ -61,7 +61,7 @@ void executionImpl::accumulate(ContainerOverSubrelations& evals, const auto constants_AVM_WRITTEN_PUBLIC_DATA_SLOTS_TREE_HEIGHT = FF(6); const auto constants_DOM_SEP__PUBLIC_LEAF_SLOT = FF(1247650290); const auto constants_DOM_SEP__WRITTEN_SLOTS_MERKLE = FF(2292766212UL); - const auto execution_SEL_SHOULD_RESOLVE_ADDRESS = in.get(C::execution_sel_instruction_fetching_success); + const auto execution_SEL_RESOLVE_ADDRESS = in.get(C::execution_sel_instruction_fetching_success); { using View = typename std::tuple_element_t<0, ContainerOverSubrelations>::View; @@ -92,9 +92,9 @@ void executionImpl::accumulate(ContainerOverSubrelations& evals, } { // TRACE_CONTINUITY using View = typename std::tuple_element_t<4, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::execution_sel))) * - (FF(1) - static_cast(in.get(C::precomputed_first_row))) * - static_cast(in.get(C::execution_sel_shift)); + auto tmp = ((FF(1) - static_cast(in.get(C::precomputed_first_row))) - + static_cast(in.get(C::execution_enqueued_call_end))) * + (static_cast(in.get(C::execution_sel)) - static_cast(in.get(C::execution_sel_shift))); std::get<4>(evals) += (tmp * scaling_factor); } { // EXEC_CLK_INIT @@ -122,31 +122,31 @@ void executionImpl::accumulate(ContainerOverSubrelations& evals, (FF(1) - static_cast(in.get(C::execution_sel_bytecode_retrieval_failure)))); std::get<8>(evals) += (tmp * scaling_factor); } - { + { // NO_FETCHING_NO_INSTR_FETCH_ERROR using View = typename std::tuple_element_t<9, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_instruction_fetching_success)) - - static_cast(in.get(C::execution_sel_bytecode_retrieval_success)) * - (FF(1) - static_cast(in.get(C::execution_sel_instruction_fetching_failure)))); + auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_bytecode_retrieval_success))) * + static_cast(in.get(C::execution_sel_instruction_fetching_failure)); std::get<9>(evals) += (tmp * scaling_factor); } - { // NO_FETCHING_NO_INSTR_FETCH_ERROR + { using View = typename std::tuple_element_t<10, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_bytecode_retrieval_success))) * - static_cast(in.get(C::execution_sel_instruction_fetching_failure)); + auto tmp = (static_cast(in.get(C::execution_sel_instruction_fetching_success)) - + (static_cast(in.get(C::execution_sel_bytecode_retrieval_success)) - + static_cast(in.get(C::execution_sel_instruction_fetching_failure)))); std::get<10>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<11, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_should_read_registers)) - - CView(execution_SEL_SHOULD_RESOLVE_ADDRESS) * - (FF(1) - static_cast(in.get(C::execution_sel_addressing_error)))); + auto tmp = + (static_cast(in.get(C::execution_sel_read_registers)) - + (CView(execution_SEL_RESOLVE_ADDRESS) - static_cast(in.get(C::execution_sel_addressing_error)))); std::get<11>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<12, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_should_check_gas)) - - static_cast(in.get(C::execution_sel_should_read_registers)) * - (FF(1) - static_cast(in.get(C::execution_sel_register_read_error)))); + auto tmp = (static_cast(in.get(C::execution_sel_check_gas)) - + (static_cast(in.get(C::execution_sel_read_registers)) - + static_cast(in.get(C::execution_sel_register_read_error)))); std::get<12>(evals) += (tmp * scaling_factor); } { @@ -197,7 +197,7 @@ void executionImpl::accumulate(ContainerOverSubrelations& evals, static_cast(in.get(C::execution_sel_gas_emit_public_log)) * CView(constants_AVM_DYN_GAS_ID_EMITPUBLICLOG) + static_cast(in.get(C::execution_sel_gas_sstore)) * CView(constants_AVM_DYN_GAS_ID_SSTORE)) - - static_cast(in.get(C::execution_sel_should_check_gas)) * + static_cast(in.get(C::execution_sel_check_gas)) * static_cast(in.get(C::execution_dyn_gas_id))); std::get<19>(evals) += (tmp * scaling_factor); } @@ -287,9 +287,9 @@ void executionImpl::accumulate(ContainerOverSubrelations& evals, } { using View = typename std::tuple_element_t<31, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_should_execute_opcode)) - - static_cast(in.get(C::execution_sel_should_check_gas)) * - (FF(1) - static_cast(in.get(C::execution_sel_out_of_gas)))); + auto tmp = (static_cast(in.get(C::execution_sel_execute_opcode)) - + (static_cast(in.get(C::execution_sel_check_gas)) - + static_cast(in.get(C::execution_sel_out_of_gas)))); std::get<31>(evals) += (tmp * scaling_factor); } { @@ -403,7 +403,7 @@ void executionImpl::accumulate(ContainerOverSubrelations& evals, static_cast(in.get(C::execution_sel_exec_dispatch_ecc_add)) * CView(constants_AVM_SUBTRACE_ID_ECC) + static_cast(in.get(C::execution_sel_exec_dispatch_to_radix)) * CView(constants_AVM_SUBTRACE_ID_TO_RADIX)) - - static_cast(in.get(C::execution_sel_should_execute_opcode)) * + static_cast(in.get(C::execution_sel_execute_opcode)) * static_cast(in.get(C::execution_subtrace_id))); std::get<46>(evals) += (tmp * scaling_factor); } @@ -575,8 +575,7 @@ void executionImpl::accumulate(ContainerOverSubrelations& evals, } { // PC_NEXT_ROW_INT_CALL_JUMP using View = typename std::tuple_element_t<69, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::execution_sel_shift)) * - (static_cast(in.get(C::execution_sel_execute_internal_call)) + + auto tmp = (static_cast(in.get(C::execution_sel_execute_internal_call)) + static_cast(in.get(C::execution_sel_execute_jump))) * (static_cast(in.get(C::execution_pc_shift)) - static_cast(in.get(C::execution_rop_0_))); std::get<69>(evals) += (tmp * scaling_factor); @@ -584,7 +583,6 @@ void executionImpl::accumulate(ContainerOverSubrelations& evals, { // PC_NEXT_ROW_JUMPI using View = typename std::tuple_element_t<70, ContainerOverSubrelations>::View; auto tmp = - static_cast(in.get(C::execution_sel_shift)) * static_cast(in.get(C::execution_sel_execute_jumpi)) * ((static_cast(in.get(C::execution_register_0_)) * (static_cast(in.get(C::execution_rop_1_)) - static_cast(in.get(C::execution_next_pc))) + @@ -756,17 +754,17 @@ void executionImpl::accumulate(ContainerOverSubrelations& evals, static_cast(in.get(C::execution_sel_opcode_error)); std::get<92>(evals) += (tmp * scaling_factor); } - { + { // NO_OPCODE_ERROR_IF_NOT_EXECUTING using View = typename std::tuple_element_t<93, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_should_execute_opcode))) * + auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_execute_opcode))) * static_cast(in.get(C::execution_sel_opcode_error)); std::get<93>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<94, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::execution_sel_should_write_registers)) - - static_cast(in.get(C::execution_sel_should_execute_opcode)) * - (FF(1) - static_cast(in.get(C::execution_sel_opcode_error)))); + auto tmp = (static_cast(in.get(C::execution_sel_write_registers)) - + (static_cast(in.get(C::execution_sel_execute_opcode)) - + static_cast(in.get(C::execution_sel_opcode_error)))); std::get<94>(evals) += (tmp * scaling_factor); } { diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/gas.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/gas.hpp index 549d509a5940..f6ddc4c6dacf 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/gas.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/gas.hpp @@ -20,7 +20,7 @@ template class gasImpl { { using C = ColumnAndShifts; - return (in.get(C::execution_sel_should_check_gas)).is_zero(); + return (in.get(C::execution_sel_check_gas)).is_zero(); } template @@ -34,9 +34,15 @@ template class gas : public Relation> { public: static constexpr const std::string_view NAME = "gas"; + // Subrelation indices constants, to be used in tests. + static constexpr size_t SR_NO_OOG_IF_NO_GAS_CHECK = 3; + static std::string get_subrelation_label(size_t index) { - switch (index) {} + switch (index) { + case SR_NO_OOG_IF_NO_GAS_CHECK: + return "NO_OOG_IF_NO_GAS_CHECK"; + } return std::to_string(index); } }; diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/gas_impl.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/gas_impl.hpp index fc0e47e69a2a..cd8e5db51359 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/gas_impl.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/gas_impl.hpp @@ -25,14 +25,14 @@ void gasImpl::accumulate(ContainerOverSubrelations& evals, { using View = typename std::tuple_element_t<0, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::execution_sel_should_check_gas)) * + auto tmp = static_cast(in.get(C::execution_sel_check_gas)) * ((static_cast(in.get(C::execution_prev_l2_gas_used)) + CView(execution_L2_GAS_USED)) - static_cast(in.get(C::execution_total_gas_l2))); std::get<0>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<1, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::execution_sel_should_check_gas)) * + auto tmp = static_cast(in.get(C::execution_sel_check_gas)) * ((static_cast(in.get(C::execution_prev_da_gas_used)) + CView(execution_DA_GAS_USED)) - static_cast(in.get(C::execution_total_gas_da))); std::get<1>(evals) += (tmp * scaling_factor); @@ -44,9 +44,9 @@ void gasImpl::accumulate(ContainerOverSubrelations& evals, (FF(1) - static_cast(in.get(C::execution_out_of_gas_da))))); std::get<2>(evals) += (tmp * scaling_factor); } - { + { // NO_OOG_IF_NO_GAS_CHECK using View = typename std::tuple_element_t<3, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_should_check_gas))) * + auto tmp = (FF(1) - static_cast(in.get(C::execution_sel_check_gas))) * static_cast(in.get(C::execution_sel_out_of_gas)); std::get<3>(evals) += (tmp * scaling_factor); } diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/lookups_gas.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/lookups_gas.hpp index 5ed8c503ebc7..54d02faf7238 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/lookups_gas.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/lookups_gas.hpp @@ -17,7 +17,7 @@ struct lookup_gas_addressing_gas_read_settings_ { static constexpr std::string_view NAME = "LOOKUP_GAS_ADDRESSING_GAS_READ"; static constexpr std::string_view RELATION_NAME = "gas"; static constexpr size_t LOOKUP_TUPLE_SIZE = 2; - static constexpr Column SRC_SELECTOR = Column::execution_sel_should_check_gas; + static constexpr Column SRC_SELECTOR = Column::execution_sel_check_gas; static constexpr Column DST_SELECTOR = Column::precomputed_sel_addressing_gas; static constexpr Column COUNTS = Column::lookup_gas_addressing_gas_read_counts; static constexpr Column INVERSES = Column::lookup_gas_addressing_gas_read_inv; @@ -39,7 +39,7 @@ struct lookup_gas_is_out_of_gas_l2_settings_ { static constexpr std::string_view NAME = "LOOKUP_GAS_IS_OUT_OF_GAS_L2"; static constexpr std::string_view RELATION_NAME = "gas"; static constexpr size_t LOOKUP_TUPLE_SIZE = 3; - static constexpr Column SRC_SELECTOR = Column::execution_sel_should_check_gas; + static constexpr Column SRC_SELECTOR = Column::execution_sel_check_gas; static constexpr Column DST_SELECTOR = Column::gt_sel_gas; static constexpr Column COUNTS = Column::lookup_gas_is_out_of_gas_l2_counts; static constexpr Column INVERSES = Column::lookup_gas_is_out_of_gas_l2_inv; @@ -63,7 +63,7 @@ struct lookup_gas_is_out_of_gas_da_settings_ { static constexpr std::string_view NAME = "LOOKUP_GAS_IS_OUT_OF_GAS_DA"; static constexpr std::string_view RELATION_NAME = "gas"; static constexpr size_t LOOKUP_TUPLE_SIZE = 3; - static constexpr Column SRC_SELECTOR = Column::execution_sel_should_check_gas; + static constexpr Column SRC_SELECTOR = Column::execution_sel_check_gas; static constexpr Column DST_SELECTOR = Column::gt_sel_gas; static constexpr Column COUNTS = Column::lookup_gas_is_out_of_gas_da_counts; static constexpr Column INVERSES = Column::lookup_gas_is_out_of_gas_da_inv; diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/lookups_tx.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/lookups_tx.hpp index af94c04c96db..816e1ed908f6 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/lookups_tx.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/lookups_tx.hpp @@ -91,7 +91,7 @@ struct lookup_tx_read_public_call_request_phase_settings_ { static constexpr std::string_view NAME = "LOOKUP_TX_READ_PUBLIC_CALL_REQUEST_PHASE"; static constexpr std::string_view RELATION_NAME = "tx"; static constexpr size_t LOOKUP_TUPLE_SIZE = 5; - static constexpr Column SRC_SELECTOR = Column::tx_should_process_call_request; + static constexpr Column SRC_SELECTOR = Column::tx_sel_process_call_request; static constexpr Column DST_SELECTOR = Column::public_inputs_sel; static constexpr Column COUNTS = Column::lookup_tx_read_public_call_request_phase_counts; static constexpr Column INVERSES = Column::lookup_tx_read_public_call_request_phase_inv; @@ -142,7 +142,7 @@ struct lookup_tx_note_hash_append_settings_ { static constexpr std::string_view NAME = "LOOKUP_TX_NOTE_HASH_APPEND"; static constexpr std::string_view RELATION_NAME = "tx"; static constexpr size_t LOOKUP_TUPLE_SIZE = 8; - static constexpr Column SRC_SELECTOR = Column::tx_should_note_hash_append; + static constexpr Column SRC_SELECTOR = Column::tx_sel_note_hash_append; static constexpr Column DST_SELECTOR = Column::note_hash_tree_check_write; static constexpr Column COUNTS = Column::lookup_tx_note_hash_append_counts; static constexpr Column INVERSES = Column::lookup_tx_note_hash_append_inv; @@ -174,7 +174,7 @@ struct lookup_tx_nullifier_append_settings_ { static constexpr std::string_view NAME = "LOOKUP_TX_NULLIFIER_APPEND"; static constexpr std::string_view RELATION_NAME = "tx"; static constexpr size_t LOOKUP_TUPLE_SIZE = 10; - static constexpr Column SRC_SELECTOR = Column::tx_should_nullifier_append; + static constexpr Column SRC_SELECTOR = Column::tx_sel_nullifier_append; static constexpr Column DST_SELECTOR = Column::indexed_tree_check_write; static constexpr Column COUNTS = Column::lookup_tx_nullifier_append_counts; static constexpr Column INVERSES = Column::lookup_tx_nullifier_append_inv; @@ -214,7 +214,7 @@ struct lookup_tx_read_l2_l1_msg_settings_ { static constexpr std::string_view NAME = "LOOKUP_TX_READ_L2_L1_MSG"; static constexpr std::string_view RELATION_NAME = "tx"; static constexpr size_t LOOKUP_TUPLE_SIZE = 4; - static constexpr Column SRC_SELECTOR = Column::tx_should_try_l2_l1_msg_append; + static constexpr Column SRC_SELECTOR = Column::tx_sel_try_l2_l1_msg_append; static constexpr Column DST_SELECTOR = Column::public_inputs_sel; static constexpr Column COUNTS = Column::lookup_tx_read_l2_l1_msg_counts; static constexpr Column INVERSES = Column::lookup_tx_read_l2_l1_msg_inv; @@ -242,7 +242,7 @@ struct lookup_tx_write_l2_l1_msg_settings_ { static constexpr std::string_view NAME = "LOOKUP_TX_WRITE_L2_L1_MSG"; static constexpr std::string_view RELATION_NAME = "tx"; static constexpr size_t LOOKUP_TUPLE_SIZE = 4; - static constexpr Column SRC_SELECTOR = Column::tx_should_l2_l1_msg_append; + static constexpr Column SRC_SELECTOR = Column::tx_sel_l2_l1_msg_append; static constexpr Column DST_SELECTOR = Column::public_inputs_sel; static constexpr Column COUNTS = Column::lookup_tx_write_l2_l1_msg_counts; static constexpr Column INVERSES = Column::lookup_tx_write_l2_l1_msg_inv; diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/memory.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/memory.hpp index 264ab9bb93bd..1a9fcea17707 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/memory.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/memory.hpp @@ -17,7 +17,7 @@ template class memoryImpl { static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, 3, 3, 3, - 3, 4, 3, 5, 5, 2, 4, 4, 4, 4, 5, 3 }; + 3, 3, 3, 5, 5, 2, 4, 4, 4, 4, 5, 3 }; template inline static bool skip(const AllEntities& in) { diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/memory_impl.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/memory_impl.hpp index 30dfb9fe45f6..796a1744fad2 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/memory_impl.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/memory_impl.hpp @@ -341,8 +341,9 @@ void memoryImpl::accumulate(ContainerOverSubrelations& evals, } { // MEM_CONTINUITY using View = typename std::tuple_element_t<46, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::precomputed_first_row))) * - (FF(1) - static_cast(in.get(C::memory_sel))) * static_cast(in.get(C::memory_sel_shift)); + auto tmp = + ((FF(1) - static_cast(in.get(C::precomputed_first_row))) - static_cast(in.get(C::memory_sel))) * + static_cast(in.get(C::memory_sel_shift)); std::get<46>(evals) += (tmp * scaling_factor); } { // SEL_RNG_CHK diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/perms_addressing.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/perms_addressing.hpp index ad375a2eb639..a5f8dfafee87 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/perms_addressing.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/perms_addressing.hpp @@ -46,7 +46,7 @@ struct perm_addressing_indirect_from_memory_0_settings_ { static constexpr std::string_view NAME = "PERM_ADDRESSING_INDIRECT_FROM_MEMORY_0"; static constexpr std::string_view RELATION_NAME = "addressing"; static constexpr size_t COLUMNS_PER_SET = 6; - static constexpr Column SRC_SELECTOR = Column::execution_sel_should_apply_indirection_0_; + static constexpr Column SRC_SELECTOR = Column::execution_sel_apply_indirection_0_; static constexpr Column DST_SELECTOR = Column::memory_sel_addressing_indirect_0_; static constexpr Column INVERSES = Column::perm_addressing_indirect_from_memory_0_inv; static constexpr std::array SRC_COLUMNS = { @@ -75,7 +75,7 @@ struct perm_addressing_indirect_from_memory_1_settings_ { static constexpr std::string_view NAME = "PERM_ADDRESSING_INDIRECT_FROM_MEMORY_1"; static constexpr std::string_view RELATION_NAME = "addressing"; static constexpr size_t COLUMNS_PER_SET = 6; - static constexpr Column SRC_SELECTOR = Column::execution_sel_should_apply_indirection_1_; + static constexpr Column SRC_SELECTOR = Column::execution_sel_apply_indirection_1_; static constexpr Column DST_SELECTOR = Column::memory_sel_addressing_indirect_1_; static constexpr Column INVERSES = Column::perm_addressing_indirect_from_memory_1_inv; static constexpr std::array SRC_COLUMNS = { @@ -104,7 +104,7 @@ struct perm_addressing_indirect_from_memory_2_settings_ { static constexpr std::string_view NAME = "PERM_ADDRESSING_INDIRECT_FROM_MEMORY_2"; static constexpr std::string_view RELATION_NAME = "addressing"; static constexpr size_t COLUMNS_PER_SET = 6; - static constexpr Column SRC_SELECTOR = Column::execution_sel_should_apply_indirection_2_; + static constexpr Column SRC_SELECTOR = Column::execution_sel_apply_indirection_2_; static constexpr Column DST_SELECTOR = Column::memory_sel_addressing_indirect_2_; static constexpr Column INVERSES = Column::perm_addressing_indirect_from_memory_2_inv; static constexpr std::array SRC_COLUMNS = { @@ -133,7 +133,7 @@ struct perm_addressing_indirect_from_memory_3_settings_ { static constexpr std::string_view NAME = "PERM_ADDRESSING_INDIRECT_FROM_MEMORY_3"; static constexpr std::string_view RELATION_NAME = "addressing"; static constexpr size_t COLUMNS_PER_SET = 6; - static constexpr Column SRC_SELECTOR = Column::execution_sel_should_apply_indirection_3_; + static constexpr Column SRC_SELECTOR = Column::execution_sel_apply_indirection_3_; static constexpr Column DST_SELECTOR = Column::memory_sel_addressing_indirect_3_; static constexpr Column INVERSES = Column::perm_addressing_indirect_from_memory_3_inv; static constexpr std::array SRC_COLUMNS = { @@ -162,7 +162,7 @@ struct perm_addressing_indirect_from_memory_4_settings_ { static constexpr std::string_view NAME = "PERM_ADDRESSING_INDIRECT_FROM_MEMORY_4"; static constexpr std::string_view RELATION_NAME = "addressing"; static constexpr size_t COLUMNS_PER_SET = 6; - static constexpr Column SRC_SELECTOR = Column::execution_sel_should_apply_indirection_4_; + static constexpr Column SRC_SELECTOR = Column::execution_sel_apply_indirection_4_; static constexpr Column DST_SELECTOR = Column::memory_sel_addressing_indirect_4_; static constexpr Column INVERSES = Column::perm_addressing_indirect_from_memory_4_inv; static constexpr std::array SRC_COLUMNS = { @@ -191,7 +191,7 @@ struct perm_addressing_indirect_from_memory_5_settings_ { static constexpr std::string_view NAME = "PERM_ADDRESSING_INDIRECT_FROM_MEMORY_5"; static constexpr std::string_view RELATION_NAME = "addressing"; static constexpr size_t COLUMNS_PER_SET = 6; - static constexpr Column SRC_SELECTOR = Column::execution_sel_should_apply_indirection_5_; + static constexpr Column SRC_SELECTOR = Column::execution_sel_apply_indirection_5_; static constexpr Column DST_SELECTOR = Column::memory_sel_addressing_indirect_5_; static constexpr Column INVERSES = Column::perm_addressing_indirect_from_memory_5_inv; static constexpr std::array SRC_COLUMNS = { @@ -220,7 +220,7 @@ struct perm_addressing_indirect_from_memory_6_settings_ { static constexpr std::string_view NAME = "PERM_ADDRESSING_INDIRECT_FROM_MEMORY_6"; static constexpr std::string_view RELATION_NAME = "addressing"; static constexpr size_t COLUMNS_PER_SET = 6; - static constexpr Column SRC_SELECTOR = Column::execution_sel_should_apply_indirection_6_; + static constexpr Column SRC_SELECTOR = Column::execution_sel_apply_indirection_6_; static constexpr Column DST_SELECTOR = Column::memory_sel_addressing_indirect_6_; static constexpr Column INVERSES = Column::perm_addressing_indirect_from_memory_6_inv; static constexpr std::array SRC_COLUMNS = { diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/perms_tx.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/perms_tx.hpp index 5c6084f5cb0f..66351d911ae6 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/perms_tx.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/perms_tx.hpp @@ -17,7 +17,7 @@ struct perm_tx_read_calldata_hash_settings_ { static constexpr std::string_view NAME = "PERM_TX_READ_CALLDATA_HASH"; static constexpr std::string_view RELATION_NAME = "tx"; static constexpr size_t COLUMNS_PER_SET = 3; - static constexpr Column SRC_SELECTOR = Column::tx_should_process_call_request; + static constexpr Column SRC_SELECTOR = Column::tx_sel_process_call_request; static constexpr Column DST_SELECTOR = Column::calldata_hashing_end; static constexpr Column INVERSES = Column::perm_tx_read_calldata_hash_inv; static constexpr std::array SRC_COLUMNS = { ColumnAndShifts::tx_calldata_hash, @@ -40,7 +40,7 @@ struct perm_tx_dispatch_exec_start_settings_ { static constexpr std::string_view NAME = "PERM_TX_DISPATCH_EXEC_START"; static constexpr std::string_view RELATION_NAME = "tx"; static constexpr size_t COLUMNS_PER_SET = 26; - static constexpr Column SRC_SELECTOR = Column::tx_should_process_call_request; + static constexpr Column SRC_SELECTOR = Column::tx_sel_process_call_request; static constexpr Column DST_SELECTOR = Column::execution_enqueued_call_start; static constexpr Column INVERSES = Column::perm_tx_dispatch_exec_start_inv; static constexpr std::array SRC_COLUMNS = { @@ -111,7 +111,7 @@ struct perm_tx_dispatch_exec_end_settings_ { static constexpr std::string_view NAME = "PERM_TX_DISPATCH_EXEC_END"; static constexpr std::string_view RELATION_NAME = "tx"; static constexpr size_t COLUMNS_PER_SET = 20; - static constexpr Column SRC_SELECTOR = Column::tx_should_process_call_request; + static constexpr Column SRC_SELECTOR = Column::tx_sel_process_call_request; static constexpr Column DST_SELECTOR = Column::execution_enqueued_call_end; static constexpr Column INVERSES = Column::perm_tx_dispatch_exec_end_inv; static constexpr std::array SRC_COLUMNS = { diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_check.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_check.hpp index da63b0874828..701becb78fce 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_check.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_check.hpp @@ -14,7 +14,7 @@ template class public_data_checkImpl { public: using FF = FF_; - static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { 3, 4, 3, 2, 3, 3, 3, 3, 2, 3, 3, 3, + static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { 3, 3, 3, 2, 3, 3, 3, 3, 2, 3, 3, 3, 3, 3, 3, 3, 3, 5, 3, 5, 4, 4, 4, 3, 4, 3, 4, 2, 4, 3, 3, 3, 3, 3 }; diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_check_impl.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_check_impl.hpp index d9c905736ad8..6bb9718b6695 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_check_impl.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_check_impl.hpp @@ -36,9 +36,9 @@ void public_data_checkImpl::accumulate(ContainerOverSubrelations& evals, } { // TRACE_CONTINUITY using View = typename std::tuple_element_t<1, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::public_data_check_sel_shift)) * - (FF(1) - static_cast(in.get(C::public_data_check_sel))) * - (FF(1) - static_cast(in.get(C::precomputed_first_row))); + auto tmp = ((FF(1) - static_cast(in.get(C::public_data_check_sel))) - + static_cast(in.get(C::precomputed_first_row))) * + static_cast(in.get(C::public_data_check_sel_shift)); std::get<1>(evals) += (tmp * scaling_factor); } { diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_squash.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_squash.hpp index 5b6703468dc9..340dbdd3aa91 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_squash.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_squash.hpp @@ -14,7 +14,7 @@ template class public_data_squashImpl { public: using FF = FF_; - static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { 3, 4, 3, 3, 4, 4, 3, 3, 3, 3, 4 }; + static constexpr std::array SUBRELATION_PARTIAL_LENGTHS = { 3, 3, 3, 3, 4, 4, 3, 3, 3, 3, 4 }; template inline static bool skip(const AllEntities& in) { diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_squash_impl.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_squash_impl.hpp index 5ad6e0552d76..88a5353207b3 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_squash_impl.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/public_data_squash_impl.hpp @@ -32,9 +32,9 @@ void public_data_squashImpl::accumulate(ContainerOverSubrelations& evals, } { // TRACE_CONTINUITY using View = typename std::tuple_element_t<1, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::public_data_squash_sel_shift)) * - (FF(1) - static_cast(in.get(C::public_data_squash_sel))) * - (FF(1) - static_cast(in.get(C::precomputed_first_row))); + auto tmp = ((FF(1) - static_cast(in.get(C::public_data_squash_sel))) - + static_cast(in.get(C::precomputed_first_row))) * + static_cast(in.get(C::public_data_squash_sel_shift)); std::get<1>(evals) += (tmp * scaling_factor); } { diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/registers.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/registers.hpp index a5a769cbfd29..d414adfce0ba 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/registers.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/registers.hpp @@ -20,7 +20,7 @@ template class registersImpl { { using C = ColumnAndShifts; - return (in.get(C::execution_sel_should_read_registers)).is_zero(); + return (in.get(C::execution_sel_read_registers)).is_zero(); } template diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/registers_impl.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/registers_impl.hpp index a60174bf6464..5e9a4affe264 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/registers_impl.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/registers_impl.hpp @@ -29,7 +29,7 @@ void registersImpl::accumulate(ContainerOverSubrelations& evals, in.get(C::execution_sel_tag_check_reg_5_) * FF(32768) * (in.get(C::execution_mem_tag_reg_5_) - in.get(C::execution_expected_tag_reg_5_)); const auto execution_BATCHED_TAGS_DIFF_X_REG = - in.get(C::execution_sel_should_read_registers) * execution_BATCHED_TAGS_DIFF_REG; + in.get(C::execution_sel_read_registers) * execution_BATCHED_TAGS_DIFF_REG; const auto execution_BATCHED_TAGS_DIFF_Y_REG = in.get(C::execution_batched_tags_diff_inv_reg); const auto execution_BATCHED_TAGS_DIFF_E_REG = (FF(1) - in.get(C::execution_sel_register_read_error)); const auto execution_BATCHED_TAGS_DIFF_EQ_REG = @@ -43,9 +43,9 @@ void registersImpl::accumulate(ContainerOverSubrelations& evals, using View = typename std::tuple_element_t<0, ContainerOverSubrelations>::View; auto tmp = (static_cast(in.get(C::execution_sel_op_reg_effective_0_)) - static_cast(in.get(C::execution_sel_mem_op_reg_0_)) * - (static_cast(in.get(C::execution_sel_should_read_registers)) * + (static_cast(in.get(C::execution_sel_read_registers)) * (FF(1) - static_cast(in.get(C::execution_rw_reg_0_))) + - static_cast(in.get(C::execution_sel_should_write_registers)) * + static_cast(in.get(C::execution_sel_write_registers)) * static_cast(in.get(C::execution_rw_reg_0_)))); std::get<0>(evals) += (tmp * scaling_factor); } @@ -53,9 +53,9 @@ void registersImpl::accumulate(ContainerOverSubrelations& evals, using View = typename std::tuple_element_t<1, ContainerOverSubrelations>::View; auto tmp = (static_cast(in.get(C::execution_sel_op_reg_effective_1_)) - static_cast(in.get(C::execution_sel_mem_op_reg_1_)) * - (static_cast(in.get(C::execution_sel_should_read_registers)) * + (static_cast(in.get(C::execution_sel_read_registers)) * (FF(1) - static_cast(in.get(C::execution_rw_reg_1_))) + - static_cast(in.get(C::execution_sel_should_write_registers)) * + static_cast(in.get(C::execution_sel_write_registers)) * static_cast(in.get(C::execution_rw_reg_1_)))); std::get<1>(evals) += (tmp * scaling_factor); } @@ -63,9 +63,9 @@ void registersImpl::accumulate(ContainerOverSubrelations& evals, using View = typename std::tuple_element_t<2, ContainerOverSubrelations>::View; auto tmp = (static_cast(in.get(C::execution_sel_op_reg_effective_2_)) - static_cast(in.get(C::execution_sel_mem_op_reg_2_)) * - (static_cast(in.get(C::execution_sel_should_read_registers)) * + (static_cast(in.get(C::execution_sel_read_registers)) * (FF(1) - static_cast(in.get(C::execution_rw_reg_2_))) + - static_cast(in.get(C::execution_sel_should_write_registers)) * + static_cast(in.get(C::execution_sel_write_registers)) * static_cast(in.get(C::execution_rw_reg_2_)))); std::get<2>(evals) += (tmp * scaling_factor); } @@ -73,9 +73,9 @@ void registersImpl::accumulate(ContainerOverSubrelations& evals, using View = typename std::tuple_element_t<3, ContainerOverSubrelations>::View; auto tmp = (static_cast(in.get(C::execution_sel_op_reg_effective_3_)) - static_cast(in.get(C::execution_sel_mem_op_reg_3_)) * - (static_cast(in.get(C::execution_sel_should_read_registers)) * + (static_cast(in.get(C::execution_sel_read_registers)) * (FF(1) - static_cast(in.get(C::execution_rw_reg_3_))) + - static_cast(in.get(C::execution_sel_should_write_registers)) * + static_cast(in.get(C::execution_sel_write_registers)) * static_cast(in.get(C::execution_rw_reg_3_)))); std::get<3>(evals) += (tmp * scaling_factor); } @@ -83,9 +83,9 @@ void registersImpl::accumulate(ContainerOverSubrelations& evals, using View = typename std::tuple_element_t<4, ContainerOverSubrelations>::View; auto tmp = (static_cast(in.get(C::execution_sel_op_reg_effective_4_)) - static_cast(in.get(C::execution_sel_mem_op_reg_4_)) * - (static_cast(in.get(C::execution_sel_should_read_registers)) * + (static_cast(in.get(C::execution_sel_read_registers)) * (FF(1) - static_cast(in.get(C::execution_rw_reg_4_))) + - static_cast(in.get(C::execution_sel_should_write_registers)) * + static_cast(in.get(C::execution_sel_write_registers)) * static_cast(in.get(C::execution_rw_reg_4_)))); std::get<4>(evals) += (tmp * scaling_factor); } @@ -93,9 +93,9 @@ void registersImpl::accumulate(ContainerOverSubrelations& evals, using View = typename std::tuple_element_t<5, ContainerOverSubrelations>::View; auto tmp = (static_cast(in.get(C::execution_sel_op_reg_effective_5_)) - static_cast(in.get(C::execution_sel_mem_op_reg_5_)) * - (static_cast(in.get(C::execution_sel_should_read_registers)) * + (static_cast(in.get(C::execution_sel_read_registers)) * (FF(1) - static_cast(in.get(C::execution_rw_reg_5_))) + - static_cast(in.get(C::execution_sel_should_write_registers)) * + static_cast(in.get(C::execution_sel_write_registers)) * static_cast(in.get(C::execution_rw_reg_5_)))); std::get<5>(evals) += (tmp * scaling_factor); } diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/tx_context_impl.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/tx_context_impl.hpp index 5f0c04c93f58..e4163fab6215 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/tx_context_impl.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/tx_context_impl.hpp @@ -424,14 +424,14 @@ void tx_contextImpl::accumulate(ContainerOverSubrelations& evals, } { // RETRIEVED_BYTECODES_TREE_ROOT_IMMUTABILITY using View = typename std::tuple_element_t<54, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::tx_should_process_call_request))) * + auto tmp = (FF(1) - static_cast(in.get(C::tx_sel_process_call_request))) * (static_cast(in.get(C::tx_prev_retrieved_bytecodes_tree_root)) - static_cast(in.get(C::tx_next_retrieved_bytecodes_tree_root))); std::get<54>(evals) += (tmp * scaling_factor); } { // RETRIEVED_BYTECODES_TREE_SIZE_IMMUTABILITY using View = typename std::tuple_element_t<55, ContainerOverSubrelations>::View; - auto tmp = (FF(1) - static_cast(in.get(C::tx_should_process_call_request))) * + auto tmp = (FF(1) - static_cast(in.get(C::tx_sel_process_call_request))) * (static_cast(in.get(C::tx_prev_retrieved_bytecodes_tree_size)) - static_cast(in.get(C::tx_next_retrieved_bytecodes_tree_size))); std::get<55>(evals) += (tmp * scaling_factor); @@ -523,14 +523,14 @@ void tx_contextImpl::accumulate(ContainerOverSubrelations& evals, { // L2_GAS_USED_IMMUTABILITY using View = typename std::tuple_element_t<68, ContainerOverSubrelations>::View; auto tmp = - (FF(1) - static_cast(in.get(C::tx_should_process_call_request))) * + (FF(1) - static_cast(in.get(C::tx_sel_process_call_request))) * (static_cast(in.get(C::tx_prev_l2_gas_used)) - static_cast(in.get(C::tx_next_l2_gas_used))); std::get<68>(evals) += (tmp * scaling_factor); } { // DA_GAS_USED_IMMUTABILITY using View = typename std::tuple_element_t<69, ContainerOverSubrelations>::View; auto tmp = - (FF(1) - static_cast(in.get(C::tx_should_process_call_request))) * + (FF(1) - static_cast(in.get(C::tx_sel_process_call_request))) * (static_cast(in.get(C::tx_prev_da_gas_used)) - static_cast(in.get(C::tx_next_da_gas_used))); std::get<69>(evals) += (tmp * scaling_factor); } @@ -571,7 +571,7 @@ void tx_contextImpl::accumulate(ContainerOverSubrelations& evals, { // NEXT_CONTEXT_ID_CONTINUITY using View = typename std::tuple_element_t<75, ContainerOverSubrelations>::View; auto tmp = - CView(tx_NOT_LAST_ROW) * (FF(1) - static_cast(in.get(C::tx_should_process_call_request))) * + CView(tx_NOT_LAST_ROW) * (FF(1) - static_cast(in.get(C::tx_sel_process_call_request))) * (static_cast(in.get(C::tx_next_context_id_shift)) - static_cast(in.get(C::tx_next_context_id))); std::get<75>(evals) += (tmp * scaling_factor); } diff --git a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/tx_impl.hpp b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/tx_impl.hpp index 39d2b161c724..f85ba389f749 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/generated/relations/tx_impl.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/generated/relations/tx_impl.hpp @@ -195,14 +195,14 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { using View = typename std::tuple_element_t<24, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::tx_should_process_call_request)) - + auto tmp = (static_cast(in.get(C::tx_sel_process_call_request)) - (static_cast(in.get(C::tx_sel)) - static_cast(in.get(C::tx_is_padded))) * static_cast(in.get(C::tx_is_public_call_request))); std::get<24>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<25, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_process_call_request)) * + auto tmp = static_cast(in.get(C::tx_sel_process_call_request)) * (((FF(0) - static_cast(in.get(C::tx_prev_l2_gas_used))) * static_cast(in.get(C::tx_is_teardown)) + static_cast(in.get(C::tx_prev_l2_gas_used))) - @@ -211,7 +211,7 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { using View = typename std::tuple_element_t<26, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_process_call_request)) * + auto tmp = static_cast(in.get(C::tx_sel_process_call_request)) * (((FF(0) - static_cast(in.get(C::tx_prev_da_gas_used))) * static_cast(in.get(C::tx_is_teardown)) + static_cast(in.get(C::tx_prev_da_gas_used))) - @@ -220,7 +220,7 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { using View = typename std::tuple_element_t<27, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_process_call_request)) * + auto tmp = static_cast(in.get(C::tx_sel_process_call_request)) * (((static_cast(in.get(C::tx_prev_l2_gas_used)) - static_cast(in.get(C::tx_next_l2_gas_used_sent_to_enqueued_call))) * static_cast(in.get(C::tx_is_teardown)) + @@ -230,7 +230,7 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { using View = typename std::tuple_element_t<28, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_process_call_request)) * + auto tmp = static_cast(in.get(C::tx_sel_process_call_request)) * (((static_cast(in.get(C::tx_prev_da_gas_used)) - static_cast(in.get(C::tx_next_da_gas_used_sent_to_enqueued_call))) * static_cast(in.get(C::tx_is_teardown)) + @@ -249,7 +249,7 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { using View = typename std::tuple_element_t<30, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::tx_should_try_note_hash_append)) - + auto tmp = (static_cast(in.get(C::tx_sel_try_note_hash_append)) - (static_cast(in.get(C::tx_sel)) - static_cast(in.get(C::tx_is_padded))) * (static_cast(in.get(C::tx_sel_revertible_append_note_hash)) + static_cast(in.get(C::tx_sel_non_revertible_append_note_hash)))); @@ -257,7 +257,7 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { // MAX_NOTE_HASH_WRITES_REACHED using View = typename std::tuple_element_t<31, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_try_note_hash_append)) * + auto tmp = static_cast(in.get(C::tx_sel_try_note_hash_append)) * ((CView(tx_REMAINING_NOTE_HASH_WRITES) * (static_cast(in.get(C::tx_reverted)) * (FF(1) - static_cast(in.get(C::tx_remaining_side_effects_inv))) + @@ -268,28 +268,28 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { using View = typename std::tuple_element_t<32, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::tx_should_note_hash_append)) - - static_cast(in.get(C::tx_should_try_note_hash_append)) * + auto tmp = (static_cast(in.get(C::tx_sel_note_hash_append)) - + static_cast(in.get(C::tx_sel_try_note_hash_append)) * (FF(1) - static_cast(in.get(C::tx_reverted)))); std::get<32>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<33, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_note_hash_append)) * + auto tmp = static_cast(in.get(C::tx_sel_note_hash_append)) * ((static_cast(in.get(C::tx_prev_note_hash_tree_size)) + FF(1)) - static_cast(in.get(C::tx_next_note_hash_tree_size))); std::get<33>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<34, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_note_hash_append)) * + auto tmp = static_cast(in.get(C::tx_sel_note_hash_append)) * ((static_cast(in.get(C::tx_prev_num_note_hashes_emitted)) + FF(1)) - static_cast(in.get(C::tx_next_num_note_hashes_emitted))); std::get<34>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<35, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::tx_should_try_nullifier_append)) - + auto tmp = (static_cast(in.get(C::tx_sel_try_nullifier_append)) - (static_cast(in.get(C::tx_sel)) - static_cast(in.get(C::tx_is_padded))) * (static_cast(in.get(C::tx_sel_revertible_append_nullifier)) + static_cast(in.get(C::tx_sel_non_revertible_append_nullifier)))); @@ -303,7 +303,7 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { // MAX_NULLIFIER_WRITES_REACHED using View = typename std::tuple_element_t<37, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_try_nullifier_append)) * + auto tmp = static_cast(in.get(C::tx_sel_try_nullifier_append)) * ((CView(tx_REMAINING_NULLIFIER_WRITES) * (static_cast(in.get(C::tx_nullifier_limit_error)) * (FF(1) - static_cast(in.get(C::tx_remaining_side_effects_inv))) + @@ -314,21 +314,21 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { using View = typename std::tuple_element_t<38, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_try_nullifier_append)) * + auto tmp = static_cast(in.get(C::tx_sel_try_nullifier_append)) * static_cast(in.get(C::tx_nullifier_limit_error)) * (FF(1) - static_cast(in.get(C::tx_reverted))); std::get<38>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<39, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::tx_should_nullifier_append)) - - static_cast(in.get(C::tx_should_try_nullifier_append)) * + auto tmp = (static_cast(in.get(C::tx_sel_nullifier_append)) - + static_cast(in.get(C::tx_sel_try_nullifier_append)) * (FF(1) - static_cast(in.get(C::tx_nullifier_limit_error)))); std::get<39>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<40, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_nullifier_append)) * + auto tmp = static_cast(in.get(C::tx_sel_nullifier_append)) * ((CView(constants_AVM_PUBLIC_INPUTS_AVM_ACCUMULATED_DATA_NULLIFIERS_ROW_IDX) + static_cast(in.get(C::tx_prev_num_nullifiers_emitted))) - static_cast(in.get(C::tx_write_nullifier_pi_offset))); @@ -336,34 +336,34 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { using View = typename std::tuple_element_t<41, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_nullifier_append)) * + auto tmp = static_cast(in.get(C::tx_sel_nullifier_append)) * (static_cast(in.get(C::tx_nullifier_tree_height)) - CView(constants_NULLIFIER_TREE_HEIGHT)); std::get<41>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<42, ContainerOverSubrelations>::View; auto tmp = - static_cast(in.get(C::tx_should_nullifier_append)) * + static_cast(in.get(C::tx_sel_nullifier_append)) * (static_cast(in.get(C::tx_nullifier_merkle_separator)) - CView(constants_DOM_SEP__NULLIFIER_MERKLE)); std::get<42>(evals) += (tmp * scaling_factor); } { // NULLIFIER_TREE_SIZE_INCREMENT using View = typename std::tuple_element_t<43, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_nullifier_append)) * + auto tmp = static_cast(in.get(C::tx_sel_nullifier_append)) * ((static_cast(in.get(C::tx_prev_nullifier_tree_size)) + FF(1)) - static_cast(in.get(C::tx_next_nullifier_tree_size))); std::get<43>(evals) += (tmp * scaling_factor); } { // NULLIFIER_EMITTED_COUNT_INCREMENT using View = typename std::tuple_element_t<44, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_nullifier_append)) * + auto tmp = static_cast(in.get(C::tx_sel_nullifier_append)) * ((static_cast(in.get(C::tx_prev_num_nullifiers_emitted)) + FF(1)) - static_cast(in.get(C::tx_next_num_nullifiers_emitted))); std::get<44>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<45, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::tx_should_try_l2_l1_msg_append)) - + auto tmp = (static_cast(in.get(C::tx_sel_try_l2_l1_msg_append)) - (static_cast(in.get(C::tx_sel)) - static_cast(in.get(C::tx_is_padded))) * (static_cast(in.get(C::tx_sel_revertible_append_l2_l1_msg)) + static_cast(in.get(C::tx_sel_non_revertible_append_l2_l1_msg)))); @@ -371,7 +371,7 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { // MAX_L2_L1_MSG_WRITES_REACHED using View = typename std::tuple_element_t<46, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_try_l2_l1_msg_append)) * + auto tmp = static_cast(in.get(C::tx_sel_try_l2_l1_msg_append)) * ((CView(tx_REMAINING_L2_TO_L1_MSG_WRITES) * (static_cast(in.get(C::tx_reverted)) * (FF(1) - static_cast(in.get(C::tx_remaining_side_effects_inv))) + @@ -382,15 +382,15 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { using View = typename std::tuple_element_t<47, ContainerOverSubrelations>::View; - auto tmp = (static_cast(in.get(C::tx_should_l2_l1_msg_append)) - - static_cast(in.get(C::tx_should_try_l2_l1_msg_append)) * + auto tmp = (static_cast(in.get(C::tx_sel_l2_l1_msg_append)) - + static_cast(in.get(C::tx_sel_try_l2_l1_msg_append)) * (FF(1) - static_cast(in.get(C::tx_reverted))) * (FF(1) - static_cast(in.get(C::tx_discard)))); std::get<47>(evals) += (tmp * scaling_factor); } { using View = typename std::tuple_element_t<48, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_l2_l1_msg_append)) * + auto tmp = static_cast(in.get(C::tx_sel_l2_l1_msg_append)) * ((CView(constants_AVM_PUBLIC_INPUTS_AVM_ACCUMULATED_DATA_L2_TO_L1_MSGS_ROW_IDX) + static_cast(in.get(C::tx_prev_num_l2_to_l1_messages))) - static_cast(in.get(C::tx_write_pi_offset))); @@ -398,7 +398,7 @@ void txImpl::accumulate(ContainerOverSubrelations& evals, } { // UPDATE_NUM_L2_TO_L1_MSGS using View = typename std::tuple_element_t<49, ContainerOverSubrelations>::View; - auto tmp = static_cast(in.get(C::tx_should_try_l2_l1_msg_append)) * + auto tmp = static_cast(in.get(C::tx_sel_try_l2_l1_msg_append)) * (FF(1) - static_cast(in.get(C::tx_reverted))) * ((static_cast(in.get(C::tx_prev_num_l2_to_l1_messages)) + FF(1)) - static_cast(in.get(C::tx_next_num_l2_to_l1_messages))); diff --git a/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution.cpp b/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution.cpp index 5c1e96bd2037..7fe522407264 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution.cpp @@ -1,13 +1,12 @@ #include "barretenberg/vm2/simulation/gadgets/execution.hpp" +#include #include -#include #include #include "barretenberg/common/bb_bench.hpp" #include "barretenberg/common/log.hpp" #include "barretenberg/vm2/common/aztec_constants.hpp" -#include "barretenberg/vm2/common/tagged_value.hpp" #include "barretenberg/vm2/common/to_radix.hpp" #include "barretenberg/vm2/common/uint1.hpp" #include "barretenberg/vm2/simulation/events/addressing_event.hpp" @@ -19,6 +18,7 @@ #include "barretenberg/vm2/simulation/events/keccakf1600_event.hpp" #include "barretenberg/vm2/simulation/events/poseidon2_event.hpp" #include "barretenberg/vm2/simulation/events/sha256_event.hpp" +// Interface headers not included in execution.hpp because the types are forward-declared there. #include "barretenberg/vm2/simulation/interfaces/addressing.hpp" #include "barretenberg/vm2/simulation/interfaces/alu.hpp" #include "barretenberg/vm2/simulation/interfaces/bitwise.hpp" @@ -26,6 +26,7 @@ #include "barretenberg/vm2/simulation/interfaces/call_stack_metadata_collector.hpp" #include "barretenberg/vm2/simulation/interfaces/context_provider.hpp" #include "barretenberg/vm2/simulation/interfaces/data_copy.hpp" +#include "barretenberg/vm2/simulation/interfaces/db.hpp" #include "barretenberg/vm2/simulation/interfaces/debug_log.hpp" #include "barretenberg/vm2/simulation/interfaces/ecc.hpp" #include "barretenberg/vm2/simulation/interfaces/emit_public_log.hpp" diff --git a/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution.hpp b/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution.hpp index 0806bcc4f226..2c40a5d412f3 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution.hpp @@ -3,34 +3,23 @@ #include #include #include +#include +#include #include #include "barretenberg/vm2/common/aztec_types.hpp" #include "barretenberg/vm2/common/field.hpp" #include "barretenberg/vm2/common/memory_types.hpp" #include "barretenberg/vm2/common/opcodes.hpp" -#include "barretenberg/vm2/common/tagged_value.hpp" #include "barretenberg/vm2/simulation/events/context_events.hpp" #include "barretenberg/vm2/simulation/events/event_emitter.hpp" #include "barretenberg/vm2/simulation/events/execution_event.hpp" -#include "barretenberg/vm2/simulation/interfaces/alu.hpp" -#include "barretenberg/vm2/simulation/interfaces/bitwise.hpp" +// Note: many interface headers are NOT included here because the corresponding types are +// forward-declared below and used only as references/pointers. The full definitions are +// included in execution.cpp instead. #include "barretenberg/vm2/simulation/interfaces/context.hpp" -#include "barretenberg/vm2/simulation/interfaces/context_provider.hpp" -#include "barretenberg/vm2/simulation/interfaces/data_copy.hpp" -#include "barretenberg/vm2/simulation/interfaces/db.hpp" -#include "barretenberg/vm2/simulation/interfaces/debug_log.hpp" -#include "barretenberg/vm2/simulation/interfaces/ecc.hpp" -#include "barretenberg/vm2/simulation/interfaces/emit_public_log.hpp" #include "barretenberg/vm2/simulation/interfaces/execution.hpp" -#include "barretenberg/vm2/simulation/interfaces/execution_components.hpp" #include "barretenberg/vm2/simulation/interfaces/gas_tracker.hpp" -#include "barretenberg/vm2/simulation/interfaces/get_contract_instance.hpp" -#include "barretenberg/vm2/simulation/interfaces/gt.hpp" -#include "barretenberg/vm2/simulation/interfaces/keccakf1600.hpp" -#include "barretenberg/vm2/simulation/interfaces/poseidon2.hpp" -#include "barretenberg/vm2/simulation/interfaces/sha256.hpp" -#include "barretenberg/vm2/simulation/interfaces/to_radix.hpp" #include "barretenberg/vm2/simulation/lib/cancellation_token.hpp" #include "barretenberg/vm2/simulation/lib/execution_id_manager.hpp" #include "barretenberg/vm2/simulation/lib/instruction_info.hpp" @@ -38,7 +27,8 @@ namespace bb::avm2::simulation { -// Forward declaration. +// Forward declarations for interface types that are only used as references in this header. +// Their full definitions are included in execution.cpp. class CallStackMetadataCollectorInterface; class AluInterface; class BitwiseInterface; @@ -49,15 +39,12 @@ class ToRadixInterface; class Sha256Interface; class ExecutionComponentsProviderInterface; class ContextProviderInterface; -class InstructionInfoDBInterface; -class ExecutionIdManagerInterface; class KeccakF1600Interface; class GreaterThanInterface; class GetContractInstanceInterface; class EmitPublicLogInterface; class DebugLoggerInterface; class HighLevelMerkleDBInterface; -class GasTrackerInterface; // In charge of executing a single enqueued call. class Execution : public ExecutionInterface { @@ -218,7 +205,6 @@ class Execution : public ExecutionInterface { std::optional halting_message; // If reverted. }; - // Only here for testing. TODO(fcarreiro): try to improve. virtual GasTrackerInterface& get_gas_tracker() { return *gas_tracker; } void set_execution_result(const ExecutionResult& exec_result) { this->exec_result = exec_result; } @@ -236,8 +222,8 @@ class Execution : public ExecutionInterface { void handle_exit_call(); void handle_exceptional_halt(ContextInterface& context, const std::string& halting_message); - // TODO(#13683): This is leaking circuit implementation details. We should have a better way to do this. - // Setters for inputs and output for gadgets/subtraces. These are used for register allocation. + // Improvement candidate #13683: This is leaking circuit implementation details. We should have a better way to do + // this. Setters for inputs and output for gadgets/subtraces. These are used for register allocation. void set_and_validate_inputs(ExecutionOpCode opcode, const std::vector& inputs); void set_output(ExecutionOpCode opcode, const MemoryValue& output); const std::vector& get_inputs() const { return inputs; } diff --git a/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution_components.cpp b/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution_components.cpp index a1071d71eab9..857a6dddc686 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution_components.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution_components.cpp @@ -1,12 +1,18 @@ #include "barretenberg/vm2/simulation/gadgets/execution_components.hpp" -#include "barretenberg/vm2/simulation/events/addressing_event.hpp" -#include "barretenberg/vm2/simulation/events/event_emitter.hpp" +#include + #include "barretenberg/vm2/simulation/gadgets/addressing.hpp" -#include "barretenberg/vm2/simulation/gadgets/context.hpp" +#include "barretenberg/vm2/simulation/gadgets/gas_tracker.hpp" namespace bb::avm2::simulation { +/** + * @brief Create an addressing resolver that writes its resolution results into the given event. + * + * @param event The addressing event to populate during resolution. + * @return A unique pointer to the addressing interface. + */ std::unique_ptr ExecutionComponentsProvider::make_addressing(AddressingEvent& event) { auto event_emitter = std::make_unique>(event); @@ -15,6 +21,14 @@ std::unique_ptr ExecutionComponentsProvider::make_addressin return addressing; } +/** + * @brief Create a gas tracker bound to the given event, instruction, and context. + * + * @param gas_event The gas event to populate during gas consumption. + * @param instruction The current instruction (for gas cost lookup). + * @param context The execution context (for gas limits and usage). + * @return A unique pointer to the gas tracker interface. + */ std::unique_ptr ExecutionComponentsProvider::make_gas_tracker(GasEvent& gas_event, const Instruction& instruction, ContextInterface& context) diff --git a/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution_components.hpp b/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution_components.hpp index 533a773c0e81..8524b5974f1d 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution_components.hpp +++ b/barretenberg/cpp/src/barretenberg/vm2/simulation/gadgets/execution_components.hpp @@ -1,22 +1,12 @@ #pragma once #include -#include +#include -#include "barretenberg/vm2/common/aztec_types.hpp" -#include "barretenberg/vm2/common/field.hpp" -#include "barretenberg/vm2/simulation/events/addressing_event.hpp" -#include "barretenberg/vm2/simulation/events/context_events.hpp" #include "barretenberg/vm2/simulation/events/event_emitter.hpp" -#include "barretenberg/vm2/simulation/events/memory_event.hpp" -#include "barretenberg/vm2/simulation/gadgets/addressing.hpp" -#include "barretenberg/vm2/simulation/gadgets/bytecode_manager.hpp" -#include "barretenberg/vm2/simulation/gadgets/context.hpp" -#include "barretenberg/vm2/simulation/gadgets/gas_tracker.hpp" -#include "barretenberg/vm2/simulation/gadgets/gt.hpp" -#include "barretenberg/vm2/simulation/gadgets/memory.hpp" -#include "barretenberg/vm2/simulation/gadgets/range_check.hpp" #include "barretenberg/vm2/simulation/interfaces/execution_components.hpp" +#include "barretenberg/vm2/simulation/interfaces/gt.hpp" +#include "barretenberg/vm2/simulation/lib/instruction_info.hpp" namespace bb::avm2::simulation { @@ -37,9 +27,8 @@ class ExecutionComponentsProvider : public ExecutionComponentsProviderInterface GreaterThanInterface& greater_than; const InstructionInfoDBInterface& instruction_info_db; - // Sadly someone has to own these. - // TODO(fcarreiro): We are creating one of these per execution row and only releasing them at - // the end of the TX. Ideally we'd improve this. + // Improvement candidate AVM-265: We are creating one of these per execution row and only + // releasing them at the end of the TX. std::vector>> addressing_event_emitters; }; diff --git a/barretenberg/cpp/src/barretenberg/vm2/tracegen/execution_trace.cpp b/barretenberg/cpp/src/barretenberg/vm2/tracegen/execution_trace.cpp index 6c9aebc7d859..b51e36b95ef1 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/tracegen/execution_trace.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/tracegen/execution_trace.cpp @@ -65,11 +65,10 @@ constexpr std::array RESOLVED_OPERAND_TAG_COLUMNS = { C::execution_rop_tag_0_, C::execution_rop_tag_1_, C::execution_rop_tag_2_, C::execution_rop_tag_3_, C::execution_rop_tag_4_, C::execution_rop_tag_5_, C::execution_rop_tag_6_, }; -constexpr std::array OPERAND_SHOULD_APPLY_INDIRECTION_COLUMNS = { - C::execution_sel_should_apply_indirection_0_, C::execution_sel_should_apply_indirection_1_, - C::execution_sel_should_apply_indirection_2_, C::execution_sel_should_apply_indirection_3_, - C::execution_sel_should_apply_indirection_4_, C::execution_sel_should_apply_indirection_5_, - C::execution_sel_should_apply_indirection_6_, +constexpr std::array OPERAND_APPLY_INDIRECTION_COLUMNS = { + C::execution_sel_apply_indirection_0_, C::execution_sel_apply_indirection_1_, C::execution_sel_apply_indirection_2_, + C::execution_sel_apply_indirection_3_, C::execution_sel_apply_indirection_4_, C::execution_sel_apply_indirection_5_, + C::execution_sel_apply_indirection_6_, }; constexpr std::array OPERAND_RELATIVE_OVERFLOW_COLUMNS = { C::execution_sel_relative_overflow_0_, C::execution_sel_relative_overflow_1_, C::execution_sel_relative_overflow_2_, @@ -291,6 +290,30 @@ uint32_t dying_context_for_phase(TransactionPhase phase, const FailingContexts& } // namespace +/** + * @brief Process the execution events and populate the relevant columns in the trace. + * ExecutionError enum is used to track the error type of the event. Each error + * type is mutually exclusive and pertains to a specific temporality group. Each + * temporality group is processed sequentially and an error prevents the processing + * of the subsequent temporality groups. + * + * Events are emitted in the following flavors (keyed by ExecutionError enum value). + * The error field is populated in all failing variants; the bullets below describe + * which additional (non-error) fields are populated: + * 1. ExecutionError::NONE — normal execution: all fields populated. + * 2. ExecutionError::BYTECODE_RETRIEVAL — TG1 failure: only context fields populated. + * 3. ExecutionError::INSTRUCTION_FETCHING — TG2 failure: context and bytecode fields populated. + * 4. ExecutionError::ADDRESSING — TG2 failure: instruction fetched but operand + * resolution failed. + * 5. ExecutionError::REGISTER_READ — TG3 failure: addressing succeeded but tag + * validation failed. + * 6. ExecutionError::GAS — TG4 failure: registers read but gas check failed. + * 7. ExecutionError::OPCODE_EXECUTION — TG5 failure: gas consumed but opcode logic + * failed, no register write. + * + * @param ex_events Container of ExecutionEvent to process. + * @param trace The trace container to populate. + */ void ExecutionTraceBuilder::process( const simulation::EventEmitterInterface::Container& ex_events, TraceContainer& trace) { @@ -491,12 +514,12 @@ void ExecutionTraceBuilder::process( * Temporality group 3: Registers read. **************************************************************************************************/ - // Note that if addressing did not fail, register reading will not fail. + // Note that if addressing did not fail, register reading will be performed. std::array registers; std::ranges::fill(registers, MemoryValue::from_tag(static_cast(0), 0)); - const bool should_process_registers = instruction_fetching_success && !addressing_failed; + const bool do_process_registers = instruction_fetching_success && !addressing_failed; const bool register_processing_failed = ex_event.error == ExecutionError::REGISTER_READ; - if (should_process_registers) { + if (do_process_registers) { process_registers( *exec_opcode, ex_event.inputs, ex_event.output, registers, register_processing_failed, trace, row); } @@ -505,8 +528,8 @@ void ExecutionTraceBuilder::process( * Temporality group 4: Gas (both base and dynamic). **************************************************************************************************/ - const bool should_check_gas = should_process_registers && !register_processing_failed; - if (should_check_gas) { + const bool check_gas = do_process_registers && !register_processing_failed; + if (check_gas) { process_gas(ex_event.gas_event, *exec_opcode, trace, row); // To_Radix Dynamic Gas Factor related selectors. @@ -542,21 +565,21 @@ void ExecutionTraceBuilder::process( * Temporality group 5: Opcode execution. **************************************************************************************************/ - const bool should_execute_opcode = should_check_gas && !oog; + const bool execute_opcode = check_gas && !oog; // These booleans are used after of the "opcode code execution" block but need // to be set as part of the "opcode code execution" block. bool sel_enter_call = false; bool sel_exit_call = false; - bool should_execute_revert = false; + bool execute_revert = false; const bool opcode_execution_failed = ex_event.error == ExecutionError::OPCODE_EXECUTION; - if (should_execute_opcode) { + if (execute_opcode) { // At this point we can assume instruction fetching succeeded, so this should never fail. const auto& dispatch_to_subtrace = get_subtrace_info_map().at(*exec_opcode); trace.set(row, { { - { C::execution_sel_should_execute_opcode, 1 }, + { C::execution_sel_execute_opcode, 1 }, { C::execution_sel_opcode_error, opcode_execution_failed ? 1 : 0 }, { get_subtrace_selector(dispatch_to_subtrace.subtrace_selector), 1 }, } }); @@ -595,7 +618,7 @@ void ExecutionTraceBuilder::process( } }); } else if (*exec_opcode == ExecutionOpCode::REVERT) { sel_exit_call = true; - should_execute_revert = true; + execute_revert = true; } else if (exec_opcode == ExecutionOpCode::GETENVVAR) { BB_ASSERT_EQ(ex_event.addressing_event.resolution_info.size(), static_cast(2), @@ -623,9 +646,8 @@ void ExecutionTraceBuilder::process( { C::execution_remaining_data_writes_inv, remaining_data_writes }, // Will be inverted in batch later. { C::execution_sel_write_public_data, opcode_execution_failed ? 0 : 1 }, - { C::execution_written_slots_tree_height, AVM_WRITTEN_PUBLIC_DATA_SLOTS_TREE_HEIGHT }, - { C::execution_written_slots_merkle_separator, DOM_SEP__WRITTEN_SLOTS_MERKLE }, - { C::execution_written_slots_tree_siloing_separator, DOM_SEP__PUBLIC_LEAF_SLOT }, + // written_slots_tree_height, _merkle_separator, _tree_siloing_separator + // are set in the check_gas SSTORE branch above (check_gas covers execute_opcode). } }); } else if (*exec_opcode == ExecutionOpCode::NOTEHASHEXISTS) { uint64_t leaf_index = registers[1].as(); @@ -708,8 +730,8 @@ void ExecutionTraceBuilder::process( * Temporality group 6: Register write. **************************************************************************************************/ - const bool should_process_register_write = should_execute_opcode && !opcode_execution_failed; - if (should_process_register_write) { + const bool do_process_register_write = execute_opcode && !opcode_execution_failed; + if (do_process_register_write) { process_registers_write(*exec_opcode, trace, row); } @@ -722,11 +744,11 @@ void ExecutionTraceBuilder::process( // No need to condition by `!is_dying_context` as batch inversion skips 0. const FF dying_context_diff = FF(ex_event.after_context_event.id) - FF(dying_context_id); - // This is here instead of guarded by `should_execute_opcode` because is_err is a higher level error + // This is here instead of guarded by `execute_opcode` because is_err is a higher level error // than just an opcode error (i.e., it is on if there are any errors in any temporality group). const bool is_err = ex_event.error != ExecutionError::NONE; sel_exit_call = sel_exit_call || is_err; // sel_execute_revert || sel_execute_return || sel_error - const bool is_failure = should_execute_revert || is_err; + const bool is_failure = execute_revert || is_err; const bool enqueued_call_end = sel_exit_call && !has_parent; const bool nested_failure = is_failure && has_parent; @@ -813,6 +835,13 @@ void ExecutionTraceBuilder::process_instr_fetching(const simulation::Instruction } } +/** + * @brief Process the execution specification lookup columns (gas costs, register info, subtrace dispatch). + * + * @param ex_event The execution event. + * @param trace The trace container to populate. + * @param row The current row index. + */ void ExecutionTraceBuilder::process_execution_spec(const simulation::ExecutionEvent& ex_event, TraceContainer& trace, uint32_t row) @@ -838,7 +867,7 @@ void ExecutionTraceBuilder::process_execution_spec(const simulation::ExecutionEv { REGISTER_IS_WRITE_COLUMNS[i], register_info.is_write(i) ? 1 : 0 }, { REGISTER_MEM_OP_COLUMNS[i], register_info.is_active(i) ? 1 : 0 }, { REGISTER_EXPECTED_TAG_COLUMNS[i], - register_info.need_tag_check(i) ? static_cast(*(register_info.expected_tag(i))) : 0 }, + register_info.need_tag_check(i) ? static_cast(*(register_info.expected_tag(i))) : 0 }, { REGISTER_TAG_CHECK_COLUMNS[i], register_info.need_tag_check(i) ? 1 : 0 }, } }); } @@ -859,6 +888,14 @@ void ExecutionTraceBuilder::process_execution_spec(const simulation::ExecutionEv } }); } +/** + * @brief Process gas consumption and populate gas-related columns (OOG flags, addressing gas, dynamic gas). + * + * @param gas_event The gas event from simulation. + * @param exec_opcode The execution opcode. + * @param trace The trace container to populate. + * @param row The current row index. + */ void ExecutionTraceBuilder::process_gas(const simulation::GasEvent& gas_event, ExecutionOpCode exec_opcode, TraceContainer& trace, @@ -867,7 +904,7 @@ void ExecutionTraceBuilder::process_gas(const simulation::GasEvent& gas_event, bool oog = gas_event.oog_l2 || gas_event.oog_da; trace.set(row, { { - { C::execution_sel_should_check_gas, 1 }, + { C::execution_sel_check_gas, 1 }, { C::execution_out_of_gas_l2, gas_event.oog_l2 ? 1 : 0 }, { C::execution_out_of_gas_da, gas_event.oog_da ? 1 : 0 }, { C::execution_sel_out_of_gas, oog ? 1 : 0 }, @@ -887,6 +924,14 @@ void ExecutionTraceBuilder::process_gas(const simulation::GasEvent& gas_event, } } +/** + * @brief Process addressing resolution and populate operand columns (relative, indirect, resolved values, error flags). + * + * @param addr_event The addressing event from simulation. + * @param instruction The fetched instruction (for addressing mode bits). + * @param trace The trace container to populate. + * @param row The current row index. + */ void ExecutionTraceBuilder::process_addressing(const simulation::AddressingEvent& addr_event, const simulation::Instruction& instruction, TraceContainer& trace, @@ -908,7 +953,7 @@ void ExecutionTraceBuilder::process_addressing(const simulation::AddressingEvent .error = std::nullopt, }); - std::array should_apply_indirection{}; + std::array apply_indirection{}; std::array is_relative{}; std::array is_indirect{}; std::array is_relative_effective{}; @@ -935,7 +980,7 @@ void ExecutionTraceBuilder::process_addressing(const simulation::AddressingEvent is_indirect[i] = is_operand_indirect(instruction.addressing_mode, i); is_relative_effective[i] = op_is_address && is_relative[i]; is_indirect_effective[i] = op_is_address && is_indirect[i]; - should_apply_indirection[i] = is_indirect_effective[i] && !relative_oob[i] && !base_address_invalid; + apply_indirection[i] = is_indirect_effective[i] && !relative_oob[i] && !base_address_invalid; resolved_operand_tag[i] = static_cast(resolution_info.resolved_operand.get_tag()); after_relative[i] = resolution_info.after_relative; resolved_operand[i] = resolution_info.resolved_operand; @@ -955,7 +1000,7 @@ void ExecutionTraceBuilder::process_addressing(const simulation::AddressingEvent { OPERAND_IS_INDIRECT_WIRE_COLUMNS[i], is_indirect[i] ? 1 : 0 }, { OPERAND_RELATIVE_OVERFLOW_COLUMNS[i], relative_oob[i] ? 1 : 0 }, { OPERAND_AFTER_RELATIVE_COLUMNS[i], after_relative[i] }, - { OPERAND_SHOULD_APPLY_INDIRECTION_COLUMNS[i], should_apply_indirection[i] ? 1 : 0 }, + { OPERAND_APPLY_INDIRECTION_COLUMNS[i], apply_indirection[i] ? 1 : 0 }, { OPERAND_IS_RELATIVE_VALID_BASE_COLUMNS[i], (is_relative_effective[i] && !base_address_invalid) ? 1 : 0 }, { RESOLVED_OPERAND_COLUMNS[i], resolved_operand[i] }, @@ -988,7 +1033,7 @@ void ExecutionTraceBuilder::process_addressing(const simulation::AddressingEvent if (some_final_check_failed) { FF power_of_2 = 1; for (size_t i = 0; i < AVM_MAX_OPERANDS; ++i) { - if (should_apply_indirection[i]) { + if (apply_indirection[i]) { batched_tags_diff += power_of_2 * (FF(resolved_operand_tag[i]) - FF(MEM_TAG_U32)); } power_of_2 *= 8; // 2^3 @@ -1035,6 +1080,11 @@ void ExecutionTraceBuilder::process_addressing(const simulation::AddressingEvent } }); } +/** + * @brief Batch-invert all columns that were populated with pre-inversion values during trace generation. + * + * @param trace The trace container whose columns are inverted in place. + */ void ExecutionTraceBuilder::invert_columns(TraceContainer& trace) { trace.invert_columns({ { @@ -1060,6 +1110,17 @@ void ExecutionTraceBuilder::invert_columns(TraceContainer& trace) } }); } +/** + * @brief Process register reads: populate register value/tag columns and detect tag check failures. + * + * @param exec_opcode The execution opcode (determines register layout). + * @param inputs The input memory values from simulation. + * @param output The output memory value from simulation. + * @param registers Output span filled with the register values for downstream use. + * @param register_processing_failed Whether a tag check failed during register reading. + * @param trace The trace container to populate. + * @param row The current row index. + */ void ExecutionTraceBuilder::process_registers(ExecutionOpCode exec_opcode, const std::vector& inputs, const MemoryValue& output, @@ -1097,7 +1158,7 @@ void ExecutionTraceBuilder::process_registers(ExecutionOpCode exec_opcode, trace.set(REGISTER_COLUMNS[i], row, registers[i]); trace.set(REGISTER_MEM_TAG_COLUMNS[i], row, static_cast(registers[i].get_tag())); // This one is special because it sets the reads (but not the writes). - // If we got here, sel_should_read_registers=1. + // If we got here, sel_read_registers=1. if (register_info.is_active(i) && !register_info.is_write(i)) { trace.set(REGISTER_OP_REG_EFFECTIVE_COLUMNS[i], row, 1); } @@ -1117,26 +1178,41 @@ void ExecutionTraceBuilder::process_registers(ExecutionOpCode exec_opcode, trace.set(row, { { - { C::execution_sel_should_read_registers, 1 }, + { C::execution_sel_read_registers, 1 }, { C::execution_batched_tags_diff_inv_reg, batched_tags_diff_reg }, // Will be inverted in batch. { C::execution_sel_register_read_error, register_processing_failed ? 1 : 0 }, } }); } +/** + * @brief Process register writes: activate the write selector and effective write columns for the opcode. + * + * @param exec_opcode The execution opcode (determines which registers are written). + * @param trace The trace container to populate. + * @param row The current row index. + */ void ExecutionTraceBuilder::process_registers_write(ExecutionOpCode exec_opcode, TraceContainer& trace, uint32_t row) { const auto& register_info = get_exec_instruction_spec().at(exec_opcode).register_info; - trace.set(C::execution_sel_should_write_registers, row, 1); + trace.set(C::execution_sel_write_registers, row, 1); for (size_t i = 0; i < AVM_MAX_REGISTERS; i++) { // This one is special because it sets the writes. - // If we got here, sel_should_write_registers=1. + // If we got here, sel_write_registers=1. if (register_info.is_active(i) && register_info.is_write(i)) { trace.set(REGISTER_OP_REG_EFFECTIVE_COLUMNS[i], row, 1); } } } +/** + * @brief Process the GETENVVAR opcode: populate environment variable lookup and selector columns. + * + * @param envvar_enum The environment variable enum operand (must have tag U8). + * @param output The output memory value produced by simulation. + * @param trace The trace container to populate. + * @param row The current row index. + */ void ExecutionTraceBuilder::process_get_env_var_opcode(Operand envvar_enum, MemoryValue output, TraceContainer& trace, diff --git a/barretenberg/cpp/src/barretenberg/vm2/tracegen/execution_trace.test.cpp b/barretenberg/cpp/src/barretenberg/vm2/tracegen/execution_trace.test.cpp index b187359a3342..2de5ba168620 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/tracegen/execution_trace.test.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/tracegen/execution_trace.test.cpp @@ -125,7 +125,6 @@ TEST(ExecutionTraceGenTest, RegisterAllocation) builder.process({ ex_event }, trace); - // todo: Test doesnt check the other register fields are zeroed out. EXPECT_THAT(trace.as_rows(), ElementsAre( // First row is empty @@ -145,6 +144,22 @@ TEST(ExecutionTraceGenTest, RegisterAllocation) ROW_FIELD_EQ(execution_rw_reg_0_, 0), ROW_FIELD_EQ(execution_rw_reg_1_, 0), ROW_FIELD_EQ(execution_rw_reg_2_, 1)))); + + // Verify that unused registers (3-5) and their associated fields are zeroed out. + const auto rows = trace.as_rows(); + EXPECT_THAT(rows[1], + AllOf(ROW_FIELD_EQ(execution_register_3_, 0), + ROW_FIELD_EQ(execution_register_4_, 0), + ROW_FIELD_EQ(execution_register_5_, 0), + ROW_FIELD_EQ(execution_mem_tag_reg_3_, 0), + ROW_FIELD_EQ(execution_mem_tag_reg_4_, 0), + ROW_FIELD_EQ(execution_mem_tag_reg_5_, 0), + ROW_FIELD_EQ(execution_sel_mem_op_reg_3_, 0), + ROW_FIELD_EQ(execution_sel_mem_op_reg_4_, 0), + ROW_FIELD_EQ(execution_sel_mem_op_reg_5_, 0), + ROW_FIELD_EQ(execution_rw_reg_3_, 0), + ROW_FIELD_EQ(execution_rw_reg_4_, 0), + ROW_FIELD_EQ(execution_rw_reg_5_, 0))); } TEST(ExecutionTraceGenTest, Call) @@ -636,7 +651,7 @@ TEST(ExecutionTraceGenTest, JumpI) ROW_FIELD_EQ(execution_mem_tag_reg_0_, static_cast(ValueTag::U1)), ROW_FIELD_EQ(execution_expected_tag_reg_0_, static_cast(ValueTag::U1)), ROW_FIELD_EQ(execution_sel_tag_check_reg_0_, 1), - ROW_FIELD_EQ(execution_sel_should_read_registers, 1), + ROW_FIELD_EQ(execution_sel_read_registers, 1), ROW_FIELD_EQ(execution_sel_register_read_error, 0), ROW_FIELD_EQ(execution_subtrace_operation_id, AVM_EXEC_OP_ID_JUMPI)))); } @@ -678,7 +693,7 @@ TEST(ExecutionTraceGenTest, JumpiWrongTag) ROW_FIELD_EQ(execution_mem_tag_reg_0_, static_cast(MemoryTag::U8)), ROW_FIELD_EQ(execution_expected_tag_reg_0_, static_cast(MemoryTag::U1)), ROW_FIELD_EQ(execution_sel_tag_check_reg_0_, 1), - ROW_FIELD_EQ(execution_sel_should_read_registers, 1), + ROW_FIELD_EQ(execution_sel_read_registers, 1), ROW_FIELD_EQ(execution_batched_tags_diff_inv_reg, 1), // (2**0 * (mem_tag_reg[0] - expected_tag_reg[0]))^-1 = 1 ROW_FIELD_EQ(execution_sel_register_read_error, 1), diff --git a/barretenberg/cpp/src/barretenberg/vm2/tracegen/tx_trace.cpp b/barretenberg/cpp/src/barretenberg/vm2/tracegen/tx_trace.cpp index 66eda44f9ef5..b6bb05a0c42c 100644 --- a/barretenberg/cpp/src/barretenberg/vm2/tracegen/tx_trace.cpp +++ b/barretenberg/cpp/src/barretenberg/vm2/tracegen/tx_trace.cpp @@ -324,7 +324,7 @@ std::vector> handle_gas_limit(TransactionPhase phase, const Gas */ std::vector> handle_enqueued_call_event(const EnqueuedCallEvent& event) { - return { { C::tx_should_process_call_request, 1 }, + return { { C::tx_sel_process_call_request, 1 }, { C::tx_msg_sender, event.msg_sender }, { C::tx_contract_addr, event.contract_address }, { C::tx_fee, event.transaction_fee }, @@ -353,8 +353,8 @@ std::vector> handle_note_hash_append(const PrivateAppendTreeEve return { { C::tx_leaf_value, event.leaf_value }, { C::tx_remaining_side_effects_inv, remaining_note_hashes }, // Will be inverted in batch later - { C::tx_should_try_note_hash_append, 1 }, - { C::tx_should_note_hash_append, remaining_note_hashes > 0 ? 1 : 0 }, + { C::tx_sel_try_note_hash_append, 1 }, + { C::tx_sel_note_hash_append, remaining_note_hashes > 0 ? 1 : 0 }, }; } @@ -374,8 +374,8 @@ std::vector> handle_nullifier_append(const PrivateAppendTreeEve return { { C::tx_leaf_value, event.leaf_value }, { C::tx_nullifier_limit_error, remaining_nullifiers > 0 ? 0 : 1 }, { C::tx_remaining_side_effects_inv, remaining_nullifiers }, // Will be inverted in batch later - { C::tx_should_try_nullifier_append, 1 }, - { C::tx_should_nullifier_append, remaining_nullifiers > 0 ? 1 : 0 }, + { C::tx_sel_try_nullifier_append, 1 }, + { C::tx_sel_nullifier_append, remaining_nullifiers > 0 ? 1 : 0 }, { C::tx_write_nullifier_pi_offset, AVM_PUBLIC_INPUTS_AVM_ACCUMULATED_DATA_NULLIFIERS_ROW_IDX + state_before.tree_states.nullifier_tree.counter }, @@ -420,9 +420,9 @@ std::vector> handle_l2_l1_msg_event(const PrivateEmitL2L1Messag { uint32_t remaining_l2_to_l1_msgs = MAX_L2_TO_L1_MSGS_PER_TX - state_before.numL2ToL1Messages; return { - { C::tx_should_try_l2_l1_msg_append, 1 }, + { C::tx_sel_try_l2_l1_msg_append, 1 }, { C::tx_remaining_side_effects_inv, remaining_l2_to_l1_msgs }, // Will be inverted in batch later - { C::tx_should_l2_l1_msg_append, (remaining_l2_to_l1_msgs > 0 && !discard) ? 1 : 0 }, + { C::tx_sel_l2_l1_msg_append, (remaining_l2_to_l1_msgs > 0 && !discard) ? 1 : 0 }, { C::tx_l2_l1_msg_contract_address, event.scoped_msg.contract_address }, { C::tx_l2_l1_msg_recipient, event.scoped_msg.message.recipient }, { C::tx_l2_l1_msg_content, event.scoped_msg.message.content }, From 259a9ec379d42ad70c06bd8fb461f39d0ffb28ce Mon Sep 17 00:00:00 2001 From: Jean M <132435771+jeanmon@users.noreply.github.com> Date: Thu, 23 Apr 2026 13:08:13 +0200 Subject: [PATCH 2/2] test(avm): integration test for alu truncation (#22684) Linear issue: [AVM-267](https://linear.app/aztec-labs/issue/AVM-267/write-integration-test-for-alu-truncation) --- .../avm_check_circuit_custom_bc.test.ts | 26 ++++ .../public/fixtures/custom_bytecode_tests.ts | 140 +++++++++++++++++- .../apps_tests/custom_bc.test.ts | 34 +++++ 3 files changed, 199 insertions(+), 1 deletion(-) diff --git a/yarn-project/bb-prover/src/avm_proving_tests/avm_check_circuit_custom_bc.test.ts b/yarn-project/bb-prover/src/avm_proving_tests/avm_check_circuit_custom_bc.test.ts index c2f720db3d8b..eb86d7596105 100644 --- a/yarn-project/bb-prover/src/avm_proving_tests/avm_check_circuit_custom_bc.test.ts +++ b/yarn-project/bb-prover/src/avm_proving_tests/avm_check_circuit_custom_bc.test.ts @@ -3,6 +3,7 @@ import { addressingWithIndirectTagIssueTest, addressingWithIndirectThenRelativeTagIssueTest, addressingWithRelativeOverflowAndIndirectTagIssueTest, + castTruncationTest, defaultGlobals, instructionTruncatedTest, invalidByteTest, @@ -10,6 +11,7 @@ import { invalidTagValueAndInstructionTruncatedTest, invalidTagValueTest, pcOutOfRangeTest, + setTruncationTest, } from '@aztec/simulator/public/fixtures'; import { NativeWorldStateService } from '@aztec/world-state'; @@ -97,3 +99,27 @@ describe('AVM bytecode flow unhappy paths', () => { expect(result.revertCode.isOK()).toBe(false); }); }); + +describe('AVM custom bytecodes truncation', () => { + let tester: AvmProvingTester; + let worldStateService: NativeWorldStateService; + + beforeEach(async () => { + worldStateService = await NativeWorldStateService.tmp(); + tester = await AvmProvingTester.new(worldStateService, /*checkCircuitOnly*/ true, /*globals=*/ defaultGlobals()); + }); + + afterEach(async () => { + await worldStateService.close(); + }); + + it('SET truncation to narrower target tags', async () => { + const result = await setTruncationTest(tester); + expect(result.revertCode.isOK()).toBe(true); + }, 20_000); + + it('CAST truncation to narrower target tags', async () => { + const result = await castTruncationTest(tester); + expect(result.revertCode.isOK()).toBe(true); + }, 20_000); +}); diff --git a/yarn-project/simulator/src/public/fixtures/custom_bytecode_tests.ts b/yarn-project/simulator/src/public/fixtures/custom_bytecode_tests.ts index 220432369f85..237d8dc6d4e6 100644 --- a/yarn-project/simulator/src/public/fixtures/custom_bytecode_tests.ts +++ b/yarn-project/simulator/src/public/fixtures/custom_bytecode_tests.ts @@ -2,7 +2,7 @@ import { strict as assert } from 'assert'; import { TypeTag } from '../avm/avm_memory_types.js'; import { Addressing, AddressingMode } from '../avm/opcodes/addressing_mode.js'; -import { Add, CalldataCopy, Jump, Return, Set } from '../avm/opcodes/index.js'; +import { Add, CalldataCopy, Cast, Jump, Return, Set } from '../avm/opcodes/index.js'; import { encodeToBytecode } from '../avm/serialization/bytecode_serialization.js'; import { MAX_OPCODE_VALUE, @@ -208,6 +208,144 @@ export async function invalidTagValueAndInstructionTruncatedTest(tester: PublicT return await deployAndExecuteCustomBytecode(bytecode, tester, txLabel); } +// Exercise SET truncation: set values whose widths exceed the target tag and +// rely on `buildFromTagTruncating` to truncate to the low bits of the tag. +// Covers sources larger than 128 bits (via SET_FF) and sources in (32, 128] +// bits (via SET_64) against destination tags U1/U8/U16/U32/U64/U128. +export async function setTruncationTest(tester: PublicTxSimulationTester) { + // 200-bit value: forces truncation for every target tag up to U128. + const LARGE_FIELD_VALUE = (1n << 200n) + 0x1234567890abcdef1234567890abcdefn; + // 40-bit value: forces truncation for target tags up to U32. + const LARGE_U64_VALUE = (1n << 40n) + 0xdeadbeefn; + + const bytecode = encodeToBytecode([ + // Zero U32 at offset 0 — used as the Return copy-size slot. + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 0, TypeTag.UINT32, /*value=*/ 0).as(Opcode.SET_8, Set.wireFormat8), + + // Source >128 bits (via SET_FF) truncated to smaller target tags. + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 1, TypeTag.UINT128, LARGE_FIELD_VALUE).as( + Opcode.SET_FF, + Set.wireFormatFF, + ), + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 2, TypeTag.UINT64, LARGE_FIELD_VALUE).as( + Opcode.SET_FF, + Set.wireFormatFF, + ), + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 3, TypeTag.UINT32, LARGE_FIELD_VALUE).as( + Opcode.SET_FF, + Set.wireFormatFF, + ), + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 4, TypeTag.UINT16, LARGE_FIELD_VALUE).as( + Opcode.SET_FF, + Set.wireFormatFF, + ), + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 5, TypeTag.UINT8, LARGE_FIELD_VALUE).as( + Opcode.SET_FF, + Set.wireFormatFF, + ), + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 6, TypeTag.UINT1, LARGE_FIELD_VALUE).as( + Opcode.SET_FF, + Set.wireFormatFF, + ), + + // Source in (32, 128] bits (via SET_64) truncated to smaller target tags. + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 7, TypeTag.UINT32, LARGE_U64_VALUE).as( + Opcode.SET_64, + Set.wireFormat64, + ), + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 8, TypeTag.UINT16, LARGE_U64_VALUE).as( + Opcode.SET_64, + Set.wireFormat64, + ), + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 9, TypeTag.UINT8, LARGE_U64_VALUE).as( + Opcode.SET_64, + Set.wireFormat64, + ), + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 10, TypeTag.UINT1, LARGE_U64_VALUE).as( + Opcode.SET_64, + Set.wireFormat64, + ), + + new Return(/*addressing_mode=*/ 0, /*copySizeOffset=*/ 0, /*returnOffset=*/ 0), + ]); + + const txLabel = 'SetTruncation'; + return await deployAndExecuteCustomBytecode(bytecode, tester, txLabel); +} + +// Exercise CAST truncation: store a wide source value in memory then CAST it +// to smaller destination tags. Covers sources larger than 128 bits (FIELD +// source) and sources in (32, 128] bits (UINT64 source) against destination +// tags U1/U8/U16/U32/U64/U128. +export async function castTruncationTest(tester: PublicTxSimulationTester) { + // 200-bit source: stored as FIELD so that CASTs to any integer tag truncate. + const LARGE_FIELD_VALUE = (1n << 200n) + 0x1234567890abcdef1234567890abcdefn; + // 40-bit source: stored as UINT64 so CASTs to U1/U8/U16/U32 truncate. + const LARGE_U64_VALUE = (1n << 40n) + 0xdeadbeefn; + + const bytecode = encodeToBytecode([ + // Zero U32 at offset 0 — used as the Return copy-size slot. + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 0, TypeTag.UINT32, /*value=*/ 0).as(Opcode.SET_8, Set.wireFormat8), + + // Store wide FIELD source at offset 10, then CAST to smaller tags. + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 10, TypeTag.FIELD, LARGE_FIELD_VALUE).as( + Opcode.SET_FF, + Set.wireFormatFF, + ), + new Cast(/*addressing_mode=*/ 0, /*srcOffset=*/ 10, /*dstOffset=*/ 11, TypeTag.UINT128).as( + Opcode.CAST_8, + Cast.wireFormat8, + ), + new Cast(/*addressing_mode=*/ 0, /*srcOffset=*/ 10, /*dstOffset=*/ 12, TypeTag.UINT64).as( + Opcode.CAST_8, + Cast.wireFormat8, + ), + new Cast(/*addressing_mode=*/ 0, /*srcOffset=*/ 10, /*dstOffset=*/ 13, TypeTag.UINT32).as( + Opcode.CAST_8, + Cast.wireFormat8, + ), + new Cast(/*addressing_mode=*/ 0, /*srcOffset=*/ 10, /*dstOffset=*/ 14, TypeTag.UINT16).as( + Opcode.CAST_8, + Cast.wireFormat8, + ), + new Cast(/*addressing_mode=*/ 0, /*srcOffset=*/ 10, /*dstOffset=*/ 15, TypeTag.UINT8).as( + Opcode.CAST_8, + Cast.wireFormat8, + ), + new Cast(/*addressing_mode=*/ 0, /*srcOffset=*/ 10, /*dstOffset=*/ 16, TypeTag.UINT1).as( + Opcode.CAST_8, + Cast.wireFormat8, + ), + + // Store UINT64 source at offset 20, then CAST to smaller integer tags. + new Set(/*addressing_mode=*/ 0, /*dstOffset=*/ 20, TypeTag.UINT64, LARGE_U64_VALUE).as( + Opcode.SET_64, + Set.wireFormat64, + ), + new Cast(/*addressing_mode=*/ 0, /*srcOffset=*/ 20, /*dstOffset=*/ 21, TypeTag.UINT32).as( + Opcode.CAST_8, + Cast.wireFormat8, + ), + new Cast(/*addressing_mode=*/ 0, /*srcOffset=*/ 20, /*dstOffset=*/ 22, TypeTag.UINT16).as( + Opcode.CAST_8, + Cast.wireFormat8, + ), + new Cast(/*addressing_mode=*/ 0, /*srcOffset=*/ 20, /*dstOffset=*/ 23, TypeTag.UINT8).as( + Opcode.CAST_8, + Cast.wireFormat8, + ), + new Cast(/*addressing_mode=*/ 0, /*srcOffset=*/ 20, /*dstOffset=*/ 24, TypeTag.UINT1).as( + Opcode.CAST_8, + Cast.wireFormat8, + ), + + new Return(/*addressing_mode=*/ 0, /*copySizeOffset=*/ 0, /*returnOffset=*/ 0), + ]); + + const txLabel = 'CastTruncation'; + return await deployAndExecuteCustomBytecode(bytecode, tester, txLabel); +} + /** * Returns the offset of the tag in an instruction. * @details Loops over the wire format operand type entries until it finds the tag. diff --git a/yarn-project/simulator/src/public/public_tx_simulator/apps_tests/custom_bc.test.ts b/yarn-project/simulator/src/public/public_tx_simulator/apps_tests/custom_bc.test.ts index 0e1a4f213eb3..b3d61ec8d66e 100644 --- a/yarn-project/simulator/src/public/public_tx_simulator/apps_tests/custom_bc.test.ts +++ b/yarn-project/simulator/src/public/public_tx_simulator/apps_tests/custom_bc.test.ts @@ -7,12 +7,14 @@ import { import { NativeWorldStateService } from '@aztec/world-state/native'; import { + castTruncationTest, instructionTruncatedTest, invalidByteTest, invalidOpcodeTest, invalidTagValueAndInstructionTruncatedTest, invalidTagValueTest, pcOutOfRangeTest, + setTruncationTest, } from '../../fixtures/custom_bytecode_tests.js'; import { PublicTxSimulationTester } from '../../fixtures/public_tx_simulation_tester.js'; @@ -114,3 +116,35 @@ describe.each([ expect(result.revertCode.isOK()).toBe(false); }); }); + +describe.each([ + { useCppSimulator: false, simulatorName: 'TS Simulator' }, + { useCppSimulator: true, simulatorName: 'Cpp Simulator' }, +])('Public TX simulator apps tests: custom bytecodes truncation ($simulatorName)', ({ useCppSimulator }) => { + let worldStateService: NativeWorldStateService; + let tester: PublicTxSimulationTester; + + beforeEach(async () => { + worldStateService = await NativeWorldStateService.tmp(); + tester = await PublicTxSimulationTester.create( + worldStateService, + /*globals=*/ undefined, + /*metrics=*/ undefined, + useCppSimulator, + ); + }); + + afterEach(async () => { + await worldStateService.close(); + }); + + it('SET truncation to narrower target tags', async () => { + const result = await setTruncationTest(tester); + expect(result.revertCode.isOK()).toBe(true); + }); + + it('CAST truncation to narrower target tags', async () => { + const result = await castTruncationTest(tester); + expect(result.revertCode.isOK()).toBe(true); + }); +});