Skip to main content

Module bench

Module bench 

Source

Structs§

BenchmarkEntry
A single benchmark result.

Constants§

MAINNET_BLOCK_GAS_LIMIT
MAINNET_CONTRACT_MAX_SIZE
MAINNET_GAS_PER_BYTE
MAINNET_GAS_PRICE_FACTOR
MAINNET_MAX_GAS_PER_PREDICATE
MAINNET_MAX_GAS_PER_TX
MAINNET_MAX_MESSAGE_DATA_LENGTH
MAINNET_MAX_PREDICATE_DATA_LENGTH
MAINNET_MAX_PREDICATE_LENGTH
MAINNET_MAX_STORAGE_SLOTS
MAINNET_MAX_TX_SIZE

Functions§

apply_mainnet_consensus_params
Applies Fuel mainnet (Ignition v7) consensus parameters to chain_config in-place. Call this inside setup_wallets_mainnet before launching the provider so benchmarks reflect real on-chain constraints.
bench_filter
Regex for filtering benchmarks to execute. Configured via environment variable BENCH_FILTER.
bench_is_list_only
True if benchmarks should only be listed and not executed. Configured via environment variable BENCH_LIST_ONLY: BENCH_LIST_ONLY=1
extract_gas_used
Returns the total gas consumed by a contract call response.
write_bench_results
Writes benchmark results to the JSON output files specified by the BENCH_OUTPUT_GAS and BENCH_OUTPUT_MATCHES environment variables (defaulting to benchmark-results-{gas|matches}.json in the current directory).