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

Pre-update / post-update #28

Open
Calvin-L opened this issue May 9, 2018 · 0 comments
Open

Pre-update / post-update #28

Calvin-L opened this issue May 9, 2018 · 0 comments

Comments

@Calvin-L
Copy link
Collaborator

Calvin-L commented May 9, 2018

The query synthesizer should have visibility into whether it is performing its work before or after a change has been made to its underlying state.

Currently Cozy performs state maintenance for an update method by (1) inserting a hardcoded snippet and (2) generating some subgoals for the query synthesizer to optimize. These subgoals are always in terms of the original abstract state of the data structure---before the update has taken place. However, sometimes it is useful to perform the update afterwards. Consider this state:

theMin = min xs

and this update:

xs.remove(x)

We might desire an implementation such as:

heap.remove(x)
theMin = heap.peek()

However, Cozy cannot discover this, since the synthesizer will always see the original heap, before the removal has taken place.

@Calvin-L Calvin-L self-assigned this May 9, 2018
@Calvin-L Calvin-L removed their assignment Jul 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant