Introduction

Hi, I'm cardene, a software engineer and technical writer focused on blockchain and AI.

I've also authored Japanese technical books on specification-driven development with LLMs and decentralized application (DApp) development.

I also build and publish a variety of tools, libraries, and open-source projects.

ACP-176 proposes dynamic gas pricing for Avalanche EVM chains, including C-Chain and Subnet-EVM. It allows block proposers to adjust the target gas consumption rate, aiming to reduce abrupt fee increases and accommodate changing network capacity.

This article explains the proposal, with additional context and examples.

My other articles cover EIPs, BIPs, SLIPs, CAIPs, ENSIPs, RFCs, and ACPs.

Overview

ACP-176 proposes a mechanism similar to the dynamic fees introduced for Avalanche's P-Chain in ACP-103. Its distinctive addition is that block proposers can gradually adjust the target gas consumption rate.

For more background on ACP-103, see:

ACP-103: Dynamic fees on Avalanche's P-Chain

Rather than permanently fixing the target gas rate, the mechanism lets validators influence it according to network capacity and demand. This provides a more flexible basis for fee adjustment and scaling.

The expected benefits include:

  • Reducing the impact of large blocks. Individual large blocks should be less likely to cause disproportionate fee increases.
  • Flexible capacity adjustment. Validators can influence the gas target, allowing capacity to adapt to network resources and future transaction demand.

These changes aim to support sustainable growth of C-Chain and Subnet-EVM networks.

Motivation

The previous C-Chain mechanism used a static gas target and a modified EIP-1559 fee adjustment model. References to the existing mechanism in this article describe the proposal's historical baseline, not necessarily the network configuration today.

For background on EIP-1559, see:

EIP-1559: Ethereum's gas pricing mechanism

The previous gas target was 15 million gas over a rolling ten-second window. Base fees were adjusted using gas consumption over that window.

The proposal identifies two limitations.

Fee spikes caused by large blocks

Under the rolling-window mechanism, a block that consumes its entire gas allowance continues to contribute to the window for subsequent blocks. Fees may therefore continue rising even when those later blocks are small, potentially causing unexpected costs for users.

Inflexibility of a static gas target

Changing the fixed target requires a network upgrade. Improvements in hardware or client efficiency cannot immediately translate into a higher gas target, slowing capacity adjustment.

Specification

Dynamic fees on C-Chain

Previously, C-Chain used a fixed target of 1,500,000 gas per second and a modified EIP-1559 fee mechanism. ACP-176 builds on the ACP-103 mechanism to address fee spikes and inflexible targets.

Fees are determined using a target gas consumption rate per second, TT. Sustained gas consumption above the target increases prices, while consumption below it reduces prices. Unlike the original P-Chain model, C-Chain proposers can gradually adjust TT.

Relationship between qq and TT

The target is defined as:

T=P⋅eqDT = P \cdot e^{\frac{q}{D}}

Here, PP is the minimum target, qq is an integer that can change with each block, and DD determines the rate of change. Validators configure their preferred target and derive a corresponding value of qq. Each proposer can move the current value a bounded amount toward its preference. Over time, competing stake-weighted preferences influence the effective network target.

Changing TT also changes:

  • R=2⋅TR = 2 \cdot T (capacity replenished per second).
  • C=10⋅TC = 10 \cdot T (maximum accumulated capacity).
  • K=87⋅TK = 87 \cdot T (price response coefficient).

These relationships scale capacity and price responsiveness together and balance price increases and decreases under corresponding utilization levels.

Gas price stability

The gas price depends on an internal excess-gas variable xx. When KK changes, xx is adjusted proportionally to avoid an abrupt discontinuity in the price. The updates are applied after executing the block, so they affect the following block rather than transactions already executed.

Overall effects

The mechanism aims to reduce fee spikes from large blocks, adjust capacity to network resources, and converge toward a target reflecting validator preferences.

Related mechanisms have been used in Ethereum's EIP-4844 blob fee market and Avalanche's P-Chain. Those precedents support the design rationale but do not replace testing of this particular implementation.

Determining the gas price

ACP-176 uses the principles of the gas pricing mechanism introduced by ACP-103. The base fee for block bb depends on the following parameters.

Parameter Meaning
TT Target gas consumption per second
MM Minimum gas price
KK Price update coefficient
CC Maximum accumulated gas capacity
RR Gas capacity replenished per second

The model combines a capacity limit, replenishment rate, and a fee response to excess consumption. TT is the desired consumption rate, RR replenishes capacity, CC caps accumulated capacity, KK determines price responsiveness, and MM sets the price floor. The internal excess state xx is updated using elapsed time, gas consumed GG, and the relevant parameters.

Making TT dynamic

The mechanism introduces a nonnegative integer qq, initialized to zero at activation.

T=P⋅eqDT = P \cdot e^{\frac{q}{D}}

PP is the minimum permitted gas target, DD controls the rate of change, and e≈2.71828e\approx2.71828 is the base of natural logarithms.

After executing block bb, the proposer can adjust qq by at most QQ. The constraint ∣Δq∣≤Q\lvert \Delta q \rvert \le Q must hold; a block that violates the bound is invalid.

Each validator can configure a desired target. The corresponding desired qq is:

qdesired=D⋅ln⁡ ⁣(TdesiredP)q_{\text{desired}} = D \cdot \ln\!\left(\frac{T_{\text{desired}}}{P}\right)

The natural logarithm can be approximated and rounded for this local calculation. This is a local preference and need not be identical across validators.

When constructing a block, the proposer computes the next value of q by moving toward its desired value by no more than Q, as illustrated below.

python
# 指定ブロックにおける次のqを計算
def calc_next_q(q_current: int, q_desired: int, max_change: int) -> int:
    if q_desired > q_current:
        return q_current + min(q_desired - q_current, max_change)
    else:
        return q_current - min(q_current - q_desired, max_change)

The Japanese comment means "calculate the next q for a given block." The update occurs after transaction execution, and the target is recalculated as:

T=P⋅eqDT = P \cdot e^{\frac{q}{D}}

The capacity replenishment rate becomes:

R=2⋅TR = 2 \cdot T

This helps keep price increases and decreases balanced.

The maximum capacity also scales with the target:

C=10⋅TC = 10 \cdot T

With no gas consumption, replenishing capacity from zero to the maximum takes five seconds because C/R=10T/2T=5C/R=10T/2T=5 seconds.

The price response coefficient scales as:

K=87⋅TK = 87 \cdot T

Under sustained maximum utilization of 2T2T gas per second, the fee doubles in approximately 60.3 seconds. The original article compares this with about 70 seconds under EIP-1559 and around 50 seconds under the earlier C-Chain mechanism, depending on block intervals.

To avoid a price discontinuity when KK changes, the excess-gas state is rescaled. The proposal adjusts the excess after accounting for gas consumption using the next block's coefficient:

xn+1=(x+G)⋅Kn+1Knx_{n+1} = (x + G) \cdot \frac{K_{n+1}}{K_{n}}

Updates to qq and consequently T,R,C,K,xT, R, C, K, x take effect after block bb executes. They influence pricing for block b+1b+1, not transactions included in block bb.

Because block proposal opportunities are expected to reflect stake weights, the effective target may tend toward the point at which equal stake weight prefers increases and decreases. This is a convergence expectation rather than a guarantee of an optimal target or a separate explicit majority vote.

Under the ACP-103 capacity model, the maximum consumption over an interval Δt\Delta t is r+R⋅Δtr + R \cdot \Delta t, where rr is the remaining capacity following the previous block. The corresponding upper bound across intervals is C+R⋅ΔtC + R \cdot \Delta t.

For a particular block, the gas limit is:

gasLimitb=min⁡(r+R⋅Δt,  C)gasLimit_{b} = \min(r + R \cdot \Delta t,\; C)

Configuration parameters

The mechanism depends on T,M,K,C,RT,M,K,C,R. The target is adjusted based on DD and PP, and the other dynamic parameters are derived from it.

