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

Update Kontrol test name, Makefile; format lemmas #2

Merged
merged 1 commit into from
Jul 11, 2024

Conversation

palinatolmach
Copy link
Contributor

This PR updates Kontrol-related tests, lemmas, and instructions in Makefile. In particular, it

  • renames check_hellFunc_doesnt_revert_kontrol to test_hellFunc_doesnt_revert_kontrol in KontrolTest, which is needed for the test to be reported as failing once a reverting path is identified (in Kontrol, functions that are not prefixed with test are explored but not checked for failures to report);
  • updates the test name in Makefile instructions accordingly;
  • comments the cheatcode invocation kevm.infiniteGas() in KontrolTest — infinite gas is now being assumed by default in Kontrol (in our documentation it is just meant to serve as an example of Kontrol-specific cheatcodes);
  • removes --use-booster flag from instructions in Makefile, since it is now on by default;
  • adds --no-break-on-calls flag to kontrol prove command in Makefile — this option instructs Kontrol to not save a KCFG node every time a CALL is made, which speeds up the execution;
  • changes a failing node number in get-model command according to the results of the updated kontrol prove instruction;
  • performs a minor cleanup of lemmas.k

Please also note that we fixed an issue with model generation, so kontrol prove --counterexample-information will now return a model as follows:

PROOF FAILED: KontrolTest.test_hellFunc_doesnt_revert_kontrol(uint128):0
1 Failure nodes. (0 pending and 1 failing)
...
  Model:
    VV0_num_114b9705 = 99

Running kontrol get-model for the same failing node will return the same result.

@PatrickAlphaC PatrickAlphaC merged commit fc9a94c into Cyfrin:main Jul 11, 2024
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.

2 participants