SAT vs SMT solvers: the engines inside formal verification
This article is part of our formal verification guide, which covers the foundations, model checking, solvers, theorem proving, equivalence checking and industry use cases.
Nearly every automatic formal tool ends up asking a solver a question: "can this formula be true?" SAT solvers answer it for pure Boolean formulas; SMT solvers answer it for formulas over richer data such as bit-vectors, arrays and integers. Understanding the difference helps you understand why some proofs are fast and others never finish.
SAT: Boolean satisfiability
A SAT problem is a Boolean formula, usually in conjunctive normal form (an AND of clauses, each an OR of literals). The solver either finds values for the variables that make every clause true, or reports that none exist.
(a OR b) AND (NOT a OR c) AND (NOT b OR NOT c)
-> satisfiable, e.g. a = 1, b = 0, c = 1SAT was the first problem proven NP-complete (Cook, 1971), so no known algorithm is fast on every instance. Yet industrial instances have structure that modern solvers exploit extremely well.
How a CDCL solver works
- Decide: pick an unassigned variable and guess a value.
- Propagate: clauses with one unassigned literal force that literal (unit propagation).
- Conflict: if a clause becomes false, analyse why, and learn a new clause that prevents the same combination of decisions from ever being tried again.
- Backjump: undo several decisions at once, not just the last one, and continue.
Clause learning, efficient data structures and restarts — refined from the late 1990s onwards — took SAT from academic curiosity to the backbone of hardware verification. The lesson SAT solving in a nutshell walks through an example.
SMT: satisfiability modulo theories
Hardware and software are not naturally Boolean: they have 32-bit adders, memories and integer counters. Encoding those as individual bits ("bit-blasting") works but loses structure. An SMT solver combines a SAT engine with theory solvers that reason directly about richer data:
| Theory | Reasons about | Typical use |
|---|---|---|
| Bit-vectors (QF_BV) | Fixed-width machine words: +, *, shifts, comparisons with wrap-around | Hardware, binaries, smart contracts |
| Arrays | Memories: read(write(m, a, v), a) = v | Memories, register files, storage maps |
| Linear integer / real arithmetic | Sums and inequalities over unbounded numbers | Software loops, timing, scheduling |
| Uninterpreted functions | Only "equal inputs give equal outputs" | Abstracting datapaths (see data abstraction) |
Problems are exchanged in the standard SMT-LIB format, so the same query can be sent to different solvers:
(set-logic QF_BV)
(declare-const x (_ bv8))
(declare-const y (_ bv8))
(assert (= (bvadd x y) #x00)) ; x + y wraps to zero
(assert (not (= x #x00)))
(check-sat) ; sat, e.g. x = #x01, y = #xff
(get-model)SAT vs SMT at a glance
| SAT | SMT | |
|---|---|---|
| Input | Boolean clauses (CNF) | First-order formulas over theories |
| Level | Bits | Words, arrays, numbers |
| Strength | Raw speed on huge Boolean problems | Compact encodings, structure-aware reasoning |
| Weak spot | Large arithmetic once bit-blasted | Some theory combinations (e.g. non-linear integer arithmetic) are hard or undecidable |
| Examples | MiniSat-family solvers, CaDiCaL, Kissat | Z3, cvc5, Yices, Bitwuzla |
Where solvers are used
- Hardware model checking: BMC and k-induction pose one solver query per depth — see
BMC vs k-induction. SymbiYosys's
smtbmcengine talks SMT-LIB to solvers such as Yices or Z3. - Equivalence checking: each pair of compared logic cones becomes a SAT question: "can the outputs differ?"
- Software verification and symbolic execution: path conditions become SMT queries.
- Smart contracts: 256-bit EVM words map naturally to bit-vector theory — see formal verification for smart contracts.
Why your proof is slow: solver-level reasons
- Multipliers and dividers are notoriously hard for both SAT and bit-vector SMT. Abstract them when the property is about control.
- Deep unrolling multiplies formula size by the depth. Make properties inductive instead.
- Wide data that the property does not depend on adds variables for nothing. Reduce widths when the design is data-independent.
Solvers are the foundation of most of the techniques in our complete formal verification guide.