Parameter Meaning C-Chain activation value
PP Minimum target gas consumption per second 1,000,0001{,}000{,}000
DD Target adjustment coefficient 2252^{25}
QQ Maximum per-block adjustment of q 2152^{15}
MM Minimum gas price 1×10−181 \times 10^{-18} AVAX
KK Initial price update coefficient 87,000,00087{,}000{,}000

PP was chosen as a conservative minimum compared with the earlier C-Chain target of 1,500,000 gas per second. The proposal expects the effective target to remain near this minimum if a majority of stake weight prefers it.

The ratio of QQ to DD allows approximately a 1/1024 relative adjustment in the target per block. This follows the adjustment scale used by Ethereum's execution-layer gas limit, with an additional factor of 2152^{15} for finer granularity.

MM is set to the smallest native asset denomination to facilitate price discovery. Related fee mechanisms have operated on P-Chain and in Ethereum's blob gas market. By increasing fees under high demand, such mechanisms aim to mitigate sustained overload and denial-of-service risks.

For background on EIP-4844, see:

EIP-4844: Shard blob transactions

The value of KK produces a doubling time of approximately 60.3 seconds at sustained maximum utilization, as described above.

The maximum instantaneous price multiplier associated with a full capacity of gas is:

eCK=e10⋅T87⋅T=e1087≈1.12e^{\frac{C}{K}} = e^{\frac{10 \cdot T}{87 \cdot T}} = e^{\frac{10}{87}} \approx 1.12

Because C/KC/K stays constant, the multiplier remains the same when the target changes.

Choosing the desired target

Validators can configure their own desired gas target. A higher target permits greater resource consumption and potentially higher throughput, but requires nodes capable of sustaining that workload.

Validators should consider local hardware and software resource requirements, the network benefits of higher throughput, and network stability at the proposed level. Client implementations may provide defaults, while validators retain discretion over their local preference.

Compatibility

ACP-176 requires a coordinated network upgrade for activation. Before activation, the previous gas limit and price discovery mechanism apply. The transaction format does not change, so the expected impact on developer tools and wallets is limited.

After activation, the maximum accumulated capacity CC changes dynamically. Consequently, the gas available in a block, and thus the maximum transaction size that can fit, can vary. A transaction that cannot fit at one point may fit later, or vice versa. If the minimum target is sufficiently high, the practical impact may be limited. Variable block gas limits are also familiar in Ethereum.

The proposal discusses potential delays for large transactions during periods of rising fees. It recommends that producers wait until sufficient gas capacity is available before building a block. The historical maximum transaction size before activation was 15 million gas.

The proposed heuristic is to wait until capacity reaches min⁡(8⋅T,  15,000,000)\min(8\cdot T,\;15{,}000{,}000). The original article reports that this allowed transactions of up to 12.8 million gas to compete for block space at the referenced target.

Reference implementation

The proposal's implementation was merged into Coreth behind the Fortuna upgrade flag, with the implementation available in the following historical release:

  • coreth version v0.14.1-acp-176.1 (see GitHub Releases).

The flag controls when the new protocol behavior takes effect. This describes the implementation and activation approach documented by the proposal; the current deployment status is not independently verified here.

Security considerations

ACP-176 changes the gas pricing mechanism for Avalanche EVM chains. Prices should adapt to demand and discover a sustainable market-clearing level. If the mechanism responds incorrectly, prices could remain too low during high load, exposing the network to denial-of-service risks, or become excessive during low demand.

Although related mechanisms have operated on the P-Chain, the proposal calls for thorough testing before activating the new C-Chain mechanism.

The proposal also allows validators to influence gas limits. If those limits become too high, some nodes may be unable to keep up with block processing. A fixed upper cap could mitigate this risk but would require a further network upgrade to scale beyond it. The design must balance resource requirements, stability under load, and future scalability.

Conclusion

ACP-176 proposes adaptive fee calculation and bounded validator-driven adjustments to the gas target, aiming to reduce abrupt fee increases and accommodate changing processing capacity across Avalanche EVM chains.

If you have questions, feel free to contact me on Twitter.

Twitter @cardene777

You can also find my work on the following sites.

https://chaldene.net/