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

Implement a per-allocation-site memory-safety checking #768

Open
shaobo-he opened this issue Nov 17, 2021 · 0 comments
Open

Implement a per-allocation-site memory-safety checking #768

shaobo-he opened this issue Nov 17, 2021 · 0 comments

Comments

@shaobo-he
Copy link
Contributor

Motivation

Currently, we only have one bookkeeping variable $Alloc for the entire program. We can split it into multiple bookkeep variables such that one variable roughly corresponds to one allocation site (i.e., a call to malloc or an alloca instruction). Having multiple bookkeeping variables reduces the solver's burden to reason about arrays.

Implementation Plan

The key idea to implement this feature is to id allocation sites and find out which allocate sites a pointer is associated with.

However, an implication of having multiple bookkeeping variables is that we have to change the signature of $alloca, malloc, or __SMACK_check_memory_safety procedures since they check/constrain/update different variables.

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