[ethereum/go-ethereum] Eip1283 (#17383)

This PR implements [EIP 1283(https://github.com/ethereum/EIPs/blob/master/EIPS/eip-1283.md#specification-version-ii). 1283 is an alternative to 1087, which does not require as much post-processing.

The cost for SSTORE operations rely on current value, new value and `original` value, where `original` means ‘what is currently in the trie’ a.k.a ‘the value that would remain if this current transaction was wholly reverted’.

This PR uses a map in state_object to store original value whenever a slot is updated.
This PR is experimental, in that it does not contain any testcases whatsoever, the intention being more to test how complex it would be to implement rather than being a fully-fledged merge-ready PR.
You can view, comment on, or merge this pull request online at:


— Commit Summary —

* core, state: initial implementation of Eip-1283
* core,state: finish implementing Eip 1283

— File Changes —

M core/state/state_object.go (25)
M core/state/statedb.go (19)
M core/vm/gas_table.go (54)
M core/vm/interface.go (2)
M core/vm/jump_table.go (8)
M core/vm/noop.go (2)

— Patch Links —


Добавить комментарий