Chapter # 3: Multi-Level Combinational Logic
Chapter # 3: Multi-Level Combinational Logic
Chapter # 3: Multi-Level Combinational Logic
Randy H. Katz
University of California, Berkeley
June 1993
No. 3-1
Chapter Overview
• Multi-Level Logic
Conversion to NAND-NAND and NOR-NOR Networks
No. 3-2
Boolean Algebra
Commutative Laws:
a+b=b+a a •b = b •a
Associative Laws:
Identities:
a+0=a a •0 = 0
a•1=a a+1=1
Distributive Laws:
a + (b •c) = (a+b) •(b+c) a •(b+c) = (a •b) + (a •c)
No. 3-3
Boolean Algebra
Complement:
a+a=1 a •a = 0
a+a=a a •a = a
Theorems:
a + ab = a ab + ab = b
DeMorgan’s Theorem:
a •b = a + b a + b = a •b
No. 3-4
Multi-Level Logic: Advantages
Reduced sum of products form:
A
D 1
F
A
E 2
F
A
B B 1
D 3
C
F
B D
E 4 7 x E
2 3
4 x
F F
C G
D 5
F Factored form:
C
E 6 x = (A + B + C) (D + E) F + G
F
G 1 x 3-input OR gate, 2 x 2-input OR gates,
1 x 3-input AND gate
10 wires (7 literals plus 3 internal wires)
No. 3-5
OR/NAND
Equivalence
≡
A A B B A +B A• B A +B A •B A A
OR OR
0 1 0 1 0 0 1 1 B B
0 1 1 0 1 1 1 1
1 0 0 1 1 1 1 1
≡
1 0 1 0 1 1 0 0 A A
B Nand Nand
B
No. 3-6
Mult-Level Logic: Conversion Between Forms
AND/NOR
Equivalence
≡
A A B B A•B A+ B A•B A+B A A
AND AND
0 1 0 1 0 0 1 1 B B
0 1 1 0 0 0 0 0
1 0 0 1 0 0 0 0
≡
1 0 1 0 1 1 0 0 A A
B NOR NOR
B
No. 3-7
(A) A (B) A
B B AND
OR
C C
D D AND
(C) A (D) B
A
B
C C
D NAND D NAND
NAND NAND
No. 3-8
Example: Map AND/OR network to NAND/NAND network
NAND
A A
B B
Z Z
NAND
C C
NAND
D D
= (A • B) + (C • D) ¦
This is the easy conversion!
No. 3-9
A \A
\B NOR
B
Z Z
C NOR NOR
\C
D
\D
Conserve Conserve
"Bubbles" Step 1 Step 2 "Bubbles"
Z=
No. 3-10
Example: Map AND/OR network to NOR/NOR network
A \A
\B
B NOR
Z Z
C
NOR NOR
\C
D
\D
Step 1 Step 2
Conserve Conserve
"Bubbles" "Bubbles"
Z = {[(A' + B')' + (C' + D')']'}'
= (A • B) + (C • D)
NOR
NOR
NOR
Conserve
Bubbles
Verify equivalence
of the two forms Z=
No. 3-12
Example: Map OR/AND network to NOR/NOR network
NOR
NOR
NOR
Conserve
Bubbles
= (A + B) • (C + D)
Nand Nand
Nand
Conserve
Step 1 Step 2 Conserve
Bubbles! Bubbles!
No. 3-14
Example: Map OR/AND network to NAND/NAND network
Nand Nand
Nand
Step 1 Step 2
Conserve Conserve
Bubbles! Bubbles!
Z = {[(A' • B')' • (C' • D')']'}'
= (A + B) • (C + D)
C G1
D G3
Original B
AND-OR Network A G4 G5 F
B G2
\C
C
Introduction and D
G1
G3
G4
Conservation of Bubbles G5 F
B
A
B G2
\C
Redrawn in terms
C
of conventional D
G1 G3
NAND Gates G4 G5 F
\B
A
B
\C G2
No. 3-16
Multi-Level Logic: More than Two Levels
C
G1
G3
D G4 G5 F
B
A
Same beginning network
after introduction of
\B
bubbles
G2
C
\C
G1
\D G3 G4
G5
B F
\A
B G2
\C Final network, redrawn
in NOR-only form
No. 3-17
Conversion Example
A A
B F B F
C C
X X
D D
(a) Original circuit (b) Add double bubbles at inputs
A
X
A
B B
C F C F
\X \X
\D \D
(c) (d) Insert inverters to fix mismatches
Distribute bubbles
some mismatches
No. 3-18
Multi- Level Logic: AND-OR-Invert Block (AOI)
logical concept
A C
True
A
B B D Z
Z
C A B
D
False
C D
AND OR Invert
two-input two-stack
No. 3-19
&
2x2 AOI Schematic
+
Symbol &
&
3x2 AOI Schematic +
Symbol &
No. 3-20
Example: XOR implementation
(A' B + A B')'
(A + B') (A' + B)
(A B + A' B')
Example:
AB A F = B C' + A C' + A B
C 00 01 11 10
0 1 0 0 0 F' = A' B' + A' C + B' C
1 1 1 0 1
2-input 3-stack AOI gate
B
F K-map
F = (A + B) (A + C') (B + C')
F' = (B' + C) (A' + C) (A' + B')
2-input 3-stack OAI gate
No. 3-22
Example: 4-bit Equality Function
No. 3-23
Conservation of bubbles
No. 3-24
Multi-Level Logic: CAD Tools for Simplification
Multi-Level Optimization:
1. Factor out common sublogic (reduce fan-in, increase gate levels),
subject to timing constraints
Factored Form:
sum of products of sum of products . . .
A
•
B F1 X = (A B + B' C) (C + D (E + A C')) + (D + E)(F G)
+
B
•
•
C C
+F
D 2
• + X
E F5
+ F F4
A •
• G
D •
C +
E F3
No. 3-25
• Extraction
Manipulate network by interactively
issuing the appropriate instructions
• Factoring
There exists no algorithm that guarantees
"optimal" multi-level network will be
• Substitution obtained
• Collapsing
No. 3-26
Time Response in Combinational Networks
• emphasis on timing behavior of circuits
Terms:
gate delay - time for change at input to cause change at output
minimum delay vs. typical/nominal delay vs. maximum delay
careful designers design for the worst case!
rise time - time for output to transition from low to high voltage
fall time - time for output to transition from high to low voltage
No. 3-27
A' • A = 0
3 gate delays
No. 3-28
Another Pulse Shaping Circuit
+
Resistor
A B
Open C D
Switch
Initially undefined
No. 3-29
1 1
Static Input change causes output to
0 1-hazard go from 1 to 0 to 1
1
Static
0 0
0-hazard Input change causes output to
go from 0 to 1 to 0
1 1
0 0
Dynamic
Input change causes a double change
1 1 hazards from 0 to 1 to 0 to 1 OR
from 1 to 0 to 1 to 0
0 0
Kinds of Hazards
No. 3-31
Glitch Example A
AB
00 01 11 10
1 1 CD
A 1 A 1
G1 G1
\C
1
\C 1 00 0 0 1 1
1 G3 F 1 G3 F
\A 0 \A 0
G2 G2 01 1 1 1 1
D 0 D 0
0 0
D
ABCD = 1100 ABCD = 1101 11 1 1 0 0
C
input change within product term 10 0 0 0 0
F = A' D + A C'
1 0 0
A 1 A 0 A 0
G1 G1 G1
\C \C 0 \C 1
1 1 1 1
G3 F G3 F G3 F
\A 0 \A 0 \A 1
G2 G2 G2
D 0 D 0 D 1
1 1 1
A
AB
Re-express F in PoS form: CD
00 01 11 10
00 0 0 1 1
F = (A' + C')(A + D)
01 1 1 1 1
D
Glitch present! 11 1 1 0 0
C
Add term: (C' + D) 10 0 0 0 0
B
This expression is equivalent
to the hazard-free SoP form of F
No. 3-33
Glitch Example
= A C + C D' + A' D’
Example:
F = A B C + (A + D) (A' + C')
F1 = A B C + A A' + A C' + A' D + C' D 2-level form
A
AB
00 01 11 10
CD ABCD: 1111 to 1110, covered by term
00 0 0 1 1 ABC, so no 1-hazard present
01 1 1 1 1 ABCD: 1110 to 1100, term ABC goes low
D while term AC' goes high
11 1 1 1 0
C some static hazards are present!
10 0 0 1 0
B
No. 3-35
Static 1-hazards
Solution:
Add redundant terms to insure all adjacent
transitions are covered by terms
100
A
B
C
D
F
F2
1's hazards in F
corrected in F2
No. 3-36
Static 0-Hazards
Similar to previous case, but work with the complement of F
No. 3-37
Static 0-Hazards
100
A
B
C
D
F
F3
0-Hazard
Corrected in F3
No. 3-38
Designing Networks for Hazard-free operation
A F(A,B,C,D) = •m(1,3,5,7,8,9,12,13,14,15)
AB
00 01 11 10
CD
F = A B + A' D + B D + A C' + C' D
00 0 0 1 1
01 1 1 1 1
= (A' + B + C') D + A (B + C')
D
(factored by distributive law, which does not
11 1 1 1 0
introduce hazards since it does not depend on
C the complementarity laws for its validity)
10 0 0 1 0
No. 3-39
Dynamic Hazards
1 01
\A
G1
B
01
Slow G3
10 1 01
\B
G2 1 01 0
\C 10
1 G5 F
0
A 10
G4
\B
10
V ery slow
1. Description of Function
2. A function/truth table
3. A logic schematic with labeled I/Os
4. Boolean expression of function in terms of I/Os
5. Alternative package pint-outs
6. Internal transistor shcematics
7. Operating specifications
8. Recommended operating conditions
9. Electrical characteristics.
10. Switching characteristics.
No. 3-41
I OH : max current gate can supply to maintain volt of logic 1 (-0.4 mA)
I OL: min current gate can supply to maintain volt of logic 0 (8 mA)
No. 3-42
Electrical Characteristics: voltages and currents that can
be observed at the inputs and outputs.
V OH : min output high volt (2.7v min, 3.4v typical)
V OL: max output low volt (0.4v max, 0.25v typical)
No. 3-44
Technology Metrics
SSI: up to 10 gates
MSI: up to 100 gates (not important)
LSI / VLSI: up to 1000 gates (MOS has advantage)
No. 3-45