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

uc-crux-llvm: Specify function postconditions #981

Merged
merged 17 commits into from
May 18, 2022
Merged

Conversation

langston-barrett
Copy link
Contributor

The Postcondition module declares a type that approximates a specification of a function's postconditions. This is used in Classify to infer such postconditions on return values, in the future it may be used to infer information about clobbered memory.

Also implement some additional pretty-printing machinery.

This is based on top of #980, which it requires. We could merge that first and rebase this, or just merge this.

@travitch
Copy link
Contributor

I think this would probably be quite a bit easier to review if we merge #980 first and then rebase - could we give that a try?

@langston-barrett
Copy link
Contributor Author

Absolutely! Would you mind giving that one a look then?

The Postcondition module declares a type that approximates a
specification of a function's postconditions. This is used in Classify
to infer such postconditions on return values, in the future it may be
used to infer information about clobbered memory.

This module supersedes the "Clobber" specs that were part of the Skip
override machinery. These weren't amenable to use-cases such as
inference.

Also implement some additional pretty-printing machinery.
@langston-barrett
Copy link
Contributor Author

@travitch Rebased!

uc-crux-llvm/src/UCCrux/LLVM/Constraints.hs Outdated Show resolved Hide resolved
uc-crux-llvm/src/UCCrux/LLVM/FullType/PP.hs Outdated Show resolved Hide resolved
uc-crux-llvm/src/UCCrux/LLVM/FullType/CrucibleType.hs Outdated Show resolved Hide resolved
uc-crux-llvm/src/UCCrux/LLVM/FullType/CrucibleType.hs Outdated Show resolved Hide resolved
uc-crux-llvm/src/UCCrux/LLVM/Postcondition/Type.hs Outdated Show resolved Hide resolved
uc-crux-llvm/src/UCCrux/LLVM/Precondition.hs Outdated Show resolved Hide resolved
Weirdly, GHC 9 doesn't seem to like how these were written. Change to something
equivalent.
@langston-barrett langston-barrett merged commit 40995e2 into master May 18, 2022
@langston-barrett langston-barrett deleted the lb/postcond branch May 18, 2022 19:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
uc-crux Issues specific to under-constrained crux
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants