Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Memory optimization for RPC Jumpdests fetching #767

Open
2 of 3 tasks
einar-polygon opened this issue Nov 4, 2024 · 0 comments
Open
2 of 3 tasks

Memory optimization for RPC Jumpdests fetching #767

einar-polygon opened this issue Nov 4, 2024 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@einar-polygon
Copy link
Contributor

This continues the work in #427 and addresses one problem: CREATE and CREATE2 required memory dumps to obtain the relevant contract code and code_hash for call stack simulation, and we opted instead to fail over to simulation, since memory dumps were slow.

This branch introduces the following changes:

  • Reinstantiate the match case for CREATE and CREATE2, but ignore code and code_hash.
  • Prove only the current context. The old version generates all Jumpdest proofs in the very first context. This meant that the witness had to provide the relevant mapping between code_hash and context. This change means two things: current_code and current_code_hash is always available, so we do away with the mapping in the witness, essentially simplifying it to a mapping ctx->[offset].
  • Simplify the witness including removal of the tracking of code and code_hash in the Jumpdest generation.

Work has started in PR: Prefetch JUMPDESTs through RPC with progressive proving #765

Status: The first 100 blocks on testchain2 succeed, but there are still many errors later.

@einar-polygon einar-polygon added the enhancement New feature or request label Nov 4, 2024
@einar-polygon einar-polygon self-assigned this Nov 4, 2024
@github-project-automation github-project-automation bot moved this to Backlog in Zero EVM Nov 4, 2024
@Nashtare Nashtare added this to the Performance Tuning milestone Nov 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: Backlog
Development

No branches or pull requests

2 participants