Sunteți pe pagina 1din 18

Design Verification & Testing

Testability Measures

CMPE 418

Testability Measures
Testability measures used to get approximate measure of:
T Difficulty of setting internal circuit lines to 0 or 1 by setting primary circuit inputs
T Difficulty of observing internal circuit lines by observing primary outputs
This knowledge can be used to:
T Provided analysis of difficulty of testing internal circuit parts, might require redesigning or addition of special testing hardware
T Provides guidance for algorithms performing test pattern generation, avoid using
hard-to-control lines
T Provides an estimation of fault coverage
T Provides an estimation of test vector length
Controllability: difficulty in setting a particular circuit node to 0 or 1.
Observability: difficulty of observing the state of a logic signal.
1

Design Verification & Testing

Testability Measures

CMPE 418

Testability Measures
Testability analysis attributes:
T Involves circuit topology analysis, but no test vectors
T It has linear complexity, otherwise it is pointless and one might as well use automatic
test pattern generation (ATPG) algorithms
The origin of testability measures is in control theory. Several algorithms have been proposed:
T Rutman 1972: First definition of controllability
T Goldstein 1979: SCOAP
First definition of observability
First elegant formulation
First efficient algorithm to compute controllability and observability
T Parker and McCluskey 1975: Definition of probabilistic controllability
T Brglez 1984: COP
First probabilistic measures
T Seth, Pan and Agrawal 1985: PREDICT
First exact probabilistic measures
2

Testability Measures

Design Verification & Testing

CMPE 418

SCOAP (Sandia Controllability/Observability Analysis Program)


Goldstein developed SCOAP testability measures and described a linear complexity algorithm to compute them
Before we go into SCOAP details, a few notes about assumptions
The algorithm assumes that signals at reconvergent fanout stems are independent
A
Out
B
C
For e.g. B fans out to three branches, 2 feeding the 2 AND gates, and 1 to the OR gate
All the three signals reconverge at the OR gate, as outputs of 2 ANDs feed the other
two inputs of the OR gate
3

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP
The assumption of signal independence is the key behind SCOAP's linear time algorithm.
However, this reduces its accuracy in predicting which individual faults will remain
undetected and which will be detected.
SCOAP testability measures:
X Controllability: From 1 (easiest) to infinity (hardest).
X Observability: From 0 (easiest) to infinity (hardest).
Combinational measures are related to the number of signals that may be manipulated to
control or observe a line l.
Sequential measures are related to the number of times a FF must be clocked to control or
observe a line l.
Another approach is to make them probability based, i.e., they range between 0 and 1.
Jain and Agrawal address this, in PREDICT using conditional probabilities for
observability.
4

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Controllabilities
Goldstein's algorithm: SCOAP
Consists of 6 numerical measures for each signal (l) in the circuit:
T Combinational 0-controllability, CC0(l); Sequential 0-controllability, SC0(l)
T Combinational 1-controllability, CC1(l); Sequential 1-controllability, SC1(l)
T Combinational observability, CO(l); Sequential observability, SO(l)
We will focus mainly on combinational circuits.
Controllabilities: Set Primary Input (PI) controllabilities to 1, progress from PIs to Primary
Outputs (POs), add 1 to account for logic depth.
General rules for setting controllabilities
T If only one input sets gate output:
output controllability = min (input controllabilites) + 1
T If all inputs set gate output:
output controllability = sum (input controllabilities) + 1
T If gate output is determined by multiple input sets, e.g., XOR:
output controllability = min(controllabilities of input sets) + 1
5

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Controllability Examples

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Observability
Observabilities: After controllabilities have been computed, set PO observabilities to 0,
progress from POs to PIs, add 1 to account for logic depth.
The difficulty of observing a designated input to a gate is the sum of
(1) the output observability
(2) the difficulty of setting all other inputs to non-dominant values
(3) and 1 for the logic depth

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Observability Examples

The accuracy problem occurs for the computation of the observability of a fanout stem with
n branches. One attempt is to bound the stem probability by:
T min(all fanout branch observabilities)
The events of observing a signal through each branch are independent.
T max(all fanout branch observabilities)
They are all dependent, therefore the branch that is hardest to observe is the
correct choice.
8

Testability Measures

Design Verification & Testing

CMPE 418

SCOAP Observability Examples


Problem: These ignore the possibility that observing a signal may require its propagation
through some or all fanout branches.
Goldstein uses: CO(stem) = min(CO(branches))
Therefore, observability calculation errors occur and ATPG algorithms which use
them may be misled.
Therefore, Goldstein's algorithm has only O(2*n) or O(n) complexity.
2,3 (4)
A 1,1 (6)
2,3 (4,inf)
1,1 (5,inf)
6,2 (0)
1,1 (6)
Out
4,2 (0)
1,1 (5)
(1,1,4,6)
1,1 (6)
1,1 (5)
B
1,1 (4,6)
C
1,1 (6)
1,1 (5,inf)

2,3 (4)
2,3 (4,inf)

Format:
CC0, CC1 (CO)
SCOAP in red
Correct in green
Observability
0 1
CC0, CC1 (CO, CO)

Note that the red numbers are given by the SCOAP algorithm and the green number
are the exact values.
9

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Example

The above circuit is sequential. However, let's assume that special test hardware is present
in the circuit so that
T We can read out the present state of the flip-flop
T We can set the present state of the flip-flop
10

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Example
Then for testing purposes, the two flip-flops can be modeled as a pair of primary input, primary output pairs
T The D line is referred to as pseudo-primary output (PPO), since it can be observed
T The Q line is referred to as pseudo-primary input (PPI), since it can be controlled
Levellization Algorithm
X Label each gate with maximum no. of logic levels from primary inputs (or maximum no.
of levels from primary outputs when computing observabilities)
X Assign level no. 0 to all PIs
X For each PI fanout
T Label that line with the PI level no.
T Queue logic gate driven by that fanout for evaluation
X While queue is not empty
T Dequeue next logic gate
T If all gate inputs have level nos., label the gate with the maximum of them + 1
T Else, requeue the gate

11

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Example
Controllabilities through level 0

Format
Numbers in circles on top of each gate give level numbers
(CC0, CC1) next to each signal line

12

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Example
Controllabilities through level 2

Format
Numbers in circles on top of each gate give level numbers
(CC0, CC1) next to each signal line
13

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Example
Final Controllabilities

Format
Numbers in circles on top of each gate give level numbers
(CC0, CC1) next to each signal line
14

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Example
Observabilities for Level 1

Format
Numbers in squares on top of each gate give level numbers from primary outputs
(CC0, CC1) CO next to each signal line
15

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Example
Observabilities for Level 2

Format
Numbers in squares on top of each gate give level numbers from primary outputs
(CC0, CC1) CO next to each signal line
16

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Example
Final Observabilities

Format
Numbers in squares on top of each gate give level numbers from primary outputs
(CC0, CC1) CO next to each signal line
17

Design Verification & Testing

Testability Measures

CMPE 418

SCOAP Sequential Differences


Sequential SCOAP measures differences:
X Increment the sequential measure by 1 only when:
T Signals propagate from FF inputs to Q or Q, or
T Signals propagate from FF outputs backwards to D, Clk, SET or RESET inputs.
X One must iterate on feedback loops until controllabilities stabilize.
SC0, SC1 and SO formulas differ from CC0, CC1 and C0 only in that you do NOT add one
when moving from one level to another.
SC0 and SC1 roughly measure the number of times various FFs must be clocked to control
a signal.
If line l can only be set to 1 but clocking FF a twice and FF b three times, SC1(l)
should be 5.
SO correspondingly measure the number of times a FF must be clocked to observe a combinational signal.
Read section in text for details on D flip-flop SC0, SC1 and SO.
18

S-ar putea să vă placă și