Skip to content

[SV-COMP'18 5/19] Abort concurrency encoding in possibly unsound cases #1994

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

Merged
merged 1 commit into from
Jun 14, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion regression/cbmc-concurrency/thread_chain_posix2/test.desc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
CORE
KNOWNBUG
main.c
-D_ENABLE_CHAIN_ --unwind 2
^EXIT=0$
Expand Down
2 changes: 1 addition & 1 deletion regression/cbmc-concurrency/thread_chain_posix3/test.desc
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
CORE
KNOWNBUG
main.c
-D_ENABLE_CHAIN_ -D_SANITY_CHECK_ --unwind 2
^EXIT=10$
Expand Down
8 changes: 6 additions & 2 deletions regression/cbmc/realloc3/test.desc
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
CORE
main.c

^EXIT=0$
^EXIT=6$
^SIGNAL=0$
^VERIFICATION SUCCESSFUL$
pointer handling for concurrency is unsound
--
^warning: ignoring
--
The test uses "__CPROVER_ASYNC_1:" and the async-called function foo does
pointer operations over allocated memory - which is not handled in a sound way
in CBMC.
4 changes: 4 additions & 0 deletions src/goto-symex/goto_symex_state.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,10 @@ void goto_symex_statet::assignment(
assert_l2_renaming(lhs);
assert_l2_renaming(rhs);

// see #305 on GitHub for a simple example and possible discussion
if(is_shared && lhs.type().id() == ID_pointer)
throw "pointer handling for concurrency is unsound";
Copy link
Member

Choose a reason for hiding this comment

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

Note: that should be turned into a user facing exception (not an invariant) during the error handling clean up.


// for value propagation -- the RHS is L2

if(!is_shared && record_value && constant_propagation(rhs))
Expand Down