all: define Berlin hard fork spec
This commit is contained in:
@ -56,24 +56,23 @@ var (
|
||||
byzantiumInstructionSet = newByzantiumInstructionSet()
|
||||
constantinopleInstructionSet = newConstantinopleInstructionSet()
|
||||
istanbulInstructionSet = newIstanbulInstructionSet()
|
||||
yoloV3InstructionSet = newYoloV3InstructionSet()
|
||||
berlinInstructionSet = newBerlinInstructionSet()
|
||||
)
|
||||
|
||||
// JumpTable contains the EVM opcodes supported at a given fork.
|
||||
type JumpTable [256]*operation
|
||||
|
||||
// newYoloV3InstructionSet creates an instructionset containing
|
||||
// - "EIP-2315: Simple Subroutines"
|
||||
// - "EIP-2929: Gas cost increases for state access opcodes"
|
||||
func newYoloV3InstructionSet() JumpTable {
|
||||
// newBerlinInstructionSet returns the frontier, homestead, byzantium,
|
||||
// contantinople, istanbul, petersburg and berlin instructions.
|
||||
func newBerlinInstructionSet() JumpTable {
|
||||
instructionSet := newIstanbulInstructionSet()
|
||||
enable2315(&instructionSet) // Subroutines - https://eips.ethereum.org/EIPS/eip-2315
|
||||
enable2929(&instructionSet) // Access lists for trie accesses https://eips.ethereum.org/EIPS/eip-2929
|
||||
return instructionSet
|
||||
}
|
||||
|
||||
// newIstanbulInstructionSet returns the frontier, homestead
|
||||
// byzantium, contantinople and petersburg instructions.
|
||||
// newIstanbulInstructionSet returns the frontier, homestead, byzantium,
|
||||
// contantinople, istanbul and petersburg instructions.
|
||||
func newIstanbulInstructionSet() JumpTable {
|
||||
instructionSet := newConstantinopleInstructionSet()
|
||||
|
||||
@ -84,7 +83,7 @@ func newIstanbulInstructionSet() JumpTable {
|
||||
return instructionSet
|
||||
}
|
||||
|
||||
// newConstantinopleInstructionSet returns the frontier, homestead
|
||||
// newConstantinopleInstructionSet returns the frontier, homestead,
|
||||
// byzantium and contantinople instructions.
|
||||
func newConstantinopleInstructionSet() JumpTable {
|
||||
instructionSet := newByzantiumInstructionSet()
|
||||
|
Reference in New Issue
Block a user