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

create opcode should use code cache #2929

Open
arnetheduck opened this issue Dec 12, 2024 · 0 comments
Open

create opcode should use code cache #2929

arnetheduck opened this issue Dec 12, 2024 · 0 comments
Labels
EL enhancement New feature or request EVM

Comments

@arnetheduck
Copy link
Member

When creating a new contract using the create/create2 opcodes, we should check whether the code already exists in the cache and reuse the cached version - otherwise, we need to recompute the code jump destination filter each time which is slow.

While executing the code the first time, the cache should not be updated (peek) - only when the transaction is fully successful should the cache be updated to include the new code, to avoid contracts stuffing the cache with junk code.

@jangko jangko added enhancement New feature or request EVM EL labels Dec 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
EL enhancement New feature or request EVM
Projects
None yet
Development

No branches or pull requests

2 participants