Outline Introduction/ Motivation Preliminaries Circuit, Fault - - PDF document

outline
SMART_READER_LITE
LIVE PREVIEW

Outline Introduction/ Motivation Preliminaries Circuit, Fault - - PDF document

Autom atic Test Pattern Generation Rolf Drechsler, Grschwin Fey University of Bremen drechsle@informatik.uni-bremen.de Outline Introduction/ Motivation Preliminaries Circuit, Fault Model, Test Pattern Generation Proof


slide-1
SLIDE 1

1

Autom atic Test Pattern Generation

Rolf Drechsler, Görschwin Fey University of Bremen

drechsle@informatik.uni-bremen.de

2

Outline

  • Introduction/ Motivation
  • Preliminaries

– Circuit, Fault Model, Test Pattern Generation

  • Proof techniques

– Boolean satisfiability, BDD, SAT, Circuit to SAT Conversion

  • SAT-based ATPG

– Problem description – Multi-valued Encoding – Variable Selection

  • Experimental Results
  • Conclusions
slide-2
SLIDE 2

2

3

Motivation

Source: Intel

4

Motivation

  • Increasing size of circuits
  • Post-production test is a crucial step:

– Have there been problems during production? – Does the circuit contain faults?

  • Test patterns are applied
slide-3
SLIDE 3

3

5

Motivation

  • Test pattern generation happens at the

Boolean level

  • Classical ATPG algorithms reach their

limits There is a need for more efficient ATPG tools!

6

Circuits

  • Basic gates

– AND, OR, EXOR, NOT

OR AND XOR NOT

slide-4
SLIDE 4

4

7

Fault Model

  • Model “realistic” fault

– Physical faults or defects at the Boolean level

  • Simplified assumption
  • Based on netlist
  • Static or dynamic

– Here: static only

8

Stuck-at Fault Model

  • Single line is assumed to have a fixed

value (0 or 1)

  • Example: stuck-at 0 fault at line d

correct faulty

a b c f d e a b c f d e

slide-5
SLIDE 5

5

9

Test Pattern Generation

  • Physical defects are modeled on the

Boolean level

  • Automatic Test Pattern Generation (ATPG)

Given: Circuit C and Fault-Model F Objective: Calculate test patterns for faults in C with respect to F x Stuck-at-0 Inputs Output

10

Boolean Difference

  • BD of faulty and fault free circuit

a b c f d e f’ d’ e’ BD

slide-6
SLIDE 6

6

11

Fault Classification

  • If there is a test, the fault is testable.
  • If there does not exist a test, the fault

is redundant.

  • Decision is NP complete.

12

ATPG: D-Algorithm

  • An error is observed due to differing values at a line in

the circuit with or without failure. Such a divergence is denoted by values D or D´ to mark differences 1/ 0 or 0/ 1, respectively.

  • Instead of Boolean values, the set { 0,1,D,D´ } is used to

evaluate gates and carry out implications.

  • A gate that is not on a path between the error and any
  • utput does never have a D-value.
  • A necessary condition for testability is the existence of a

path from the error to an output, where all intermediate gates either have a D-value or are not assigned yet. Such a path is called a potential D-chain.

  • A gate is on a D-chain, if it is on a path from the error

location to an output and all intermediate gates have a D-value.

slide-7
SLIDE 7

7

13

General Structure

  • Justification and Propagation

Propagation Fault site Justifi- cation Reconvergent path

14

I m provem ents

  • PODEM: only branch on inputs
  • FAN: branching on fanout stems
  • SOCRATES: learning
  • HANIBAL: recursive learning
  • Alternative: SAT-based

– Formulation based on formal techniques – Proof techniques: BDD and SAT

slide-8
SLIDE 8

8

15

  • Truth table
  • SoP (DNF) and PoS (CNF)
  • Examples
  • Sum-of-products

F = x1’x2x3 + x1x2’x3 + x1x2x3

  • Product-of-sums

