Skip to content

Fixing issues #410 and #338#899

Merged
marcoeilers merged 4 commits into
masterfrom
meilers_fix_410_only
Feb 14, 2025
Merged

Fixing issues #410 and #338#899
marcoeilers merged 4 commits into
masterfrom
meilers_fix_410_only

Conversation

@marcoeilers

Copy link
Copy Markdown
Contributor

When inside a package statement, we have to always call the continuation, we cannot use shortcuts that just return Success(). If we do that, Silicon still continues verification after the package block, but it will not know that it has to continue with the heap from the infeasible branch.

Thus, this PR:

  • adds a new state entry which marks whether we are currently inside a package block (exhaleExt does not work for this because it's temporarily set to false e.g. when evaluating pure assertions)
  • changes the three places in the code that return Success() when in an infeasible branch s.t. verification continues, possibly with an unknown value if we're reading a field that we don't have permission to

@ArquintL ArquintL left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me; although, I must admit that I don't fully grasp the necessity of optimalSnapshotSort

@marcoeilers

Copy link
Copy Markdown
Contributor Author

Looks good to me; although, I must admit that I don't fully grasp the necessity of optimalSnapshotSort

Depending on what is in a predicate, its snapshot has a different sort (e.g. a predicate containing only a permission to an int field will have type int; if it contains multiple values, it'll be type snap). The fix needs us to continue verification when we're in an infeasible state when reading a resource we don't have any chunk of; to do that, we need to return a fresh value of the expected sort.

@marcoeilers marcoeilers merged commit ff4d359 into master Feb 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants