Skip to content

Commit c420544

Browse files
author
Enrico Steffinlongo
committed
Add README.md for new incremental smt backend
1 parent 22fec4c commit c420544

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# Incremental SMT backend
2+
3+
CBMC comes with a solver-agnostic incremental SMT backend.
4+
5+
The SMT incremental backend supports the following `C` features:
6+
7+
- Integers (via Bit vector arithmetics)
8+
- Pointers
9+
- Arrays (support is currently incomplete)
10+
11+
Primitive not supported are:
12+
13+
- Floating point values and arithmetics
14+
- Structs
15+
16+
Usage of the incremental SMT backend requires a SMT solver compatible with
17+
incremental SMTlib v2.6 formatted input from the standard input and that
18+
supports the `QF_AUFBV` (Quantifier Free Array Uninterpreted Functions and Bit
19+
Vectors) logic.
20+
21+
To use this functionality it is enough to add the argument
22+
`--incremental-smt2-solver <cmd>` where `<cmd>` is the command to invoke the SMT
23+
solver of choice using the incremental mode and accepting input from the
24+
standard input.
25+
26+
Examples of invocations with various solvers:
27+
28+
1. `--incremental-smt2-solver 'z3 -smt2 -in'` to use the Z3 solver.
29+
2. `--incremental-smt2-solver 'cvc5 --lang=smtlib2.6 --incremental'` to use the
30+
CVC5 solver.
31+
32+
The new incremental SMT backend has been designed to interoperate with external
33+
solvers, so the solver name must be in the `PATH` or an executable with full
34+
path must be provided.
35+
36+
Due to lack of support for conversion of `array_of` expressions that are added
37+
by CBMC in the before the new SMT backend is invoked, it is necessary to supply
38+
an extra argument `--slice-formula` so that instances of `arrayof_exprt` are
39+
removed from the formula to be converted.
40+
41+
As we move forward with our array-support implementation, we anticipate that the
42+
need for this extra flag will be diminished.

0 commit comments

Comments
 (0)