-
Notifications
You must be signed in to change notification settings - Fork 44
Reuse kompiled contracts.k
and foundry.k
in Kontrol performance test
#3845
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
Conversation
871968c
to
0f2a66f
Compare
0f2a66f
to
c57242d
Compare
A test run with 7 workers. Still noisy, but perhaps slightly less so?
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. I worry that the more assumptions/fixes we add in our script the more we will have to keep patching it when the CLI arguments/foundry folders/etc. change. I guess time will tell and perhaps these can be up-streamed to kontrol directly.
@geo2a this seems like something that we could have made a change directly to Kontrol for. Consider doing so there! (as I think @goodlyrottenapple also suggested). |
~Needs runtimeverification/evm-semantics#2417 Allows compiling the K definitions needs for proofs in advance, with the hope of reducing measurement noise. In the spirit of #3845, but now for KEVM rather than Kontrol.
This PR attempts to reduce the influence of the K compiler processes on the Kontrol performance test. To achieve that, we compile everything in-advance, ensuring that there will be no calls to
kompile
when running the actual proof test:test_foundy_kompile
test, which is essentially just a wrapper for thefoundry
pytest fixture that generates and compiles thecontracts.k
andfoundry.k
files. This produces thefoundry/out/kompiled
directoryfoundry
directory to them explicitly. This makes sure that the pytest fixture will not be forced to recompile stuff in everypytest-xdist
worker.foundry
directory has a side-effect of also reusing thefoundry/out/proofs
directory. To make sure that we actually run the proofs inmaster_shell
, and not re-use the ones produced byfeature_shell
, we delete them between the steps.Some things I've noticed that may be worth accounting for, but not in this PR:
server
fixture is module-scoped. That means that all tests in a certain test module will reuse the same server instance, individually in each test worker.