@@ -297,17 +297,17 @@ pol constant p_decomposition_limb;
297297// ===== Section 9: Execution instruction spec (EXECUTION_INSTRUCTION_SPEC) =====
298298// Each valid row encodes: gas costs (L2 opcode, base DA, dynamic L2, dynamic DA),
299299// per-register flags (memory access, read/write, tag check, expected tag) for 6 registers,
300- // subtrace/gadget dispatch IDs, dynamic gas ID, and address-operand flags for 7 operands.
300+ // subtrace/gadget dispatch IDs, dynamic gas ID, and address-operand flags for 5 operands.
301301// Used by the execution subtrace to dispatch and constrain instruction behavior.
302302//
303303// Example trace (idx encodes the ExecutionOpCode; array columns use [a,b,...] notation):
304304//
305- // idx | sel_exec_spec | opcode_gas | base_da | dyn_l2 | dyn_da | mem_op[0..5] | rw[0..5] | subtrace_id | sub_op_id | dyn_gas_id | is_addr[0..6 ]
305+ // idx | sel_exec_spec | opcode_gas | base_da | dyn_l2 | dyn_da | mem_op[0..5] | rw[0..5] | subtrace_id | sub_op_id | dyn_gas_id | is_addr[0..4 ]
306306// -----------------+---------------+------------+---------+--------+--------+--------------------+--------------------+-------------+-----------+------------+----------------------
307- // 0 (ADD) | 1 | 12 | 0 | 0 | 0 | [1,1,1,0,0,0] | [0,0,1,0,0,0] | 1 | 1 | 0 | [1,1,1,0,0,0,0 ]
308- // 1 (SUB) | 1 | 12 | 0 | 0 | 0 | [1,1,1,0,0,0] | [0,0,1,0,0,0] | 1 | 2 | 0 | [1,1,1,0,0,0,0 ]
307+ // 0 (ADD) | 1 | 12 | 0 | 0 | 0 | [1,1,1,0,0,0] | [0,0,1,0,0,0] | 1 | 1 | 0 | [1,1,1,0,0]
308+ // 1 (SUB) | 1 | 12 | 0 | 0 | 0 | [1,1,1,0,0,0] | [0,0,1,0,0,0] | 1 | 2 | 0 | [1,1,1,0,0]
309309// ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ... | ...
310- // 45 (TORADIXBE) | 1 | 24 | 0 | 3 | 0 | [1,1,1,1,0,0] | [0,0,0,0,0,0] | 13 | 0 | 4 | [1,1,1,1,1,0,0 ]
310+ // 45 (TORADIXBE) | 1 | 24 | 0 | 3 | 0 | [1,1,1,1,0,0] | [0,0,0,0,0,0] | 13 | 0 | 4 | [1,1,1,1,1]
311311
312312pol constant sel_exec_spec;
313313// Gas Costs
@@ -348,9 +348,9 @@ pol constant sel_op_is_address[5];
348348// 1 | 1 | 3 (operand 0 indirect)
349349// 3 | 1 | 9 (operand 0 indirect + relative)
350350// ... | 1 | ...
351- // 4095 | 1 | 39 (operands 0-5 indirect + relative)
351+ // 1023 | 1 | 33 (operands 0-4 indirect + relative; this is the max gas value for addressing )
352352// ... | 1 | ...
353- // 65535 | 1 | 45 (all 7 operands indirect + relative )
353+ // 65535 | 1 | 33 (all bits above operand 4 are ignored, see addressing.pil for why this table still needs to be 16-bits )
354354
355355pol constant sel_addressing_gas;
356356pol constant addressing_gas;
0 commit comments