Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
126 commits
Select commit Hold shift + click to select a range
6a16371
all commits of old branch
Apr 23, 2016
74d5022
all commits of old branch
Apr 23, 2016
1a0174b
all commits of old branch
Apr 23, 2016
dad32a4
merged comp-kind-old
Apr 23, 2016
772f34f
fixed compilation errors after merge
Apr 23, 2016
c6f5f77
fixed ssa_unwinder bug
kumarmadhukar Apr 24, 2016
b5e4fd3
use cex analyser concrete with --inline
Apr 25, 2016
69f7d4d
Merge pull request #1 from peterschrammel/comp-kind
kumarmadhukar Apr 25, 2016
2fa037e
made sure that the executable is named 2ls
Apr 25, 2016
553bcd2
Merge pull request #2 from peterschrammel/comp-kind
kumarmadhukar Apr 25, 2016
ab95c3a
fixed ssa_unwinder bug (#1)
kumarmadhukar Apr 26, 2016
fe10936
fixed warning from comparing unsigned with long
kumarmadhukar Apr 26, 2016
a56186f
bug fixes for abstract case
kumarmadhukar Apr 26, 2016
a26facd
Merge pull request #2 from kumarmadhukar/comp-kind
peterschrammel Apr 26, 2016
d936759
loop-specific unwinding code, in progress
kumarmadhukar Apr 26, 2016
d817661
minor spelling correction
kumarmadhukar Apr 26, 2016
92037fc
commented new code to check loop-specific unwinding
kumarmadhukar Apr 27, 2016
8f77de9
commented debug code
kumarmadhukar Apr 27, 2016
eea322b
corrected the id generator for #arg
kumarmadhukar Apr 27, 2016
de80c29
put unwinding suffix into ID_suffix attribute
Apr 28, 2016
26fe4d8
Merge branch 'comp-kind' of github.com:peterschrammel/2ls into comp-kind
Apr 28, 2016
6bd7c93
Merge pull request #3 from peterschrammel/comp-kind
kumarmadhukar May 2, 2016
85a5f65
collect nondet vars in local_SSA
May 11, 2016
bf27eda
add nondets as OUT vars to summary template for backwards analysis
May 11, 2016
138c575
fixed various places where nondet_symbols in templates were not expected
May 11, 2016
728346a
Merge pull request #4 from peterschrammel/comp-kind
kumarmadhukar May 12, 2016
348cdc7
added a comment for new fields in loopt
kumarmadhukar May 13, 2016
895e97e
fixes to replace_globals when inlining
May 13, 2016
6482398
nondet locals only once
May 13, 2016
ec54dce
fixed filtering of non-violating assertion instances before running s…
May 13, 2016
e7870fc
modified loop-specific unwinder to iterate over all loops
kumarmadhukar May 16, 2016
3b4ea1d
selective unwinding code
kumarmadhukar May 20, 2016
75c55eb
output unsat core for spurious cex, uses incremental solver debug fac…
May 20, 2016
55bbe1d
Merge branch 'comp-kind' of https://github.com/peterschrammel/2ls int…
kumarmadhukar May 21, 2016
4768793
Merge branch 'peterschrammel-comp-kind' into selective-unwind
kumarmadhukar May 21, 2016
b2f574f
Srivas' examples
May 23, 2016
b7cb93f
Merge pull request #6 from peterschrammel/comp-kind
kumarmadhukar May 23, 2016
d8577d3
moved assertion into bar()
May 23, 2016
8a79cbd
Merge pull request #7 from peterschrammel/comp-kind
kumarmadhukar May 23, 2016
c9e59c8
recompute dependency graphs after unwinding
May 23, 2016
fd451e1
fixed renaming of nondets on inlining
May 23, 2016
6a99d32
propagate nondets in error summaries up to entry point
May 23, 2016
4ebc661
fixed use of ssa_expr in trace output
May 23, 2016
877fc77
minor bug fixes
kumarmadhukar May 24, 2016
5583220
Merge branch 'comp-kind' of https://github.com/peterschrammel/2ls int…
kumarmadhukar May 24, 2016
684519a
unsat core output (without using incremental solver debug mode)
May 25, 2016
c71f093
get reason for spuriousness
May 25, 2016
3b710f9
Merge pull request #9 from peterschrammel/comp-kind
kumarmadhukar May 25, 2016
43714a8
to start with, add all functions and loop ids to reason
May 26, 2016
5c9c8ba
Merge pull request #10 from peterschrammel/comp-kind
kumarmadhukar May 26, 2016
db80f3c
reason grouped by functions; identify callee by call site location
May 26, 2016
5507f85
Merge pull request #11 from peterschrammel/comp-kind
kumarmadhukar May 26, 2016
25a27f9
selective unwinding and inlining code - in progress
kumarmadhukar May 27, 2016
62d56ae
code for unwinding and inlining
kumarmadhukar May 27, 2016
1828bb9
minor fix in inlining code
kumarmadhukar May 28, 2016
98bf653
more k-induction tests
May 28, 2016
10559ea
spurious check refactoring started
May 28, 2016
3a76512
Merge pull request #4 from kumarmadhukar/selective-unwind
peterschrammel May 28, 2016
fc0720a
refactoring done, except loop continuations
May 28, 2016
9bf9cc6
Merge branch 'spurious-check-refactoring' into comp-kind
May 28, 2016
cccda17
loop-specific continuation conditions
May 28, 2016
320b3a4
update enable_expr after 0th unwinding
May 28, 2016
c72193e
concrete only complete with inline
May 28, 2016
df6421b
Merge pull request #12 from peterschrammel/comp-kind
kumarmadhukar May 29, 2016
82a1d1b
take into account enabling_expr in depgraph construction
May 29, 2016
10624d4
Merge pull request #13 from peterschrammel/comp-kind
kumarmadhukar May 29, 2016
1fdcb57
fixed all no-cex regressions for complete
May 29, 2016
f41279f
Merge pull request #14 from peterschrammel/comp-kind
kumarmadhukar May 29, 2016
96e9549
factor out SSA refinements into separate classes
May 29, 2016
e6581d9
Merge pull request #15 from peterschrammel/comp-kind
kumarmadhukar May 29, 2016
0598f08
unwind output one-off
May 29, 2016
84eef10
flag functions as inlined and debug output in ssa_refiner about what …
May 29, 2016
9c70e4f
recursive gathering of summaries and inlined functions
May 29, 2016
f554e49
basic unsat-core based refinement selection
May 29, 2016
e2938a0
todo: loophead selects and continuation expressions must be recursive…
May 29, 2016
bec9752
Merge pull request #16 from peterschrammel/comp-kind
kumarmadhukar May 30, 2016
3e291ed
unwind value propagation bug fixed
kumarmadhukar May 30, 2016
1b24bbd
fully-unwound check fixed as far as possible
May 30, 2016
c3aef77
Merge pull request #17 from peterschrammel/comp-kind
kumarmadhukar May 30, 2016
83264b5
unwind value propagation bug fixed (#5)
kumarmadhukar May 30, 2016
74a25b2
check whether function has assertion was too semantic, we needed to s…
May 30, 2016
2a73af4
Merge pull request #18 from peterschrammel/comp-kind
kumarmadhukar May 30, 2016
e73b482
loop enabling expr fixed
May 30, 2016
23a589f
loop enabling expr fixed, removed superfluous variables
May 30, 2016
90c1a2e
Merge pull request #19 from peterschrammel/comp-kind
kumarmadhukar May 30, 2016
1b76b2a
unwind value propagation bug fixed (#6)
kumarmadhukar May 30, 2016
fe07b2c
signed/unsigned comparison fixed
May 30, 2016
540ed6a
Merge pull request #20 from peterschrammel/comp-kind
kumarmadhukar May 30, 2016
6548e30
missing regressions
May 30, 2016
c0e239b
Merge pull request #21 from peterschrammel/comp-kind
kumarmadhukar May 30, 2016
f81fa0d
simplified example that exposes problem with monolithic --k-induction…
May 30, 2016
16cdbd6
wrong assertions feeded into cex checker; output assignments in incre…
May 30, 2016
746b189
Merge pull request #22 from peterschrammel/comp-kind
kumarmadhukar May 30, 2016
9eb2e6b
collecting renamed error assertions - still some of them are missed
May 30, 2016
41585e1
Merge pull request #23 from peterschrammel/comp-kind
kumarmadhukar May 30, 2016
53bc2ff
assertion renaming in cex_complete fixed
May 30, 2016
9ff3c62
be more robust w.r.t. functions that are not in the SSA db
May 30, 2016
331bafc
assumptions must hold in backwards analysis
May 30, 2016
1dcdecb
clean up summary_checker_base
May 30, 2016
d16b72e
check for inlined functions whether they have assertions
May 30, 2016
7c58c7a
recursively collect assertions from inlined functions through inliner
May 30, 2016
196db09
sync
May 30, 2016
e2633fb
Merge pull request #24 from peterschrammel/comp-kind
kumarmadhukar May 31, 2016
65a2261
depgraph renaming problem fixed
May 31, 2016
cbc7851
Merge pull request #25 from peterschrammel/comp-kind
kumarmadhukar May 31, 2016
544afa5
inlined functions must not contain negated assertions; assertions are…
May 31, 2016
d329abf
Merge pull request #26 from peterschrammel/comp-kind
kumarmadhukar May 31, 2016
2da8de3
regression tests refactored
May 31, 2016
818ca57
Merge pull request #27 from peterschrammel/comp-kind
kumarmadhukar May 31, 2016
eeee97a
partial upgrade to new cbmc version
Sep 17, 2016
2d17dbb
soon compiles with CBMC master
Sep 17, 2016
af9b845
bounds simplification
peterschrammel Sep 18, 2016
faf3f18
merge
Sep 17, 2016
2d3559b
merge
Sep 17, 2016
f32b3c2
bounds simplification
peterschrammel Sep 18, 2016
87b3310
missing summarizer_languages file
peterschrammel Sep 18, 2016
b128ce5
merge
nsv2020 Sep 18, 2016
3ec7bbb
Merge branch 'compile-with-cbmc-master' of github.com:diffblue/2ls in…
nsv2020 Sep 18, 2016
8a6e4a1
Merge branch 'comp-kind' of https://github.com/kumarmadhukar/2ls into…
nsv2020 Sep 18, 2016
3420966
after rebase
kumarmadhukar Apr 4, 2017
c454929
added spurious check option
kumarmadhukar Apr 17, 2017
c098fb6
Remove duplicate option
peterschrammel May 3, 2017
cecd690
Synchronise install script
peterschrammel May 3, 2017
0ec33ec
Fix regression test makefiles
peterschrammel May 3, 2017
b510dcd
same as ps comp-kind branch
kumarmadhukar Jun 28, 2017
c60433c
fixed spurious-check options
kumarmadhukar Jun 28, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
4 changes: 2 additions & 2 deletions COMPILING
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
2LS 0.4
2LS 0.5

./install.sh

The executable is src/summarizer/2ls
The executable is src/2ls/2ls

21 changes: 21 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
[![Build Status][build_img]][travis]

About
=====

2LS is a verification tool for C programs. It is built upon the
CPROVER framework ([cprover.org](http://www.cprover.org)), which
supports C89, C99, most of C11 and most compiler extensions provided
by gcc and Visual Studio. It allows verifying array bounds (buffer
overflows), pointer safety, exceptions, user-specified assertions, and
termination properties. The analysis is performed by template-based
predicate synthesis and abstraction refinements techniques.

For more information see [cprover.org](http://www.cprover.org/2LS).

License
=======
4-clause BSD license, see `LICENSE` file.

[build_img]: https://travis-ci.org/diffblue/2ls.svg?branch=master
[travis]: https://travis-ci.org/diffblue/2ls
4,776 changes: 0 additions & 4,776 deletions doc/deltacheck_logo.ai

This file was deleted.

Binary file removed doc/deltacheck_logo_large.png
Binary file not shown.
Binary file removed doc/deltacheck_logo_small.png
Binary file not shown.
9 changes: 0 additions & 9 deletions doc/deltacheck_logo_small_html.html

This file was deleted.

36 changes: 28 additions & 8 deletions install.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,33 @@
git clone https://github.com/diffblue/cbmc
#!/bin/bash

CBMC_REPO=https://github.com/peterschrammel/cbmc
CBMC_VERSION=d95e7da28018fd315b04a1201d5b7cfe8195cbc6

if [ "$1" != "" ]
then
COMPILER="$1"
fi

git clone $CBMC_REPO
cd cbmc
CBMC=`pwd`
git checkout e4a5a611f569c72f97c0e099e56a827c9a55d2aa
cd src
make minisat2-download
make
cd ../../src
git checkout $CBMC_VERSION
make -C src minisat2-download
if [ "$COMPILER" != "" ]
then
make -C src CXX=$COMPILER
else
make -C src
fi

cd ../src
cp config.inc.template config.inc
sed -i.bak "s#CBMC = ~/my-cbmc#CBMC = $CBMC#g" config.inc
make
if [ "$COMPILER" != "" ]
then
make CXX=$COMPILER
else
make
fi
cd ..
echo "The executable is src/summarizer/2ls"
echo "The executable is src/2ls/2ls"
4 changes: 2 additions & 2 deletions regression/interprocedural/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ default: tests.log
FLAGS = --verbosity 10

test:
@../test.pl -c "../../../src/summarizer/2ls $(FLAGS)"
@../test.pl -c "../../../src/2ls/2ls $(FLAGS)"

tests.log: ../test.pl
@../test.pl -c "../../../src/summarizer/2ls $(FLAGS)"
@../test.pl -c "../../../src/2ls/2ls $(FLAGS)"

show:
@for dir in *; do \
Expand Down
34 changes: 17 additions & 17 deletions regression/interprocedural/contextsensitive1/main.c
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
int sign(int x)
{
if(x>0) return 1;
else if (x==0) return 0;
return -1;
}
void main()
{
int x = 1;
int y = sign(x);
x = -x;
int z = sign(x);
assert(-1<=y && y<=1 && -1<=z && z<=1);
}

int sign(int x)
{
if(x>0) return 1;
else if (x==0) return 0;
return -1;
}

void main()
{
int x = 1;
int y = sign(x);
x = -x;
int z = sign(x);
assert(-1<=y && y<=1 && -1<=z && z<=1);
}

56 changes: 28 additions & 28 deletions regression/interprocedural/contextsensitive2/main.c
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
int sign(int x)
{
if(x>0) return 1;
else if (x==0) return 0;
return -1;
}
int do1(int x)
{
return sign(x);
}
int do2(int x)
{
return sign(x);
}
void main()
{
int x = 1;
int y = do1(x);
assert(y==1);
x = -x;
int z = do2(x);
assert(-1<=z && z<=1);
}

int sign(int x)
{
if(x>0) return 1;
else if (x==0) return 0;
return -1;
}

int do1(int x)
{
return sign(x);
}

int do2(int x)
{
return sign(x);
}

void main()
{
int x = 1;
int y = do1(x);
assert(y==1);
x = -x;
int z = do2(x);
assert(-1<=z && z<=1);
}

56 changes: 28 additions & 28 deletions regression/interprocedural/contextsensitive3/main.c
Original file line number Diff line number Diff line change
@@ -1,28 +1,28 @@
int sign(int x)
{
if(x>0) return 1;
else if (x==0) return 0;
return -1;
}
int do1(int x)
{
return sign(x);
}
int do2(int x)
{
return sign(x);
}
void main()
{
int x = 1;
int y = do2(x);
assert(y==1);
x = -x;
int z = do1(x);
assert(-1<=z && z<=1);
}

int sign(int x)
{
if(x>0) return 1;
else if (x==0) return 0;
return -1;
}

int do1(int x)
{
return sign(x);
}

int do2(int x)
{
return sign(x);
}

void main()
{
int x = 1;
int y = do2(x);
assert(y==1);
x = -x;
int z = do1(x);
assert(-1<=z && z<=1);
}

58 changes: 29 additions & 29 deletions regression/interprocedural/contextsensitive4/main.c
Original file line number Diff line number Diff line change
@@ -1,29 +1,29 @@
int x = 1;
int sign(int x)
{
if(x>0) return 1;
else if (x==0) return 0;
return -1;
}
int do1(int x)
{
return sign(x);
}
int do2(int x)
{
return sign(x);
}
void main()
{
int y = do1(x);
assert(y==1);
x = -x;
int z = do2(x);
assert(-1<=z && z<=1);
}

int x = 1;

int sign(int x)
{
if(x>0) return 1;
else if (x==0) return 0;
return -1;
}

int do1(int x)
{
return sign(x);
}

int do2(int x)
{
return sign(x);
}

void main()
{
int y = do1(x);
assert(y==1);
x = -x;
int z = do2(x);
assert(-1<=z && z<=1);
}

30 changes: 15 additions & 15 deletions regression/interprocedural/contextsensitive5/main.c
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
#include <stdlib.h>
void foo(int* x)
{
assert(x!=NULL);
*x = 0;
}
void main()
{
int x;
int *y = &x;
foo(y);
}
#include <stdlib.h>

void foo(int* x)
{
assert(x!=NULL);
*x = 0;
}

void main()
{
int x;
int *y = &x;
foo(y);
}

24 changes: 12 additions & 12 deletions regression/interprocedural/contextsensitive6/main.c
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
void foo(int x)
{
assert(x!=0);
}
void main()
{
int x = 1;
foo(x);
}

void foo(int x)
{
assert(x!=0);
}

void main()
{
int x = 1;
foo(x);
}

Loading