F = (x1+ x2+ x3) (x1+ x2+ x3’) (x1+ x2’+ x3) (x1’+ x2+ x3) (x1’+ x2’+ x3)

  • Decision tree

Representation

16

Truth Table and Decision Tree

slide-9
SLIDE 9

9

17

Rule 1 : I som orphism Rule Nodes must be unique (I-reduction) Rule 2 : Elim ination Rule Redundant tests should not be present (S-reduction)

Reduction of Decision Tree

18

BDD Decision Tree reduction

Exam ple of Tree Reduction

slide-10
SLIDE 10

10

19

  • A Boolean function can be expanded by

Shannon F(x,y,z) = x’ Fx’ + x Fx where Fx’ and Fx are positive (negative) cofactors Fx’ = F(0, y, z), Fx = F(1, y, z)

Shannon Expansion

20

  • If-Then-Else-Operator:

ITE(F, G, H) = F G + F’ H

  • Boolean operations over ITE arguments can be

expressed as ITE of F, G, and constants

  • Example: AND(F, G) = ITE(F, G, 0)
  • Computation of Boolean operations is based on the

Shannon expansion: ITE(F,G,H) = ITE(x, ITE(Fx’,Gx’,Hx’), ITE(Fx,Gx,Gx))

Synthesis Operations: I TE

slide-11
SLIDE 11

11

21

F= ac+ bc+ d G= ac’+ d F+ G = ?

Exam ple:

22

Exam ple:

F= ac+ bc+ d G= ac’+ d F+ G = a+ bc+ d

reduction

slide-12
SLIDE 12

12

23

Properties

  • Efficient implementation
  • Compact representation for many

Boolean functions

  • Polynomial manipulation algorithms
  • Sensitive to variable ordering

– NP-complete problem – Dynamic variable ordering

24

  • BDD-based representation of
  • functions (with don’t cares)
  • relations
  • minterms, cubes
  • sets (of sets)
  • state machines
  • ...
  • Common features of all successful BDD-based

representations

Function Representation

slide-13
SLIDE 13

13

25

Sim ulation

  • Application of values
  • Fast computation

– linear time

  • New evaluation for each input pattern
  • Complete simulation only feasible for small

circuits – exponential in the number of inputs 1 1 1

26

Sym bolic Sim ulation

  • Application of variables
  • One computation for all

input patterns in parallel

  • Construction of

diagrams for each gate – synthesis

  • perations
  • Size of diagrams
slide-14
SLIDE 14

14

27

SAT

  • Often all patterns are not needed
  • A single test-vector is sufficient
  • Construction of satisfying assignment
  • SAT-problem: For a given Boolean

function f find an assignment a, such that f(a)= 1 or prove that such an assignment does not exist.

28

SAT

“real problem” SAT instance SAT solver SAT solution “real solution”

