static noise margin parametric test walsh v1p1

16
Static Noise Margin Parametric Test S. Walsh Rev. 1.0 June 2000 Rev. 1.1 March 2006 Contents: Purpose Test Module Description Outline of Test Algorithm Test Procedure Data Reduction Procedure Pseudo-code for Computation of Static Noise Margin Purpose: The static noise margin test is intended to e stimate the noise level on one n ode of a SRAM bit that will “flip the bit” to its opposite value (i.e., cause an error in the stored value). Test Module Description: The static noise margin (SNM) is measured on a pair of SRAM inverters (i.e., the two driver-load stacks in one SRAM bit. Each inverter is characterized independently, and the results are combined to estimate the SNM. Outline of Test Algorithm: Each inverter is characterized by sweeping the input voltage and measuring the output voltage, as shown:

Upload: shawnhsn

Post on 06-Apr-2018

223 views

Category:

Documents


0 download

TRANSCRIPT

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 1/16

Static Noise Margin Parametric Test

S. Walsh

Rev. 1.0 June 2000

Rev. 1.1 March 2006

Contents:

Purpose

Test Module Description

Outline of Test Algorithm

Test Procedure

Data Reduction Procedure

Pseudo-code for Computation of Static Noise Margin

Purpose:

The static noise margin test is intended to estimate the noise level on one node of 

a SRAM bit that will “flip the bit” to its opposite value (i.e., cause an error in the storedvalue).

Test Module Description:

The static noise margin (SNM) is measured on a pair of SRAM inverters (i.e., thetwo driver-load stacks in one SRAM bit. Each inverter is characterized independently,

and the results are combined to estimate the SNM.

Outline of Test Algorithm:

Each inverter is characterized by sweeping the input voltage and measuring the

output voltage, as shown:

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 2/16

The two inverter curves are combined to make a “butterfly wing” graph; the bit-bar 

inverter curve is rotated about a 45o

axis so that the output of the bit inverter forms theinput to the bit-bar inverter (and vice versa, just as in the SRAM cell). The static noise

margin is defined as the smaller of inscribed squares in the “wings” of the butterfly curve,

as shown:

Test Procedure:

1. Generate the input-output curves for the bit and bit-bar inverters. Check that the

outputs at the limits (Vin = 0 and Vdd) are within spec. If Vout fails to attain the spec

levels, output an error code2. Transpose the x and y values for the bit-bar inverter curve (equivalent to rotating

about a 45o

axis).

3. Check that the two inverter curves cross each other to create a “butterfly wing” graph.

If the curves fail to cross at least three times (minimum to form the “butterfly wing”),output an error code. The procedure for checking for crossing is detailed below.

4. Compute the largest square that can be inscribed in each lobe of the “butterfly wing.”

The procedure for computing the inscribed square is detailed below. The static noisemargin is defined as the length of the side of the smaller of these inscribed squares.

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 3/16

Data Reduction Procedure

Assign the bit and bitbar data to X-Y arrays so both curves in the butterfly chart

are aligned

In the butterfly chart, the bitbar curve is reversed from its normal orientation. To

simplify computation of the SNM, the indices of the bitbar data array should be reversedso both bit and bitbar curves start with the lowest index at X = 0 and end with the highest

index at X = Vdd

1. Iterate through data arrays Vin-bit(n), Vout-bit(n), Vin-bar (n) and Vout-bar (n) 

2. Assign the data values to the X-Y arrays. Note that Npts is the number of data

 points in each data array

X bit(n) = Vin-bit(n)Y bit(n) = Vout-bit(n)

X bar (n) = Vout-bar (Npts + 1 – n) this operation aligns the bitbar curve X array 

Y bar (n) = Vin-bar (Npts + 1 – n) this operation aligns the bitbar curve Y array 

Procedure for determining curve crossing pointsThere should be three crossing points in the butterfly chart:

One near the middle of the chart; the data array indices should be ~ Npts/2One near the upper end of the chart

One near the lower end of the chart

We have to find all three to verify we have a good butterfly chart.

1. Start with the line segment formed by the first two data points of the bit inverter curve,

(X bit(1), Y bit(1)) and (X bit(2), Y bit(2)), and the line segment formed by the first two data pointsof the bit-bar inverter curve, (X bar(1), Y bar(1)) and (X bar(2), Y bar(2)).

2. Compute the coordinates, (Xintcpt

, Yintcpt

) of the intersection of the lines containing

these line segments, per the following ten cases:

[ X bit(n), Y bit(n) ]

[ X bar (n), Y bar (n) ]

[ X bit(n+1), Y bit(n+1) ]

[ X bar (n+1), Y bar (n+1) ]

[ Xintcpt, Yintcpt ]

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 4/16

 

Case 1: both bit and bitbar segments are horizontal, i.e., Y bit(1) = Y bit(2) andY bar(1) = Y bar(2)

In this case, the segments do not intersect

Xintcpt = null data value 

Yintcpt = null data value

Case 2: both bit and bitbar segments are vertical, i.e., X bit(1) = X bit(2) and X bar(1) 

= X bar(2)

In this case, the segments do not intersect

Xintcpt = null data value 

Yintcpt = null data value

Case 3: bit segment is horizontal, i.e., Y bit(1) = Y bit(2), and bitbar segment is

vertical, i.e., X bar(1) = X bar(2)

Xintcpt = X bar(1)

Yintcpt = Y bit(1)

Case 4: bit segment is vertical, i.e., X bit(1) = X bit(2), and bitbar segment ishorizontal, i.e., Y bar(1) = Y bar(2)

Xintcpt = X bit(1)

Yintcpt = Y bar(1) 

Case 5: bit segment is horizontal, i.e., Y bit(1) = Y bit(2), and bitbar segment has

finite slope, i.e., X bar(1)  ≠ X bar(2) and Y bar(1)  ≠ Y bar(2) slope bar  = (Y bar(2) - Y bar(1)) / (X bar(2) – X bar(1))

intercept bar  = [(Y bar(1) × X bar(2)) – (Y bar(1) × X bar(2))] / (X bar(2) – X bar(1))

Xintcpt = (Y bit(1) - intercept bar ) / slope bar Yintcpt = Y bit(1) 

Case 6: bitbar segment is horizontal, i.e., Y bar(1) = Y bar(2), and bit segment has

finite slope, i.e., X bit(1)  ≠ X bit(2) and Y bit(1)  ≠ Y bit(2) 

slope bit = (Y bit(2) - Y bit(1)) / (X bit(2) – X bit(1))

intercept bit = [(Y bit(1) × X bit(2)) – (Y bit(1) × X bit(2))] / (X bit(2) – X bit(1))

Xintcpt = (Y bar(1) - intercept bit) / slope bit

Yintcpt = Y bar(1)

Case 7: bit segment is vertical, i.e., X bit(1) = X bit(2), and bitbar segment has finite

slope, i.e., X bar(1) ≠

X bar(2) and Y bar(1) ≠

Y bar(2) slope bar  = (Y bar(2) - Y bar(1)) / (X bar(2) – X bar(1))

intercept bar  = [(Y bar(1) × X bar(2)) – (Y bar(1) × X bar(2))] / (X bar(2) – X bar(1))

Xintcpt = X bit(1) 

Yintcpt = (slope bar   × X bit(1)) + intercept bar  

Case 8: bitbar segment is vertical, i.e., X bar(1) = X bar(2), and bit segment has finiteslope, i.e., X bit(1)  ≠ X bit(2) and Y bit(1)  ≠ Y bit(2) 

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 5/16

slope bit = (Y bit(2) - Y bit(1)) / (X bitr(2) – X bit(1))

intercept bit = [(Y bit(1) × X bit(2)) – (Y bit(1) × X bit(2))] / (X bit(2) – X bit(1))

Xintcpt = X bar(1) 

Yintcpt = (slope bit  × X bar(1)) + intercept bit 

Case 9: both segments have finite slopes, and slope bit = slope bar  In this case, the segments do not intersect

Xintcpt = null data value 

Yintcpt = null data value

Case 10: both segments have finite slopes, and slope bit ≠ slope bar  

slope bit = (Y bit(2) - Y bit(1)) / (X bit(2) – X bit(1))

intercept bit = [(Y bit(1) × X bit(2)) – (Y bit(1) × X bit(2))] / (X bit(2) – X bit(1))

slope bar  = (Y bar(2) - Y bar(1)) / (X bar(2) – X bar(1))

intercept bar  = [(Y bar(1) × X bar(2)) – (Y bar(1) × X bar(2))] / (X bar(2) – X bar(1))

Xintcpt = (intercept bar – intercept bit) / (slope bit – slope bar )

Yintcpt = (slope bit × intercept bar – slope bar  × intercept bit) / (slope bit – slope bar )

3. Check for crossing of the two segments. The segments cross if, and only if,

minimum(X bit(1),X bit(2)) ≤ Xintcpt  ≤ maximum(X bit(1),X bit(2))and

minimum(X bar(1),X bar(2)) ≤ Xintcpt  ≤ maximum(X bar(1),X bar(2))and

minimum(Y bit(1),Y bit(2)) ≤ Yintcpt  ≤ maximum(Y bit(1),Y bit(2))

and

minimum(Y bar(1),Y bar(2)) ≤ Yintcpt  ≤ maximum(Y bar(1),Y bar(2))

If the segments cross, record the Xintcpt and Yintcpt and the bit and bitbar indices of the

crossing point for use in computing the inscribed square. Keep track of the number of 

crossings.

4. Repeat this procedure using all pairs of line segments in each inverter curve:

 bit curve segment 1 and bit-bar curve segment 1 bit curve segment 1 and bit-bar curve segment 2

 bit curve segment 1 and bit-bar curve segment 3etc.

 bit curve segment 1 and bit-bar curve segment N

 bit curve segment 2 and bit-bar curve segment 1

 bit curve segment 2 and bit-bar curve segment 2

 bit curve segment 2 and bit-bar curve segment 3

etc. bit curve segment 2 and bit-bar curve segment N

etc. etc.

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 6/16

 

 bit curve segment N and bit-bar curve segment 1 bit curve segment N and bit-bar curve segment 2

 bit curve segment N and bit-bar curve segment 3

etc.

 bit curve segment N and bit-bar curve segment N

After all the crossings have been found, if there are exactly three crossings, proceed to

the find the SNM. Otherwise, report a defective DUT (i.e., an error code).

Procedure for computing the inscribed square in the “butterfly wing”

The maximum inscribe square will have one corner on a data point; this can beseen by imagining a 45

oline moving down the lobe. The maximum inscribed square will

correspond to the longest 45o

line segment that fits in the lobe. The longest segment will

intersect a data point, since there are no local maxima in the line segments connecting thedata points.

1. Find the extent of the upper lobe of the “butterfly wing”

A. Start with the middle crossing (Xintcpt(m), Yintcpt(m)), and the upper crossing(Xintcpt(u), Yintcpt(u)), as shown in the diagram. Note that the intersections will usually not

 be at a data point in either of the inverter curves.

B. Find the points on each inverter curve between these two intersections:For the bit inverter curve, the points (X bit(n), Y bit(n))in the upper lobe must

satisfy Xintcpt(u) < X bit(n) < Xintcpt(m) 

For the bit-bar inverter curve, the points (X bar(n), Y bar(n))in the upper lobemust satisfy Yintcpt(m) < Y bar(n) < Yintcpt(u) 

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 7/16

 

2. For each bit curve data point (X bit(n), Y bit(n)) in the upper lobe, compute the length of the diagonal line segment from that data point to the bitbar curve:

The equation for a 45o

line through the data point (X bit(n), Y bit(n)) is:

Y = X + (Y bit(n) – X bit(n))

Start with the line segment formed by the first two data points of the opposite

curve in the upper lobe, as found in Step 1, (X bar(1), Y bar (1)) and (X bar (2), Y bar (2)). The line

containing this line segment is given by:

Y = slope bar  × X + intercept bar 

slope bar  = (Y bar (2) – Y bar (1)) / (X bar (2) – X bar (1))

intercept bar  = [(Y bar (1) × X bar (2)) - (Y bar (2) × X bar (1))] / (X bar (2) – X bar (1))

Compute the coordinates of the intersection of these two lines (the 45o

line from

the bit data point and the line segment of the bitbar curve):

Xintcpt = [intercept bar – (Y bit(n) – X bit(n))] / (1 – slope bar )

Yintcpt = [intercept bar – slope bar  × (Y bit(n) – X bit(n))] / (1 – slope bar )

Check that the intersection is inside the bitbar curve line segment:

minimum(X bar(1), X bar(2)) ≤ Xintcpt ≤ maximum(X bar(1), X bar(2))and

minimum(X bar(1), X bar(2)) ≤ Xintcpt ≤ maximum(X bar(1), X bar(2))

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 8/16

 

Make a sanity check that the intersection lies on the correct side of the bit curve:Xintcpt < X bit(n) (upper lobe only)

If this condition is not met, the butterfly chart is not correct; report an error code.

3. If these conditions are met, then the length of the inscribed square from this data pointis the absolute value of Xintcpt – X bit(n), i.e., | Xintcpt – X bit(n) |

4. Repeat steps 1-3 for all bit curve data points in the upper lobe. Record the length of the largest inscribed square.

5. Repeat steps 1-4 for the bitbar curve points in the upper lobe. For the bitbar curve, thesanity check condition is Xintcpt > X bar(n) (upper lobe only). The length of the largest

inscribed square for the bit and bitbar curves is the static noise margin for the upper lobe.

6. Repeat the whole procedure for the lower lobe.

The data point range for the lower lobe isXintcpt(m) < X bit(n) < Xintcpt(l) and  Yintcpt(l) < Y bar(n) < Yintcpt(m)

The sanity check conditions areBit curve: Xintcpt > X bit(n) (lower lobe only)

Bitbar curve: Xintcpt < X bar(n) (lower lobe only)

The static noise margin to be reported for this test is the lesser of the static noise margins

for the two lobes.

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 9/16

Pseudo-code for computing the Static Noise Margin:

Inputs:

1. Array of Vin and Vout for bit inverter (units: volts):

Vbit-in(1), Vbit-in(2), . . . Vbit-in(Npts)

Vbit-out(1), Vbit-out(2), . . . Vbit-out(Npts)2. Array of Vin and Vout for bitbar inverter (units: volts):

Vbitbar-in(1), Vbitbar-in(2), . . . Vbitbar-in(Npts)

Vbitbar-out(1), Vbitbar-out(2), . . . Vbitbar-out(Npts)

Output:

1. Static Noise Margin (units: mV)

Arrays used in computations:

This array keeps track of the crossings of the butterfly curve1. Crossing_array (crossing number, crossing index)

Outline of procedure:

1. Generate the X and Y arrays for the bit inverter curve. X = Vin, Y = Vout. LOOP index from 1 to Npts

 Xbit(index) = Vbit-in(index)

Ybit(index) = Vbit-out(index) NEXT index

2. Generate the X and Y arrays for the bitbar inverter. Note that the X and Y definitionsare switched from the bit inverter case. X = Vout, Y = Vin.

 LOOP index from 1 to Npts Xbar(index) = Vbar-out(Npts+1- index)

Ybar(index) = Vbar-in(Npts+1- index)

 NEXT index

3. Find the crossing points of the butterfly curve

 LOOP bit_index from 1 to Npts-1

 LOOP bitbar_index from 1 to Npts-1COMMENT: check for a crossing of the bit and bitbar segments, using the ten

cases described above

COMMENT: this counter keeps track of the number of crossingsCrossing_counter = 0

COMMENT: Case 1 both segments are vertical  IF Xbit(bit_index) = Xbit(bit_index+1) AND Xbar(bitbar_index) =

 Xbar(bitbar_index+1)

THEN 

COMMENT: no crossing  Xintcpt = -1

Yintcpt = -1

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 10/16

END IF 

COMMENT: Case 2 both segments are horizontal 

 IF Ybit(bit_index) = Ybit(bit_index+1) AND Ybar(bitbar_index) =

Ybar(bitbar_index+1)

THEN COMMENT: no crossing 

 Xintcpt = -1

Yintcpt = -1 END IF 

COMMENT: Case 3 bit segment is horizontal and bitbar segment is vertical  IF Ybit(bit_index) = Ybit(bit_index+1) AND Xbar(bitbar_index) =

 Xbar(bitbar_index+1)

THEN COMMENT: Intercept coordinates computed 

 Xintcpt = Xbar(bitbar_index)Yintcpt = Ybit(bit_index)

 END IF 

COMMENT: Case 4 bit segment is vertical and bitbar segment is horizontal   IF Xbit(bit_index) = Xbit(bit_index+1) AND Ybar(bitbar_index) =

Ybar(bitbar_index+1)THEN 

COMMENT: Intercept coordinates computed  Xintcpt = Xbit(bit_index)

Yintcpt = Ybar(bitbar_index)

 END IF 

COMMENT : Case 5 bit segment is horizontal and bitbar segment has finite

 slope

 IF Ybit(bit_index) = Ybit(bit_index+1) AND Xbar(bitbar_index) ≠  Xbar(bitbar_index+1) AND Ybar(bitbar_index) ≠ Ybar(bitbar_index+1)

THEN 

COMMENT: Intercept coordinates computed Slope_bar = (Ybar(bitbar_index+1) - Ybar(bitbar_index)) / 

(Xbar(bitbar_index+1) – Xbar(bitbar_index))

  Intercept_bar = ((Ybar(bitbar_index)× Xbar(bitbar_index+1)) – 

(Ybar(bitbar_index+1) × Xbar(bitbar_index+1))) / (Xbar(bitbar_index+1) –  Xbar(bitbar_index))

  Xintcpt = (Ybit(bit_index) - Intercept_bar ) / Slope_bar 

Yintcpt = Ybit(bit_index)

 END IF 

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 11/16

COMMENT: Case 6 bitbar segment is horizontal and bit segment has finite

 slope IF Ybar(bitbar_index) = Ybar(bitbar_index+1) AND Xbit(bit_index) ≠ 

 Xbit(bit_index+1) AND Ybit(bit_index) ≠ Ybit(bit_index+1)

THEN 

COMMENT: Intercept coordinates computed Slope_bit = (Ybit(bit_index+1) - Ybit(bit_index)) / (Xbit(bit_index+1)

- Xbit(bit_index))

  Intercept_bit = ((Ybit(bit_index)× Xbit(bit_index+1)) – 

(Ybit(bit_index+1) × Xbit(bit_index+1))) / (Xbitr(bit_index+1) – Xbit(bit_index)) Xintcpt = (Ybar(bitbar_index) - Intercept_bit ) / Slope_bit  Yintcpt = Ybar(bitbar_index)

 END IF 

COMMENT: Case 7 bit segment is vertical and bitbar segment has finite slope

 IF Xbit(bit_index) = Xbit(bit_index+1) AND Xbar(bitbar_index) ≠ 

 Xbar(bitbar_index+1) AND Ybar(bitbar_index) ≠ Ybar(bitbar_index+1)THEN 

COMMENT: Intercept coordinates computed 

Slope_bar = (Ybar(bitbar_index+1) - Ybar(bitbar_index)) / (Xbar(bitbar_index+1) – Xbar(bitbar_index))

  Intercept_bar = ((Ybar(bitbar_index)× Xbar(bitbar_index+1)) – 

(Ybar(bitbar_index+1) × Xbar(bitbar_index+1))) / (Xbar(bitbar_index+1) – 

 Xbar(bitbar_index)) Xintcpt = Xbit(bit_index)

Yintcpt = (Slope_bar  × Xbit(bit_index)) + Intercept_bar  END IF 

COMMENT: Case 8 bitbar segment is vertical and bit segment has finite slope IF Xbar(bitbar_index) = Xbar(bitbar_index+1) AND Xbit(bit_index) ≠ 

 Xbit(bit_index+1) AND Ybit(bit_index) ≠ Ybit(bit_index+1)THEN 

COMMENT: Intercept coordinates computed 

Slope_bit = (Ybit(bit_index+1) - Ybit(bit_index)) / (Xbit(bit_index+1)- Xbit(bit_index))

  Intercept_bit = ((Ybit(bit_index)× Xbit(bit_index+1)) – 

(Ybit(bit_index+1) × Xbit(bit_index+1))) / (Xbitr(bit_index+1) – Xbit(bit_index))

 Xintcpt = Xbar(bitbar_index)

Yintcpt = (Slope_bit  × Xbar(bitbar_index)) + Intercept_bit 

COMMENT: Case 9 both segments have finite slopes, and bit slope = bitbar  slope

 IF Xbit(bit_index) ≠ Xbit(bit_index+1) AND Ybit(bit_index) ≠ Ybit(bit_index+1)

 AND Xbar(bitbar_index) ≠ Xbar(bitbar_index+1) AND Ybar(bitbar_index) ≠ Ybar(bitbar_index+1) AND = (Ybit(bit_index+1) - Ybit(bit_index)) / 

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 12/16

(Xbit(bit_index+1) - Xbit(bit_index)) = (Ybar(bitbar_index+1) - Ybar(bitbar_index)) / 

(Xbar(bitbar_index+1) – Xbar(bitbar_index))THEN 

COMMENT: no crossing 

 Xintcpt = -1

Yintcpt = -1 END IF 

COMMENT: Case 10 both segments have finite slopes, and slopebit  ≠ slopebar   IF Xbit(bit_index) ≠ Xbit(bit_index+1) AND Ybit(bit_index) ≠ Ybit(bit_index+1)

 AND Xbar(bitbar_index) ≠ Xbar(bitbar_index+1) AND Ybar(bitbar_index) ≠ 

Ybar(bitbar_index+1) AND = (Ybit(bit_index+1) - Ybit(bit_index)) / (Xbit(bit_index+1) - Xbit(bit_index)) = (Ybar(bitbar_index+1) - Ybar(bitbar_index)) / 

(Xbar(bitbar_index+1) – Xbar(bitbar_index))

THEN COMMENT: Intercept coordinates computed 

Slope_bit = (Ybit(bit_index+1) - Ybit(bit_index)) / (Xbit(bit_index+1)- Xbit(bit_index))

  Intercept_bit = ((Ybit(bit_index)× Xbit(bit_index+1)) – 

(Ybit(bit_index+1) × Xbit(bit_index+1))) / (Xbitr(bit_index+1) – Xbit(bit_index))Slope_bar = (Ybar(bitbar_index+1) - Ybar(bitbar_index)) / 

(Xbar(bitbar_index+1) – Xbar(bitbar_index))

  Intercept_bar = ((Ybar(bitbar_index)× Xbar(bitbar_index+1)) – 

(Ybar(bitbar_index+1) × Xbar(bitbar_index+1))) / (Xbar(bitbar_index+1) –  Xbar(bitbar_index))

 Xintcpt = (Intercept_bar – Intercept_bit) / (Slope_bit – Slope_bar)

Yintcpt = (Slope_bit  ×  Intercept_bar – Slope_bar ×  Intercept_bit) / (Slope_bit – 

Slope_bar)

4. Check for crossing of the two segments.

 IF minimum(Xbit(bit_index), Xbit(bit_index+1)) ≤   Xintcpt 

 AND Xintcpt  ≤  maximum(Xbit(bit_index), Xbit(bit_index+1))

 AND minimum(Xbar(bitbar_index), Xbar(bitbar_index+1)) ≤   Xintcpt 

 AND Xintcpt  ≤  maximum(Xbar(bitbar_index), Xbar(bitbar_index+1))

  AND minimum(Ybit(bit_index), Ybit(bit_index+1))≤   Yintcpt 

 AND Yintcpt ≤  maximum(Ybit(bit_index), Ybit(bit_index+1))

 AND minimum(Ybar(bitbar_index), Ybar(bitbar_index+1)) ≤   Yintcpt 

 AND Yintcpt ≤  maximum(Ybar(bitbar_index), Ybar(bitbar_index+1))

THEN COMMENT: This is a crossing 

COMMENT: increment the crossing counter Crossing_counter = Crossing_counter +1

COMMENT: record the crossing location

Crossing_array(Crossing_counter, 1) = bit_indexCrossing_array(Crossing_counter, 2) = bitbar_index

 END IF 

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 13/16

 

 NEXT bit_index NEXT bitbar_index

5. Check for exactly three crossings, otherwise generate an error code

IF Crossing_counter ≠ 3THEN 

COMMENT: generate an error code

 Exit subroutine END IF  

6. Find the static noise margin (SNM) in the upper lobe of the butterfly curve6.1. measure the diagonals from the bit curve to the bitbar curve, in the upper lobe

COMMENT: initialize variables:

SNM_upper_lobe = 0 LOOP bit_index from Crossing_array(1, 1)to Crossing_array(2, 1) -1

 LOOP bitbar_index from Crossing_array(1, 2)to Crossing_array(2, 2) -1COMMENT: compute the equation for the bitbar line segment

 IF Xbitbar(bitbar_index+1) = Xbitbar(bitbar_index)THEN 

 Xintercept = Xbitbar(bitbar_index)

Yintercept = Xbitbar(bitbar_index) + Ybit(bit_index) - Xbit(bit_index) ELSE 

bitbar_slope = [Ybitbar(bitbar_index+1) - Ybitbar(bitbar_index)] / 

[Xbitbar(bitbar_index+1) - Xbitbar(bitbar_index)]bitbar_intercept = Ybitbar(bitbar_index) – 

[Xbitbar(bitbar_index) × bitbar_slope]

 Xintercept = [bitbar_intercept + Xbit(bit_index) – Ybit(bit_index)] / [1 – bitbar_slope]Yintercept = Xintercept + Ybit(bit_index) - Xbit(bit_index)

 END IF 

COMMENT: check that the intercept occurs inside the line segment of the

two bitbar data points under consideration: IF Xintercept ≥ Xbitbar(bitbar_index)

 AND Xintercept ≤ Xbitbar(bitbar_index + 1)

 AND Yintercept ≤ Ybitbar(bitbar_index) AND Yintercept ≥ Ybitbar(bitbar_index+1)

THEN 

COMMENT: the diagonal intercepts the bitbar line segmentCOMMENT: compute the SNM for this bit curve data point

SNM = Xbit(bit_index) – Xintercept 

COMMENT: compare the SNM for this data point to the max SNMfound so far:

 IF SNM > SNM_upper_lobe

THEN SNM_upper_lobe = SNM 

 END IF 

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 14/16

END IF 

  NEXT bitbar_index  NEXT bit_index

6.2. measure the diagonals from the bitbar curve to the bit curve, in the upper lobe

COMMENT: initialize variables: no initialization necessary  LOOP bit_index from Crossing_array(1, 1)to Crossing_array(2, 1) -1

 LOOP bitbar_index from Crossing_array(1, 2)to Crossing_array(2, 2) -1

COMMENT: compute the equation for the bit line segment IF Xbit (bit_index+1) = Xbit (bit_index)

THEN 

 Xintercept = Xbit (bit_index)Yintercept = Xbit (bit_index) + Ybitbar(bit_index) - Xbitbar(bit_index)

 ELSE 

bit_slope = [Ybit(bit_index+1) - Ybit(bit_index)] / [Xbit(bit_index+1) - Xbit(bit_index)]

bit_intercept = Ybit(bit_index) – [Xbit(bit_index) × bit_slope] Xintercept = [bit_intercept + Xbitbar(bitbar_index) – 

Ybitbar(bitbar_index)] / [1 – bit_slope]

Yintercept = Xintercept + Ybitbar(bitbar_index) –  Xbitbar(bitbar_index)

 END IF 

COMMENT : check that the intercept occurs inside the line segment of the two bit data points under consideration:

 IF Xintercept ≥ Xbit (bit_index)

 AND Xintercept ≤ Xbit (bit_index + 1)

 AND Yintercept ≤ 

Ybit (bit_index) AND Yintercept ≥ Ybit (bit_index+1)THEN 

COMMENT: the diagonal intercepts the bit line segment

COMMENT: compute the SNM for this bitbar curve data point

SNM = Xintercept - Xbitbar(bitbar_index)COMMENT: compare the SNM for this data point to the max SNM

found so far:

 IF SNM > SNM_upper_lobeTHEN SNM_upper_lobe = SNM 

 END IF 

 END IF   NEXT bitbar_index

  NEXT bit_index

7. Find the static noise margin (SNM) in the lower lobe of the butterfly curve

7.1. measure the diagonals from the bit curve to the bitbar curve, in the lower lobe

COMMENT: initialize variables:

SNM_lower_lobe = 0

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 15/16

   LOOP bit_index from Crossing_array(2, 1)+1 to Crossing_array(3, 1)-1

 LOOP bitbar_index from Crossing_array(2, 2)+1 to Crossing_array(3, 2)-1COMMENT: compute the equation for the bitbar line segment

 IF Xbitbar(bitbar_index+1) = Xbitbar(bitbar_index)

THEN 

 Xintercept = Xbitbar(bitbar_index)Yintercept = Xbitbar(bitbar_index) + Ybit(bit_index) - Xbit(bit_index)

 ELSE 

bitbar_slope = [Ybitbar(bitbar_index+1) - Ybitbar(bitbar_index)] / [Xbitbar(bitbar_index+1) - Xbitbar(bitbar_index)]

bitbar_intercept = Ybitbar(bitbar_index) – 

[Xbitbar(bitbar_index) × bitbar_slope]

 Xintercept = [bitbar_intercept + Xbit(bit_index) – Ybit(bit_index)]

 / [1 – bitbar_slope]Yintercept = Xintercept + Ybit(bit_index) - Xbit(bit_index)

 END IF 

COMMENT: check that the intercept occurs inside the line segment of thetwo bitbar data points under consideration: IF Xintercept ≥ Xbitbar(bitbar_index)

 AND Xintercept ≤ Xbitbar(bitbar_index + 1)

 AND Yintercept ≤ Ybitbar(bitbar_index) AND Yintercept ≥ Ybitbar(bitbar_index+1)

THEN 

COMMENT: the diagonal intercepts the bitbar line segmentCOMMENT: compute the SNM for this bit curve data point

SNM = Xintercept - Xbit(bit_index)

COMMENT: compare the SNM for this data point to the max SNM

found so far:  IF SNM > SNM_lower_lobeTHEN SNM_lower_lobe = SNM 

 END IF 

 END IF 

  NEXT bitbar_index  NEXT bit_index

7.2. measure the diagonals from the bitbar curve to the bit curve, in the lower lobeinitialize variables: no initialization necessary 

 LOOP bit_index from Crossing_array(2, 1)+1 to Crossing_array(3, 1)-1

 LOOP bitbar_index from Crossing_array(2, 2)+1 to Crossing_array(3, 2)-1COMMENT: compute the equation for the bit line segment

 IF Xbit (bit_index+1) = Xbit (bit_index)

THEN  Xintercept = Xbit (bit_index)

Yintercept = Xbit (bit_index) + Ybitbar(bit_index) - Xbitbar(bit_index)

 ELSE 

bit_slope = [Ybit(bit_index+1) - Ybit(bit_index)] / 

8/3/2019 Static Noise Margin Parametric Test Walsh v1p1

http://slidepdf.com/reader/full/static-noise-margin-parametric-test-walsh-v1p1 16/16

[Xbit(bit_index+1) - Xbit(bit_index)]

bit_intercept = Ybit(bit_index) – 

[Xbit(bit_index) × bit_slope]

 Xintercept = [bit_intercept + Xbitbar(bitbar_index) – Ybitbar(bitbar_index)] / [1 – bit_slope]

Yintercept = Xintercept + Ybitbar(bitbar_index) –  Xbitbar(bitbar_index)

 END IF COMMENT : check that the intercept occurs inside the line segment of 

the two bit data points under consideration:

 IF Xintercept ≥ Xbit (bit_index) AND Xintercept ≤ Xbit (bit_index + 1)

 AND Yintercept ≤ Ybit (bit_index)

 AND Yintercept ≥ Ybit (bit_index+1)THEN 

COMMENT: the diagonal intercepts the bit line segment

COMMENT: compute the SNM for this bitbar curve data pointSNM = Xbitbar(bitbar_index) - Xintercept COMMENT: compare the SNM for this data point to the max SNM

found so far:

 IF SNM > SNM_lower_lobeTHEN SNM_lower_lobe = SNM 

 END IF 

 END IF   NEXT bitbar_index

  NEXT bit_index

8. Compute the Static Noise Margin as the lower of the SNM values in the upper andlower lobes:Static Noise Margin = minimum(SNM_upper_lobe, SNM_lower_lobe)