Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
eeb3a97
fix(ported_static): fork-conditional gas bumps for stCallCodes/stCall…
leolara May 12, 2026
0c3d36c
fix(ported_static): fork-conditional tx_gas for stCreate2 collision t…
leolara May 12, 2026
477ac04
fix(ported_static): fork-conditional tx_gas for stCreate2 revert_dept…
leolara May 12, 2026
20a30fc
fix(ported_static): fork-conditional tx_gas for stRandom*/test_random…
leolara May 12, 2026
dfb713d
fix(ported_static): fork-conditional CALL gas for push0 / revert_opco…
leolara May 12, 2026
37f6169
fix(ported_static): batch fork-conditional gas bumps for 7 simple cases
leolara May 12, 2026
1ec821d
fix(ported_static): fork-conditional tx_gas for stSystemOperationsTes…
leolara May 12, 2026
936bc9f
fix(ported_static): fork-conditional tx_gas for stMemoryTest mem32kb/…
leolara May 12, 2026
352857e
fix(ported_static): fork-conditional tx_gas for stMemoryTest mem{0,31…
leolara May 12, 2026
c67d8f0
fix(ported_static): fork-conditional tx_gas bumps for stPreCompiledCo…
leolara May 12, 2026
6d2ae98
fix(ported_static): fork-conditional tx_gas for stRandom/stRandom2 au…
leolara May 12, 2026
d72f726
fix(ported_static): fork-conditional gas for stTransactionTest/intern…
leolara May 12, 2026
4983a29
fix(ported_static): fork-conditional gas bumps for misc stCreateTest/…
leolara May 12, 2026
b28e3e4
fix(ported_static): fork-conditional gas for stInitCodeTest deploy txs
leolara May 12, 2026
f7f0f94
fix(ported_static): fork-conditional tx_gas[1] for stCreate2/test_cre…
leolara May 12, 2026
5050482
fix(ported_static): fork-conditional gas for stRevertTest revert_in_c…
leolara May 12, 2026
c604840
chore(ported_static): restore Amsterdam skip entries that the gas bum…
leolara May 12, 2026
cc4a53b
chore(test): hex -> int for readability
fselmo May 12, 2026
7cfa787
chore(ported_static): trim verbose state-gas narrative from suicide_e…
spencer-tb May 12, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
883 changes: 233 additions & 650 deletions tests/ported_static/amsterdam_skip_list.txt

Large diffs are not rendered by default.

19 changes: 17 additions & 2 deletions tests/ported_static/stCallCodes/test_callcall_00_suicide_end.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@

Ported from:
state_tests/stCallCodes/callcall_00_SuicideEndFiller.json

@manually-enhanced: Do not overwrite. The hardcoded inner-CALL gas
values (50k / 100k / 150k) were tuned to the pre-EIP-8037 gas budget.

"""

import pytest
Expand All @@ -15,6 +19,7 @@
StateTestFiller,
Transaction,
)
from execution_testing.forks import Fork
from execution_testing.vm import Op

REFERENCE_SPEC_GIT_PATH = "N/A"
Expand All @@ -29,8 +34,18 @@
def test_callcall_00_suicide_end(
state_test: StateTestFiller,
pre: Alloc,
fork: Fork,
) -> None:
"""Call -> (call -> code) suicide ."""
# EIP-8037 inner-CALL gas bumps: original values restored for
# pre-EIP-8037 forks; bumped values cover the per-storage state-
# gas spill into regular gas on Amsterdam.
outer_call_gas = 150000
inner_call_gas = 50000
if fork.is_eip_enabled(8037):
outer_call_gas = 1000000
inner_call_gas = 100000

coinbase = Address(0x2ADC25665018AA1FE0E6BC666DAC8FC2697FF9BA)
sender = pre.fund_eoa(amount=0xDE0B6B3A7640000)

Expand All @@ -57,7 +72,7 @@ def test_callcall_00_suicide_end(
code=Op.SSTORE(
key=0x0,
value=Op.CALL(
gas=0x249F0,
gas=outer_call_gas,
address=0xF741CFEE7B7FB1025DCCEF3DB5A3CBC8FFB776F8,
value=0x0,
args_offset=0x0,
Expand All @@ -77,7 +92,7 @@ def test_callcall_00_suicide_end(
code=Op.SSTORE(
key=0x1,
value=Op.CALL(
gas=0xC350,
gas=inner_call_gas,
address=0x703B936FD4D674F0FF5D6957F61097152F8781B8,
value=0x0,
args_offset=0x0,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@

Ported from:
state_tests/stCallCodes/callcallcall_000_SuicideEndFiller.json

@manually-enhanced: Do not overwrite. The hardcoded inner-CALL gas
values (50k / 100k / 150k) were tuned to the pre-EIP-8037 gas budget.

"""

import pytest
Expand All @@ -15,6 +19,7 @@
StateTestFiller,
Transaction,
)
from execution_testing.forks import Fork
from execution_testing.vm import Op