f f e f d f e d d c d c c b c a c b a ⋅ + ⋅ + ⋅ + + ⋅ + ⋅ + ⋅ + ⋅ + ⋅ + + ) ( ) ( ) ( ) ( ) ( ) ( ) ( ) ( 1 , 1 1 , , , = = = = = = f e d c b a

slide-15
SLIDE 15

15

29

SAT for Circuits

ϕ = h [d= ¬(ab)] [e= ¬(b + c)] [f= ¬d] [g = d + e] [h = fg]

30

CNF of a Gate

ϕd = [d = ¬(a b)] = ¬[d ⊕ ¬(a b)] = ¬[¬(a b)¬d + a b d] = ¬[¬a ¬d + ¬b ¬d + a b d] = (a + d)(b + d)(¬a + ¬b + ¬d)

slide-16
SLIDE 16

16

31

CNF for Circuit

ϕ = h [d = (ab)] [e = ¬(b + c)] [f = ¬d] [g = d + e] [h = fg] = h

(¬b + ¬e)(¬c + ¬e)(b + c + e) (¬d + ¬f)(d + f) (¬d + g)(¬e + g)(d + e + ¬g) (f + ¬h)(g + ¬h)(¬f + ¬g + h)

  • CNF for circuit and

assignment h= 1

(a + d)(b + d)(¬a + ¬b + ¬d)

32

SAT Solving

  • Most Algorithms are based on DLL

procedure

  • Overall flow

– Assign variables in the CNF – If a contradiction occurs backtrack

slide-17
SLIDE 17

17

33

Basic Procedure

34

  • Unit clause: Only one unspecified literal

⇒ c = 0

(¬a + b + ¬c) = = 1

  • Boolean constraint propagation (BCP) is based
  • n iteration of unit clause rule
  • Fast implementation, since

CNF is very regular

  • BCP corresponds to

implications on the net list

I m plications

slide-18
SLIDE 18

18

35

Reasons for SAT Efficiency

  • Implications
  • Analysis of backtracks
  • Decision heuristics
  • Conflict learning

– Instance grows

  • Non-chronological backtracking
  • Data structure

– CNF – Circuit

36

DLL – An Exam ple

a b c (a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ b+ c+ d)

slide-19
SLIDE 19

19

37

DLL – An Exam ple

a b c

1

(a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ b+ c+ d)

38

DLL – An Exam ple

a b c

1 1

(a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ b+ c+ d)

slide-20
SLIDE 20

20

39

DLL – An Exam ple

a b c

1 1

d (a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ b+ c+ d)

40

DLL – An Exam ple

a b c

1 1

d

1

(a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ b+ c+ d)

slide-21
SLIDE 21

21

41

DLL – An Exam ple

a b c

1 1

d

1 1

(a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ b+ c+ d)

42

DLL – An Exam ple

(a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ c+ d) · (a+ b+ c+ d) a

1

b

1

c

1

d

1

c d b

1

1

slide-22
SLIDE 22

22

43

BDDs versus SAT

  • BDDs consider all solutions
  • SAT finds single solution
  • Backtrack tree similar to BDD structure
  • Advanced SAT techniques:

– Variable selection strategies – Efficient implementations

  • Engineering

– Implications – Conflict analysis

44

Motivation for SAT-based ATPG

  • Substantial improvements in SAT

solving Use – Advanced SAT techniques – In combination with structural information For – Large industrial circuits – In a multi-valued domain

slide-23
SLIDE 23

23

45

Test Pattern Generation

xStuck-at-0 Output Inputs Output BD = 1 !

?

FAULTY CORRECT

46

SAT-based ATPG

  • I nput: Circuit C, Fault F
  • 1. Fault modeling:

BD between fault free and faulty circuit

  • 2. Translate into CNF
  • 3. Use SAT solver to calculate solution
  • Output: Classification of F, Testvector T
slide-24
SLIDE 24

24

47

Circuit → CNF

  • AND-gate:

(c’+ d’+ e) · (c+ e’) · (d+ e’)

  • OR-gate:

(a+ b+ d’) · (a’+ d) · (b’+ d)

  • Linear size conversion

a b c d e

48

Use of Structural I nform ation

  • Influenced circuit parts

Fault Shadow Cone of Influence Fault site

slide-25
SLIDE 25

25

49

Create I nstance

  • Build circuit structure accordingly

1 Fault free Faulty

50

Fault m odeling

a b c d e a b c dg eg a b dg ef df BD

slide-26
SLIDE 26

26

51

CNF

  • F= (c + dg + eg) · (c+ eg) · (dg + eg)

· (a + b + dg) · (a + dg) · (b + dg) ·(df) · (c + df + ef) · (c+ ef) · (df+ ef) · (eg+ ef+ BD) · (eg + ef + BD) · (eg + ef+ BD) · (eg + ef + BD) ·(BD)

  • F is the CNF for circuit with d s-a-1
  • Inputs satisfy CNF → can detect fault
  • CNF is linear in circuit size

a b c dg eg a b dg ef df BD

52

Structural inform ation: TEGUS

  • Use approach as in D- algorithm
  • Gate G on path between fault and output:

– unfaulty circuit: Gg = G(Xg) – faulty circuit: Gf = G(Xf)

  • G on a D-chain implies

– difference: Gd → (Gf ≠ Gg) – at least one successor is on the D-chain: Gd → (H1,d + ... + Hk,d)

slide-27
SLIDE 27

27

53

Structural I nform ation: TEGUS

x SA-0 Inputs BD = 1 ! FAULTY CORRECT Gg Gd Gf H1,f H2,f H3,f

54

Features of PASSAT

  • Memory Management
  • Advanced SAT techniques
  • Problem specific variable selection
  • Multi-valued model
slide-28
SLIDE 28

28

55

Advanced SAT Techniques

  • Built-in techniques from Zchaff

– Conflict based learning – Non-chronological backtracking – Event-driven evaluations – Clever decision heuristics

56

Advanced SAT Techniques: SAT Run Tim es for Redundant Faults

slide-29
SLIDE 29

29

57

Variable Selection

  • Use problem specific strategies to chose

next decision variable

  • Only inputs
  • Only fanouts
  • Zchaff´ s default strategy
  • Combined strategy

– First: Only inputs with time-out – Then: Zchaff´ s default

In Out

58

Variable Selection

  • Use problem specific strategies to chose

next decision variable

  • Only inputs
  • Only fanouts
  • Zchaff´ s default strategy
  • Combined strategy

– First: Only inputs with time-out – Then: Zchaff´ s default

In Out

slide-30
SLIDE 30

30

59

Variable Selection

  • Use problem specific strategies to chose

next decision variable

  • Only inputs
  • Only fanouts
  • Zchaff´ s default strategy
  • Combined strategy

– First: Only inputs with time-out – Then: Zchaff´ s default

In Out

60

Variable Selection

  • Use problem specific strategies to chose

next decision variable

  • Only inputs
  • Only fanouts
  • Zchaff´ s default strategy
  • Combined strategy

– First: Only inputs with time-out – Then: Zchaff´ s default

In Out

slide-31
SLIDE 31

31

61

Variable Selection: p4 9 k

3847 255 1 All 2568 256 Fanout 2084 1 68 187 Input+ All 1787 2 67 187 Input Time(s) Ab Red Cnt Heuristic

62

Multi-valued Model

  • Application to industrial circuits
  • Allow for ‚Z´ and ‚U´ values
  • Encode circuit lines by two variables
  • Optimize the encoding
slide-32
SLIDE 32

32

63

Multi-valued Model

  • Encoding
  • Clauses for c = a • b

64

Multi-valued Model: Encodings

„natural“

slide-33
SLIDE 33

33

65

Multi-valued Model: Encodings

66

Experim ental Results

slide-34
SLIDE 34

34

67

Tim e to classify faults

8 440 961 P565k 13 5 58 119 137 P177k 7 167 106 P88k 207 9 P80k 1581 385 P49k 19 57 P44k abort 10-20 1-10 0.1-1 < 0.1 Time for classification circuit

68

Multi-valued m odel: I ndustrial Circuits

3073 1456 28343 26372 1175605 P565k 36965 4364 4548 759 131913 P99k 9044 2985 169 2354 126929 P88k 5591 7420 9 5 176159 P80k 334 1156 126338 P77k 30797 17821 823 61230 P44k SAT (s) Eqn (s) Ab Red Cnt Circuit

slide-35
SLIDE 35

35

69

Challenges/ Future W ork

  • Use of advanced SAT techniques

– incremental SAT

  • Optimization of SAT instance

– Boolean reasoning during creation

  • Other fault models

– dynamic model, e.g. path delay faults

70

Conclusions

  • SAT for ATPG
  • Formulation based on formal techniques
  • Use of structural information
  • Advanced SAT techniques
  • Multi-valued circuits
  • Better run times for “hard” faults
  • Applicable to large industrial circuits