Skip to content

Conversation

@nerolation
Copy link
Contributor

First draft implementation of EIP-7981, which is going to be proposed for Glamsterdam.


for access in access_list:
# Count bytes in address (20 bytes)
for byte in access.account:
Copy link
Contributor

Choose a reason for hiding this comment

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

Counting zero and non-zero bytes is being used in a couple of other places as well, including for call data in calculate_intrinsic_cost. Perhaps it would be a good idea to refactor it into a function in the ethereum.utils.byte module.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

yeah agree, makes sense

danceratopz pushed a commit to danceratopz/execution-specs that referenced this pull request Oct 22, 2025
This combines the cases of `test_all_opcodes_stack_underflow()`
to `test_all_opcodes_variadic_stack_underflow()`.
By the way, this also improves some details, e.g. avoids instruction
sequence as `RETURN STOP`.
@nerolation nerolation changed the base branch from forks/osaka to forks/amsterdam November 3, 2025 12:44
Add additional gas costs for access list data bytes as specified in EIP-7981.

- Add count_bytes utility function for zero/non-zero byte counting
- Add EIP-7981 gas cost constants for access list bytes
- Add count_access_list_bytes function to count bytes in access lists
- Modify calculate_intrinsic_cost to include EIP-7981 access list data costs
- Update function documentation to reference EIP-7981

Maintains compatibility with existing EIP-2930 access list functionality.
@nerolation nerolation changed the title Add EIP-7981 Implementation feat(specs): Add EIP-7981 implementation Nov 3, 2025
@fselmo fselmo force-pushed the forks/amsterdam branch 3 times, most recently from 28a68cd to cb3daac Compare November 11, 2025 15:11
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.

3 participants