Skip to content

Support transparent procedures#45

Closed
keyboardDrummer-bot wants to merge 8 commits into
formatting-and-debugging-improvementsfrom
transparency-pass-only
Closed

Support transparent procedures#45
keyboardDrummer-bot wants to merge 8 commits into
formatting-and-debugging-improvementsfrom
transparency-pass-only

Conversation

@keyboardDrummer-bot

@keyboardDrummer-bot keyboardDrummer-bot commented May 8, 2026

Copy link
Copy Markdown
Collaborator

Depends on

Base PR for:

Changes

  • Change handling of free postconditions in Core so they do not show up, instead of showing up as passing proofs. This is useful in this PR because this PR is adding new usages of free postconditions.
  • Improve usage of source locations in the lifting phase, which improves diagnostics
  • For procedure without a source body, use free postconditions instead of assuming the non-free postconditions in a generated body.
  • Add the transparency pass. for each non-functional Core procedure, generate a function with the same signature and name suffixed with $asFunction. If a Core procedure is marked as transparent, attempt to generate a functional body for the $asFunction, where assertions are erased and all calls are to functional versions. Tie the functional version to the procedure using a free postcondition.
  • When translating an $asFunction function to Core, do not generate Core expressions that contains assertions, such as safe division or safe destructors. In a follow-up PR, we will merge Laurel functions and procedures, with both getting both a Core function and a Core procedures, and then we will never use Core functions/expression that contain assertions.
  • Refactored CoreGroupingAndOrdering to compute SCC ordering for functions and procedures separately. This is required because TransparencyPass creates a new AST type, UnorderedCoreWithLaurelTypes, where functions and procedures are already separated.

Testing

  • Updated T20_TransparentBody to account for new feature. In a follow-up we will have many more tests, because we'll convert all functions in tests to procedures.
  • Added T20_TransparentBodyError to capture some not supported cases

@keyboardDrummer keyboardDrummer changed the base branch from issue-21-assign-variable-type to main May 13, 2026 17:19
@github-actions github-actions Bot added Git conflicts PR has merge conflicts with the base branch and removed Git conflicts PR has merge conflicts with the base branch labels May 13, 2026
@keyboardDrummer keyboardDrummer force-pushed the transparency-pass-only branch from 284c852 to 7380f7c Compare May 14, 2026 08:40
@keyboardDrummer keyboardDrummer changed the base branch from main to transparencyPassBase May 14, 2026 08:44
@keyboardDrummer keyboardDrummer force-pushed the transparency-pass-only branch from ee8185b to bd66145 Compare May 14, 2026 08:50
@keyboardDrummer keyboardDrummer changed the title Add transparency pass (without contract and return elimination) Merge Laurel functions and procedures May 14, 2026
@keyboardDrummer keyboardDrummer changed the title Merge Laurel functions and procedures Unify Laurel functions and procedures May 14, 2026
@keyboardDrummer keyboardDrummer changed the title Unify Laurel functions and procedures Support contracts on functions May 15, 2026
@keyboardDrummer keyboardDrummer changed the title Support contracts on functions Support transparent procedures May 26, 2026
@github-actions github-actions Bot removed the Python label May 26, 2026
@keyboardDrummer keyboardDrummer force-pushed the transparency-pass-only branch from 021acfe to f246686 Compare May 26, 2026 10:04
@keyboardDrummer keyboardDrummer changed the base branch from transparencyPassBase to formatting-and-debugging-improvements May 26, 2026 10:05
@github-actions github-actions Bot added Python SMT GOTO dependencies Git conflicts PR has merge conflicts with the base branch labels May 26, 2026
@keyboardDrummer keyboardDrummer force-pushed the formatting-and-debugging-improvements branch from 26db19f to 7e34b04 Compare May 26, 2026 10:05
Repository owner deleted a comment from keyboardDrummer-bot May 26, 2026
@keyboardDrummer keyboardDrummer marked this pull request as ready for review May 26, 2026 11:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants