Abstract

On many blockchain platforms, gas fees have to be paid for deploying and executing smart contracts. These fees depend on the size of the contract code as well as the needed computational steps and required storage space of a smart contract. Because of the large amount of gas cost paid each day, there is an inherent motivation to optimize smart contract code in order to reduce these cost. Within this paper, we discuss the application of 25 strategies for code optimization to Solidity smart contracts. A prototype is developed which detects potential optimizations and partially automatically optimizes the code accordingly. The optimization strategies are evaluated based on 3,018 verified open source smart contracts from etherscan.io. We find 471 rule violations in the test data spread across 204 different contract files.

Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call