You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Every gas counter in evmone is int64_t, but all per-transaction gas quantities fit in 32 bits.
EIP-7825 caps a transaction's gas limit at TX_MAX_GAS_LIMIT = 2^24 (MAX_TX_GAS_LIMIT, test/state/transaction.hpp), and block gas limits are far below 2^32. A pending EIP-8037 change would additionally cap tx.gas itself at 2^32-1, so the whole two-dimensional budget stays inside an unsigned 32-bit integer.
Candidates:
gas_left threaded through the interpreter and Result / TermResult
StateGas::left and StateGas::spilled (lib/evmone/state_gas.hpp)
The interpreter relies on gas going negative ((gas_left -= cost) < 0). An unsigned counter needs a borrow-based check instead, e.g. __builtin_usub_overflow.
The evmc_* fields are public ABI, so changing them is a breaking change.
Activity
Drop the two leftover review markers