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

Tighten up our gas analysis tests #30

Open
nagisa opened this issue Jan 11, 2023 · 0 comments
Open

Tighten up our gas analysis tests #30

nagisa opened this issue Jan 11, 2023 · 0 comments
Labels
A-gas-analysis Area: the gas analysis implemented in this crate

Comments

@nagisa
Copy link
Collaborator

nagisa commented Jan 11, 2023

Today the gas analysis tests executes an instrumented wast test and compares that an overall gas cost to execute the test was the same.

This isn’t particularly great, it does not actually verify that the gas counters are precise at all points where a side effect does in fact occur, for example. We could have the interpreter output markers where it thinks side effects are occurring and have it validate the traces more tightly/rigorously.

Conceptually I expected that it would be possible to make each gas instrumentation point such a segmentation point, but this has not really panned out due to tests not always charging fees before the execution of a given instruction – loop is an example of that, function prologue is another.

@nagisa nagisa added the A-gas-analysis Area: the gas analysis implemented in this crate label Jan 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-gas-analysis Area: the gas analysis implemented in this crate
Projects
None yet
Development

No branches or pull requests

1 participant