From 1b7bf02ac82ff66949e8897ae280f68696b63ddd Mon Sep 17 00:00:00 2001 From: fractasy Date: Tue, 15 Oct 2024 18:26:01 +0000 Subject: [PATCH] Add no_counters to ProcessStatelessBatchRequestV2 gRPC method --- src/grpc/gen/executor.pb.cc | 665 +++++++++++----------- src/grpc/gen/executor.pb.h | 31 + src/grpc/proto/executor.proto | 3 + src/service/executor/executor_service.cpp | 2 +- 4 files changed, 382 insertions(+), 319 deletions(-) diff --git a/src/grpc/gen/executor.pb.cc b/src/grpc/gen/executor.pb.cc index 2b7a2269c..69299c872 100644 --- a/src/grpc/gen/executor.pb.cc +++ b/src/grpc/gen/executor.pb.cc @@ -1223,6 +1223,7 @@ const ::PROTOBUF_NAMESPACE_ID::uint32 TableStruct_executor_2eproto::offsets[] PR PROTOBUF_FIELD_OFFSET(::executor::v1::ProcessStatelessBatchRequestV2, context_id_), PROTOBUF_FIELD_OFFSET(::executor::v1::ProcessStatelessBatchRequestV2, trace_config_), PROTOBUF_FIELD_OFFSET(::executor::v1::ProcessStatelessBatchRequestV2, l1_info_tree_index_min_timestamp_), + PROTOBUF_FIELD_OFFSET(::executor::v1::ProcessStatelessBatchRequestV2, no_counters_), ~0u, // no _has_bits_ PROTOBUF_FIELD_OFFSET(::executor::v1::L1DataV2, _internal_metadata_), ~0u, // no _extensions_ @@ -1506,25 +1507,25 @@ static const ::PROTOBUF_NAMESPACE_ID::internal::MigrationSchema schemas[] PROTOB { 274, -1, sizeof(::executor::v1::ProcessBatchRequestV2)}, { 303, 310, sizeof(::executor::v1::ProcessStatelessBatchRequestV2_L1InfoTreeIndexMinTimestampEntry_DoNotUse)}, { 312, -1, sizeof(::executor::v1::ProcessStatelessBatchRequestV2)}, - { 327, -1, sizeof(::executor::v1::L1DataV2)}, - { 336, -1, sizeof(::executor::v1::DebugV2)}, - { 346, 353, sizeof(::executor::v1::ProcessBatchResponseV2_ReadWriteAddressesEntry_DoNotUse)}, - { 355, -1, sizeof(::executor::v1::ProcessBatchResponseV2)}, - { 394, -1, sizeof(::executor::v1::ResponseDebug)}, - { 400, -1, sizeof(::executor::v1::TraceConfigV2)}, - { 410, 417, sizeof(::executor::v1::OverrideAccountV2_StateEntry_DoNotUse)}, - { 419, 426, sizeof(::executor::v1::OverrideAccountV2_StateDiffEntry_DoNotUse)}, - { 428, -1, sizeof(::executor::v1::OverrideAccountV2)}, - { 438, 445, sizeof(::executor::v1::InfoReadWriteV2_ScStorageEntry_DoNotUse)}, - { 447, -1, sizeof(::executor::v1::InfoReadWriteV2)}, - { 457, -1, sizeof(::executor::v1::FullTraceV2)}, - { 464, -1, sizeof(::executor::v1::TransactionContextV2)}, - { 484, 491, sizeof(::executor::v1::TransactionStepV2_StorageEntry_DoNotUse)}, - { 493, -1, sizeof(::executor::v1::TransactionStepV2)}, - { 513, -1, sizeof(::executor::v1::ContractV2)}, - { 524, -1, sizeof(::executor::v1::ProcessBlockResponseV2)}, - { 542, -1, sizeof(::executor::v1::ProcessTransactionResponseV2)}, - { 568, -1, sizeof(::executor::v1::LogV2)}, + { 328, -1, sizeof(::executor::v1::L1DataV2)}, + { 337, -1, sizeof(::executor::v1::DebugV2)}, + { 347, 354, sizeof(::executor::v1::ProcessBatchResponseV2_ReadWriteAddressesEntry_DoNotUse)}, + { 356, -1, sizeof(::executor::v1::ProcessBatchResponseV2)}, + { 395, -1, sizeof(::executor::v1::ResponseDebug)}, + { 401, -1, sizeof(::executor::v1::TraceConfigV2)}, + { 411, 418, sizeof(::executor::v1::OverrideAccountV2_StateEntry_DoNotUse)}, + { 420, 427, sizeof(::executor::v1::OverrideAccountV2_StateDiffEntry_DoNotUse)}, + { 429, -1, sizeof(::executor::v1::OverrideAccountV2)}, + { 439, 446, sizeof(::executor::v1::InfoReadWriteV2_ScStorageEntry_DoNotUse)}, + { 448, -1, sizeof(::executor::v1::InfoReadWriteV2)}, + { 458, -1, sizeof(::executor::v1::FullTraceV2)}, + { 465, -1, sizeof(::executor::v1::TransactionContextV2)}, + { 485, 492, sizeof(::executor::v1::TransactionStepV2_StorageEntry_DoNotUse)}, + { 494, -1, sizeof(::executor::v1::TransactionStepV2)}, + { 514, -1, sizeof(::executor::v1::ContractV2)}, + { 525, -1, sizeof(::executor::v1::ProcessBlockResponseV2)}, + { 543, -1, sizeof(::executor::v1::ProcessTransactionResponseV2)}, + { 569, -1, sizeof(::executor::v1::LogV2)}, }; static ::PROTOBUF_NAMESPACE_ID::Message const * const file_default_instances[] = { @@ -1695,7 +1696,7 @@ const char descriptor_table_protodef_executor_2eproto[] PROTOBUF_SECTION_VARIABL "codeEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028" "\001\032T\n\022StateOverrideEntry\022\013\n\003key\030\001 \001(\t\022-\n\005" "value\030\002 \001(\0132\036.executor.v1.OverrideAccoun" - "tV2:\0028\001\"\302\003\n\036ProcessStatelessBatchRequest" + "tV2:\0028\001\"\327\003\n\036ProcessStatelessBatchRequest" "V2\022\017\n\007witness\030\001 \001(\014\022\023\n\013data_stream\030\002 \001(\014" "\022\020\n\010coinbase\030\003 \001(\t\022\032\n\022old_acc_input_hash" "\030\004 \001(\014\022\024\n\014l1_info_root\030\005 \001(\014\022\027\n\017timestam" @@ -1704,297 +1705,298 @@ const char descriptor_table_protodef_executor_2eproto[] PROTOBUF_SECTION_VARIABL " \001(\0132\032.executor.v1.TraceConfigV2\022v\n l1_i" "nfo_tree_index_min_timestamp\030\n \003(\0132L.exe" "cutor.v1.ProcessStatelessBatchRequestV2." - "L1InfoTreeIndexMinTimestampEntry\032B\n L1In" - "foTreeIndexMinTimestampEntry\022\013\n\003key\030\001 \001(" - "\004\022\r\n\005value\030\002 \001(\004:\0028\001\"e\n\010L1DataV2\022\030\n\020glob" - "al_exit_root\030\001 \001(\014\022\025\n\rblock_hash_l1\030\002 \001(" - "\014\022\025\n\rmin_timestamp\030\003 \001(\004\022\021\n\tsmt_proof\030\004 " - "\003(\014\"\204\001\n\007DebugV2\022\021\n\tgas_limit\030\001 \001(\004\022\026\n\016ne" - "w_state_root\030\002 \001(\014\022\032\n\022new_acc_input_hash" - "\030\003 \001(\014\022\033\n\023new_local_exit_root\030\004 \001(\014\022\025\n\rn" - "ew_batch_num\030\005 \001(\004\"\202\t\n\026ProcessBatchRespo" - "nseV2\022\026\n\016new_state_root\030\001 \001(\014\022\032\n\022new_acc" - "_input_hash\030\002 \001(\014\022\033\n\023new_local_exit_root" - "\030\003 \001(\014\022\025\n\rnew_batch_num\030\004 \001(\004\022\031\n\021cnt_kec" - "cak_hashes\030\005 \001(\r\022\033\n\023cnt_poseidon_hashes\030" - "\006 \001(\r\022\035\n\025cnt_poseidon_paddings\030\007 \001(\r\022\026\n\016" - "cnt_mem_aligns\030\010 \001(\r\022\027\n\017cnt_arithmetics\030" - "\t \001(\r\022\024\n\014cnt_binaries\030\n \001(\r\022\021\n\tcnt_steps" - "\030\013 \001(\r\022\031\n\021cnt_sha256_hashes\030\014 \001(\r\022<\n\017blo" - "ck_responses\030\r \003(\0132#.executor.v1.Process" - "BlockResponseV2\022)\n\005error\030\016 \001(\0162\032.executo" - "r.v1.ExecutorError\022Y\n\024read_write_address" - "es\030\017 \003(\0132;.executor.v1.ProcessBatchRespo" - "nseV2.ReadWriteAddressesEntry\022\020\n\010flush_i" - "d\030\020 \001(\004\022\027\n\017stored_flush_id\030\021 \001(\004\022\021\n\tprov" - "er_id\030\022 \001(\t\022\020\n\010gas_used\030\023 \001(\004\022\020\n\010smt_key" - "s\030\024 \003(\014\022\024\n\014program_keys\030\025 \003(\014\022\017\n\007fork_id" - "\030\026 \001(\004\022\025\n\rinvalid_batch\030\027 \001(\r\022(\n\terror_r" - "om\030\030 \001(\0162\025.executor.v1.RomError\022!\n\031cnt_r" - "eserve_keccak_hashes\030\031 \001(\r\022#\n\033cnt_reserv" - "e_poseidon_hashes\030\032 \001(\r\022%\n\035cnt_reserve_p" - "oseidon_paddings\030\033 \001(\r\022\036\n\026cnt_reserve_me" - "m_aligns\030\034 \001(\r\022\037\n\027cnt_reserve_arithmetic" - "s\030\035 \001(\r\022\034\n\024cnt_reserve_binaries\030\036 \001(\r\022\031\n" - "\021cnt_reserve_steps\030\037 \001(\r\022!\n\031cnt_reserve_" - "sha256_hashes\030 \001(\r\022\026\n\016old_state_root\030! " - "\001(\014\022)\n\005debug\030\" \001(\0132\032.executor.v1.Respons" - "eDebug\032W\n\027ReadWriteAddressesEntry\022\013\n\003key" - "\030\001 \001(\t\022+\n\005value\030\002 \001(\0132\034.executor.v1.Info" - "ReadWriteV2:\0028\001\"\"\n\rResponseDebug\022\021\n\terro" - "r_log\030\001 \001(\t\"\232\001\n\rTraceConfigV2\022\027\n\017disable" - "_storage\030\001 \001(\r\022\025\n\rdisable_stack\030\002 \001(\r\022\025\n" - "\renable_memory\030\003 \001(\r\022\032\n\022enable_return_da" - "ta\030\004 \001(\r\022&\n\036tx_hash_to_generate_full_tra" - "ce\030\005 \001(\014\"\236\002\n\021OverrideAccountV2\022\017\n\007balanc" - "e\030\001 \001(\014\022\r\n\005nonce\030\002 \001(\004\022\014\n\004code\030\003 \001(\014\0228\n\005" - "state\030\004 \003(\0132).executor.v1.OverrideAccoun" - "tV2.StateEntry\022A\n\nstate_diff\030\005 \003(\0132-.exe" - "cutor.v1.OverrideAccountV2.StateDiffEntr" - "y\032,\n\nStateEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 " - "\001(\t:\0028\001\0320\n\016StateDiffEntry\022\013\n\003key\030\001 \001(\t\022\r" - "\n\005value\030\002 \001(\t:\0028\001\"\310\001\n\017InfoReadWriteV2\022\r\n" - "\005nonce\030\001 \001(\t\022\017\n\007balance\030\002 \001(\t\022\017\n\007sc_code" - "\030\003 \001(\t\022\?\n\nsc_storage\030\004 \003(\0132+.executor.v1" - ".InfoReadWriteV2.ScStorageEntry\022\021\n\tsc_le" - "ngth\030\005 \001(\t\0320\n\016ScStorageEntry\022\013\n\003key\030\001 \001(" - "\t\022\r\n\005value\030\002 \001(\t:\0028\001\"p\n\013FullTraceV2\0222\n\007c" - "ontext\030\001 \001(\0132!.executor.v1.TransactionCo" - "ntextV2\022-\n\005steps\030\002 \003(\0132\036.executor.v1.Tra" - "nsactionStepV2\"\224\002\n\024TransactionContextV2\022" - "\014\n\004type\030\001 \001(\t\022\014\n\004from\030\002 \001(\t\022\n\n\002to\030\003 \001(\t\022" - "\014\n\004data\030\004 \001(\014\022\013\n\003gas\030\005 \001(\004\022\r\n\005value\030\006 \001(" - "\t\022\022\n\nblock_hash\030\007 \001(\014\022\016\n\006output\030\010 \001(\014\022\020\n" - "\010gas_used\030\t \001(\004\022\021\n\tgas_price\030\n \001(\t\022\026\n\016ex" - "ecution_time\030\013 \001(\r\022\026\n\016old_state_root\030\014 \001" - "(\014\022\r\n\005nonce\030\r \001(\004\022\020\n\010tx_index\030\016 \001(\004\022\020\n\010c" - "hain_id\030\017 \001(\004\"\240\003\n\021TransactionStepV2\022\022\n\ns" - "tate_root\030\001 \001(\014\022\r\n\005depth\030\002 \001(\r\022\n\n\002pc\030\003 \001" - "(\004\022\013\n\003gas\030\004 \001(\004\022\020\n\010gas_cost\030\005 \001(\004\022\022\n\ngas" - "_refund\030\006 \001(\004\022\n\n\002op\030\007 \001(\r\022\r\n\005stack\030\010 \003(\t" - "\022\016\n\006memory\030\t \001(\014\022\023\n\013memory_size\030\n \001(\r\022\025\n" - "\rmemory_offset\030\013 \001(\r\022\023\n\013return_data\030\014 \001(" - "\014\022)\n\010contract\030\r \001(\0132\027.executor.v1.Contra" - "ctV2\022$\n\005error\030\016 \001(\0162\025.executor.v1.RomErr" - "or\022<\n\007storage\030\017 \003(\0132+.executor.v1.Transa" - "ctionStepV2.StorageEntry\032.\n\014StorageEntry" - "\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"e\n\nCont" - "ractV2\022\017\n\007address\030\001 \001(\t\022\016\n\006caller\030\002 \001(\t\022" - "\r\n\005value\030\003 \001(\t\022\014\n\004data\030\004 \001(\014\022\013\n\003gas\030\005 \001(" - "\004\022\014\n\004type\030\006 \001(\t\"\344\002\n\026ProcessBlockResponse" - "V2\022\023\n\013parent_hash\030\001 \001(\014\022\020\n\010coinbase\030\002 \001(" - "\t\022\021\n\tgas_limit\030\003 \001(\004\022\024\n\014block_number\030\004 \001" - "(\004\022\021\n\ttimestamp\030\005 \001(\004\022\013\n\003ger\030\006 \001(\014\022\025\n\rbl" - "ock_hash_l1\030\007 \001(\014\022\020\n\010gas_used\030\010 \001(\004\022\027\n\017b" - "lock_info_root\030\t \001(\014\022\022\n\nblock_hash\030\n \001(\014" - "\022<\n\tresponses\030\013 \003(\0132).executor.v1.Proces" - "sTransactionResponseV2\022 \n\004logs\030\014 \003(\0132\022.e" - "xecutor.v1.LogV2\022$\n\005error\030\r \001(\0162\025.execut" - "or.v1.RomError\"\236\004\n\034ProcessTransactionRes" - "ponseV2\022\017\n\007tx_hash\030\001 \001(\014\022\022\n\ntx_hash_l2\030\002" - " \001(\014\022\016\n\006rlp_tx\030\003 \001(\014\022\022\n\nblock_hash\030\004 \001(\014" - "\022\024\n\014block_number\030\005 \001(\004\022\014\n\004type\030\006 \001(\r\022\024\n\014" - "return_value\030\007 \001(\014\022\020\n\010gas_left\030\010 \001(\004\022\020\n\010" - "gas_used\030\t \001(\004\022\033\n\023cumulative_gas_used\030\n " - "\001(\004\022\024\n\014gas_refunded\030\013 \001(\004\022$\n\005error\030\014 \001(\016" - "2\025.executor.v1.RomError\022\026\n\016create_addres" - "s\030\r \001(\t\022\022\n\nstate_root\030\016 \001(\014\022 \n\004logs\030\017 \003(" - "\0132\022.executor.v1.LogV2\022,\n\nfull_trace\030\020 \001(" - "\0132\030.executor.v1.FullTraceV2\022\033\n\023effective" - "_gas_price\030\021 \001(\t\022\034\n\024effective_percentage" - "\030\022 \001(\r\022\033\n\023has_gasprice_opcode\030\023 \001(\r\022\032\n\022h" - "as_balance_opcode\030\024 \001(\r\022\016\n\006status\030\025 \001(\r\"" - "\246\001\n\005LogV2\022\017\n\007address\030\001 \001(\t\022\016\n\006topics\030\002 \003" - "(\014\022\014\n\004data\030\003 \001(\014\022\024\n\014block_number\030\004 \001(\004\022\017" - "\n\007tx_hash\030\005 \001(\014\022\022\n\ntx_hash_l2\030\006 \001(\014\022\020\n\010t" - "x_index\030\007 \001(\r\022\022\n\nblock_hash\030\010 \001(\014\022\r\n\005ind" - "ex\030\t \001(\r*\347\n\n\010RomError\022\031\n\025ROM_ERROR_UNSPE" - "CIFIED\020\000\022\026\n\022ROM_ERROR_NO_ERROR\020\001\022\030\n\024ROM_" - "ERROR_OUT_OF_GAS\020\002\022\034\n\030ROM_ERROR_STACK_OV" - "ERFLOW\020\003\022\035\n\031ROM_ERROR_STACK_UNDERFLOW\020\004\022" - "$\n ROM_ERROR_MAX_CODE_SIZE_EXCEEDED\020\005\022(\n" - "$ROM_ERROR_CONTRACT_ADDRESS_COLLISION\020\006\022" - " \n\034ROM_ERROR_EXECUTION_REVERTED\020\007\022\"\n\036ROM" - "_ERROR_OUT_OF_COUNTERS_STEP\020\010\022$\n ROM_ERR" - "OR_OUT_OF_COUNTERS_KECCAK\020\t\022$\n ROM_ERROR" - "_OUT_OF_COUNTERS_BINARY\020\n\022!\n\035ROM_ERROR_O" - "UT_OF_COUNTERS_MEM\020\013\022#\n\037ROM_ERROR_OUT_OF" - "_COUNTERS_ARITH\020\014\022%\n!ROM_ERROR_OUT_OF_CO" - "UNTERS_PADDING\020\r\022&\n\"ROM_ERROR_OUT_OF_COU" - "NTERS_POSEIDON\020\016\022!\n\035ROM_ERROR_OUT_OF_COU" - "NTERS_SHA\020\017\022\032\n\026ROM_ERROR_INVALID_JUMP\020\020\022" - "\034\n\030ROM_ERROR_INVALID_OPCODE\020\021\022\034\n\030ROM_ERR" - "OR_INVALID_STATIC\020\022\022(\n$ROM_ERROR_INVALID" - "_BYTECODE_STARTS_EF\020\023\022)\n%ROM_ERROR_INTRI" - "NSIC_INVALID_SIGNATURE\020\024\022(\n$ROM_ERROR_IN" - "TRINSIC_INVALID_CHAIN_ID\020\025\022%\n!ROM_ERROR_" - "INTRINSIC_INVALID_NONCE\020\026\022)\n%ROM_ERROR_I" - "NTRINSIC_INVALID_GAS_LIMIT\020\027\022\'\n#ROM_ERRO" - "R_INTRINSIC_INVALID_BALANCE\020\030\022/\n+ROM_ERR" - "OR_INTRINSIC_INVALID_BATCH_GAS_LIMIT\020\031\022+" - "\n\'ROM_ERROR_INTRINSIC_INVALID_SENDER_COD" - "E\020\032\022\'\n#ROM_ERROR_INTRINSIC_TX_GAS_OVERFL" - "OW\020\033\022 \n\034ROM_ERROR_BATCH_DATA_TOO_BIG\020\034\022!" - "\n\035ROM_ERROR_UNSUPPORTED_FORK_ID\020\035\022\031\n\025ROM" - "_ERROR_INVALID_RLP\020\036\022,\n(ROM_ERROR_INVALI" - "D_DECODE_CHANGE_L2_BLOCK\020\037\0222\n.ROM_ERROR_" - "INVALID_NOT_FIRST_TX_CHANGE_L2_BLOCK\020 \0228" - "\n4ROM_ERROR_INVALID_TX_CHANGE_L2_BLOCK_L" - "IMIT_TIMESTAMP\020!\0226\n2ROM_ERROR_INVALID_TX" - "_CHANGE_L2_BLOCK_MIN_TIMESTAMP\020\"\022(\n$ROM_" - "ERROR_INVALID_L1_INFO_TREE_INDEX\020#*\355+\n\rE" - "xecutorError\022\036\n\032EXECUTOR_ERROR_UNSPECIFI" - "ED\020\000\022\033\n\027EXECUTOR_ERROR_NO_ERROR\020\001\022\033\n\027EXE" - "CUTOR_ERROR_DB_ERROR\020\002\0222\n.EXECUTOR_ERROR" - "_SM_MAIN_COUNTERS_OVERFLOW_STEPS\020\003\0223\n/EX" - "ECUTOR_ERROR_SM_MAIN_COUNTERS_OVERFLOW_K" - "ECCAK\020\004\0223\n/EXECUTOR_ERROR_SM_MAIN_COUNTE" - "RS_OVERFLOW_BINARY\020\005\0220\n,EXECUTOR_ERROR_S" - "M_MAIN_COUNTERS_OVERFLOW_MEM\020\006\0222\n.EXECUT" - "OR_ERROR_SM_MAIN_COUNTERS_OVERFLOW_ARITH" - "\020\007\0224\n0EXECUTOR_ERROR_SM_MAIN_COUNTERS_OV" - "ERFLOW_PADDING\020\010\0225\n1EXECUTOR_ERROR_SM_MA" - "IN_COUNTERS_OVERFLOW_POSEIDON\020\t\022&\n\"EXECU" - "TOR_ERROR_UNSUPPORTED_FORK_ID\020\n\022#\n\037EXECU" - "TOR_ERROR_BALANCE_MISMATCH\020\013\022\035\n\031EXECUTOR" - "_ERROR_FEA2SCALAR\020\014\022\030\n\024EXECUTOR_ERROR_TO" - "S32\020\r\022.\n*EXECUTOR_ERROR_SM_MAIN_INVALID_" - "UNSIGNED_TX\020\016\022.\n*EXECUTOR_ERROR_SM_MAIN_" - "INVALID_NO_COUNTERS\020\017\0229\n5EXECUTOR_ERROR_" - "SM_MAIN_ARITH_ECRECOVER_DIVIDE_BY_ZERO\020\020" - "\022/\n+EXECUTOR_ERROR_SM_MAIN_ADDRESS_OUT_O" - "F_RANGE\020\021\022+\n\'EXECUTOR_ERROR_SM_MAIN_ADDR" - "ESS_NEGATIVE\020\022\022.\n*EXECUTOR_ERROR_SM_MAIN" - "_STORAGE_INVALID_KEY\020\023\022 \n\034EXECUTOR_ERROR" - "_SM_MAIN_HASHK\020\024\0222\n.EXECUTOR_ERROR_SM_MA" - "IN_HASHK_SIZE_OUT_OF_RANGE\020\025\0222\n.EXECUTOR" - "_ERROR_SM_MAIN_HASHK_POSITION_NEGATIVE\020\026" - "\022@\n\0222\n.EXECUTOR_ERROR_SM_MAIN_" - "MEMALIGN_WRITE_MISMATCH\020\?\0223\n/EXECUTOR_ER" - "ROR_SM_MAIN_MEMALIGN_WRITE8_MISMATCH\020@\0221" - "\n-EXECUTOR_ERROR_SM_MAIN_MEMALIGN_READ_M" - "ISMATCH\020A\022,\n(EXECUTOR_ERROR_SM_MAIN_JMPN" - "_OUT_OF_RANGE\020B\0222\n.EXECUTOR_ERROR_SM_MAI" - "N_HASHK_READ_OUT_OF_RANGE\020C\0222\n.EXECUTOR_" - "ERROR_SM_MAIN_HASHP_READ_OUT_OF_RANGE\020D\022" - ")\n%EXECUTOR_ERROR_INVALID_OLD_STATE_ROOT" - "\020E\022-\n)EXECUTOR_ERROR_INVALID_OLD_ACC_INP" - "UT_HASH\020F\022#\n\037EXECUTOR_ERROR_INVALID_CHAI" - "N_ID\020G\022(\n$EXECUTOR_ERROR_INVALID_BATCH_L" - "2_DATA\020H\022+\n\'EXECUTOR_ERROR_INVALID_GLOBA" - "L_EXIT_ROOT\020I\022#\n\037EXECUTOR_ERROR_INVALID_" - "COINBASE\020J\022\037\n\033EXECUTOR_ERROR_INVALID_FRO" - "M\020K\022!\n\035EXECUTOR_ERROR_INVALID_DB_KEY\020L\022#" - "\n\037EXECUTOR_ERROR_INVALID_DB_VALUE\020M\0221\n-E" - "XECUTOR_ERROR_INVALID_CONTRACTS_BYTECODE" - "_KEY\020N\0223\n/EXECUTOR_ERROR_INVALID_CONTRAC" - "TS_BYTECODE_VALUE\020O\022\"\n\036EXECUTOR_ERROR_IN" - "VALID_GET_KEY\020P\0223\n/EXECUTOR_ERROR_SM_MAI" - "N_COUNTERS_OVERFLOW_SHA256\020Q\022 \n\034EXECUTOR" - "_ERROR_SM_MAIN_HASHS\020R\0222\n.EXECUTOR_ERROR" - "_SM_MAIN_HASHS_SIZE_OUT_OF_RANGE\020S\0222\n.EX" - "ECUTOR_ERROR_SM_MAIN_HASHS_POSITION_NEGA" - "TIVE\020T\022@\nZ\0222\n.EX" + "ECUTOR_ERROR_SM_MAIN_MEMALIGN_WRITE_MISM" + "ATCH\020\?\0223\n/EXECUTOR_ERROR_SM_MAIN_MEMALIG" + "N_WRITE8_MISMATCH\020@\0221\n-EXECUTOR_ERROR_SM" + "_MAIN_MEMALIGN_READ_MISMATCH\020A\022,\n(EXECUT" + "OR_ERROR_SM_MAIN_JMPN_OUT_OF_RANGE\020B\0222\n." + "EXECUTOR_ERROR_SM_MAIN_HASHK_READ_OUT_OF" + "_RANGE\020C\0222\n.EXECUTOR_ERROR_SM_MAIN_HASHP" + "_READ_OUT_OF_RANGE\020D\022)\n%EXECUTOR_ERROR_I" + "NVALID_OLD_STATE_ROOT\020E\022-\n)EXECUTOR_ERRO" + "R_INVALID_OLD_ACC_INPUT_HASH\020F\022#\n\037EXECUT" + "OR_ERROR_INVALID_CHAIN_ID\020G\022(\n$EXECUTOR_" + "ERROR_INVALID_BATCH_L2_DATA\020H\022+\n\'EXECUTO" + "R_ERROR_INVALID_GLOBAL_EXIT_ROOT\020I\022#\n\037EX" + "ECUTOR_ERROR_INVALID_COINBASE\020J\022\037\n\033EXECU" + "TOR_ERROR_INVALID_FROM\020K\022!\n\035EXECUTOR_ERR" + "OR_INVALID_DB_KEY\020L\022#\n\037EXECUTOR_ERROR_IN" + "VALID_DB_VALUE\020M\0221\n-EXECUTOR_ERROR_INVAL" + "ID_CONTRACTS_BYTECODE_KEY\020N\0223\n/EXECUTOR_" + "ERROR_INVALID_CONTRACTS_BYTECODE_VALUE\020O" + "\022\"\n\036EXECUTOR_ERROR_INVALID_GET_KEY\020P\0223\n/" + "EXECUTOR_ERROR_SM_MAIN_COUNTERS_OVERFLOW" + "_SHA256\020Q\022 \n\034EXECUTOR_ERROR_SM_MAIN_HASH" + "S\020R\0222\n.EXECUTOR_ERROR_SM_MAIN_HASHS_SIZE" + "_OUT_OF_RANGE\020S\0222\n.EXECUTOR_ERROR_SM_MAI" + "N_HASHS_POSITION_NEGATIVE\020T\022@\nZ(reinterpret_cast(&no_counters_) - + reinterpret_cast(×tamp_limit_)) + sizeof(no_counters_)); // @@protoc_insertion_point(copy_constructor:executor.v1.ProcessStatelessBatchRequestV2) } @@ -9385,8 +9389,8 @@ void ProcessStatelessBatchRequestV2::SharedCtor() { forced_blockhash_l1_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); context_id_.UnsafeSetDefault(&::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited()); ::memset(&trace_config_, 0, static_cast( - reinterpret_cast(×tamp_limit_) - - reinterpret_cast(&trace_config_)) + sizeof(timestamp_limit_)); + reinterpret_cast(&no_counters_) - + reinterpret_cast(&trace_config_)) + sizeof(no_counters_)); } ProcessStatelessBatchRequestV2::~ProcessStatelessBatchRequestV2() { @@ -9440,7 +9444,9 @@ void ProcessStatelessBatchRequestV2::Clear() { delete trace_config_; } trace_config_ = nullptr; - timestamp_limit_ = PROTOBUF_ULONGLONG(0); + ::memset(×tamp_limit_, 0, static_cast( + reinterpret_cast(&no_counters_) - + reinterpret_cast(×tamp_limit_)) + sizeof(no_counters_)); _internal_metadata_.Clear<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(); } @@ -9536,6 +9542,13 @@ const char* ProcessStatelessBatchRequestV2::_InternalParse(const char* ptr, ::PR } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<82>(ptr)); } else goto handle_unusual; continue; + // uint32 no_counters = 11; + case 11: + if (PROTOBUF_PREDICT_TRUE(static_cast<::PROTOBUF_NAMESPACE_ID::uint8>(tag) == 88)) { + no_counters_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr); + CHK_(ptr); + } else goto handle_unusual; + continue; default: { handle_unusual: if ((tag & 7) == 4 || tag == 0) { @@ -9659,6 +9672,12 @@ ::PROTOBUF_NAMESPACE_ID::uint8* ProcessStatelessBatchRequestV2::_InternalSeriali } } + // uint32 no_counters = 11; + if (this->no_counters() != 0) { + target = stream->EnsureSpace(target); + target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::WriteUInt32ToArray(11, this->_internal_no_counters(), target); + } + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormat::InternalSerializeUnknownFieldsToArray( _internal_metadata_.unknown_fields<::PROTOBUF_NAMESPACE_ID::UnknownFieldSet>(::PROTOBUF_NAMESPACE_ID::UnknownFieldSet::default_instance), target, stream); @@ -9747,6 +9766,13 @@ size_t ProcessStatelessBatchRequestV2::ByteSizeLong() const { this->_internal_timestamp_limit()); } + // uint32 no_counters = 11; + if (this->no_counters() != 0) { + total_size += 1 + + ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::UInt32Size( + this->_internal_no_counters()); + } + if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) { return ::PROTOBUF_NAMESPACE_ID::internal::ComputeUnknownFieldsSize( _internal_metadata_, total_size, &_cached_size_); @@ -9806,6 +9832,9 @@ void ProcessStatelessBatchRequestV2::MergeFrom(const ProcessStatelessBatchReques if (from.timestamp_limit() != 0) { _internal_set_timestamp_limit(from._internal_timestamp_limit()); } + if (from.no_counters() != 0) { + _internal_set_no_counters(from._internal_no_counters()); + } } void ProcessStatelessBatchRequestV2::CopyFrom(const ::PROTOBUF_NAMESPACE_ID::Message& from) { @@ -9838,8 +9867,8 @@ void ProcessStatelessBatchRequestV2::InternalSwap(ProcessStatelessBatchRequestV2 forced_blockhash_l1_.Swap(&other->forced_blockhash_l1_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); context_id_.Swap(&other->context_id_, &::PROTOBUF_NAMESPACE_ID::internal::GetEmptyStringAlreadyInited(), GetArena()); ::PROTOBUF_NAMESPACE_ID::internal::memswap< - PROTOBUF_FIELD_OFFSET(ProcessStatelessBatchRequestV2, timestamp_limit_) - + sizeof(ProcessStatelessBatchRequestV2::timestamp_limit_) + PROTOBUF_FIELD_OFFSET(ProcessStatelessBatchRequestV2, no_counters_) + + sizeof(ProcessStatelessBatchRequestV2::no_counters_) - PROTOBUF_FIELD_OFFSET(ProcessStatelessBatchRequestV2, trace_config_)>( reinterpret_cast(&trace_config_), reinterpret_cast(&other->trace_config_)); diff --git a/src/grpc/gen/executor.pb.h b/src/grpc/gen/executor.pb.h index 22db30d68..a203bce8b 100644 --- a/src/grpc/gen/executor.pb.h +++ b/src/grpc/gen/executor.pb.h @@ -5226,6 +5226,7 @@ class ProcessStatelessBatchRequestV2 PROTOBUF_FINAL : kContextIdFieldNumber = 8, kTraceConfigFieldNumber = 9, kTimestampLimitFieldNumber = 6, + kNoCountersFieldNumber = 11, }; // map l1_info_tree_index_min_timestamp = 10; int l1_info_tree_index_min_timestamp_size() const; @@ -5446,6 +5447,15 @@ class ProcessStatelessBatchRequestV2 PROTOBUF_FINAL : void _internal_set_timestamp_limit(::PROTOBUF_NAMESPACE_ID::uint64 value); public: + // uint32 no_counters = 11; + void clear_no_counters(); + ::PROTOBUF_NAMESPACE_ID::uint32 no_counters() const; + void set_no_counters(::PROTOBUF_NAMESPACE_ID::uint32 value); + private: + ::PROTOBUF_NAMESPACE_ID::uint32 _internal_no_counters() const; + void _internal_set_no_counters(::PROTOBUF_NAMESPACE_ID::uint32 value); + public: + // @@protoc_insertion_point(class_scope:executor.v1.ProcessStatelessBatchRequestV2) private: class _Internal; @@ -5468,6 +5478,7 @@ class ProcessStatelessBatchRequestV2 PROTOBUF_FINAL : ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr context_id_; ::executor::v1::TraceConfigV2* trace_config_; ::PROTOBUF_NAMESPACE_ID::uint64 timestamp_limit_; + ::PROTOBUF_NAMESPACE_ID::uint32 no_counters_; mutable ::PROTOBUF_NAMESPACE_ID::internal::CachedSize _cached_size_; friend struct ::TableStruct_executor_2eproto; }; @@ -17398,6 +17409,26 @@ ProcessStatelessBatchRequestV2::mutable_l1_info_tree_index_min_timestamp() { return _internal_mutable_l1_info_tree_index_min_timestamp(); } +// uint32 no_counters = 11; +inline void ProcessStatelessBatchRequestV2::clear_no_counters() { + no_counters_ = 0u; +} +inline ::PROTOBUF_NAMESPACE_ID::uint32 ProcessStatelessBatchRequestV2::_internal_no_counters() const { + return no_counters_; +} +inline ::PROTOBUF_NAMESPACE_ID::uint32 ProcessStatelessBatchRequestV2::no_counters() const { + // @@protoc_insertion_point(field_get:executor.v1.ProcessStatelessBatchRequestV2.no_counters) + return _internal_no_counters(); +} +inline void ProcessStatelessBatchRequestV2::_internal_set_no_counters(::PROTOBUF_NAMESPACE_ID::uint32 value) { + + no_counters_ = value; +} +inline void ProcessStatelessBatchRequestV2::set_no_counters(::PROTOBUF_NAMESPACE_ID::uint32 value) { + _internal_set_no_counters(value); + // @@protoc_insertion_point(field_set:executor.v1.ProcessStatelessBatchRequestV2.no_counters) +} + // ------------------------------------------------------------------- // L1DataV2 diff --git a/src/grpc/proto/executor.proto b/src/grpc/proto/executor.proto index 51a6bf677..ebf1e6048 100644 --- a/src/grpc/proto/executor.proto +++ b/src/grpc/proto/executor.proto @@ -314,6 +314,9 @@ message ProcessStatelessBatchRequestV2 { // Mapping to provide minTimestamp for each l1InfoTreeIndex in a batch map l1_info_tree_index_min_timestamp = 10; + + // flag to indicate that counters should not be taken into account + uint32 no_counters = 11; } message L1DataV2 { diff --git a/src/service/executor/executor_service.cpp b/src/service/executor/executor_service.cpp index 04d7998f3..77136ea69 100644 --- a/src/service/executor/executor_service.cpp +++ b/src/service/executor/executor_service.cpp @@ -1925,7 +1925,7 @@ ::grpc::Status ExecutorServiceImpl::ProcessStatelessBatchV2 (::grpc::ServerConte // Flags proverRequest.input.bUpdateMerkleTree = true; - proverRequest.input.bNoCounters = false; + proverRequest.input.bNoCounters = request->no_counters(); proverRequest.input.bGetKeys = false; proverRequest.input.bSkipVerifyL1InfoRoot = true; proverRequest.input.bSkipFirstChangeL2Block = false;