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

Heap-zones: fixing one variable in a difference row causes the other one to be fixed, too. #131

Open
viktormalik opened this issue Oct 15, 2018 · 2 comments

Comments

@viktormalik
Copy link
Collaborator

viktormalik commented Oct 15, 2018

If one variable is a standalone variable that occurs in a condition of a loop, and the other variable is a field of a dynamic object, values of all fields of all objects represented by the given abstract dynamic objects may be fixed for the rest of the program.
For example:

while (nondet && !mark) {
    x = malloc(...);
    mark = nondet ? 1 : 0;
    x->val = mark;
}
assert(head->val == 0)

Since mark occurs in the while condition, SSA contains mark==0 for the code after the loop. Also, heap-zones domain computes dynamic_object$0.val - mark == 0, which causes dynamic_object$0.val to be equal to 0 and the assertion is wrongly evaluated as true.

@viktormalik
Copy link
Collaborator Author

I suggest we check for variables occurring in conditions of loops (or maybe in conditions in general) and then forbid any difference template rows that use such variables with fields of abstract dynamic objects to be used in the rest of the program.

@viktormalik
Copy link
Collaborator Author

@peterschrammel Can you please assign the issue to me? Or you can give me a permission to assign people to issues, so I can do it myself.

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

No branches or pull requests

1 participant