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

Interop gas charging workaround #1723

Open
wants to merge 10 commits into
base: main
Choose a base branch
from

Conversation

bzawisto
Copy link
Contributor

@bzawisto bzawisto commented Oct 29, 2024

This PR introduces a workaround and performs different gas tracking for evm->scilla calls. In order to figure out if such logic should be applied, each account has additional creation_at_block field saying if it's ZQ1 or ZQ2(block_number).
Since we need to know how much gas is left inside the precompile - each evm run has thin ZQ2Inspector which tracks gas left and stores the value in PendingSubstate. Later, PendingSubstate is accessible from precompile and we can provide suitable value to scilla runs from precompile.

@bzawisto bzawisto marked this pull request as draft October 30, 2024 15:10
@bzawisto bzawisto removed the request for review from JamesHinshelwood October 30, 2024 15:10
@bzawisto bzawisto changed the title Preliminary changes needed for interop workarounds Interop gas charging workaround Nov 5, 2024
@bzawisto bzawisto self-assigned this Nov 5, 2024
@bzawisto bzawisto marked this pull request as ready for review November 5, 2024 14:58
…ere-the-calling-contract-was-deployed-before-a-configured-block
Copy link
Contributor

@86667 86667 left a comment

Choose a reason for hiding this comment

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

👍

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.

Charge less gas for EVM->Scilla calls where the calling contract was deployed before a configured block
2 participants