Empirically Analyzing Ethereum's Gas Mechanism
This work addresses a critical issue for Ethereum's security and decentralization by identifying misalignments in its Gas mechanism that could undermine node diversity.
The authors conducted the first large-scale empirical study of Ethereum's Gas mechanism, analyzing terabytes of transaction execution traces to assess alignment between Gas costs and actual computational costs. They found that the current model poorly captures I/O costs and disadvantages modestly resourced nodes, threatening node diversity and network decentralization.
Ethereum's Gas mechanism attempts to set transaction fees in accordance with the computational cost of transaction execution: a cost borne by default by every node on the network to ensure correct smart contract execution. Gas encourages users to author transactions that are efficient to execute and in so doing encourages node diversity, allowing modestly resourced nodes to join and contribute to the security of the network. However, the effectiveness of this scheme relies on Gas costs being correctly aligned with observed computational costs in reality. In this work, we performed the first large scale empirical study to understand to what degree this alignment exists in practice, by collecting and analyzing Tera-bytes worth of nanosecond-precision transaction execution traces. Besides confirming potential denial-of-service vectors, our results also shed light on the role of I/O in transaction costs which remains poorly captured by the current Gas cost model. Finally, our results suggest that under the current Gas cost model, nodes with modest computational resources are disadvantaged compared to their better resourced peers, which we identify as an ongoing threat to node diversity and network decentralization.