| id | TIP-1010 |
|---|---|
| title | Mainnet Gas Parameters |
| description | Initial gas parameters for Tempo mainnet launch including base fee pricing, payment lane capacity, and transaction gas limits. |
| authors | Dankrad Feist @dankrad |
| status | Mainnet |
| related | TIP-1000, Payment Lane Specification, Sub block Specification |
| protocolVersion | T1 |
This TIP specifies the initial gas parameters for Tempo mainnet, including base fee pricing, payment lane capacity, and main transaction gas limits. These parameters are calibrated to support Tempo's target of approximately 20,000 TPS for payment transactions while maintaining economically sustainable fee levels.
Tempo is designed as a high-throughput blockchain optimized for stablecoin payments. To achieve this, the gas parameters must be carefully calibrated to:
- Enable high throughput: Support ~20,000 TPS for payment transactions
- Maintain low fees: Target 0.1 cent per standard TIP-20 transfer
- Prevent spam: Ensure fees are high enough to deter abuse
- Balance capacity: Allocate appropriate gas limits between payment lane and general transactions
The parameters defined in this TIP represent the initial mainnet configuration and may be adjusted through future governance processes.
Value: 2 × 10^10 attodollars (20 billion attodollars per gas)
Rationale:
- A standard TIP-20 transfer costs approximately 50,000 gas
- At this basefee: 50,000 gas × 20 billion attodollars/gas = 10^15 attodollars = 1,000 microdollars = $0.001
- This targets approximately 0.1 cent (1,000 microdollars) per TIP-20 transfer
Note on units: Attodollars (10^-18 USD) are the gas price unit. TIP-20 tokens use 6 decimals, so 1 token unit = 1 microdollar (10^-6 USD). Conversion: attodollars / 10^12 = microdollars.
Note: The base fee is fixed per protocol version and does not adjust dynamically based on block utilization. Unlike EIP-1559, there is no in-protocol mechanism that raises or lowers the base fee in response to congestion. Changes to the base fee require a hardfork upgrade.
Value: 500,000,000 gas per block (total block gas limit)
Rationale:
- At 50,000 gas per TIP-20 transfer:
500,000,000 / 50,000 = 10,000 transfers per block - With 500ms block time:
10,000 × 2 = 20,000 TPSfor payment transactions - This capacity supports Tempo's target throughput for payment use cases
Gas Budget Breakdown:
- Total block gas limit: 500,000,000 gas
- Shared gas limit (validator subblocks): 50,000,000 gas (
block_gas_limit / 10) - Non-shared gas limit (proposer pool): 450,000,000 gas (
block_gas_limit - shared_gas_limit) - General gas limit (non-payment cap): 30,000,000 gas (see below)
:::info
Shared capacity model: The payment lane is non-dedicated. General and payment transactions selected by the proposer share the non-shared gas budget (450M). General transactions are capped at general_gas_limit (30M), guaranteeing that at least 420M gas remains available for proposer payment transactions. The remaining 50M (shared_gas_limit) is reserved for validator subblocks as defined in the Sub-block Specification.
:::
Constraints:
- Only transactions qualifying for the payment lane (simple TIP-20 transfers, memos, etc.) may exceed the
general_gas_limit - Complex contract interactions use the general gas limit instead
Value: 30,000,000 gas per block (general_gas_limit)
Rationale:
- Aligned with the transaction gas cap to ensure maximum-sized contract deployments can be included in a block
- Supports general smart contract interactions beyond simple payments
- Provides capacity for:
- Contract deployments (including max 24KB contracts)
- DEX swaps
- Complex multi-step transactions
- Other non-payment use cases
:::warning Transactions exceeding 16,000,000 gas are not recommended. The elevated gas limits (30M) exist solely to accommodate maximum-sized contract deployments under TIP-1000 state creation costs. Applications should not rely on transactions consuming more than 16M gas for normal operations. When storage pricing is moved to a separate mechanism (e.g., storage rent or state expiry), the transaction gas cap is expected to return to 16,000,000 gas. :::
Value: 30,000,000 gas per transaction
Rationale:
- Increased from the previous 16,000,000 gas limit
- Accommodates deployment of maximum-size contracts (24,576 bytes per EIP-170) under TIP-1000 state creation costs:
- Base transaction cost: 21,000 gas
- Calldata for initcode (up to 49,152 bytes per EIP-3860): ~500,000-800,000 gas
- CREATE base cost (TIP-1000, fixed upfront contract creation cost): 500,000 gas (replaces old 32,000)
- Initcode execution: variable (~3,000 gas minimum)
- Contract code storage (TIP-1000):
24,576 bytes × 1,000 gas/byte = 24,576,000 gas - Total: ~25,600,000-25,900,000 gas (fits within 30M limit)
| Parameter | Value | Purpose |
|---|---|---|
| Base fee | 2 × 10^10 attodollars |
Target 0.1 cent (1,000 microdollars) per TIP-20 transfer |
| Total block gas limit | 500,000,000 gas/block | Total block capacity |
| Non-shared gas limit | 450,000,000 gas/block | Proposer pool transactions |
| Shared gas limit | 50,000,000 gas/block | Validator subblocks (see Sub-block Specification) |
| General gas limit | 30,000,000 gas/block | Cap for non-payment transactions |
| Transaction gas cap | 30,000,000 gas | Allow max-size contract deployment |
At full payment lane utilization:
- 10,000 transfers per block × 1,000 microdollars = 10,000,000 microdollars ($10) per block
- At 2 blocks/second: $20/second
- Daily: ~$1,728,000 in base fees from payment lane alone
| Operation | Gas Cost | USD Cost (at target base fee) |
|---|---|---|
| TIP-20 transfer (existing recipient) | 50,000 | $0.001 (0.1 cent / 1,000 microdollars) |
| TIP-20 transfer (new recipient) | 300,000 | $0.006 (0.6 cent / 6,000 microdollars) |
| First transaction from new account | 300,000 | $0.006 (0.6 cent / 6,000 microdollars) |
| Small contract deployment (1KB) | ~1,800,000 | $0.036 (3.6 cents / 36,000 microdollars) |
| Max contract deployment (24,576 bytes) | ~25,900,000 | $0.518 (~52 cents / 518,000 microdollars) |
-
Base Fee Invariant: The base fee is fixed at
2 × 10^10attodollars per protocol version and can only be changed via a hardfork upgrade. At the current base fee, a TIP-20 transfer (50,000 gas) MUST cost approximately 0.1 cent (1,000 microdollars). -
Payment Lane Priority: Transactions qualifying for the payment lane MUST be able to consume up to the remaining block gas capacity (total gas limit minus gas already consumed by general transactions).
-
Shared Gas Pool: Proposer pool transactions (payment and general) share the non-shared gas budget (450M). General transactions are additionally constrained by
general_gas_limit(30M). The remaining 50M is reserved for validator subblocks. -
Transaction Gas Cap: No single transaction MUST be allowed to consume more than the transaction gas cap (30,000,000 gas).
-
Block Gas Validity: A block MUST be invalid if any of the following hold:
- Total gas used by proposer pool transactions (payment + general) exceeds the non-shared gas limit (450M)
- Total gas used by non-payment (general) transactions exceeds the general gas limit (30M)
- Total gas used by validator subblock transactions exceeds the shared gas limit (50M)
These parameters are configured at the chainspec level and applied during block validation. Future adjustments may be made through:
- Hard fork upgrades (for significant changes)
- Governance proposals (if on-chain governance is implemented)
- Emergency response procedures (for critical security issues)
- Base fee targeting: Verify that at equilibrium, TIP-20 transfers cost approximately 0.1 cent (1,000 microdollars)
- Payment lane capacity: Verify that 10,000 TIP-20 transfers can be included in a single block
- General gas limit: Verify that general transactions are correctly bounded by the 30M gas limit
- Transaction gas cap: Verify that transactions exceeding 30M gas are rejected
- Contract deployment: Verify that a 24KB contract can be deployed within the transaction gas cap
- Lane separation: Verify that payment lane and general transactions are independently tracked