-
Notifications
You must be signed in to change notification settings - Fork 144
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
Annotating rules that preserve definedness #2260
Conversation
rule <k> #newAccount ACCT => . ... </k> | ||
<accounts> | ||
( .Bag | ||
=> | ||
<account> | ||
<acctID> ACCT </acctID> | ||
<balance> 0 </balance> | ||
<code> .Bytes:AccountCode </code> | ||
<storage> .Map </storage> | ||
<origStorage> .Map </origStorage> | ||
<nonce> 0 </nonce> | ||
</account> | ||
) | ||
... | ||
</accounts> [owise, preserves-definedness] |
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.
By moving this account creation here, the [owise]
guarantees that ACCT
is not in the <accounts>
map, and the rule preserves definedness. Previosly, with the account creation isolated inside #newFreshAccount
, which could be in principle called from anywhere, this would not hold.
@jberthold Is there a systematic way of understanding all of the rules for which the backend cannot establish preservation of definedness? |
We have plans to make this available as a log level or with a CLI option, runtimeverification/hs-backend-booster#459 but there might be higher-priority things getting in the way (and I will be away to another funeral in my family :-| next week). |
f3ed1b0
to
36f8e92
Compare
…l/test-arithmetictest-test_wmul_wdiv_inverse_underflow-uint256-uint256-0-spec.k` pass
@ehildenb @PetarMax the
but I wanted to ask for your opinion first. This might also indicate that we should bump the default timeout in KEVM and Kontrol. |
I would like to know what the SMT query in question is. |
We can take a transcript of the SMT interactions with the |
These are the transcripts of SMT interactions, and I also attached the error message with the term: If I understand correctly, here's the relevant part of the SMT logs:
|
@ehildenb said that he's fine with keeping the timeout of 1.6s and that we can also increase the default timeout in KEVM and Kontrol (I can do it, if we all agree on it). |
…ul_wdiv_inverse_underflow-uint256-uint256-0-spec` in Booster
After a discussion with @PetarMax, we decided to skip the failing test on booster and keep the 300ms timeout since it's sufficient for all other tests; I created an issue to track the investigation on the skipped test: #2314. |
@PetarMax shall we get it merged, or are we waiting for some more feedback from the reviewers? |
This PR aims to annotate all of the KEVM rules for which we know that they preserve definedness, but the backend is not able to prove this on its own.