Iitb Atpg Slides
Iitb Atpg Slides
Introduction
Virendra Singh
Associate Professor
Computer Architecture and Dependable Systems Lab
Department of Electrical Engineering
Indian Institute of Technology Bombay
http://www.ee.iitb.ac.in/~viren/
E-mail: [email protected]
Determine requirements
Write specifications
Test development
Fabrication
Manufacturing test
Chips to customer
=e −λ x
Die Yield
=e −λ
Die Yield x
λ = Average number x x
x
of defects per Die
x x x
= Defect Density x
x Die Area
x x
x
Yield = 1/e (37%) for λ = 1
Defect Density ~ 0.5 defects/sq cm
Largest Die are ~ 2 sq cms
(b)
(c)
A
A
A
Z Z Z
L1 L1
L1 L1
L2 L2
L2 L2
(a ) (b )
(a ) (b )
S tu c k - a t 1 S tu c k -a t 0
V d d S tu c k -a t 1 G N D S tu c k -a t 0
V dd G N D
(c )
(c )
B r id g in g F a u lt
B r id g in g F a u lt
(d )
(d )
Shorts 51
Opens 1
Missing components 6
Wrong components 13
Reversed components 6
Bent leads 8
Analog specifications 5
Digital logic 5
Performance (timing) 5
Ref.: J. Bateson, In-Circuit Testing, Van Nostrand Reinhold, 1985.
Mode Duration
Transient
Intermittent
f k
Test vector for h s-a-0 fault
sa0 sa1
NOT
sa1 sa0
s-a-1
s-a-1
s-a-0
A dominance collapsed fault set
Checkpoints ( ) = 10
x2 x2 x2
x3 x3 x3 x3 x3
0 0 0 1 0 1 0 1 0 1
0 1 0 1
b1 a2 a2
a2 a3 a3 a3 a3
b2 b1 b1 b1 b1
a3 b2 b2
b3 b3
0 1 0 1
Linear Growth Exponential Growth
• Application-Based Heuristics
Exploit characteristics of application
e.g., Ordering for functions of combinational circuit
Traverse circuit graph depth-first from outputs to
inputs
Assign variables to primary inputs in order
encountered
Jan 28, 2012 EE-709@IITB 5 CADSL
Sample Function Classes
General Experience
Many tasks have reasonable OBDD
representations
Algorithms remain practical for up to 500,000 node
OBDDs
Heuristic ordering methods generally satisfactory
X OP X
X1
X1
+
BDD for BDD for
f1|x1=0 OP f2 f1|x1=1 OP f2
f1=X1XNOR X2
f2=X’2
BDD for + =
=
f1|x1=0 OP f2
X1
=
OP
BDD for BDD for
f1|x1=0 OP f2 f1|x1=1 OP f2
f1=X1XNOR X2
f2=X’2
= =
G1 G4
G3
X2
X1 X1 X1 X1 X1
1 0 1 0 0 1 0 1
0 1
X2 X2 X2 X2 X2 X2
1 0 1 0 1 1
0 1 0 1 0 0
0 1 0 1 0 1 0 1 0 1 0 1
• Challenge
– Must prove all assignments fail
• Co-NP complete problem
– Typically explore significant
fraction of inputs
– Exponential time complexity
a ( a + c )( b + c )( a + b + c )( c + e)( d + e)( c + d + e)
e( d + e )
Jan 28, 2012 EE-709@IITB 21 CADSL
Anatomy of a modern SAT solver
Yes
Test Is there a D or D’
generated on any PO?
No
May be
Test Possible with additional
Assigned PIs?
No
1
D’
1
D
1
D’ D’
D’
1 0
1 D’ 1
sa1
sa1
sa1
sa1
0
0
sa1
0
0
sa1
0
0
sa1
0
0
1 sa1
1 0 sa1 D 1
1 1
D
D
1
0
0
sa1
0 sa1
0
1
sa1
sa1
1
1
0 sa1
1
0
1
0 sa1
1
1
0
0
1
1 sa1
1 1 sa1 D
D
0
D
D
v = vs;
while (s is a gate output)
if (s is NAND or INVERTER or NOR) v = v;
if (objective requires setting all inputs)
select unassigned input a of s with hardest
controllability to value v;
else
select unassigned input a of s with easiest
controllability to value v;
s = a;
return (s, v) /* Gate and value to be assigned */;
FAN
(Fujiwara and Shimono, 1983)
Objective
New concepts:
Immediate assignment of
uniquely-determined signals
Unique sensitization
Stop Backtrace at head lines
Multiple Backtrace
Strategy 2:
Assign faulty signal D or D’ that is
uniquely determined or implied by the
fault in question
14 Feb 2013 EE-709@IITB 39 CADSL
PODEM Fails to Determine Unique
Signals
0
0 1 0
1
J=1
A=1 C=1 F =D’ H =D
K M
B=0
E =D
G =1 L=1
Strategies:
Strategy 3:
When the Dfrontier consists of a single gate, apply a unique
sensitization
Strategy 4:
Stop the backtrace at a headline, and postpone the line
justification for the headline to later
K
A J
B L
C
K
A J
B 0 L
C
A=1
J=1
B=1
B=0
J=0
C=1
C=0 Backtracking at Head-lines
PODEM
FAN – breadth-first
passes –
1 time
PODEM –
depth-first
passes – 6 times
1 D
X
Cn
Cn+1
X
Combinational logic 1
Sn X
FF
An-1 Bn-1 An Bn
Time-frame -1 Time-frame 0
1 1 1
s-a-0 1
D X s-a-0
D D
1 1
Cn-1 1 D X D
Cn 1 1
Cn+1
X
1
Combinational logic Combinational logic 1
Sn-1 Sn
X
D
FF
Unknown
Time- State Time- Time- Next
or given
frame variables frame frame state
Init. state
-n+1 -1 0
Comb.
block PO -n+1 PO -1 PO 0
FF1
B
A FF2
s-a-1
A 0 A 0
s-a-1 s-a-1
D D
X X X
FF1 FF1
X D D
FF2 FF2
B X B X
Time-frame -1 Time-frame 0
A 0 A X
s-a-1 s-a-1
0/1 X/1
X 0/X 0/X
FF1 FF1
X 0/1 X/1
FF2 FF2
B X B 0/1
Time-frame -0 Time-frame
F2
F3
F1
3
Level = 1 F2
2
s - graph
F1 F3 dseq = 3
Level = 1 3
0 1 2
1
MUX
SD Q
CK D flip-flop
MCK Q
SCK D flip-flop
SD
MCK
Normal
mode
Logic TCK
overhead
TCK MCK
mode
Scan
TCK
SCK
t
28 Feb 2013 EE-709@IITB 9 CADSL
Adding Scan Structure
PI PO
logic SFF
SFF
PI I1 I2 O1 O2 PO
Combinational
SCANIN
SCANOUT
TC
logic
Next
Present S1 S2 N1 N2 state
state
SCANIN S1 S2
TC 0000000 1 0000000 1 0000000
PO O1 O2
SCANOUT N1 N2
SFF
SFF
TC
CK
IO SFF
pad cell
SCANIN
Flip-
flop
cell
Y Y’
TC SCAN
OUT
Routing
channels
Interconnects Active areas: XY and X’Y’
Original Full-scan
Number of combinational gates 2,781 2,781
Number of non-scan flip-flops (10 gates each) 179 0
Number of scan flip-flops (14 gates each) 0 179
Gate overhead 0.0% 15.66%
Number of faults 4,603 4,603
PI/PO for ATPG 35/49 214/228
Fault coverage 70.0% 99.1%
Fault efficiency 70.9% 100.0%
CPU time on SUN Ultra II, 200MHz processor 5,533 s 5s
Number of ATPG vectors 414 585
Scan sequence length 414 105,662
❖ fT = {0,1}n → {0.1}
❖ Procedure
➢ Compute TF, T(s,x,t)
➢ Compute conjunction of T and C
➢ Existentially abstract all s variable and all x
variable - provides I(t)
➢ I(t) is the smallest function independent of s
and x which contains all the tripples in f(s,x,t)
0.0 1.1
❖ Implicit representation
❖ Graphs and their traversal are converted to
Boolean functions and Boolean operations
❖ BDD can be use for symbolic computation
• Transition Function
s2 = p1 + a2
Next state
Present state: 00, Input: 10
T(0,0,s1,s2,0,1) = S1 . S2
11
characteristic function
Next state
PI Comb. PO
Logic Combinational Equiv. Checking
PS1 NS1
Comb. PO
MATCH
LATCHES PI Logic 1 NS ?
=
PS PO
Comb.
CIRCUIT 2
Logic 2 NS
PS2 NS2
Comb.
PI Logic PO
PI Comb. PO
Logic Combinational Equiv. Checking
PS1 NS1
Comb. PO
MATCH
LATCHES PI Logic 1 NS ?
=
PS PO
Comb.
CIRCUIT 2
Logic 2 NS
PS2 NS2
Comb. Represent logic functions for this
PI Logic PO entire circuit with BDD or SAT
Iterate No Fixed-point ?
Yes
Done !!
Barrier to adoption of
Manual effort System-level design
Methodology!
RTL
Current design
iterations
Gate-level design
Manual effort
Equivalence
Checking
RTL
Gate-level design
Automatic
Manual effort Synthesis
RTL
Gate-level design
“The task of proof construction is in general quite tedious and a good deal of
ingenuity may be required to organize the proof in a manageable fashion.
The global state graph of the concurrent systems can be viewed as a finite Kripke
structure and an efficient algorithm can be given to determine whether a structure
is a model of a particular formula (i.e. to determine if the program meets its
specification)”.
Virendra Singh
Associate Professor
Computer Architecture and Dependable Systems Lab
Department of Electrical Engineering
Indian Institute of Technology Bombay
http://www.ee.iitb.ac.in/~viren/
E-mail: [email protected]
P,q
P,q
q,r r r
q,r
p,q r r
q,r r r r
• Path is represented as π = s1 → s2 → s3
→...
• πs1 = s → s2 → s3EE709@IITB
→ . . . (path starting from
19 Mar 20131 3 CADSL
Computation Tree Logics
P,q
P,q
q,r r r
q,r
p,q r r
π 1
1
q,r r r r
π 1
2
φ ::= T | ¬T | p | ¬φ | (φ ∧ φ ) | (φ ∨ φ ) | (φ → φ )
| ( X φ ) | (Fφ ) | (Gφ ) | (φUφ ) | (φW φ ) | (φ Rφ )
2. s0 |= ~r q,r r
3. s0 |= Xr
4. s0 |= X(q ^ r) does not hold p,q r r
5. s0 |= G ~(p ^ r) q,r r r r
1. ¬ (φ ∧ ψ) Ξ (¬ φ ∨ ¬ ψ)
2. ¬ (φ ∨ ψ) Ξ (¬ φ ∧ ¬ ψ)
3. ¬ G φ Ξ F ¬ φ
4. ¬ F φ Ξ G ¬ φ
5. ¬ Xφ Ξ X ¬ φ
1. ¬ (φ U ψ) Ξ (¬ φ R ¬ ψ)
2. ¬ (φ R ψ) Ξ (¬ φ U ¬ ψ)
3. F φ Ξ T U φ
4. G φ Ξ ¬T Rφ
5. φ U ψ Ξ φ Wψ ∧ F ψ
1. φ W ψ Ξ φ Uψ ∨ G φ
2. φ W ψ Ξ ψ R (ψ ∨φ)
3. φ R ψ Ξ ψ W (ψ ∧ φ)
Essential Set
1. {U , X}
2. {R, X}
3. {W , X}
Path P1
1
D 1
D
P2 1
1
D’
1 D D
2 3
SA0 P3
1
D 1
0
D’
P2 1
D’
1 D D
2 3
SA0 P3
1
Path P1
X0
0D 1
00
1D’
P2 1
1D’
01 0D 0D
2 3
SA0 P3
01
Cheng’s classification
Robustly testable
Non-robustly (NR) testable
Functional sensitizable (FS) testable
Functionally unsensitizable (functionally
redundant)
Cheng’s classification
Robustly testable
Non-robustly (NR) testable
Functional sensitizable (FS) testable
Functionally unsensitizable (functionally
redundant)
V1 V2 V1 V2
S1 S0
S1 S0
U0/F0 U0/F0 U1/R1 U1/R1
S0 S0 S0 S0 S0 S0 S0 S0 U0 S1 U1 XX
U0 S0 U0 U0 U0 U0 U0 U0 U0 S1 U1 XX
Input 2
Input 2
S1 S0 U0 S1 U1 XX S1 S1 S1 S1 S1 S1
U1 S0 U0 U1 U1 XX U1 U1 U1 S1 U1 U1
XX S0 U0 XX XX XX XX XX XX S1 U1 XX
Input
S0 U0 S1 U1 XX Ref.:
NOT
Lin-Reddy
S1 U1 S0 U0 XX IEEETCAD-87
A. Place F0 at R1
path origin
Path P3
F0
XX F0 R1
U0 Robust Test:
B. Propagate F0 through OR gate; S0, F0, U0
also propagates as R1 through
NOT gate
Path P2 U1
A. Place R1 at
path origin
R1
R1 U1 U0 Non-robust test requires
XX Static sensitization:
S0=U0, S1=U1
U0
B. Propagate R1 through OR gate;
interpreted as U1 on off-path signal; Non-robust test:
propagates as U0 through NOT gate U1, R1, U0
Path P2 S1
A. Place R1 at
path origin
F0
F0 U0 U1 NO TEST
XX
U0
B. Propagate R1 through OR gate;
interpreted as U1 on off-path signal; Non-robust test:
propagates as U0 through NOT gate U1, R1, U0
Input Output
test clock Test Rated test clock
clock clock
period period
Input
test clock
Output
test clock
V1 V2
applied applied Output
latched
PI Combinational PO
CK
circuit
CK TC
SCAN- HOLD
OUT HL SFF
Scanout
V1 settles result
HL SFF
SCANIN
Normal
Normal
mode
HOLD
mode
Scan mode
CK TC TC
CK: system clock Scanin Scanin
TC: test control V1 V2 states Result
HOLD: hold signal states latched
SFF: scan flip-flop V1 PI V2 PI
HL: hold latch applied applied
TC
Normal
mode
Scan mode Scan mode
SFF (A)
SCANIN
Slow CK
CK TC period
X0 (t + 1) 0 1 0 … 0 0 X0 (t)
0 0 1 … 0 0
X1 (t + 1) . . . . . X1 (t)
. . . . .
. = . . . . . .
. .
. 0 0 0 … 1 0 .
Xn3 (t + 1) 0 0 0 … 0 1 Xn-3 (t)
1 h h2 … hn-2 hn-1
Xn2 (t + 1) 1 Xn-2 (t)
Xn1 (t + 1) Xn-1 (t)
X (t + 1) = Ts X (t) (Ts is companion matrix)
4 3
4 3 3
2
Transition count:
m
x2 +1
x5 + x3 + x + 1 +x
7 + x3
x
+ x5 + x3 + x2
x7 +x
x5 + x2
+x +1
remainder x5 + x3 +1
3 + x2
x
Remainder matches that from logic simulation
of the response compacter!
X0 (t + 1) 0 1 … 0 0 X0 (t) d0 (t)
0 0 … 0 0
X1 (t + 1) . . . . X1 (t) d1 (t)
. . . .
. . . . . . .
. = 0 . .
. 0 … 1 0 . + .
Xn-3 (t + 1) 0 0 … 0 1 Xn-3 (t) dn-3 (t)
1 h1 … h
Xn-2 (t + 1) n-2 hn-1 Xn-2 (t) dn-2 (t)
Xn-1 (t + 1) Xn-1 (t) dn-1 (t)
08 Apr 2013 EE-709@IITB 16 CADSL
Modular MISR Example
X0 (t + 1) 0 0 1 X0 (t) d0 (t)
= 1 0 1 +
X1 (t + 1) 0 1 0 X1 (t) d1 (t)
X2 (t + 1) X2 (t) d2 (t)
08 Apr 2013 EE-709@IITB 17 CADSL
Multiple Signature Checking
• Use 2 different testing epochs:
1st with MISR with 1 polynomial
2nd with MISR with different polynomial
• Reduces probability of aliasing –
Very unlikely that both polynomials will alias
for the same fault
• Low hardware cost:
A few XOR gates for the 2nd MISR polynomial
A 2-1 MUX to select between two feedback
polynomials
08 Apr 2013 EE-709@IITB 18 CADSL
Aliasing Probability
• Aliasing – when bad machine signature equals
good machine signature
• Consider error vector e (n) at POs
Set to a 1 when good and faulty machines
differ at the PO at time t
• Pal ≡ aliasing probability
• p ≡ probability of 1 in e (n)
• Aliasing limits:
0 < p≤ ½, ≤ pk P≤al (1 – p)k
≤ ≤ ≤k ≤
½ p 1, (1 – p) Pal pk
08 Apr 2013 EE-709@IITB 19 CADSL
Aliasing Theorems
• Theorem : Assuming that each PO dij has probability
pj of being in error, where the pj probabilities are
independent, and that all outputs dij are independent,
in a k-bit MISR, Pal = 1/(2k), regardless of the
initial condition.
Pattern Responses
abc Good a sa1 f sa1 b sa1
000 0 0 1 0
001 1 1 1 0
010 0 1 1 0
011 0 1 1 0
100 0 0 1 1
101 1 1 1 1
110 1 1 1 1
111 1 1 1 1
Signatures
Transition Count 3 3 0 1
LFSR 001 101 001 010
• Testing epoch I:
LFSR1 generates tests for CUT1 and CUT2
BILBO2 (LFSR3) compacts CUT1 (CUT2)
• Testing epoch II:
BILBO2 generates test patterns for CUT3
LFSR3 compacts CUT3 response
• B1 B2 = “10”
• B1 B2 = “11”