Skip to content

Conversation

@pdobacz
Copy link
Contributor

@pdobacz pdobacz commented Oct 20, 2025

Opening here as draft to collect early feedback. I'll migrate the PR over to EELS once the Weld is complete.

This responds to a gap in coverage uncovered by evmone coverage report in lib/evmone/baseline_execution.cpp - it seems there was not test to cause opcodes to go out-of-gas on the very basic constant amount of gas.

  • no such test in ethereum/tests
  • no such test in ethereum/legacytests
  • no such test in evmone's unittests
  • new tests pass on hive for a bunch of non-evmone clients.

from ethereum_test_vm import Opcode, UndefinedOpcodes
from ethereum_test_vm import Opcodes as Op
from tests.unscheduled.eip7692_eof_v1.eip3540_eof_v1.opcodes import V1_EOF_ONLY_OPCODES
from tests.unscheduled.eip7692_eof_v1.gas_test import gas_test
Copy link
Contributor Author

@pdobacz pdobacz Oct 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

my main point I'm not 100% sold on, but gas_test handles a ton of issues out-of-the-box for us. Once EOF tests are maybe removed it could be simplified and moved out of that EOF specific directory.

The bits that gas_tests handles:

  • setting the exact amount of gas needed to oog
  • warm and cold call
  • sanity check, i.e. add one gas and no more oog
  • (not) having to deal with intrinsic gas etc.
  • in general - recognizing when the oog happened and when not - just by manipulating tx gas_limit is quite difficult

@pdobacz pdobacz force-pushed the tests/constant-gas-oog branch from 613cffe to a862e9c Compare October 20, 2025 21:31
@LouisTsai-Csie
Copy link
Collaborator

Thanks for this, i think this is necessary for upcoming gas-repricing refactor for us

@pdobacz pdobacz force-pushed the tests/constant-gas-oog branch from a7fcd0e to bcdb497 Compare October 27, 2025 09:55
@pdobacz
Copy link
Contributor Author

pdobacz commented Oct 27, 2025

closing in favor of ethereum/execution-specs#1686

@pdobacz pdobacz closed this Oct 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants