Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove ReadOnlyStateDB, use snapshot+revert
I has been stated that StaticCall can do modifications to the state in multiple places in the geth code base. Therefore, we first did a copy of the state to avoid changes and later switched to used the ReadOnlyStateDB to achieve the same result with better performance. Upon closer examination, the only state change that StaticCall actually does is "touching" the called address, which only makes a difference on legacy Ethereum chains, and tracking the access list. This can be avoided by doing a snapshot+revert. The performance impact should be low, since the revert only has to undo the access list change. With the removal of ReadOnlyStateDB, further testing of it is pointless: Closes celo-org/celo-blockchain-planning#355
- Loading branch information