From 4fbed86e6b41d31635921b2b31dc66d9664ee30d Mon Sep 17 00:00:00 2001 From: Dan Brownstein Date: Sun, 7 Jul 2024 14:37:34 +0300 Subject: [PATCH] chore: sort versioned constants --- .../resources/versioned_constants.json | 326 ++++++------ .../resources/versioned_constants_13_0.json | 296 +++++------ .../resources/versioned_constants_13_1.json | 484 +++++++++--------- .../resources/versioned_constants_13_1_1.json | 484 +++++++++--------- 4 files changed, 795 insertions(+), 795 deletions(-) diff --git a/crates/blockifier/resources/versioned_constants.json b/crates/blockifier/resources/versioned_constants.json index dca45e382e..4bd31296cf 100644 --- a/crates/blockifier/resources/versioned_constants.json +++ b/crates/blockifier/resources/versioned_constants.json @@ -1,19 +1,11 @@ { - "tx_event_limits": { - "max_data_length": 300, - "max_keys_length": 50, - "max_n_emitted_events": 1000 - }, + "disable_cairo0_redeclaration": true, "gateway": { "max_calldata_length": 4000, "max_contract_bytecode_size": 81920 }, "invoke_tx_max_n_steps": 4000000, "l2_resource_gas_costs": { - "gas_per_data_felt": [ - 128, - 1000 - ], "event_key_factor": [ 2, 1 @@ -21,11 +13,15 @@ "gas_per_code_byte": [ 875, 1000 + ], + "gas_per_data_felt": [ + 128, + 1000 ] }, - "disable_cairo0_redeclaration": true, "max_recursion_depth": 50, "os_constants": { + "bitwise_builtin_gas_cost": 594, "block_hash_contract_address": 1, "call_contract_gas_cost": { "entry_point_gas_cost": 1, @@ -54,8 +50,8 @@ "entry_point_type_external": 0, "entry_point_type_l1_handler": 1, "error_block_number_out_of_range": "Block number out of range", - "error_invalid_input_len": "Invalid input length", "error_invalid_argument": "Invalid argument", + "error_invalid_input_len": "Invalid input length", "error_out_of_gas": "Out of gas", "execute_entry_point_selector": "0x15d40a3d6ca2ac30f4031e42be28da9b056fef9bb7357ac5e85627ee876e5ad", "fee_transfer_gas_cost": { @@ -85,16 +81,9 @@ "library_call_gas_cost": { "call_contract_gas_cost": 1 }, - "sha256_process_block_gas_cost": { - "step_gas_cost": 1852, - "range_check_gas_cost": 65, - "bitwise_builtin_gas_cost": 1115, - "syscall_base_gas_cost": 1 - }, "memory_hole_gas_cost": 10, "nop_entry_point_offset": -1, "range_check_gas_cost": 70, - "bitwise_builtin_gas_cost": 594, "replace_class_gas_cost": { "step_gas_cost": 50, "syscall_base_gas_cost": 1 @@ -151,6 +140,12 @@ "step_gas_cost": 50, "syscall_base_gas_cost": 1 }, + "sha256_process_block_gas_cost": { + "bitwise_builtin_gas_cost": 1115, + "range_check_gas_cost": 65, + "step_gas_cost": 1852, + "syscall_base_gas_cost": 1 + }, "sierra_array_len_bound": 4294967296, "step_gas_cost": 100, "storage_read_gas_cost": { @@ -181,378 +176,383 @@ "validated": "VALID" }, "os_resources": { + "compute_os_kzg_commitment_info": { + "builtin_instance_counter": { + "range_check_builtin": 17 + }, + "n_memory_holes": 0, + "n_steps": 113 + }, "execute_syscalls": { "CallContract": { - "n_steps": 827, "builtin_instance_counter": { "range_check_builtin": 15 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 827 }, "DelegateCall": { - "n_steps": 713, "builtin_instance_counter": { "range_check_builtin": 19 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 713 }, "DelegateL1Handler": { - "n_steps": 692, "builtin_instance_counter": { "range_check_builtin": 15 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 692 }, "Deploy": { - "n_steps": 1097, "builtin_instance_counter": { "pedersen_builtin": 7, "range_check_builtin": 18 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 1097 }, "EmitEvent": { - "n_steps": 61, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 61 }, "GetBlockHash": { - "n_steps": 104, "builtin_instance_counter": { "range_check_builtin": 2 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 104 }, "GetBlockNumber": { - "n_steps": 40, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 40 }, "GetBlockTimestamp": { - "n_steps": 38, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 38 }, "GetCallerAddress": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetContractAddress": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetExecutionInfo": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetSequencerAddress": { - "n_steps": 34, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 34 }, "GetTxInfo": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetTxSignature": { - "n_steps": 44, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 44 }, "Keccak": { - "n_steps": 381, "builtin_instance_counter": { "bitwise_builtin": 6, "keccak_builtin": 1, "range_check_builtin": 56 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 381 }, "LibraryCall": { - "n_steps": 818, "builtin_instance_counter": { "range_check_builtin": 15 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 818 }, "LibraryCallL1Handler": { - "n_steps": 659, "builtin_instance_counter": { "range_check_builtin": 15 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 659 }, "ReplaceClass": { - "n_steps": 98, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 98 }, "Secp256k1Add": { - "n_steps": 410, "builtin_instance_counter": { "range_check_builtin": 29 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 410 }, "Secp256k1GetPointFromX": { - "n_steps": 395, "builtin_instance_counter": { "range_check_builtin": 30 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 395 }, "Secp256k1GetXy": { - "n_steps": 207, "builtin_instance_counter": { "range_check_builtin": 11 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 207 }, "Secp256k1Mul": { - "n_steps": 76505, "builtin_instance_counter": { "range_check_builtin": 7045 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 76505 }, "Secp256k1New": { - "n_steps": 461, "builtin_instance_counter": { "range_check_builtin": 35 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 461 }, "Secp256r1Add": { - "n_steps": 593, "builtin_instance_counter": { "range_check_builtin": 57 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 593 }, "Secp256r1GetPointFromX": { - "n_steps": 514, "builtin_instance_counter": { "range_check_builtin": 44 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 514 }, "Secp256r1GetXy": { - "n_steps": 209, "builtin_instance_counter": { "range_check_builtin": 11 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 209 }, "Secp256r1Mul": { - "n_steps": 125344, "builtin_instance_counter": { "range_check_builtin": 13961 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 125344 }, "Secp256r1New": { - "n_steps": 580, "builtin_instance_counter": { "range_check_builtin": 49 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 580 }, "SendMessageToL1": { - "n_steps": 141, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 141 }, "Sha256ProcessBlock": { - "n_steps": 1855, "builtin_instance_counter": { - "range_check_builtin": 65, - "bitwise_builtin": 1115 + "bitwise_builtin": 1115, + "range_check_builtin": 65 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 1855 }, "StorageRead": { - "n_steps": 87, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 87 }, "StorageWrite": { - "n_steps": 89, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 89 } }, "execute_txs_inner": { "Declare": { "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { - "n_steps": 2973, "builtin_instance_counter": { "pedersen_builtin": 16, "range_check_builtin": 53 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 2973 } }, "resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { - "n_steps": 3079, "builtin_instance_counter": { "pedersen_builtin": 4, - "range_check_builtin": 58, - "poseidon_builtin": 10 + "poseidon_builtin": 10, + "range_check_builtin": 58 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 3079 } } }, "DeployAccount": { "deprecated_resources": { - "constant": { - "n_steps": 4015, + "calldata_factor": { "builtin_instance_counter": { - "pedersen_builtin": 23, - "range_check_builtin": 72 + "pedersen_builtin": 2 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 21 }, - "calldata_factor": { - "n_steps": 21, + "constant": { "builtin_instance_counter": { - "pedersen_builtin": 2 + "pedersen_builtin": 23, + "range_check_builtin": 72 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 4015 } }, "resources": { - "constant": { - "n_steps": 4137, + "calldata_factor": { "builtin_instance_counter": { - "pedersen_builtin": 11, - "range_check_builtin": 77, - "poseidon_builtin": 10 + "pedersen_builtin": 2 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 21 }, - "calldata_factor": { - "n_steps": 21, + "constant": { "builtin_instance_counter": { - "pedersen_builtin": 2 + "pedersen_builtin": 11, + "poseidon_builtin": 10, + "range_check_builtin": 77 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 4137 } } }, "InvokeFunction": { "deprecated_resources": { - "constant": { - "n_steps": 3763, + "calldata_factor": { "builtin_instance_counter": { - "pedersen_builtin": 14, - "range_check_builtin": 69 + "pedersen_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 8 }, - "calldata_factor": { - "n_steps": 8, + "constant": { "builtin_instance_counter": { - "pedersen_builtin": 1 + "pedersen_builtin": 14, + "range_check_builtin": 69 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 3763 } }, "resources": { - "constant": { - "n_steps": 3904, + "calldata_factor": { "builtin_instance_counter": { - "pedersen_builtin": 4, - "range_check_builtin": 74, - "poseidon_builtin": 11 + "pedersen_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 8 }, - "calldata_factor": { - "n_steps": 8, + "constant": { "builtin_instance_counter": { - "pedersen_builtin": 1 + "pedersen_builtin": 4, + "poseidon_builtin": 11, + "range_check_builtin": 74 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 3904 } } }, "L1Handler": { "deprecated_resources": { - "constant": { - "n_steps": 1233, + "calldata_factor": { "builtin_instance_counter": { - "pedersen_builtin": 11, - "range_check_builtin": 16 + "pedersen_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 13 }, - "calldata_factor": { - "n_steps": 13, + "constant": { "builtin_instance_counter": { - "pedersen_builtin": 1 + "pedersen_builtin": 11, + "range_check_builtin": 16 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 1233 } }, "resources": { - "constant": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 - }, "calldata_factor": { - "n_steps": 13, "builtin_instance_counter": { "pedersen_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 13 + }, + "constant": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 } } } - }, - "compute_os_kzg_commitment_info": { - "n_steps": 113, - "builtin_instance_counter": { - "range_check_builtin": 17 - }, - "n_memory_holes": 0 } }, + "tx_event_limits": { + "max_data_length": 300, + "max_keys_length": 50, + "max_n_emitted_events": 1000 + }, "validate_max_n_steps": 1000000, "vm_resource_fee_cost": { "add_mod_builtin": [ @@ -595,11 +595,11 @@ 8, 100 ], - "range_check_builtin": [ + "range_check96_builtin": [ 4, 100 ], - "range_check96_builtin": [ + "range_check_builtin": [ 4, 100 ] diff --git a/crates/blockifier/resources/versioned_constants_13_0.json b/crates/blockifier/resources/versioned_constants_13_0.json index 1531f6fc13..1939cacdc5 100644 --- a/crates/blockifier/resources/versioned_constants_13_0.json +++ b/crates/blockifier/resources/versioned_constants_13_0.json @@ -6,153 +6,158 @@ "invoke_tx_max_n_steps": 3000000, "max_recursion_depth": 50, "os_constants": { - "nop_entry_point_offset": -1, - "entry_point_type_external": 0, - "entry_point_type_l1_handler": 1, - "entry_point_type_constructor": 2, - "l1_handler_version": 0, - "sierra_array_len_bound": 4294967296, - "constructor_entry_point_selector": "0x28ffe4ff0f226a9107253e17a904099aa4f63a02a5621de0576e5aa71bc5194", - "execute_entry_point_selector": "0x15d40a3d6ca2ac30f4031e42be28da9b056fef9bb7357ac5e85627ee876e5ad", - "validate_entry_point_selector": "0x162da33a4585851fe8d3af3c2a9c60b557814e221e0d4f30ff0b2189d9c7775", - "validate_declare_entry_point_selector": "0x289da278a8dc833409cabfdad1581e8e7d40e42dcaed693fa4008dcdb4963b3", - "validate_deploy_entry_point_selector": "0x36fcbf06cd96843058359e1a75928beacfac10727dab22a3972f0af8aa92895", - "transfer_entry_point_selector": "0x83afd3f4caedc6eebf44246fe54e38c95e3179a5ec9ea81740eca5b482d12e", - "default_entry_point_selector": 0, "block_hash_contract_address": 1, - "stored_block_hash_buffer": 10, - "step_gas_cost": 100, - "range_check_gas_cost": 70, - "memory_hole_gas_cost": 10, - "initial_gas_cost": { - "step_gas_cost": 100000000 + "call_contract_gas_cost": { + "entry_point_gas_cost": 1, + "step_gas_cost": 10, + "syscall_base_gas_cost": 1 }, - "entry_point_initial_budget": { - "step_gas_cost": 100 + "constructor_entry_point_selector": "0x28ffe4ff0f226a9107253e17a904099aa4f63a02a5621de0576e5aa71bc5194", + "default_entry_point_selector": 0, + "deploy_gas_cost": { + "entry_point_gas_cost": 1, + "step_gas_cost": 200, + "syscall_base_gas_cost": 1 }, - "syscall_base_gas_cost": { - "step_gas_cost": 100 + "emit_event_gas_cost": { + "step_gas_cost": 10, + "syscall_base_gas_cost": 1 }, "entry_point_gas_cost": { "entry_point_initial_budget": 1, "step_gas_cost": 500 }, + "entry_point_initial_budget": { + "step_gas_cost": 100 + }, + "entry_point_type_constructor": 2, + "entry_point_type_external": 0, + "entry_point_type_l1_handler": 1, + "error_block_number_out_of_range": "Block number out of range", + "error_invalid_argument": "Invalid argument", + "error_invalid_input_len": "Invalid input length", + "error_out_of_gas": "Out of gas", + "execute_entry_point_selector": "0x15d40a3d6ca2ac30f4031e42be28da9b056fef9bb7357ac5e85627ee876e5ad", "fee_transfer_gas_cost": { "entry_point_gas_cost": 1, "step_gas_cost": 100 }, - "transaction_gas_cost": { - "entry_point_gas_cost": 2, - "fee_transfer_gas_cost": 1, - "step_gas_cost": 100 + "get_block_hash_gas_cost": { + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 }, - "call_contract_gas_cost": { - "syscall_base_gas_cost": 1, + "get_execution_info_gas_cost": { "step_gas_cost": 10, - "entry_point_gas_cost": 1 - }, - "deploy_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 200, - "entry_point_gas_cost": 1 + "syscall_base_gas_cost": 1 }, - "get_block_hash_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 + "initial_gas_cost": { + "step_gas_cost": 100000000 }, - "get_execution_info_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 10 + "keccak_gas_cost": { + "syscall_base_gas_cost": 1 }, + "keccak_round_cost_gas_cost": 180000, + "l1_gas": "L1_GAS", + "l1_gas_index": 0, + "l1_handler_version": 0, + "l2_gas": "L2_GAS", + "l2_gas_index": 1, "library_call_gas_cost": { "call_contract_gas_cost": 1 }, + "memory_hole_gas_cost": 10, + "nop_entry_point_offset": -1, + "range_check_gas_cost": 70, "replace_class_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 - }, - "storage_read_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 - }, - "storage_write_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 - }, - "emit_event_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 10 - }, - "send_message_to_l1_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 }, "secp256k1_add_gas_cost": { - "step_gas_cost": 406, - "range_check_gas_cost": 29 + "range_check_gas_cost": 29, + "step_gas_cost": 406 }, "secp256k1_get_point_from_x_gas_cost": { - "step_gas_cost": 391, + "memory_hole_gas_cost": 20, "range_check_gas_cost": 30, - "memory_hole_gas_cost": 20 + "step_gas_cost": 391 }, "secp256k1_get_xy_gas_cost": { - "step_gas_cost": 239, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 11, - "memory_hole_gas_cost": 40 + "step_gas_cost": 239 }, "secp256k1_mul_gas_cost": { - "step_gas_cost": 76401, - "range_check_gas_cost": 7045 + "range_check_gas_cost": 7045, + "step_gas_cost": 76401 }, "secp256k1_new_gas_cost": { - "step_gas_cost": 475, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 35, - "memory_hole_gas_cost": 40 + "step_gas_cost": 475 }, "secp256r1_add_gas_cost": { - "step_gas_cost": 589, - "range_check_gas_cost": 57 + "range_check_gas_cost": 57, + "step_gas_cost": 589 }, "secp256r1_get_point_from_x_gas_cost": { - "step_gas_cost": 510, + "memory_hole_gas_cost": 20, "range_check_gas_cost": 44, - "memory_hole_gas_cost": 20 + "step_gas_cost": 510 }, "secp256r1_get_xy_gas_cost": { - "step_gas_cost": 241, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 11, - "memory_hole_gas_cost": 40 + "step_gas_cost": 241 }, "secp256r1_mul_gas_cost": { - "step_gas_cost": 125240, - "range_check_gas_cost": 13961 + "range_check_gas_cost": 13961, + "step_gas_cost": 125240 }, "secp256r1_new_gas_cost": { - "step_gas_cost": 594, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 49, - "memory_hole_gas_cost": 40 + "step_gas_cost": 594 }, - "keccak_gas_cost": { + "send_message_to_l1_gas_cost": { + "step_gas_cost": 50, "syscall_base_gas_cost": 1 }, - "keccak_round_cost_gas_cost": 180000, "sha256_process_block_gas_cost": { - "step_gas_cost": 0, "range_check_gas_cost": 0, + "step_gas_cost": 0, "syscall_base_gas_cost": 0 }, - "error_block_number_out_of_range": "Block number out of range", - "error_out_of_gas": "Out of gas", - "error_invalid_input_len": "Invalid input length", - "error_invalid_argument": "Invalid argument", - "validated": "VALID", - "l1_gas": "L1_GAS", - "l2_gas": "L2_GAS", - "l1_gas_index": 0, - "l2_gas_index": 1 + "sierra_array_len_bound": 4294967296, + "step_gas_cost": 100, + "storage_read_gas_cost": { + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 + }, + "storage_write_gas_cost": { + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 + }, + "stored_block_hash_buffer": 10, + "syscall_base_gas_cost": { + "step_gas_cost": 100 + }, + "transaction_gas_cost": { + "entry_point_gas_cost": 2, + "fee_transfer_gas_cost": 1, + "step_gas_cost": 100 + }, + "transfer_entry_point_selector": "0x83afd3f4caedc6eebf44246fe54e38c95e3179a5ec9ea81740eca5b482d12e", + "validate_declare_entry_point_selector": "0x289da278a8dc833409cabfdad1581e8e7d40e42dcaed693fa4008dcdb4963b3", + "validate_deploy_entry_point_selector": "0x36fcbf06cd96843058359e1a75928beacfac10727dab22a3972f0af8aa92895", + "validate_entry_point_selector": "0x162da33a4585851fe8d3af3c2a9c60b557814e221e0d4f30ff0b2189d9c7775", + "validated": "VALID" }, "os_resources": { + "compute_os_kzg_commitment_info": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "execute_syscalls": { "CallContract": { "builtin_instance_counter": { @@ -356,7 +361,12 @@ }, "execute_txs_inner": { "Declare": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { "builtin_instance_counter": { "pedersen_builtin": 15, @@ -364,14 +374,14 @@ }, "n_memory_holes": 0, "n_steps": 2711 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 } }, - "deprecated_resources": { + "resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { "builtin_instance_counter": { "pedersen_builtin": 15, @@ -379,16 +389,16 @@ }, "n_memory_holes": 0, "n_steps": 2711 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 } } }, "DeployAccount": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { "builtin_instance_counter": { "pedersen_builtin": 23, @@ -396,14 +406,14 @@ }, "n_memory_holes": 0, "n_steps": 3628 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 } }, - "deprecated_resources": { + "resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { "builtin_instance_counter": { "pedersen_builtin": 23, @@ -411,16 +421,16 @@ }, "n_memory_holes": 0, "n_steps": 3628 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 } } }, "InvokeFunction": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { "builtin_instance_counter": { "pedersen_builtin": 16, @@ -428,14 +438,14 @@ }, "n_memory_holes": 0, "n_steps": 3382 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 } }, - "deprecated_resources": { + "resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { "builtin_instance_counter": { "pedersen_builtin": 16, @@ -443,16 +453,16 @@ }, "n_memory_holes": 0, "n_steps": 3382 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 } } }, "L1Handler": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { "builtin_instance_counter": { "pedersen_builtin": 11, @@ -460,14 +470,14 @@ }, "n_memory_holes": 0, "n_steps": 1069 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 } }, - "deprecated_resources": { + "resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { "builtin_instance_counter": { "pedersen_builtin": 11, @@ -475,19 +485,9 @@ }, "n_memory_holes": 0, "n_steps": 1069 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 } } } - }, - "compute_os_kzg_commitment_info": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 } }, "validate_max_n_steps": 1000000, @@ -532,13 +532,13 @@ 16, 100 ], - "range_check_builtin": [ - 8, - 100 - ], "range_check96_builtin": [ 0, 1 + ], + "range_check_builtin": [ + 8, + 100 ] } } diff --git a/crates/blockifier/resources/versioned_constants_13_1.json b/crates/blockifier/resources/versioned_constants_13_1.json index 4e28f7b711..e512c30baa 100644 --- a/crates/blockifier/resources/versioned_constants_13_1.json +++ b/crates/blockifier/resources/versioned_constants_13_1.json @@ -1,19 +1,10 @@ { - "tx_event_limits": { - "max_data_length": 300, - "max_keys_length": 50, - "max_n_emitted_events": 1000 - }, "gateway": { "max_calldata_length": 4000, "max_contract_bytecode_size": 81920 }, "invoke_tx_max_n_steps": 4000000, "l2_resource_gas_costs": { - "gas_per_data_felt": [ - 128, - 1000 - ], "event_key_factor": [ 2, 1 @@ -21,361 +12,370 @@ "gas_per_code_byte": [ 875, 1000 + ], + "gas_per_data_felt": [ + 128, + 1000 ] }, "max_recursion_depth": 50, "os_constants": { - "nop_entry_point_offset": -1, - "entry_point_type_external": 0, - "entry_point_type_l1_handler": 1, - "entry_point_type_constructor": 2, - "l1_handler_version": 0, - "sierra_array_len_bound": 4294967296, - "constructor_entry_point_selector": "0x28ffe4ff0f226a9107253e17a904099aa4f63a02a5621de0576e5aa71bc5194", - "execute_entry_point_selector": "0x15d40a3d6ca2ac30f4031e42be28da9b056fef9bb7357ac5e85627ee876e5ad", - "validate_entry_point_selector": "0x162da33a4585851fe8d3af3c2a9c60b557814e221e0d4f30ff0b2189d9c7775", - "validate_declare_entry_point_selector": "0x289da278a8dc833409cabfdad1581e8e7d40e42dcaed693fa4008dcdb4963b3", - "validate_deploy_entry_point_selector": "0x36fcbf06cd96843058359e1a75928beacfac10727dab22a3972f0af8aa92895", - "transfer_entry_point_selector": "0x83afd3f4caedc6eebf44246fe54e38c95e3179a5ec9ea81740eca5b482d12e", - "default_entry_point_selector": 0, "block_hash_contract_address": 1, - "stored_block_hash_buffer": 10, - "step_gas_cost": 100, - "range_check_gas_cost": 70, - "memory_hole_gas_cost": 10, - "initial_gas_cost": { - "step_gas_cost": 100000000 + "call_contract_gas_cost": { + "entry_point_gas_cost": 1, + "step_gas_cost": 10, + "syscall_base_gas_cost": 1 }, - "entry_point_initial_budget": { - "step_gas_cost": 100 + "constructor_entry_point_selector": "0x28ffe4ff0f226a9107253e17a904099aa4f63a02a5621de0576e5aa71bc5194", + "default_entry_point_selector": 0, + "deploy_gas_cost": { + "entry_point_gas_cost": 1, + "step_gas_cost": 200, + "syscall_base_gas_cost": 1 }, - "syscall_base_gas_cost": { - "step_gas_cost": 100 + "emit_event_gas_cost": { + "step_gas_cost": 10, + "syscall_base_gas_cost": 1 }, "entry_point_gas_cost": { "entry_point_initial_budget": 1, "step_gas_cost": 500 }, + "entry_point_initial_budget": { + "step_gas_cost": 100 + }, + "entry_point_type_constructor": 2, + "entry_point_type_external": 0, + "entry_point_type_l1_handler": 1, + "error_block_number_out_of_range": "Block number out of range", + "error_invalid_argument": "Invalid argument", + "error_invalid_input_len": "Invalid input length", + "error_out_of_gas": "Out of gas", + "execute_entry_point_selector": "0x15d40a3d6ca2ac30f4031e42be28da9b056fef9bb7357ac5e85627ee876e5ad", "fee_transfer_gas_cost": { "entry_point_gas_cost": 1, "step_gas_cost": 100 }, - "transaction_gas_cost": { - "entry_point_gas_cost": 2, - "fee_transfer_gas_cost": 1, - "step_gas_cost": 100 + "get_block_hash_gas_cost": { + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 }, - "call_contract_gas_cost": { - "syscall_base_gas_cost": 1, + "get_execution_info_gas_cost": { "step_gas_cost": 10, - "entry_point_gas_cost": 1 - }, - "deploy_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 200, - "entry_point_gas_cost": 1 + "syscall_base_gas_cost": 1 }, - "get_block_hash_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 + "initial_gas_cost": { + "step_gas_cost": 100000000 }, - "get_execution_info_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 10 + "keccak_gas_cost": { + "syscall_base_gas_cost": 1 }, + "keccak_round_cost_gas_cost": 180000, + "l1_gas": "L1_GAS", + "l1_gas_index": 0, + "l1_handler_version": 0, + "l2_gas": "L2_GAS", + "l2_gas_index": 1, "library_call_gas_cost": { "call_contract_gas_cost": 1 }, + "memory_hole_gas_cost": 10, + "nop_entry_point_offset": -1, + "range_check_gas_cost": 70, "replace_class_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 - }, - "storage_read_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 - }, - "storage_write_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 - }, - "emit_event_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 10 - }, - "send_message_to_l1_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 }, "secp256k1_add_gas_cost": { - "step_gas_cost": 406, - "range_check_gas_cost": 29 + "range_check_gas_cost": 29, + "step_gas_cost": 406 }, "secp256k1_get_point_from_x_gas_cost": { - "step_gas_cost": 391, + "memory_hole_gas_cost": 20, "range_check_gas_cost": 30, - "memory_hole_gas_cost": 20 + "step_gas_cost": 391 }, "secp256k1_get_xy_gas_cost": { - "step_gas_cost": 239, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 11, - "memory_hole_gas_cost": 40 + "step_gas_cost": 239 }, "secp256k1_mul_gas_cost": { - "step_gas_cost": 76501, + "memory_hole_gas_cost": 2, "range_check_gas_cost": 7045, - "memory_hole_gas_cost": 2 + "step_gas_cost": 76501 }, "secp256k1_new_gas_cost": { - "step_gas_cost": 475, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 35, - "memory_hole_gas_cost": 40 + "step_gas_cost": 475 }, "secp256r1_add_gas_cost": { - "step_gas_cost": 589, - "range_check_gas_cost": 57 + "range_check_gas_cost": 57, + "step_gas_cost": 589 }, "secp256r1_get_point_from_x_gas_cost": { - "step_gas_cost": 510, + "memory_hole_gas_cost": 20, "range_check_gas_cost": 44, - "memory_hole_gas_cost": 20 + "step_gas_cost": 510 }, "secp256r1_get_xy_gas_cost": { - "step_gas_cost": 241, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 11, - "memory_hole_gas_cost": 40 + "step_gas_cost": 241 }, "secp256r1_mul_gas_cost": { - "step_gas_cost": 125340, + "memory_hole_gas_cost": 2, "range_check_gas_cost": 13961, - "memory_hole_gas_cost": 2 + "step_gas_cost": 125340 }, "secp256r1_new_gas_cost": { - "step_gas_cost": 594, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 49, - "memory_hole_gas_cost": 40 + "step_gas_cost": 594 }, - "keccak_gas_cost": { + "send_message_to_l1_gas_cost": { + "step_gas_cost": 50, "syscall_base_gas_cost": 1 }, - "keccak_round_cost_gas_cost": 180000, "sha256_process_block_gas_cost": { - "step_gas_cost": 0, "range_check_gas_cost": 0, + "step_gas_cost": 0, "syscall_base_gas_cost": 0 }, - "error_block_number_out_of_range": "Block number out of range", - "error_out_of_gas": "Out of gas", - "error_invalid_input_len": "Invalid input length", - "error_invalid_argument": "Invalid argument", - "validated": "VALID", - "l1_gas": "L1_GAS", - "l2_gas": "L2_GAS", - "l1_gas_index": 0, - "l2_gas_index": 1, + "sierra_array_len_bound": 4294967296, + "step_gas_cost": 100, + "storage_read_gas_cost": { + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 + }, + "storage_write_gas_cost": { + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 + }, + "stored_block_hash_buffer": 10, + "syscall_base_gas_cost": { + "step_gas_cost": 100 + }, + "transaction_gas_cost": { + "entry_point_gas_cost": 2, + "fee_transfer_gas_cost": 1, + "step_gas_cost": 100 + }, + "transfer_entry_point_selector": "0x83afd3f4caedc6eebf44246fe54e38c95e3179a5ec9ea81740eca5b482d12e", + "validate_declare_entry_point_selector": "0x289da278a8dc833409cabfdad1581e8e7d40e42dcaed693fa4008dcdb4963b3", + "validate_deploy_entry_point_selector": "0x36fcbf06cd96843058359e1a75928beacfac10727dab22a3972f0af8aa92895", + "validate_entry_point_selector": "0x162da33a4585851fe8d3af3c2a9c60b557814e221e0d4f30ff0b2189d9c7775", "validate_rounding_consts": { "validate_block_number_rounding": 100, "validate_timestamp_rounding": 3600 - } + }, + "validated": "VALID" }, "os_resources": { + "compute_os_kzg_commitment_info": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "execute_syscalls": { "CallContract": { - "n_steps": 760, "builtin_instance_counter": { "range_check_builtin": 20 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 760 }, "DelegateCall": { - "n_steps": 713, "builtin_instance_counter": { "range_check_builtin": 19 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 713 }, "DelegateL1Handler": { - "n_steps": 692, "builtin_instance_counter": { "range_check_builtin": 15 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 692 }, "Deploy": { - "n_steps": 1012, "builtin_instance_counter": { "pedersen_builtin": 7, "range_check_builtin": 19 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 1012 }, "EmitEvent": { - "n_steps": 61, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 61 }, "GetBlockHash": { - "n_steps": 104, "builtin_instance_counter": { "range_check_builtin": 2 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 104 }, "GetBlockNumber": { - "n_steps": 40, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 40 }, "GetBlockTimestamp": { - "n_steps": 38, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 38 }, "GetCallerAddress": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetContractAddress": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetExecutionInfo": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetSequencerAddress": { - "n_steps": 34, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 34 }, "GetTxInfo": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetTxSignature": { - "n_steps": 44, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 44 }, "Keccak": { - "n_steps": 381, "builtin_instance_counter": { "bitwise_builtin": 6, "keccak_builtin": 1, "range_check_builtin": 56 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 381 }, "LibraryCall": { - "n_steps": 751, "builtin_instance_counter": { "range_check_builtin": 20 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 751 }, "LibraryCallL1Handler": { - "n_steps": 659, "builtin_instance_counter": { "range_check_builtin": 15 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 659 }, "ReplaceClass": { - "n_steps": 98, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 98 }, "Secp256k1Add": { - "n_steps": 408, "builtin_instance_counter": { "range_check_builtin": 29 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 408 }, "Secp256k1GetPointFromX": { - "n_steps": 393, "builtin_instance_counter": { "range_check_builtin": 30 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 393 }, "Secp256k1GetXy": { - "n_steps": 205, "builtin_instance_counter": { "range_check_builtin": 11 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 205 }, "Secp256k1Mul": { - "n_steps": 76503, "builtin_instance_counter": { "range_check_builtin": 7045 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 76503 }, "Secp256k1New": { - "n_steps": 459, "builtin_instance_counter": { "range_check_builtin": 35 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 459 }, "Secp256r1Add": { - "n_steps": 591, "builtin_instance_counter": { "range_check_builtin": 57 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 591 }, "Secp256r1GetPointFromX": { - "n_steps": 512, "builtin_instance_counter": { "range_check_builtin": 44 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 512 }, "Secp256r1GetXy": { - "n_steps": 207, "builtin_instance_counter": { "range_check_builtin": 11 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 207 }, "Secp256r1Mul": { - "n_steps": 125342, "builtin_instance_counter": { "range_check_builtin": 13961 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 125342 }, "Secp256r1New": { - "n_steps": 578, "builtin_instance_counter": { "range_check_builtin": 49 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 578 }, "SendMessageToL1": { - "n_steps": 139, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 139 }, "Sha256ProcessBlock": { "builtin_instance_counter": {}, @@ -383,168 +383,168 @@ "n_steps": 0 }, "StorageRead": { - "n_steps": 87, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 87 }, "StorageWrite": { - "n_steps": 89, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 89 } }, "execute_txs_inner": { "Declare": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { - "n_steps": 2839, "builtin_instance_counter": { "pedersen_builtin": 16, "range_check_builtin": 63 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 2839 } }, - "deprecated_resources": { + "resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { - "n_steps": 2839, "builtin_instance_counter": { "pedersen_builtin": 16, "range_check_builtin": 63 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 2839 } } }, "DeployAccount": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": { + "pedersen_builtin": 2 + }, + "n_memory_holes": 0, + "n_steps": 21 + }, "constant": { - "n_steps": 3792, "builtin_instance_counter": { "pedersen_builtin": 23, "range_check_builtin": 83 }, - "n_memory_holes": 0 - }, + "n_memory_holes": 0, + "n_steps": 3792 + } + }, + "resources": { "calldata_factor": { - "n_steps": 21, "builtin_instance_counter": { "pedersen_builtin": 2 }, - "n_memory_holes": 0 - } - }, - "deprecated_resources": { + "n_memory_holes": 0, + "n_steps": 21 + }, "constant": { - "n_steps": 3792, "builtin_instance_counter": { "pedersen_builtin": 23, "range_check_builtin": 83 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 21, - "builtin_instance_counter": { - "pedersen_builtin": 2 - }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 3792 } } }, "InvokeFunction": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": { + "pedersen_builtin": 1 + }, + "n_memory_holes": 0, + "n_steps": 8 + }, "constant": { - "n_steps": 3546, "builtin_instance_counter": { "pedersen_builtin": 14, "range_check_builtin": 80 }, - "n_memory_holes": 0 - }, + "n_memory_holes": 0, + "n_steps": 3546 + } + }, + "resources": { "calldata_factor": { - "n_steps": 8, "builtin_instance_counter": { "pedersen_builtin": 1 }, - "n_memory_holes": 0 - } - }, - "deprecated_resources": { + "n_memory_holes": 0, + "n_steps": 8 + }, "constant": { - "n_steps": 3546, "builtin_instance_counter": { "pedersen_builtin": 14, "range_check_builtin": 80 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 8, - "builtin_instance_counter": { - "pedersen_builtin": 1 - }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 3546 } } }, "L1Handler": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": { + "pedersen_builtin": 1 + }, + "n_memory_holes": 0, + "n_steps": 13 + }, "constant": { - "n_steps": 1146, "builtin_instance_counter": { "pedersen_builtin": 11, "range_check_builtin": 17 }, - "n_memory_holes": 0 - }, + "n_memory_holes": 0, + "n_steps": 1146 + } + }, + "resources": { "calldata_factor": { - "n_steps": 13, "builtin_instance_counter": { "pedersen_builtin": 1 }, - "n_memory_holes": 0 - } - }, - "deprecated_resources": { + "n_memory_holes": 0, + "n_steps": 13 + }, "constant": { - "n_steps": 1146, "builtin_instance_counter": { "pedersen_builtin": 11, "range_check_builtin": 17 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 13, - "builtin_instance_counter": { - "pedersen_builtin": 1 - }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 1146 } } } - }, - "compute_os_kzg_commitment_info": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 } }, + "tx_event_limits": { + "max_data_length": 300, + "max_keys_length": 50, + "max_n_emitted_events": 1000 + }, "validate_max_n_steps": 1000000, "vm_resource_fee_cost": { "add_mod_builtin": [ @@ -587,13 +587,13 @@ 8, 100 ], - "range_check_builtin": [ - 4, - 100 - ], "range_check96_builtin": [ 0, 1 + ], + "range_check_builtin": [ + 4, + 100 ] } } diff --git a/crates/blockifier/resources/versioned_constants_13_1_1.json b/crates/blockifier/resources/versioned_constants_13_1_1.json index 791dac8b9b..1a3ebdcf20 100644 --- a/crates/blockifier/resources/versioned_constants_13_1_1.json +++ b/crates/blockifier/resources/versioned_constants_13_1_1.json @@ -1,19 +1,10 @@ { - "tx_event_limits": { - "max_data_length": 300, - "max_keys_length": 50, - "max_n_emitted_events": 1000 - }, "gateway": { "max_calldata_length": 5000, "max_contract_bytecode_size": 81920 }, "invoke_tx_max_n_steps": 4000000, "l2_resource_gas_costs": { - "gas_per_data_felt": [ - 128, - 1000 - ], "event_key_factor": [ 2, 1 @@ -21,361 +12,370 @@ "gas_per_code_byte": [ 32, 1000 + ], + "gas_per_data_felt": [ + 128, + 1000 ] }, "max_recursion_depth": 50, "os_constants": { - "nop_entry_point_offset": -1, - "entry_point_type_external": 0, - "entry_point_type_l1_handler": 1, - "entry_point_type_constructor": 2, - "l1_handler_version": 0, - "sierra_array_len_bound": 4294967296, - "constructor_entry_point_selector": "0x28ffe4ff0f226a9107253e17a904099aa4f63a02a5621de0576e5aa71bc5194", - "execute_entry_point_selector": "0x15d40a3d6ca2ac30f4031e42be28da9b056fef9bb7357ac5e85627ee876e5ad", - "validate_entry_point_selector": "0x162da33a4585851fe8d3af3c2a9c60b557814e221e0d4f30ff0b2189d9c7775", - "validate_declare_entry_point_selector": "0x289da278a8dc833409cabfdad1581e8e7d40e42dcaed693fa4008dcdb4963b3", - "validate_deploy_entry_point_selector": "0x36fcbf06cd96843058359e1a75928beacfac10727dab22a3972f0af8aa92895", - "transfer_entry_point_selector": "0x83afd3f4caedc6eebf44246fe54e38c95e3179a5ec9ea81740eca5b482d12e", - "default_entry_point_selector": 0, "block_hash_contract_address": 1, - "stored_block_hash_buffer": 10, - "step_gas_cost": 100, - "range_check_gas_cost": 70, - "memory_hole_gas_cost": 10, - "initial_gas_cost": { - "step_gas_cost": 100000000 + "call_contract_gas_cost": { + "entry_point_gas_cost": 1, + "step_gas_cost": 10, + "syscall_base_gas_cost": 1 }, - "entry_point_initial_budget": { - "step_gas_cost": 100 + "constructor_entry_point_selector": "0x28ffe4ff0f226a9107253e17a904099aa4f63a02a5621de0576e5aa71bc5194", + "default_entry_point_selector": 0, + "deploy_gas_cost": { + "entry_point_gas_cost": 1, + "step_gas_cost": 200, + "syscall_base_gas_cost": 1 }, - "syscall_base_gas_cost": { - "step_gas_cost": 100 + "emit_event_gas_cost": { + "step_gas_cost": 10, + "syscall_base_gas_cost": 1 }, "entry_point_gas_cost": { "entry_point_initial_budget": 1, "step_gas_cost": 500 }, + "entry_point_initial_budget": { + "step_gas_cost": 100 + }, + "entry_point_type_constructor": 2, + "entry_point_type_external": 0, + "entry_point_type_l1_handler": 1, + "error_block_number_out_of_range": "Block number out of range", + "error_invalid_argument": "Invalid argument", + "error_invalid_input_len": "Invalid input length", + "error_out_of_gas": "Out of gas", + "execute_entry_point_selector": "0x15d40a3d6ca2ac30f4031e42be28da9b056fef9bb7357ac5e85627ee876e5ad", "fee_transfer_gas_cost": { "entry_point_gas_cost": 1, "step_gas_cost": 100 }, - "transaction_gas_cost": { - "entry_point_gas_cost": 2, - "fee_transfer_gas_cost": 1, - "step_gas_cost": 100 + "get_block_hash_gas_cost": { + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 }, - "call_contract_gas_cost": { - "syscall_base_gas_cost": 1, + "get_execution_info_gas_cost": { "step_gas_cost": 10, - "entry_point_gas_cost": 1 - }, - "deploy_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 200, - "entry_point_gas_cost": 1 + "syscall_base_gas_cost": 1 }, - "get_block_hash_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 + "initial_gas_cost": { + "step_gas_cost": 100000000 }, - "get_execution_info_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 10 + "keccak_gas_cost": { + "syscall_base_gas_cost": 1 }, + "keccak_round_cost_gas_cost": 180000, + "l1_gas": "L1_GAS", + "l1_gas_index": 0, + "l1_handler_version": 0, + "l2_gas": "L2_GAS", + "l2_gas_index": 1, "library_call_gas_cost": { "call_contract_gas_cost": 1 }, + "memory_hole_gas_cost": 10, + "nop_entry_point_offset": -1, + "range_check_gas_cost": 70, "replace_class_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 - }, - "storage_read_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 - }, - "storage_write_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 - }, - "emit_event_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 10 - }, - "send_message_to_l1_gas_cost": { - "syscall_base_gas_cost": 1, - "step_gas_cost": 50 + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 }, "secp256k1_add_gas_cost": { - "step_gas_cost": 406, - "range_check_gas_cost": 29 + "range_check_gas_cost": 29, + "step_gas_cost": 406 }, "secp256k1_get_point_from_x_gas_cost": { - "step_gas_cost": 391, + "memory_hole_gas_cost": 20, "range_check_gas_cost": 30, - "memory_hole_gas_cost": 20 + "step_gas_cost": 391 }, "secp256k1_get_xy_gas_cost": { - "step_gas_cost": 239, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 11, - "memory_hole_gas_cost": 40 + "step_gas_cost": 239 }, "secp256k1_mul_gas_cost": { - "step_gas_cost": 76501, + "memory_hole_gas_cost": 2, "range_check_gas_cost": 7045, - "memory_hole_gas_cost": 2 + "step_gas_cost": 76501 }, "secp256k1_new_gas_cost": { - "step_gas_cost": 475, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 35, - "memory_hole_gas_cost": 40 + "step_gas_cost": 475 }, "secp256r1_add_gas_cost": { - "step_gas_cost": 589, - "range_check_gas_cost": 57 + "range_check_gas_cost": 57, + "step_gas_cost": 589 }, "secp256r1_get_point_from_x_gas_cost": { - "step_gas_cost": 510, + "memory_hole_gas_cost": 20, "range_check_gas_cost": 44, - "memory_hole_gas_cost": 20 + "step_gas_cost": 510 }, "secp256r1_get_xy_gas_cost": { - "step_gas_cost": 241, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 11, - "memory_hole_gas_cost": 40 + "step_gas_cost": 241 }, "secp256r1_mul_gas_cost": { - "step_gas_cost": 125340, + "memory_hole_gas_cost": 2, "range_check_gas_cost": 13961, - "memory_hole_gas_cost": 2 + "step_gas_cost": 125340 }, "secp256r1_new_gas_cost": { - "step_gas_cost": 594, + "memory_hole_gas_cost": 40, "range_check_gas_cost": 49, - "memory_hole_gas_cost": 40 + "step_gas_cost": 594 }, - "keccak_gas_cost": { + "send_message_to_l1_gas_cost": { + "step_gas_cost": 50, "syscall_base_gas_cost": 1 }, - "keccak_round_cost_gas_cost": 180000, "sha256_process_block_gas_cost": { - "step_gas_cost": 0, "range_check_gas_cost": 0, + "step_gas_cost": 0, "syscall_base_gas_cost": 0 }, - "error_block_number_out_of_range": "Block number out of range", - "error_out_of_gas": "Out of gas", - "error_invalid_input_len": "Invalid input length", - "error_invalid_argument": "Invalid argument", - "validated": "VALID", - "l1_gas": "L1_GAS", - "l2_gas": "L2_GAS", - "l1_gas_index": 0, - "l2_gas_index": 1, + "sierra_array_len_bound": 4294967296, + "step_gas_cost": 100, + "storage_read_gas_cost": { + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 + }, + "storage_write_gas_cost": { + "step_gas_cost": 50, + "syscall_base_gas_cost": 1 + }, + "stored_block_hash_buffer": 10, + "syscall_base_gas_cost": { + "step_gas_cost": 100 + }, + "transaction_gas_cost": { + "entry_point_gas_cost": 2, + "fee_transfer_gas_cost": 1, + "step_gas_cost": 100 + }, + "transfer_entry_point_selector": "0x83afd3f4caedc6eebf44246fe54e38c95e3179a5ec9ea81740eca5b482d12e", + "validate_declare_entry_point_selector": "0x289da278a8dc833409cabfdad1581e8e7d40e42dcaed693fa4008dcdb4963b3", + "validate_deploy_entry_point_selector": "0x36fcbf06cd96843058359e1a75928beacfac10727dab22a3972f0af8aa92895", + "validate_entry_point_selector": "0x162da33a4585851fe8d3af3c2a9c60b557814e221e0d4f30ff0b2189d9c7775", "validate_rounding_consts": { "validate_block_number_rounding": 100, "validate_timestamp_rounding": 3600 - } + }, + "validated": "VALID" }, "os_resources": { + "compute_os_kzg_commitment_info": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "execute_syscalls": { "CallContract": { - "n_steps": 760, "builtin_instance_counter": { "range_check_builtin": 20 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 760 }, "DelegateCall": { - "n_steps": 713, "builtin_instance_counter": { "range_check_builtin": 19 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 713 }, "DelegateL1Handler": { - "n_steps": 692, "builtin_instance_counter": { "range_check_builtin": 15 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 692 }, "Deploy": { - "n_steps": 1012, "builtin_instance_counter": { "pedersen_builtin": 7, "range_check_builtin": 19 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 1012 }, "EmitEvent": { - "n_steps": 61, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 61 }, "GetBlockHash": { - "n_steps": 104, "builtin_instance_counter": { "range_check_builtin": 2 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 104 }, "GetBlockNumber": { - "n_steps": 40, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 40 }, "GetBlockTimestamp": { - "n_steps": 38, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 38 }, "GetCallerAddress": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetContractAddress": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetExecutionInfo": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetSequencerAddress": { - "n_steps": 34, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 34 }, "GetTxInfo": { - "n_steps": 64, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 64 }, "GetTxSignature": { - "n_steps": 44, "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 44 }, "Keccak": { - "n_steps": 381, "builtin_instance_counter": { "bitwise_builtin": 6, "keccak_builtin": 1, "range_check_builtin": 56 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 381 }, "LibraryCall": { - "n_steps": 751, "builtin_instance_counter": { "range_check_builtin": 20 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 751 }, "LibraryCallL1Handler": { - "n_steps": 659, "builtin_instance_counter": { "range_check_builtin": 15 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 659 }, "ReplaceClass": { - "n_steps": 98, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 98 }, "Secp256k1Add": { - "n_steps": 408, "builtin_instance_counter": { "range_check_builtin": 29 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 408 }, "Secp256k1GetPointFromX": { - "n_steps": 393, "builtin_instance_counter": { "range_check_builtin": 30 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 393 }, "Secp256k1GetXy": { - "n_steps": 205, "builtin_instance_counter": { "range_check_builtin": 11 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 205 }, "Secp256k1Mul": { - "n_steps": 76503, "builtin_instance_counter": { "range_check_builtin": 7045 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 76503 }, "Secp256k1New": { - "n_steps": 459, "builtin_instance_counter": { "range_check_builtin": 35 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 459 }, "Secp256r1Add": { - "n_steps": 591, "builtin_instance_counter": { "range_check_builtin": 57 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 591 }, "Secp256r1GetPointFromX": { - "n_steps": 512, "builtin_instance_counter": { "range_check_builtin": 44 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 512 }, "Secp256r1GetXy": { - "n_steps": 207, "builtin_instance_counter": { "range_check_builtin": 11 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 207 }, "Secp256r1Mul": { - "n_steps": 125342, "builtin_instance_counter": { "range_check_builtin": 13961 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 125342 }, "Secp256r1New": { - "n_steps": 578, "builtin_instance_counter": { "range_check_builtin": 49 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 578 }, "SendMessageToL1": { - "n_steps": 139, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 139 }, "Sha256ProcessBlock": { "builtin_instance_counter": {}, @@ -383,168 +383,168 @@ "n_steps": 0 }, "StorageRead": { - "n_steps": 87, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 87 }, "StorageWrite": { - "n_steps": 89, "builtin_instance_counter": { "range_check_builtin": 1 }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 89 } }, "execute_txs_inner": { "Declare": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { - "n_steps": 2839, "builtin_instance_counter": { "pedersen_builtin": 16, "range_check_builtin": 63 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 2839 } }, - "deprecated_resources": { + "resources": { + "calldata_factor": { + "builtin_instance_counter": {}, + "n_memory_holes": 0, + "n_steps": 0 + }, "constant": { - "n_steps": 2839, "builtin_instance_counter": { "pedersen_builtin": 16, "range_check_builtin": 63 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 2839 } } }, "DeployAccount": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": { + "pedersen_builtin": 2 + }, + "n_memory_holes": 0, + "n_steps": 21 + }, "constant": { - "n_steps": 3792, "builtin_instance_counter": { "pedersen_builtin": 23, "range_check_builtin": 83 }, - "n_memory_holes": 0 - }, + "n_memory_holes": 0, + "n_steps": 3792 + } + }, + "resources": { "calldata_factor": { - "n_steps": 21, "builtin_instance_counter": { "pedersen_builtin": 2 }, - "n_memory_holes": 0 - } - }, - "deprecated_resources": { + "n_memory_holes": 0, + "n_steps": 21 + }, "constant": { - "n_steps": 3792, "builtin_instance_counter": { "pedersen_builtin": 23, "range_check_builtin": 83 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 21, - "builtin_instance_counter": { - "pedersen_builtin": 2 - }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 3792 } } }, "InvokeFunction": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": { + "pedersen_builtin": 1 + }, + "n_memory_holes": 0, + "n_steps": 8 + }, "constant": { - "n_steps": 3546, "builtin_instance_counter": { "pedersen_builtin": 14, "range_check_builtin": 80 }, - "n_memory_holes": 0 - }, + "n_memory_holes": 0, + "n_steps": 3546 + } + }, + "resources": { "calldata_factor": { - "n_steps": 8, "builtin_instance_counter": { "pedersen_builtin": 1 }, - "n_memory_holes": 0 - } - }, - "deprecated_resources": { + "n_memory_holes": 0, + "n_steps": 8 + }, "constant": { - "n_steps": 3546, "builtin_instance_counter": { "pedersen_builtin": 14, "range_check_builtin": 80 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 8, - "builtin_instance_counter": { - "pedersen_builtin": 1 - }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 3546 } } }, "L1Handler": { - "resources": { + "deprecated_resources": { + "calldata_factor": { + "builtin_instance_counter": { + "pedersen_builtin": 1 + }, + "n_memory_holes": 0, + "n_steps": 13 + }, "constant": { - "n_steps": 1146, "builtin_instance_counter": { "pedersen_builtin": 11, "range_check_builtin": 17 }, - "n_memory_holes": 0 - }, + "n_memory_holes": 0, + "n_steps": 1146 + } + }, + "resources": { "calldata_factor": { - "n_steps": 13, "builtin_instance_counter": { "pedersen_builtin": 1 }, - "n_memory_holes": 0 - } - }, - "deprecated_resources": { + "n_memory_holes": 0, + "n_steps": 13 + }, "constant": { - "n_steps": 1146, "builtin_instance_counter": { "pedersen_builtin": 11, "range_check_builtin": 17 }, - "n_memory_holes": 0 - }, - "calldata_factor": { - "n_steps": 13, - "builtin_instance_counter": { - "pedersen_builtin": 1 - }, - "n_memory_holes": 0 + "n_memory_holes": 0, + "n_steps": 1146 } } } - }, - "compute_os_kzg_commitment_info": { - "n_steps": 0, - "builtin_instance_counter": {}, - "n_memory_holes": 0 } }, + "tx_event_limits": { + "max_data_length": 300, + "max_keys_length": 50, + "max_n_emitted_events": 1000 + }, "validate_max_n_steps": 1000000, "vm_resource_fee_cost": { "add_mod_builtin": [ @@ -587,13 +587,13 @@ 8, 100 ], - "range_check_builtin": [ - 4, - 100 - ], "range_check96_builtin": [ 0, 1 + ], + "range_check_builtin": [ + 4, + 100 ] } }