Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
af8b138c
Unverified
Commit
af8b138c
authored
1 year ago
by
Martin Holst Swende
Committed by
GitHub
1 year ago
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
core/vm: define cancun + enable 1153 (tstore/tload) in cancun (#27663)
parent
c2db667c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
23 additions
and
3 deletions
+23
-3
jump_table.go
core/vm/jump_table.go
+1
-0
jump_table_export.go
core/vm/jump_table_export.go
+3
-3
init.go
tests/init.go
+19
-0
No files found.
core/vm/jump_table.go
View file @
af8b138c
...
...
@@ -83,6 +83,7 @@ func validate(jt JumpTable) JumpTable {
func
newCancunInstructionSet
()
JumpTable
{
instructionSet
:=
newShanghaiInstructionSet
()
enable4844
(
&
instructionSet
)
// BLOBHASH opcode
enable1153
(
&
instructionSet
)
// EIP-1153 "Transient Storage"
return
validate
(
instructionSet
)
}
...
...
This diff is collapsed.
Click to expand it.
core/vm/jump_table_export.go
View file @
af8b138c
...
...
@@ -27,11 +27,11 @@ import (
func
LookupInstructionSet
(
rules
params
.
Rules
)
(
JumpTable
,
error
)
{
switch
{
case
rules
.
IsVerkle
:
return
new
Shanghai
InstructionSet
(),
errors
.
New
(
"verkle-fork not defined yet"
)
return
new
Cancun
InstructionSet
(),
errors
.
New
(
"verkle-fork not defined yet"
)
case
rules
.
IsPrague
:
return
new
Shanghai
InstructionSet
(),
errors
.
New
(
"prague-fork not defined yet"
)
return
new
Cancun
InstructionSet
(),
errors
.
New
(
"prague-fork not defined yet"
)
case
rules
.
IsCancun
:
return
new
ShanghaiInstructionSet
(),
errors
.
New
(
"cancun-fork not defined yet"
)
return
new
CancunInstructionSet
(),
nil
case
rules
.
IsShanghai
:
return
newShanghaiInstructionSet
(),
nil
case
rules
.
IsMerge
:
...
...
This diff is collapsed.
Click to expand it.
tests/init.go
View file @
af8b138c
...
...
@@ -299,6 +299,25 @@ var Forks = map[string]*params.ChainConfig{
TerminalTotalDifficulty
:
big
.
NewInt
(
0
),
ShanghaiTime
:
u64
(
15
_000
),
},
"Cancun"
:
{
ChainID
:
big
.
NewInt
(
1
),
HomesteadBlock
:
big
.
NewInt
(
0
),
EIP150Block
:
big
.
NewInt
(
0
),
EIP155Block
:
big
.
NewInt
(
0
),
EIP158Block
:
big
.
NewInt
(
0
),
ByzantiumBlock
:
big
.
NewInt
(
0
),
ConstantinopleBlock
:
big
.
NewInt
(
0
),
PetersburgBlock
:
big
.
NewInt
(
0
),
IstanbulBlock
:
big
.
NewInt
(
0
),
MuirGlacierBlock
:
big
.
NewInt
(
0
),
BerlinBlock
:
big
.
NewInt
(
0
),
LondonBlock
:
big
.
NewInt
(
0
),
ArrowGlacierBlock
:
big
.
NewInt
(
0
),
MergeNetsplitBlock
:
big
.
NewInt
(
0
),
TerminalTotalDifficulty
:
big
.
NewInt
(
0
),
ShanghaiTime
:
u64
(
0
),
CancunTime
:
u64
(
0
),
},
}
// AvailableForks returns the set of defined fork names
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment