Module move_core_types::gas_schedule [−][src]
Expand description
This module lays out the basic abstract costing schedule for bytecode instructions.
It is important to note that the cost schedule defined in this file does not track hashing operations or other native operations; the cost of each native operation will be returned by the native function itself.
Structs
AbstractMemorySize | A newtype wrapper that represents the (abstract) memory size that the instruction will take up. |
CostTable | The cost tables, keyed by the serialized form of the bytecode instruction. We use the serialized form as opposed to the instruction enum itself as the key since this will be the on-chain representation of bytecode instructions in the future. |
GasConstants | |
GasCost | The |
GasPrice | A newtype wrapper around the gas price for each unit of gas consumed. |
GasUnits | Units of gas as seen by clients of the Move VM. |
InternalGasUnits | Units of gas used within the Move VM, scaled for fine-grained accounting. |
Constants
CONST_SIZE | The size in bytes for a non-string or address constant on the stack |
DEFAULT_ACCOUNT_SIZE | For V1 all accounts will be ~800 bytes |
LARGE_TRANSACTION_CUTOFF | Any transaction over this size will be charged |
MAX_ABSTRACT_MEMORY_SIZE | The maximum size representable by AbstractMemorySize |
MAX_TRANSACTION_SIZE_IN_BYTES | |
MIN_EXISTS_DATA_SIZE | For exists checks on data that doesn’t exists this is the multiplier that is used. |
ONE_GAS_UNIT | One unit of gas |
REFERENCE_SIZE | The size in bytes for a reference on the stack |
STRUCT_SIZE | The size of a struct in bytes |
Traits
GasAlgebra | A trait encoding the operations permitted on the underlying carrier for the gas unit, and how other gas-related units can interact with other units – operations can only be performed across units with the same underlying carrier (i.e. as long as the underlying data is the same). |
Type Definitions
GasCarrier | The underlying carrier for gas-related units and costs. Data with this type should not be
manipulated directly, but instead be manipulated using the newtype wrappers defined around
them and the functions defined in the |