ATPG of reversible circuits

Rahul Krishnamurthy
Rahul KrishnamurthyGraduate Research Assistant en ABV-Indian Institute of Information Technology
ATPG of Reversible Circuits
Rahul Krishnamurthy
Under the Guidance of
Prof.G.K.Sharma

April 20, 2012
outline

OUTLINE

◮

Integer Linear programming for ATPG.

◮

Circuit Decomposition Approach to generate test patterns.

◮

SAT based ATPG for Reversible Circuits.
BASICS

Complete and minimal test sets

◮

Given a reversible circuit C and a fault set F ,a set of test
vectors that detect all faults in F is called a complete test set.

◮

A complete test set with the fewest possible vectors is minimal
BASICS
Observability and Controllabilty

Observability and Controllabilty

Two important properties of reversiblity simplify the test set
generation problem.
◮

Controllability: There is a test vector that generates any given
desired state on the wires at any given level

◮

Observability: Any single fault that changes an intermediate
state in the circuit also changes the output
ILP Formulation for ATPG

Basic ILP terminology

◮

i th Input Vector is denoted by Ti

◮

Each Ti associated by a binary decision variable ti .

◮

ti → one if the corresponding input vector is in the test set.

◮

ti → zero if the corresponding input vector is not in the test
set.

◮

A fault is detected if a decision variable with value one
corresponds to a vector that detects the fault.
ILP Formulation for ATPG
ILP model

ILP Model
level 0

◮

level 1

level 2

The values of the wires at the j th level for input Ti are
fj (Ti )

◮

To detect all stuck-at 0 faults at level j the following
inequalities must be satisfied
2n −1
i =0 fj (Ti )xti

◮

≥1

The above inequality guarantee that each value at the j th
level is set to 1 by some test vector ensuring that all stuck-at
0 faults are detected
ILP Formulation for ATPG
ILP model

ILP Model contd..

◮

A similar set of inequalities ensures that all stuck-at 1 faults
are also detected.

◮

Total 2n(d+1) linear inequality constarints are used to
guarantee completeness.

◮

n denotes the number of lines and d is the number of levels.
ILP Formulation for ATPG
ILP model contd..

ILP model contd..

◮

There are 3 lines and a total of 3 levels So for stuck-at 0 a
total of 3x3 constriants are there.

◮

There are 3 lines and a total of 3 levels So for stuck-at 1 a
total of 3x3 constriants are there.

◮

Total linear inequality constarints are 18 .
ILP formulation

ILP formulation
◮

The general ILP formulation of the minimal test-set problem
for a reversible circuit on n wires and with depth d is:
MINIMIZE t0 + t1 + t2 + t3 + t4 + · · · + t2n −1
subject to constraints
2n −1
i =0 fj (Ti ).ti

≥1

2n −1
i =0 fj (Ti ).ti

≥1

for all 0 ≤ j ≤ d

where ti ∈ {0, 1}, andTi is the n-bit binary expansion of
integer i
ILP formulation
example

Example

level 0

level 1

level 2

0

0

0

0

0

0

0

0

0

0

0

1

0

level 0

0

level 1

level 2

level 0

level 0

level 1

1

level 1

level 2

0
0
1

level 2

0

0

0

0

0

0

1

1

1

1

1

1

0

0

1

1

1

0
ILP formulation
Example contd..

Example Contd..

The following inequalities guarantees that each of the fault sites
can be set to 1.
0 0 0 0 1 1 1 1
7
 t0 
i =0 f0 (Ti ).ti ≥ 1
00110011
t1
0 1 0 1 0 1 0 1
7
 t2  ≥ 1
0 0 0 0 1 1 1 1 ·

 t3 
i =0 f1 (Ti ).ti ≥ 1 ⇐⇒
0 0 1 1 1 1 0 0
 t4 
0 1 0 1 0 1 0 1
7
t5
00001111
i =0 f2 (Ti ).ti ≥ 1
t6
00111100
01101001

t7
ILP formulation
Example contd..

Example Contd..
The following inequalities guarantees that each of the fault sites
can be set to 0.
1 1 1 1 0 0 0 0
7
 t0 
i =0 f0 (Ti ).ti ≥ 1
11001100
t1
1 0 1 0 1 0 1 0

7
 t2  ≥ 1
1 1 1 1 0 0 0 0 ·
 t3 
i =0 f1 (Ti ).ti ≥ 1 ⇐⇒
1 1 0 0 0 0 1 1
 t4 
1 0 1 0 1 0 1 0
7
t5
11110000
t6
i =0 f2 (Ti ).ti ≥ 1
11000011
10010110

t7

◮

Solving ILP , gives three test vectors to detect all stuck-at
faults in the circuit

◮

One such solution is t0 = t7 = t2 = 1
ILP Limitations

ILP Limitation

◮

The number of variables increases exponentially with number
of input/output bits.

◮

ILP method is feasible for small circuits.It is impractical for
large circuits.

◮

An alternative approach is to decompose the original circuit
into smaller sucircuits

◮

Use ILP formulation iteratively for these subcircuits.
Circuit-Decomposition Approach

Circuit-Decomposition Approach

◮

The circuit is first decomposed into a series of circuits acting
on small number of wires.
◮

◮

Start at the input of the circuit and add gates to the first
subcircuit C0 .
Keep adding until no more can be added without having C0
act on more than m wires.
Circuit-Decomposition Approach
Example

Example
X0
X1

X2
X3
X4
X5

C0

C1

C2

◮

The entire circuit acts on six wires.

◮

Each subcircuit acts on no more than 4 wires.
Circuit-Decomposition Approach
Example contd..

◮

ILP is performed on the subcircuit C0 which provides following
test vectors

v0 =
v1 =
v2 =

x0
X
X
X

x1
0
1
1

x2
1
0
1

x3
X
X
X

x4
1
0
1

x5
1
0
0

C
→
−0

x0
X
X
X

x1
1
1
0

x2
1
0
0

x3
X
X
X

x4
0
1
1

◮

These 3 test vectors forms complete test set for Stuck-at
faults in the C0

◮

Left and right halves represent the test vectors at the input
and output of C0 respectively

x5
0
0
1
Circuit-Decomposition Approach
Example contd

◮
◮

=⇒

◮
◮

Subcircuit C1 acts on wires x0 , x1 , x4 andx5
At the input of C1 the output of C0 is applied.
x0
X
X
X

x1
1
1
0

x4
0
1
1

x5
0
0
1

∈T

From above x0 can be either 0 or 1
For both the cases test vectors becomes
x0
0
0
0

x1
1
1
0

x4
0
1
1

x5
0
0
1

x0
1
1
1

x1
1
1
0

x4
0
1
1

x5
0
0
1
Circuit-Decomposition Approach
Example contd

◮

We generate the ILP for C1 add the following constraints
CONSTRAINTS
t4 + t12 ≥ 1
t6 + t14 ≥ 1
t3 + t11 ≥ 1

◮

Solving ILP gives the solution t6 = t11 = t12 = 1

◮

These values will be Incorporated into the the previous test
vectors.
Circuit-Decomposition Approach
Example contd

◮

Left and right halves represent the test vectors at the input
and output of C1 respectively
x0
1
0
1

x1
1
1
0

x2
1
0
0

x3
X
X
X

x4
0
1
1

x5
0
0
1

C
→
−1

x0
0
1
1

x1
1
1
0

x2
1
0
0

x3
X
X
X

x4
0
1
1

x5
0
0
1
Circuit-Decomposition Approach
Example contd

◮

Subcircuit C2 acts on wires x0 , x1 , x2 andx3

◮

Generate the ILP for this circuit and incorporate the current
test set using the following constraints:

x0
0
1
1

x1
1
1
0

x2
1
0
0

x3
X
X
X

∈ T =⇒

CONSTRAINTS
t6
+ t7
≥ 1
t12 + t13 ≥ 1
t8
+ t9
≥ 1

◮

Solving this ILP gives solutions t5 , t7 , t8 andt12

◮

The last three can be incorporated into the previous test set
however the first test vector must be added as in
Circuit-Decomposition Approach
Example contd

x0
0
1
1
0
◮

x1
1
1
0
1

x2
1
0
0
0

x3
1
0
0
1

x4
0
1
1
X

x5
0
0
1
X

=⇒

x0
0
0
1
1

x1
1
1
1
0

x2
1
0
0
0

x3
0
0
0
1

x4
0
1
1
X

x5
0
0
1
X

Filling the don’t cares with 0’s and applying C −1 to the test
set yields a complete test set for C.
SAT

SAT
◮
◮

The SAT problem is defined as follows:
Let h be a Boolean function in Conjunctive normal form i.e
product-of-sum repesentation.
◮

example : h = (x1 + x2 + x3 )(x1 + x3 )(x2 + x3 )

◮

Then the SAT problem is to determine an assignment for the
variable h so that h evaluates to 1 or to prove that no such
assignment exists

◮

For the above example x1 = 1, x2 = 1 and x3 = 1 is a
satisfying assignement for h.

◮

The values of x1 and x2 ensures that the first clause become
satisfied while x3 ensures this for the remaining two clauses
SAT Based ATPG

SAT Based ATPG terminology
◮

Let a G be circuit with n lines and d gates then
◮

◮

◮

→
1 1
1
Variable − 1 = xn , xn−1 · · · x1 represents the assignement to
x
the respective input lines of the circuit
→
Variable − d+1 = x d+1 , x d+1 · · · x d+1 represents the
x
n

n−1

1

assignement to respective output lines of the circuit
→
k k
k
Variable− k = (xn xn−1 · · · x1 ) with 2 ≤ k ≤ d represents the
x
input(output) assignment to the respective lines of the gate
gk (gk−1 )
level 1

level 2

level 3
SAT Based ATPG
constraints

Constraints
◮

For every gate gk (Ck , xtk ) in the circuit,the respective
input/output mapping is constraint
◮

Values of all lines (except the target lines)are passed through
i.e (xik+1 = xik )

◮

While the output value for the target line is determined
depending on the input values of the control and the target
line respectively
(xik+1 = xik xor ∧xc∈Ck xc )

◮

After this the constraints are added ensuring that the faulty
behavior is activated .
◮

Example: In the case that a test pattern for an SMCF at the
i th line of gate gk sholud be generated .The constraint :
(xik = 0) ∧ ( xc ∈Ck xc = 1) is added
SAT Based ATPG
Additional Constraints

Additional Constraints

◮

Finally the additional constraints are added to the instance .

◮

For example: constant inputs.

◮

i.e for each constant inputs ,constraints have to added
,ensuring that the respective variable xi1 is assigned to the
according value.
SAT based ATPG Example

SAT based ATPG Example
1
X
1

1
1
X

2
X
1

3
X
1

4
X
1

2
X
2

3
X
2

4
X
2

2
X
3

3
X
3

4
X
3

2
X
4

3
X
4

4
X
4

2
X
5

3
X
5

4
X
5

2

1
X
3
1
X
4
1
X
5

Functional Constraints:
2
1
2
1
1
x1 = x1 x2 = x2 ⊕ x5
2
1
2
1
x3 = x3 x4 = x4
2 = x1
x5
5
3
2
3
2
x1 = x1 x2 = x2
Additional Constraints:
1
x1 = 1

5
X
1
5
X
2
5
X
3
5
X
4
5
X
5

Fault constraints:
3
x2 = 0
3
x4 = 1
3
x5 = 1
SAT based ATPG Example
SAT based ATPG Example

SAT based ATPG Example

◮

The three constraints are converted into CNF -the common
input format of SAT solvers

◮

If the solver then determines a satisfying assignment for the
resulting instance,a valid test pattern can be obtained from
1
1
the assingmnet to x1 · · · xn

◮

If the SAT solver returns unsatisfiable ,then it has been proven
that no test pattern considering the additional constraints
exists- the respective fault is untestable under these
constraints.
Conclusion

Conclusion

◮

ILP provides a complete and minimal test patterns

◮

The Ilp formulation is feasible for small circuits;since the
number of variables increses exponentially with the number of
input/output bits

◮

In circuit decomposition technique the test set is not
guaranteed to be minimal.

◮

ATPG SAT is effecient when additional constraints of
Constant inputs is considered.
References

References

◮

Ketan N. Patel, John P. Hayes,and Igor L. Markov,“Fault
Testing for Reversible Circuits”,IEEE TRANSACTIONS ON
COMPUTER-AIDED DESIGN OF INTEGRATED CIRCUITS
AND SYSTEMS, VOL. 23, NO. 8, AUGUST 2004

◮

Hongyan Zhang,Robert Wille and Rolf Drechsle “SAT-based
ATPG for Reversible Circuits”,Design and Test Workshop
(IDT), 2010 5th International , vol., no., pp.149-154, 14-15
Dec. 2010
1 de 29

Recomendados

Transient analysis por
Transient analysisTransient analysis
Transient analysisMohammed Waris Senan
8.9K vistas35 diapositivas
AP PGECET Instrumentation 2016 question paper por
AP PGECET Instrumentation 2016 question paperAP PGECET Instrumentation 2016 question paper
AP PGECET Instrumentation 2016 question paperEneutron
129 vistas24 diapositivas
Non-negative Matrix Factorization por
Non-negative Matrix FactorizationNon-negative Matrix Factorization
Non-negative Matrix FactorizationAkankshaAgrawal55
1.3K vistas90 diapositivas
26 Computational Geometry por
26 Computational Geometry26 Computational Geometry
26 Computational GeometryAndres Mendez-Vazquez
1.5K vistas181 diapositivas
A unifying review of linear Gaussian Models por
A unifying review of linear Gaussian ModelsA unifying review of linear Gaussian Models
A unifying review of linear Gaussian ModelsYeziwei (Maggie) Wang
376 vistas15 diapositivas
Network synthesis por
Network synthesisNetwork synthesis
Network synthesisMohammed Waris Senan
11.1K vistas27 diapositivas

Más contenido relacionado

La actualidad más candente

Spectral divide-and-conquer algorithms for eigenvalue problems and the SVD por
Spectral divide-and-conquer algorithms for eigenvalue problems and the SVDSpectral divide-and-conquer algorithms for eigenvalue problems and the SVD
Spectral divide-and-conquer algorithms for eigenvalue problems and the SVDyuji_nakatsukasa
7.1K vistas77 diapositivas
First Order Active RC Sections por
First Order Active RC SectionsFirst Order Active RC Sections
First Order Active RC SectionsHoopeer Hoopeer
22 vistas24 diapositivas
Frequency Response Analysis and Bode Diagrams for First Order Systems por
Frequency Response Analysis and Bode Diagrams for First Order SystemsFrequency Response Analysis and Bode Diagrams for First Order Systems
Frequency Response Analysis and Bode Diagrams for First Order SystemsVishvaraj Chauhan
4K vistas15 diapositivas
Example of the Laplace Transform por
Example of the Laplace TransformExample of the Laplace Transform
Example of the Laplace TransformDavid Parker
3.7K vistas6 diapositivas
Fourier-transform analysis of a unilateral fin line and its derivatives por
Fourier-transform analysis of a unilateral fin line and its derivativesFourier-transform analysis of a unilateral fin line and its derivatives
Fourier-transform analysis of a unilateral fin line and its derivativesYong Heui Cho
407 vistas18 diapositivas
Synthesis network por
Synthesis networkSynthesis network
Synthesis networkkrishna0024
16.3K vistas50 diapositivas

La actualidad más candente(20)

Spectral divide-and-conquer algorithms for eigenvalue problems and the SVD por yuji_nakatsukasa
Spectral divide-and-conquer algorithms for eigenvalue problems and the SVDSpectral divide-and-conquer algorithms for eigenvalue problems and the SVD
Spectral divide-and-conquer algorithms for eigenvalue problems and the SVD
yuji_nakatsukasa7.1K vistas
Frequency Response Analysis and Bode Diagrams for First Order Systems por Vishvaraj Chauhan
Frequency Response Analysis and Bode Diagrams for First Order SystemsFrequency Response Analysis and Bode Diagrams for First Order Systems
Frequency Response Analysis and Bode Diagrams for First Order Systems
Vishvaraj Chauhan4K vistas
Example of the Laplace Transform por David Parker
Example of the Laplace TransformExample of the Laplace Transform
Example of the Laplace Transform
David Parker3.7K vistas
Fourier-transform analysis of a unilateral fin line and its derivatives por Yong Heui Cho
Fourier-transform analysis of a unilateral fin line and its derivativesFourier-transform analysis of a unilateral fin line and its derivatives
Fourier-transform analysis of a unilateral fin line and its derivatives
Yong Heui Cho407 vistas
Synthesis network por krishna0024
Synthesis networkSynthesis network
Synthesis network
krishna002416.3K vistas
Introduction to Digital Signal Processing (DSP) - Course Notes por Ahmed Gad
Introduction to Digital Signal Processing (DSP) - Course NotesIntroduction to Digital Signal Processing (DSP) - Course Notes
Introduction to Digital Signal Processing (DSP) - Course Notes
Ahmed Gad1.5K vistas
Applications laplace transform por Muhammad Fadli
Applications laplace transformApplications laplace transform
Applications laplace transform
Muhammad Fadli2.4K vistas
Discrete time control systems por add0103
Discrete time control systemsDiscrete time control systems
Discrete time control systems
add01031.2K vistas
discrete time signals and systems por Zlatan Ahmadovic
 discrete time signals and systems  discrete time signals and systems
discrete time signals and systems
Zlatan Ahmadovic13.9K vistas
Combinational circuits por Aneeq Malik
Combinational circuitsCombinational circuits
Combinational circuits
Aneeq Malik751 vistas
BEC-26 control-systems_unit-III_pdf por Shadab Siddiqui
BEC-26 control-systems_unit-III_pdfBEC-26 control-systems_unit-III_pdf
BEC-26 control-systems_unit-III_pdf
Shadab Siddiqui119 vistas
DSP_FOEHU - MATLAB 03 - The z-Transform por Amr E. Mohamed
DSP_FOEHU - MATLAB 03 - The z-TransformDSP_FOEHU - MATLAB 03 - The z-Transform
DSP_FOEHU - MATLAB 03 - The z-Transform
Amr E. Mohamed4.4K vistas
Lec3 Intro to Computer Engineering by Hsien-Hsin Sean Lee Georgia Tech -- CMO... por Hsien-Hsin Sean Lee, Ph.D.
Lec3 Intro to Computer Engineering by Hsien-Hsin Sean Lee Georgia Tech -- CMO...Lec3 Intro to Computer Engineering by Hsien-Hsin Sean Lee Georgia Tech -- CMO...
Lec3 Intro to Computer Engineering by Hsien-Hsin Sean Lee Georgia Tech -- CMO...
Systems Analysis & Control: Steady State Errors por JARossiter
Systems Analysis & Control: Steady State ErrorsSystems Analysis & Control: Steady State Errors
Systems Analysis & Control: Steady State Errors
JARossiter10.3K vistas
The Magic of Auto Differentiation por Sanyam Kapoor
The Magic of Auto DifferentiationThe Magic of Auto Differentiation
The Magic of Auto Differentiation
Sanyam Kapoor341 vistas
BEC- 26 control systems_unit-II por Shadab Siddiqui
BEC- 26 control systems_unit-IIBEC- 26 control systems_unit-II
BEC- 26 control systems_unit-II
Shadab Siddiqui299 vistas

Destacado

ATPG flow chart por
ATPG flow chart ATPG flow chart
ATPG flow chart Minh Anh Nguyen
2.6K vistas2 diapositivas
Qualitative Analysis of Routing Protocols in WSN por
Qualitative Analysis of Routing Protocols in WSNQualitative Analysis of Routing Protocols in WSN
Qualitative Analysis of Routing Protocols in WSNEswar Publications
223 vistas5 diapositivas
Recent publications on management of Brachial plexus injury por
Recent publications on management of Brachial plexus injuryRecent publications on management of Brachial plexus injury
Recent publications on management of Brachial plexus injuryDr. PS Bhandari
172 vistas1 diapositiva
Termoregolazione e contabilizzazione in condominio por
Termoregolazione e contabilizzazione in condominioTermoregolazione e contabilizzazione in condominio
Termoregolazione e contabilizzazione in condominioChiara Ragazzini
171 vistas20 diapositivas
Pno livret jeune et priere pasteur-yvan-castanou por
Pno livret jeune et priere pasteur-yvan-castanouPno livret jeune et priere pasteur-yvan-castanou
Pno livret jeune et priere pasteur-yvan-castanouYvan CASTANOU
1.6K vistas22 diapositivas
Lgpl license (2) por
Lgpl license (2)Lgpl license (2)
Lgpl license (2)Anu M Vijayan
209 vistas7 diapositivas

Destacado(20)

Qualitative Analysis of Routing Protocols in WSN por Eswar Publications
Qualitative Analysis of Routing Protocols in WSNQualitative Analysis of Routing Protocols in WSN
Qualitative Analysis of Routing Protocols in WSN
Eswar Publications223 vistas
Recent publications on management of Brachial plexus injury por Dr. PS Bhandari
Recent publications on management of Brachial plexus injuryRecent publications on management of Brachial plexus injury
Recent publications on management of Brachial plexus injury
Dr. PS Bhandari172 vistas
Termoregolazione e contabilizzazione in condominio por Chiara Ragazzini
Termoregolazione e contabilizzazione in condominioTermoregolazione e contabilizzazione in condominio
Termoregolazione e contabilizzazione in condominio
Chiara Ragazzini171 vistas
Pno livret jeune et priere pasteur-yvan-castanou por Yvan CASTANOU
Pno livret jeune et priere pasteur-yvan-castanouPno livret jeune et priere pasteur-yvan-castanou
Pno livret jeune et priere pasteur-yvan-castanou
Yvan CASTANOU1.6K vistas
हिंदी परीयोजना por Jayanthi Rao
हिंदी परीयोजनाहिंदी परीयोजना
हिंदी परीयोजना
Jayanthi Rao761 vistas
Efficiently decoding Reed-Muller codes from random errors por cseiitgn
Efficiently decoding Reed-Muller codes from random errorsEfficiently decoding Reed-Muller codes from random errors
Efficiently decoding Reed-Muller codes from random errors
cseiitgn615 vistas
Marco Teorico por 7304560
Marco TeoricoMarco Teorico
Marco Teorico
73045601.2K vistas
Stick Figure Harry por olafsson
Stick Figure HarryStick Figure Harry
Stick Figure Harry
olafsson413 vistas
Top movies of 2010 por annpl
Top movies of 2010Top movies of 2010
Top movies of 2010
annpl257 vistas
Österreichs Open Access Empfehlungen - Eine Erfolgsgeschichte por Patrick Danowski
Österreichs Open Access Empfehlungen - Eine ErfolgsgeschichteÖsterreichs Open Access Empfehlungen - Eine Erfolgsgeschichte
Österreichs Open Access Empfehlungen - Eine Erfolgsgeschichte
Patrick Danowski676 vistas
IELTS for FSWP in CANADA por obaied
IELTS for FSWP in CANADAIELTS for FSWP in CANADA
IELTS for FSWP in CANADA
obaied1.3K vistas
MATRIC CERTIFICATE por lucky Lucky
MATRIC CERTIFICATEMATRIC CERTIFICATE
MATRIC CERTIFICATE
lucky Lucky268 vistas
Case DPaschoal - 18ª conferência anual ASUG 2015 por Fluig
Case DPaschoal - 18ª conferência anual ASUG 2015Case DPaschoal - 18ª conferência anual ASUG 2015
Case DPaschoal - 18ª conferência anual ASUG 2015
Fluig1.4K vistas
Handout for the course Abstract Argumentation and Interfaces to Argumentative... por Federico Cerutti
Handout for the course Abstract Argumentation and Interfaces to Argumentative...Handout for the course Abstract Argumentation and Interfaces to Argumentative...
Handout for the course Abstract Argumentation and Interfaces to Argumentative...
Federico Cerutti567 vistas
fpga programming por Anish Gupta
fpga programmingfpga programming
fpga programming
Anish Gupta7.8K vistas

Similar a ATPG of reversible circuits

test generation por
test generationtest generation
test generationdennis gookyi
7.5K vistas53 diapositivas
MSc_thesis por
MSc_thesisMSc_thesis
MSc_thesisNokib Uddin
283 vistas37 diapositivas
ACS 22LIE12 lab Manul.docx por
ACS 22LIE12 lab Manul.docxACS 22LIE12 lab Manul.docx
ACS 22LIE12 lab Manul.docxVasantkumarUpadhye
5 vistas34 diapositivas
Input analysis por
Input analysisInput analysis
Input analysisBhavik A Shah
303 vistas48 diapositivas
Lecture 13 por
Lecture 13Lecture 13
Lecture 13Forward2025
635 vistas28 diapositivas
FinalReport por
FinalReportFinalReport
FinalReportNathan Wendt
146 vistas17 diapositivas

Similar a ATPG of reversible circuits(20)

Gate 2013 complete solutions of ec electronics and communication engineering por manish katara
Gate 2013 complete solutions of ec  electronics and communication engineeringGate 2013 complete solutions of ec  electronics and communication engineering
Gate 2013 complete solutions of ec electronics and communication engineering
manish katara30.6K vistas
Circuit Network Analysis - [Chapter5] Transfer function, frequency response, ... por Simen Li
Circuit Network Analysis - [Chapter5] Transfer function, frequency response, ...Circuit Network Analysis - [Chapter5] Transfer function, frequency response, ...
Circuit Network Analysis - [Chapter5] Transfer function, frequency response, ...
Simen Li26.2K vistas
Wk 6 part 2 non linearites and non linearization april 05 por Charlton Inao
Wk 6 part 2 non linearites and non linearization april 05Wk 6 part 2 non linearites and non linearization april 05
Wk 6 part 2 non linearites and non linearization april 05
Charlton Inao618 vistas
Basic potential step and sweep methods por Getachew Solomon
Basic potential step and sweep methodsBasic potential step and sweep methods
Basic potential step and sweep methods
Getachew Solomon7.6K vistas
DSP Lab Manual (10ECL57) - VTU Syllabus (KSSEM) por Ravikiran A
DSP Lab Manual (10ECL57) - VTU Syllabus (KSSEM)DSP Lab Manual (10ECL57) - VTU Syllabus (KSSEM)
DSP Lab Manual (10ECL57) - VTU Syllabus (KSSEM)
Ravikiran A28.5K vistas

Último

Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant... por
Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant...Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant...
Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant...Ms. Pooja Bhandare
73 vistas45 diapositivas
UWP OA Week Presentation (1).pptx por
UWP OA Week Presentation (1).pptxUWP OA Week Presentation (1).pptx
UWP OA Week Presentation (1).pptxJisc
87 vistas11 diapositivas
Google solution challenge..pptx por
Google solution challenge..pptxGoogle solution challenge..pptx
Google solution challenge..pptxChitreshGyanani1
117 vistas18 diapositivas
PLASMA PROTEIN (2).pptx por
PLASMA PROTEIN (2).pptxPLASMA PROTEIN (2).pptx
PLASMA PROTEIN (2).pptxMEGHANA C
66 vistas34 diapositivas
ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1} por
ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1}ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1}
ANATOMY AND PHYSIOLOGY UNIT 1 { PART-1}DR .PALLAVI PATHANIA
244 vistas195 diapositivas
Solar System and Galaxies.pptx por
Solar System and Galaxies.pptxSolar System and Galaxies.pptx
Solar System and Galaxies.pptxDrHafizKosar
89 vistas26 diapositivas

Último(20)

Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant... por Ms. Pooja Bhandare
Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant...Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant...
Pharmaceutical Inorganic Chemistry Unit IVMiscellaneous compounds Expectorant...
Ms. Pooja Bhandare73 vistas
UWP OA Week Presentation (1).pptx por Jisc
UWP OA Week Presentation (1).pptxUWP OA Week Presentation (1).pptx
UWP OA Week Presentation (1).pptx
Jisc87 vistas
PLASMA PROTEIN (2).pptx por MEGHANA C
PLASMA PROTEIN (2).pptxPLASMA PROTEIN (2).pptx
PLASMA PROTEIN (2).pptx
MEGHANA C66 vistas
Solar System and Galaxies.pptx por DrHafizKosar
Solar System and Galaxies.pptxSolar System and Galaxies.pptx
Solar System and Galaxies.pptx
DrHafizKosar89 vistas
Structure and Functions of Cell.pdf por Nithya Murugan
Structure and Functions of Cell.pdfStructure and Functions of Cell.pdf
Structure and Functions of Cell.pdf
Nithya Murugan455 vistas
The Accursed House by Émile Gaboriau por DivyaSheta
The Accursed House  by Émile GaboriauThe Accursed House  by Émile Gaboriau
The Accursed House by Émile Gaboriau
DivyaSheta187 vistas
11.28.23 Social Capital and Social Exclusion.pptx por mary850239
11.28.23 Social Capital and Social Exclusion.pptx11.28.23 Social Capital and Social Exclusion.pptx
11.28.23 Social Capital and Social Exclusion.pptx
mary850239291 vistas
Create a Structure in VBNet.pptx por Breach_P
Create a Structure in VBNet.pptxCreate a Structure in VBNet.pptx
Create a Structure in VBNet.pptx
Breach_P72 vistas
AUDIENCE - BANDURA.pptx por iammrhaywood
AUDIENCE - BANDURA.pptxAUDIENCE - BANDURA.pptx
AUDIENCE - BANDURA.pptx
iammrhaywood77 vistas
REPRESENTATION - GAUNTLET.pptx por iammrhaywood
REPRESENTATION - GAUNTLET.pptxREPRESENTATION - GAUNTLET.pptx
REPRESENTATION - GAUNTLET.pptx
iammrhaywood91 vistas
11.30.23 Poverty and Inequality in America.pptx por mary850239
11.30.23 Poverty and Inequality in America.pptx11.30.23 Poverty and Inequality in America.pptx
11.30.23 Poverty and Inequality in America.pptx
mary850239149 vistas

ATPG of reversible circuits

  • 1. ATPG of Reversible Circuits Rahul Krishnamurthy Under the Guidance of Prof.G.K.Sharma April 20, 2012
  • 2. outline OUTLINE ◮ Integer Linear programming for ATPG. ◮ Circuit Decomposition Approach to generate test patterns. ◮ SAT based ATPG for Reversible Circuits.
  • 3. BASICS Complete and minimal test sets ◮ Given a reversible circuit C and a fault set F ,a set of test vectors that detect all faults in F is called a complete test set. ◮ A complete test set with the fewest possible vectors is minimal
  • 4. BASICS Observability and Controllabilty Observability and Controllabilty Two important properties of reversiblity simplify the test set generation problem. ◮ Controllability: There is a test vector that generates any given desired state on the wires at any given level ◮ Observability: Any single fault that changes an intermediate state in the circuit also changes the output
  • 5. ILP Formulation for ATPG Basic ILP terminology ◮ i th Input Vector is denoted by Ti ◮ Each Ti associated by a binary decision variable ti . ◮ ti → one if the corresponding input vector is in the test set. ◮ ti → zero if the corresponding input vector is not in the test set. ◮ A fault is detected if a decision variable with value one corresponds to a vector that detects the fault.
  • 6. ILP Formulation for ATPG ILP model ILP Model level 0 ◮ level 1 level 2 The values of the wires at the j th level for input Ti are fj (Ti ) ◮ To detect all stuck-at 0 faults at level j the following inequalities must be satisfied 2n −1 i =0 fj (Ti )xti ◮ ≥1 The above inequality guarantee that each value at the j th level is set to 1 by some test vector ensuring that all stuck-at 0 faults are detected
  • 7. ILP Formulation for ATPG ILP model ILP Model contd.. ◮ A similar set of inequalities ensures that all stuck-at 1 faults are also detected. ◮ Total 2n(d+1) linear inequality constarints are used to guarantee completeness. ◮ n denotes the number of lines and d is the number of levels.
  • 8. ILP Formulation for ATPG ILP model contd.. ILP model contd.. ◮ There are 3 lines and a total of 3 levels So for stuck-at 0 a total of 3x3 constriants are there. ◮ There are 3 lines and a total of 3 levels So for stuck-at 1 a total of 3x3 constriants are there. ◮ Total linear inequality constarints are 18 .
  • 9. ILP formulation ILP formulation ◮ The general ILP formulation of the minimal test-set problem for a reversible circuit on n wires and with depth d is: MINIMIZE t0 + t1 + t2 + t3 + t4 + · · · + t2n −1 subject to constraints 2n −1 i =0 fj (Ti ).ti ≥1 2n −1 i =0 fj (Ti ).ti ≥1 for all 0 ≤ j ≤ d where ti ∈ {0, 1}, andTi is the n-bit binary expansion of integer i
  • 10. ILP formulation example Example level 0 level 1 level 2 0 0 0 0 0 0 0 0 0 0 0 1 0 level 0 0 level 1 level 2 level 0 level 0 level 1 1 level 1 level 2 0 0 1 level 2 0 0 0 0 0 0 1 1 1 1 1 1 0 0 1 1 1 0
  • 11. ILP formulation Example contd.. Example Contd.. The following inequalities guarantees that each of the fault sites can be set to 1. 0 0 0 0 1 1 1 1 7  t0  i =0 f0 (Ti ).ti ≥ 1 00110011 t1 0 1 0 1 0 1 0 1 7  t2  ≥ 1 0 0 0 0 1 1 1 1 ·   t3  i =0 f1 (Ti ).ti ≥ 1 ⇐⇒ 0 0 1 1 1 1 0 0  t4  0 1 0 1 0 1 0 1 7 t5 00001111 i =0 f2 (Ti ).ti ≥ 1 t6 00111100 01101001 t7
  • 12. ILP formulation Example contd.. Example Contd.. The following inequalities guarantees that each of the fault sites can be set to 0. 1 1 1 1 0 0 0 0 7  t0  i =0 f0 (Ti ).ti ≥ 1 11001100 t1 1 0 1 0 1 0 1 0  7  t2  ≥ 1 1 1 1 1 0 0 0 0 ·  t3  i =0 f1 (Ti ).ti ≥ 1 ⇐⇒ 1 1 0 0 0 0 1 1  t4  1 0 1 0 1 0 1 0 7 t5 11110000 t6 i =0 f2 (Ti ).ti ≥ 1 11000011 10010110 t7 ◮ Solving ILP , gives three test vectors to detect all stuck-at faults in the circuit ◮ One such solution is t0 = t7 = t2 = 1
  • 13. ILP Limitations ILP Limitation ◮ The number of variables increases exponentially with number of input/output bits. ◮ ILP method is feasible for small circuits.It is impractical for large circuits. ◮ An alternative approach is to decompose the original circuit into smaller sucircuits ◮ Use ILP formulation iteratively for these subcircuits.
  • 14. Circuit-Decomposition Approach Circuit-Decomposition Approach ◮ The circuit is first decomposed into a series of circuits acting on small number of wires. ◮ ◮ Start at the input of the circuit and add gates to the first subcircuit C0 . Keep adding until no more can be added without having C0 act on more than m wires.
  • 15. Circuit-Decomposition Approach Example Example X0 X1 X2 X3 X4 X5 C0 C1 C2 ◮ The entire circuit acts on six wires. ◮ Each subcircuit acts on no more than 4 wires.
  • 16. Circuit-Decomposition Approach Example contd.. ◮ ILP is performed on the subcircuit C0 which provides following test vectors v0 = v1 = v2 = x0 X X X x1 0 1 1 x2 1 0 1 x3 X X X x4 1 0 1 x5 1 0 0 C → −0 x0 X X X x1 1 1 0 x2 1 0 0 x3 X X X x4 0 1 1 ◮ These 3 test vectors forms complete test set for Stuck-at faults in the C0 ◮ Left and right halves represent the test vectors at the input and output of C0 respectively x5 0 0 1
  • 17. Circuit-Decomposition Approach Example contd ◮ ◮ =⇒ ◮ ◮ Subcircuit C1 acts on wires x0 , x1 , x4 andx5 At the input of C1 the output of C0 is applied. x0 X X X x1 1 1 0 x4 0 1 1 x5 0 0 1 ∈T From above x0 can be either 0 or 1 For both the cases test vectors becomes x0 0 0 0 x1 1 1 0 x4 0 1 1 x5 0 0 1 x0 1 1 1 x1 1 1 0 x4 0 1 1 x5 0 0 1
  • 18. Circuit-Decomposition Approach Example contd ◮ We generate the ILP for C1 add the following constraints CONSTRAINTS t4 + t12 ≥ 1 t6 + t14 ≥ 1 t3 + t11 ≥ 1 ◮ Solving ILP gives the solution t6 = t11 = t12 = 1 ◮ These values will be Incorporated into the the previous test vectors.
  • 19. Circuit-Decomposition Approach Example contd ◮ Left and right halves represent the test vectors at the input and output of C1 respectively x0 1 0 1 x1 1 1 0 x2 1 0 0 x3 X X X x4 0 1 1 x5 0 0 1 C → −1 x0 0 1 1 x1 1 1 0 x2 1 0 0 x3 X X X x4 0 1 1 x5 0 0 1
  • 20. Circuit-Decomposition Approach Example contd ◮ Subcircuit C2 acts on wires x0 , x1 , x2 andx3 ◮ Generate the ILP for this circuit and incorporate the current test set using the following constraints: x0 0 1 1 x1 1 1 0 x2 1 0 0 x3 X X X ∈ T =⇒ CONSTRAINTS t6 + t7 ≥ 1 t12 + t13 ≥ 1 t8 + t9 ≥ 1 ◮ Solving this ILP gives solutions t5 , t7 , t8 andt12 ◮ The last three can be incorporated into the previous test set however the first test vector must be added as in
  • 22. SAT SAT ◮ ◮ The SAT problem is defined as follows: Let h be a Boolean function in Conjunctive normal form i.e product-of-sum repesentation. ◮ example : h = (x1 + x2 + x3 )(x1 + x3 )(x2 + x3 ) ◮ Then the SAT problem is to determine an assignment for the variable h so that h evaluates to 1 or to prove that no such assignment exists ◮ For the above example x1 = 1, x2 = 1 and x3 = 1 is a satisfying assignement for h. ◮ The values of x1 and x2 ensures that the first clause become satisfied while x3 ensures this for the remaining two clauses
  • 23. SAT Based ATPG SAT Based ATPG terminology ◮ Let a G be circuit with n lines and d gates then ◮ ◮ ◮ → 1 1 1 Variable − 1 = xn , xn−1 · · · x1 represents the assignement to x the respective input lines of the circuit → Variable − d+1 = x d+1 , x d+1 · · · x d+1 represents the x n n−1 1 assignement to respective output lines of the circuit → k k k Variable− k = (xn xn−1 · · · x1 ) with 2 ≤ k ≤ d represents the x input(output) assignment to the respective lines of the gate gk (gk−1 ) level 1 level 2 level 3
  • 24. SAT Based ATPG constraints Constraints ◮ For every gate gk (Ck , xtk ) in the circuit,the respective input/output mapping is constraint ◮ Values of all lines (except the target lines)are passed through i.e (xik+1 = xik ) ◮ While the output value for the target line is determined depending on the input values of the control and the target line respectively (xik+1 = xik xor ∧xc∈Ck xc ) ◮ After this the constraints are added ensuring that the faulty behavior is activated . ◮ Example: In the case that a test pattern for an SMCF at the i th line of gate gk sholud be generated .The constraint : (xik = 0) ∧ ( xc ∈Ck xc = 1) is added
  • 25. SAT Based ATPG Additional Constraints Additional Constraints ◮ Finally the additional constraints are added to the instance . ◮ For example: constant inputs. ◮ i.e for each constant inputs ,constraints have to added ,ensuring that the respective variable xi1 is assigned to the according value.
  • 26. SAT based ATPG Example SAT based ATPG Example 1 X 1 1 1 X 2 X 1 3 X 1 4 X 1 2 X 2 3 X 2 4 X 2 2 X 3 3 X 3 4 X 3 2 X 4 3 X 4 4 X 4 2 X 5 3 X 5 4 X 5 2 1 X 3 1 X 4 1 X 5 Functional Constraints: 2 1 2 1 1 x1 = x1 x2 = x2 ⊕ x5 2 1 2 1 x3 = x3 x4 = x4 2 = x1 x5 5 3 2 3 2 x1 = x1 x2 = x2 Additional Constraints: 1 x1 = 1 5 X 1 5 X 2 5 X 3 5 X 4 5 X 5 Fault constraints: 3 x2 = 0 3 x4 = 1 3 x5 = 1
  • 27. SAT based ATPG Example SAT based ATPG Example SAT based ATPG Example ◮ The three constraints are converted into CNF -the common input format of SAT solvers ◮ If the solver then determines a satisfying assignment for the resulting instance,a valid test pattern can be obtained from 1 1 the assingmnet to x1 · · · xn ◮ If the SAT solver returns unsatisfiable ,then it has been proven that no test pattern considering the additional constraints exists- the respective fault is untestable under these constraints.
  • 28. Conclusion Conclusion ◮ ILP provides a complete and minimal test patterns ◮ The Ilp formulation is feasible for small circuits;since the number of variables increses exponentially with the number of input/output bits ◮ In circuit decomposition technique the test set is not guaranteed to be minimal. ◮ ATPG SAT is effecient when additional constraints of Constant inputs is considered.
  • 29. References References ◮ Ketan N. Patel, John P. Hayes,and Igor L. Markov,“Fault Testing for Reversible Circuits”,IEEE TRANSACTIONS ON COMPUTER-AIDED DESIGN OF INTEGRATED CIRCUITS AND SYSTEMS, VOL. 23, NO. 8, AUGUST 2004 ◮ Hongyan Zhang,Robert Wille and Rolf Drechsle “SAT-based ATPG for Reversible Circuits”,Design and Test Workshop (IDT), 2010 5th International , vol., no., pp.149-154, 14-15 Dec. 2010