Title: Example: Verification
1Example Verification
e.g., input/output specification of multiplier
e.g., multi-level logic representation
2Binary Decision Diagrams
Graph-based Representation of Boolean Functions
- Introduced by Lee (1959).
- Popularized by Bryant (1986).
- compact (functions of 50 variables)
- efficient (linear time manipluation)
Widely used has had a significant impact on the
CAD industry.
3Binary Decision Diagrams
Graph-based Representation of Boolean Functions
1
0
BDD is defined as Directed Acyclic Graph
0
0
1
1
4Analysis of Digital Circuits
Large domain, small range.
inputs
5Analysis of Digital Circuits
Large domain, small range.
inputs
2m possibilities
2 possibilities
6Data Structures
Truth Tables
Example
4 rows
2 variables
8 rows
3 variables
264 rows
64 variables
7Data Structures
Decision Diagrams
Example
x1
x2
x3
f
0
0
0
0
0
0
1
0
0
1
0
0
0
1
1
1
1
0
0
0
1
0
1
1
1
1
0
0
1
1
1
1
8Data Structures
Decision Diagrams
Optimize by merging nodes
x3
x3
x3
x3
9Data Structures
Decision Diagrams
S
Optimize by merging nodes
x1
1
0
x2
1
x3
x3
x3
0
1
0
1
1
10Data Structures
Decision Diagrams
Optimize by merging nodes
x2
x2
11Data Structures
Decision Diagrams
S
Optimize by merging nodes
x1
0
x2
1
0
x3
1
0
12Data Structures
Logic Operations
AND
13Decision Diagrams
Properties
- Canonical unique up to variable ordering
- Compact represent functions of up to 1000
variables - Efficient perform logic operations in
linear-time
14Ordered Binary Decision Diagrams
(a.k.a. Branching Programs)
Example
Directed Acyclic Graph variables are inspected
in order.
15Reducing OBDDs
Terminal Rule eliminate duplicate terminals.
16Reducing OBDDs
Elimination Rule eliminate a node if its 0 and
1 edges lead to the same node.
17Reducing OBDDs
Merging Rule merge two nodes that reference
the same variable and point to the same
successors.
18Reduced OBDDs
Question
What is the optimal strategy for eliminate and
merge operations?
19Reduced OBDDs
Strategy eliminate and merge nodes repeatedly,
in any order, until no further simplifications
are possible.
Is the result unique?
20Uniqueness (proof)
By induction on the number of variables.
Induction Hypothesis Assume that any two ROBDDs
for a function with k 1 variables, k gt 0, are
isomorphic.
Inductive Step Show that any two ROBDDs for a
function with k variables are isomorphic.
21Inductive Step
22Inductive Step
Show that this mapping is well-defined and
one-to-one.
23Inductive Step
24Mapping Well-Defined
low(v)
high(v)
Counter Example (Unreduced BDDs)
25Mapping One-To-One
Counter Example (Unreduced BDDs)
26Logic Operations
27Logic Operations
28Logic Operations
Compute
0
1
0
1
29Logic Operations
30Logic Operations
31Logic Operations
32Logic Operations
33Logic Operations
0
1
34Logic Operations
0
1
35Logic Operations
0
1
36Logic Operations
0
1
37Logic Operations
Simplify
0
1
38Logic Operations
Simplify
39Variable Ordering