REFERENCE_SPEC_GIT_PATH = "N/A"
Expand All @@ -29,8 +34,20 @@
def test_callcallcall_000_suicide_end(
state_test: StateTestFiller,
pre: Alloc,
fork: Fork,
) -> None:
"""Call -> call -> (call -> code) suicide."""
# EIP-8037 inner-CALL gas bumps: original values restored for
# pre-EIP-8037 forks; bumped values cover the per-storage state-
# gas spill into regular gas on Amsterdam.
outer_call_gas = 150000
middle_call_gas = 100000
inner_call_gas = 50000
if fork.is_eip_enabled(8037):
outer_call_gas = 1000000
middle_call_gas = 800000
inner_call_gas = 100000

coinbase = Address(0x2ADC25665018AA1FE0E6BC666DAC8FC2697FF9BA)
sender = pre.fund_eoa(amount=0xDE0B6B3A7640000)

Expand All @@ -57,7 +74,7 @@ def test_callcallcall_000_suicide_end(
code=Op.SSTORE(
key=0x0,
value=Op.CALL(
gas=0x249F0,
gas=outer_call_gas,
address=0x77B749FFFF7EC61D31C79ED104F230A7959B2879,
value=0x0,
args_offset=0x0,
Expand All @@ -77,7 +94,7 @@ def test_callcallcall_000_suicide_end(
code=Op.SSTORE(
key=0x1,
value=Op.CALL(
gas=0x186A0,
gas=middle_call_gas,
address=0xD957E143AD2C011BC6A2B142795F1A9BA70D0680,
value=0x0,
args_offset=0x0,
Expand All @@ -97,7 +114,7 @@ def test_callcallcall_000_suicide_end(
code=Op.SSTORE(
key=0x2,
value=Op.CALL(
gas=0xC350,
gas=inner_call_gas,
address=0xCB6497F0337B6CD0F7239A8819295EC7D1DAFD34,
value=0x0,
args_offset=0x0,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@

Ported from:
state_tests/stCallCodes/callcallcallcode_001_SuicideEndFiller.json

@manually-enhanced: Do not overwrite. The hardcoded inner-CALL gas
values (50k / 100k / 150k) were tuned to the pre-EIP-8037 gas budget.

"""

import pytest
Expand All @@ -15,6 +19,7 @@
StateTestFiller,
Transaction,
)
from execution_testing.forks import Fork
from execution_testing.vm import Op

REFERENCE_SPEC_GIT_PATH = "N/A"
Expand All @@ -29,8 +34,20 @@
def test_callcallcallcode_001_suicide_end(
state_test: StateTestFiller,
pre: Alloc,
fork: Fork,
) -> None:
"""Call -> call -> ( callcode - > code ) suicide."""
# EIP-8037 inner-CALL gas bumps: original values restored for
# pre-EIP-8037 forks; bumped values cover the per-storage state-
# gas spill into regular gas on Amsterdam.
outer_call_gas = 150000
middle_call_gas = 100000
inner_call_gas = 50000
if fork.is_eip_enabled(8037):
outer_call_gas = 1000000
middle_call_gas = 800000
inner_call_gas = 100000

coinbase = Address(0x2ADC25665018AA1FE0E6BC666DAC8FC2697FF9BA)
sender = pre.fund_eoa(amount=0xDE0B6B3A7640000)

Expand All @@ -57,7 +74,7 @@ def test_callcallcallcode_001_suicide_end(
code=Op.SSTORE(
key=0x0,
value=Op.CALL(
gas=0x249F0,
gas=outer_call_gas,
address=0x77B749FFFF7EC61D31C79ED104F230A7959B2879,
value=0x0,
args_offset=0x0,
Expand All @@ -77,7 +94,7 @@ def test_callcallcallcode_001_suicide_end(
code=Op.SSTORE(
key=0x1,
value=Op.CALL(
gas=0x186A0,
gas=middle_call_gas,
address=0x94C8F980AEECBB6575B12AE614A249FC3E836F21,
value=0x0,
args_offset=0x0,
Expand All @@ -97,7 +114,7 @@ def test_callcallcallcode_001_suicide_end(
code=Op.SSTORE(
key=0x2,
value=Op.CALLCODE(
gas=0xC350,
gas=inner_call_gas,
address=0x73B954EBC05BB0FF4A0F6A13A054D50AD1584099,
value=0x0,
args_offset=0x0,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@

Ported from:
state_tests/stCallCodes/callcallcodecall_010_SuicideEndFiller.json

@manually-enhanced: Do not overwrite. The hardcoded inner-CALL gas
values (50k / 100k / 150k) were tuned to the pre-EIP-8037 gas budget.

"""

import pytest
Expand All @@ -15,6 +19,7 @@
StateTestFiller,
Transaction,
)
from execution_testing.forks import Fork
from execution_testing.vm import Op

REFERENCE_SPEC_GIT_PATH = "N/A"
Expand All @@ -29,8 +34,20 @@
def test_callcallcodecall_010_suicide_end(
state_test: StateTestFiller,
pre: Alloc,
fork: Fork,
) -> None:
"""Call -> callcode -> (call -> code) (suicide)."""
# EIP-8037 inner-CALL gas bumps: original values restored for
# pre-EIP-8037 forks; bumped values cover the per-storage state-
# gas spill into regular gas on Amsterdam.
outer_call_gas = 150000
middle_call_gas = 100000
inner_call_gas = 50000
if fork.is_eip_enabled(8037):
outer_call_gas = 1000000
middle_call_gas = 800000
inner_call_gas = 100000

coinbase = Address(0x2ADC25665018AA1FE0E6BC666DAC8FC2697FF9BA)
sender = pre.fund_eoa(amount=0xDE0B6B3A7640000)

Expand All @@ -57,7 +74,7 @@ def test_callcallcodecall_010_suicide_end(
code=Op.SSTORE(
key=0x0,
value=Op.CALL(
gas=0x249F0,
gas=outer_call_gas,
address=0xEAF8C2AE0D01A880CEA4E1AA88DEF5EDD153D57B,
value=0x0,
args_offset=0x0,
Expand All @@ -77,7 +94,7 @@ def test_callcallcodecall_010_suicide_end(
code=Op.SSTORE(
key=0x1,
value=Op.CALLCODE(
gas=0x186A0,
gas=middle_call_gas,
address=0xD957E143AD2C011BC6A2B142795F1A9BA70D0680,
value=0x0,
args_offset=0x0,
Expand All @@ -97,7 +114,7 @@ def test_callcallcodecall_010_suicide_end(
code=Op.SSTORE(
key=0x2,
value=Op.CALL(
gas=0xC350,
gas=inner_call_gas,
address=0x73B954EBC05BB0FF4A0F6A13A054D50AD1584099,
value=0x0,
args_offset=0x0,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@

Ported from:
state_tests/stCallCodes/callcodeInInitcodeToEmptyContractFiller.json
@manually-enhanced: Do not overwrite. Gas bumped fork-conditionally
to cover EIP-8037 state-gas spill into regular gas; pre-EIP-8037
behavior unchanged.

"""

import pytest
Expand Down Expand Up @@ -58,6 +62,13 @@ def test_callcode_in_initcode_to_empty_contract(
v: int,
) -> None:
"""Callcode inside create contract init to non-existent contract."""
# EIP-8037 gas bumps: original values for pre-EIP-8037 forks.
outer_tx_gas = 1453081
inner_call_gas = 300000
if fork.is_eip_enabled(8037):
outer_tx_gas = 7265405
inner_call_gas = 1500000

coinbase = Address(0x2ADC25665018AA1FE0E6BC666DAC8FC2697FF9BA)
contract_0 = Address(0x1100000000000000000000000000000000000000)
contract_1 = Address(0x1000000000000000000000000000000000000000)
Expand All @@ -80,7 +91,7 @@ def test_callcode_in_initcode_to_empty_contract(
# { (CALL 300000 (CALLDATALOAD 0) 0 0 0 0 0) }
contract_0 = pre.deploy_contract( # noqa: F841
code=Op.CALL(
gas=0x493E0,
gas=inner_call_gas,
address=Op.CALLDATALOAD(offset=0x0),
value=0x0,
args_offset=0x0,
Expand Down Expand Up @@ -175,7 +186,7 @@ def test_callcode_in_initcode_to_empty_contract(
Hash(contract_1, left_padding=True),
Hash(contract_2, left_padding=True),
]
tx_gas = [1453081]
tx_gas = [outer_tx_gas]

tx = Transaction(
sender=sender,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@

Ported from:
state_tests/stCallCodes/callcodecall_10_SuicideEndFiller.json

@manually-enhanced: Do not overwrite. The hardcoded inner-CALL gas
values (50k / 100k / 150k) were tuned to the pre-EIP-8037 gas budget.

"""

import pytest
Expand All @@ -15,6 +19,7 @@
StateTestFiller,
Transaction,
)
from execution_testing.forks import Fork
from execution_testing.vm import Op

REFERENCE_SPEC_GIT_PATH = "N/A"
Expand All @@ -29,8 +34,18 @@
def test_callcodecall_10_suicide_end(
state_test: StateTestFiller,
pre: Alloc,
fork: Fork,
) -> None:
"""CALLCODE -> (CALL -> code) (suicide)."""
# EIP-8037 inner-CALL gas bumps: original values restored for
# pre-EIP-8037 forks; bumped values cover the per-storage state-
# gas spill into regular gas on Amsterdam.
outer_call_gas = 150000
inner_call_gas = 50000
if fork.is_eip_enabled(8037):
outer_call_gas = 1000000
inner_call_gas = 100000

coinbase = Address(0x2ADC25665018AA1FE0E6BC666DAC8FC2697FF9BA)
sender = pre.fund_eoa(amount=0xDE0B6B3A7640000)

Expand All @@ -57,7 +72,7 @@ def test_callcodecall_10_suicide_end(
code=Op.SSTORE(
key=0x0,
value=Op.CALLCODE(
gas=0x249F0,
gas=outer_call_gas,
address=0xF741CFEE7B7FB1025DCCEF3DB5A3CBC8FFB776F8,
value=0x0,
args_offset=0x0,
Expand All @@ -77,7 +92,7 @@ def test_callcodecall_10_suicide_end(
code=Op.SSTORE(
key=0x1,
value=Op.CALL(
gas=0xC350,
gas=inner_call_gas,
address=0x703B936FD4D674F0FF5D6957F61097152F8781B8,
value=0x0,
args_offset=0x0,
Expand Down
Loading
Loading