Académique Documents
Professionnel Documents
Culture Documents
Fig. 1: The SCOAP controllability and observability measures for a 3-input XOR gate
Fig. 2: SCOAP measures for a 3-input XOR gate using NAND-NOR implementation
0.5/0.5/0.5
A
0.5/0.5/0.5 0.5/0.5/1
B Z
0.5/0.5/0.5
C
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 1/12
Fig. 4: probability-based measures for a 3-input XNOR gate using NAND-NOR implementation
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 2/12
2.5 (Ad Hoc Technique)
Figure 7 shows an example of a combinational feedback loop. In this example, when A = 1, B = 0, and
C = 1, the circuit acts as an oscillator, which prevents us from being able to predict a valid value at G.
This will reduce the fault coverage of the circuit and could damage the chip.
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 3/12
2.8 (LSSD Scan Cell)
We know that ATE performs scan testing on scan chains in parallel, so test time is related to the
number of scan test vectors N. From Figure 11, we can see that one vector would take L cycles during
shift operation, 1 cycle during hold operation to observe PO values, 1 cycle during capture operation
to capture values to scan cells, and 1 cycle to observe all PPO values. Also, at the end of scan testing,
L-1 cycles are required to shift out the final capture values of the scan cells. Thus, the total test time
required to test the scan design with N test vectors is:
N(L + 3) + L – 1 = NL + 3N + L – 1
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 4/12
2.10 (Full-Scan Design)
1. In an LSSD single-latch design, the output of the master latch L1 is used to drive combinational
logic, and the slave latch L2 is used for scan shift. While in an LSSD double-latch design, the
output of slave latch L2 is used for driving both combinational logic and scan shift.
2. In an LSSD single-latch design, at least two system clocks C1 and C2 must be used as C clocks to
prevent combinational feedback loops from occurring. In an LSSD double-latch design, only C1 is
used as C clock, and C2 is used as B clock.
For there are n storage elements and m balanced scan chains in the full-scan design, the longest scan
chain length L is equal to the upper bound integer of n/m.
L = ┌n/m┐
Thus, the number of clock cycles required to shift in the test vector vi+1 is L.
Since vi+1 and the response of vi are different in d bits, in order to apply vi+1, these d bits have to be
udpated. Assuming that the clock cycles to specify an address is T, then
T = ┌log2n┐
Because one additional cycle is needed to update the specified scan cell, the total number of clock cycles
required to update d bits will become d(1+T).
The sequential circuit can be treated as a directed graph. We can easily identify whether it contains
combinational feedback loops or not with the DFS algorithm. An implementation is listed as follows:
typedef struct {int v; int w} EDGE; // Edge v->w
int count; // a counter
int ivertex[Vcount]; // Record if a vertex is visited or not
// Vcount is the count of vertexes in the graph
int iparent[Vcount]; // Record the parent of one vertex in current search
t = w;
while( t != v )
{
printf(" %d", t);
t = iparent[w];
}
return;
}
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 5/12
//DFS
void search(Graph G, EDGE e)
{
link t;
int w;
w = e.w;
ivertex[w] = count;
iparent[w] = e.v;
return;
}
//main program
void loop_identify(Graph G)
{
int v;
count = 0;
if(ivertex[v] == -1)
{
count++;
search(G, EDGE(v, v));
}
}
return;
}
Between SFF2 and SFF3, there is a clock skew, so do SFF4 and SFF5. The clock skew may cause this
failure. To fix this problem, adding one lock-up latch before SFF3 and another lock-up latch before
SFF5. Below is the modified schematic:
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 6/12
Fig. 12: Circuit structure fixed by using a lock-up latch
In this case SFF1 is positive-edge-triggered DFF and SFF2 is negative-edge-triggered DFF. Below is
the waveform:
To stitch the two cross-clock-domain scan cells into one single chain, a lock-up latch should be added
before the first negative-edge-triggered scan cell. The waveform is like below:
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 7/12
SI X SO
Q1 lock-up Q2
SFF1 latch SFF2
CLK1
CLK1
Q1 D1 D2 D3 D4 D5
X D1 D2 D3 D4
Q2 D1 D2 D3 D4
A lock-up latch cannot stitch the two cross-clock-domain scan cells into one single scan chain. A
lock-up flip-flop can do it. The lock-up flip-flop uses CK2 as its clock.
Lock-
SCp up FF SCq
CLK1
CLK2
CLK1
CLK2
Once the physical implementation of the scan design is completed, including placement and routing of
all the cells of the design, it may cause errors during shift operation between adjacent scan cells. If
two neighboring scan cells in the chain are too close, the data path delay from the output of a driving
scan cell to the scan input of the following scan cell is smaller than the clock skew that exists between
the clocks driving the two scan cells (we suppose that the two scan cells are driven by the same clock).
Finally, both scan cells will always incorrectly contain the same value at the end of each shift clock
cycle.
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 8/12
Fig. 16: Circuit structure
CK
CK+delay
X, X’ D1 D2 D3
Y D1 D2 D3
Fig. 17: Timing diagram
To fix the clock skew problem, we can insert a lock-up latch between adjacent scan cells as shown
below:
If the distance between two neighboring scan cells in the scan chain is very far, then the data path
delay from the Q output of a driving scan cell to the scan input SI of the next scan cell could be one
clock cycle longer than the clock skew that exists between the clocks driving the two scan cells. In this
case, data at the scan chain will be lost due to hold time violation. One may add pipelined flip-flops
between these two scan cells or lower the scan shift frequency.
During scan testing, the test mode signal (TM) is set to 1, in order to turn on all test-related fixes. In
order to operate the circuit in shift mode, the scan enable signal (SE) is first set to 1, so the scan cells
are reconfigured as scan chains, which allows us to shift in any desired logic values into the scan
chains. In capture mode, SE is set to 0, and the scan cells are used to capture the test response from the
combinational logic when capture clock(s) are applied.
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 9/12
2.18 (Clock Grouping)
N
Add into group
Y N
Is there any clock left in ungroup?
N
END
Fig. 19: An algorithm to find the smallest number of clock groups in clocking grouping
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 10/12
2.19 (RTL Testability Enhancement)
Q
DFF tri_en[3]
Q
CLK
d4
tri_en[2]
1'b ’ DFF dbus
CLK d3
tri_en[1]
1 'b ’ DFF
CLK d2
bus_sel[0]
bus_sel[1]
tri_en[0]
1'b ’ DFF d1
CLK
When more than two bus drivers’ Enable signals are set to 1, bus contention may occur. Therefore,
modification must be made in order to ensure only one driver controls the bus.
reg[3:0] tri_en;
always @(posedge clk)
begin
case(bus_sel)
0:tri_en[0] = 1’b1;
1:tri_en[1] = 1’b1;
2:tri_en[2] = 1’b1;
3:tri_en[3] = 1’b1;
endcase
end
assign dbus = (tri_en[0]_fix)?d1:8’bz;
assign dbus = (tri_en[1]_fix)?d2:8’bz;
assign dbus = (tri_en[2]_fix)?d3:8’bz;
assign dbus = (tri_en[3]_fix)?d4:8’bz;
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 11/12
The modified schematic:
VLSI Test Principles and Architectures Ch. 2 – Design for Testability – P. 12/12