-
Notifications
You must be signed in to change notification settings - Fork 707
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
Use llvm_points_to_bitfield
in SAW proofs
#3155
Conversation
I've marked this PR as a draft for now since I still need to update the CI to use a more recent version of SAW with the changes in GaloisInc/saw-script#1539. I am currently preparing a SAW bindist with these changes, but in the meantime, any review comments would be appreciated. |
Benchmark report |
d9623ed
to
faa3aa8
Compare
Benchmark report |
llvm_points_to_bitfield
in SAW proofsllvm_points_to_bitfield
in SAW proofs
I've pushed a commit which adjusts the CI to use a nightly version of SAW that includes GaloisInc/saw-script#1539. The AWS CodeBuild BuildBatch us-west-2 (s2nIntegrationBatch) job now fails, but I'm not entirely sure why. |
It passed on a retry |
Benchmark report |
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 like the proofs now run in <3min with the newest version of SAW. Nice!
d817587
to
c457717
Compare
Benchmark report |
Benchmark report |
70db819
to
519d295
Compare
Benchmark report |
I must have bad luck with the CI lottery, since I can't seem to get the AWS CodeBuild BuildBatch us-west-2 (s2nGeneralBatch) job to pass. The job failure looks unrelated to the changes in this PR:
|
519d295
to
85a7fc8
Compare
Benchmark report |
With that rebase, all the CI jobs are finally green. Is there anything else that should be done before this can be merged? |
Added an approval, but it needs one more pass. |
Benchmark report |
4222905
to
8349387
Compare
Benchmark report |
Ah, OK! After rebasing once more, I've achieved another round of all-green CI jobs. |
Benchmark report |
This uses SAW's new `llvm_points_to_bitfield` command (introduced in GaloisInc/saw-script#1539) to simplify specifications that involve the bitfields in `s2n_config` and `s2n_connection`. In particular, there is no longer any need to manually compute the size of the bitfields or the indices of the fields within the bitfields, as these details are handled automatically by `llvm_points_to_bitfield`. The positions of the fields within bitfields are also no longer important. This addresses a review comment in aws#3079 (comment).
These comments are no longer relevant now that the SAW proofs use the `llvm_bitfield_points_to` command, which is insensitive to the order of fields within a bitfield.
60ea61c
to
8daaf93
Compare
Benchmark report |
8daaf93
to
18319fb
Compare
Benchmark report |
18319fb
to
63572d5
Compare
Benchmark report |
Hm. I keep encountering (seemingly transient) errors whenever I try to restart the CI. I've tried restarting about 3 times, but with no luck today. Any ideas on what might be causing this? |
Benchmark report |
Thanks, everyone! |
This bumps the `s2n` commit to GaloisInc/s2n@7f1017e, which points to the `llvm_points_to_bitfield` changes that were merged into the upstream `s2n-tls` repo in aws/s2n-tls#3155.
This bumps the `s2n` commit to GaloisInc/s2n@7f1017e, which points to the `llvm_points_to_bitfield` changes that were merged into the upstream `s2n-tls` repo in aws/s2n-tls#3155.
This bumps the `s2n` commit to GaloisInc/s2n@7f1017e, which points to the `llvm_points_to_bitfield` changes that were merged into the upstream `s2n-tls` repo in aws/s2n-tls#3155.
This bumps the `s2n` commit to GaloisInc/s2n@7f1017e, which points to the `llvm_points_to_bitfield` changes that were merged into the upstream `s2n-tls` repo in aws/s2n-tls#3155.
Resolved issues:
This concludes a line of discussion that was started as a review comment in #3079 (comment).
Description of changes:
The main commit in this PR is:
Use
llvm_points_to_bitfield
in SAW proofsThis uses SAW's new
llvm_points_to_bitfield
command (introduced in GaloisInc/saw-script#1539) to simplify specifications that involve the bitfields ins2n_config
ands2n_connection
. In particular, there is no longer any need to manually compute the size of the bitfields or the indices of the fields within the bitfields, as these details are handled automatically byllvm_points_to_bitfield
. The positions of the fields within bitfields are also no longer important.Call-outs:
handshake.saw
to What4-based tactics (e.g.,w4_unint_yices
), asllvm_points_to_bitfield
only supports What4-based tactics at present.handshake_io_lowlevel.saw
uses theenable_lax_loads_and_stores
SAW command, as that is required to makellvm_points_to_bitfield
work properly.Testing:
There is no real change in functionality in this PR, just refactoring. As a result, the existing SAW CI is sufficient to test these changes. The only change to the C code is to delete obsolete comments, which should have no change in behavior on the C side of things.
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.