TDEB Top Bar

Trending
Semiconductor Industry News — The Digital Electronics Blog
Follow Us

TDEB Masthead

The Semiconductor Hub

Semiconductors.  Chips and Systems.  Innovation.

Indexed by leading Search Engines, AI and referenced by Engineers worldwide 500+ Articles 10M+ Pageviews 30+ Reports 50+ Citations

Interview Question: Scan Test Time Calculation

Murugavel Ganesan
by
0
Share Facebook X LinkedIn WhatsApp Email

A 1.2 GHz chip has scan chains of length 30,000 bits, 20,000 bits, 24,000 bits, 25,000 bits, and two of 12,000 bits. 500,000 test vectors are used for each scan chain. The tests are run at 50% of full speed.

What is the total test time?

Answer: about 25 seconds. The chains shift in parallel, so the longest chain (30,000 bits) sets the time: 500,000 x 30,000 shift cycles at 600 MHz is 25 s. (An earlier version of this post gave 20.8 s, which is the result for a 25,000-bit longest chain, not the 30,000-bit chain in the question.)

What the question is testing

This is a classic design-for-test (DFT) interview question. It checks whether you understand how scan testing spends its time, and whether you can spot the one number that matters. Most of the data in the question is there to tempt you into adding things up.

Scan testing in one paragraph

In a scan design, the flip-flops of the chip are stitched into long shift registers called scan chains. To apply one test pattern (one "vector"), the tester shifts a pattern of ones and zeros into every chain, pulses the functional clock once so the logic between the flip-flops captures its response, and then shifts the captured values out to compare them with the expected result. The shift-out of one pattern overlaps with the shift-in of the next, so in steady state each pattern costs roughly one full chain length of shift cycles plus a capture cycle.

Why only the longest chain counts

All the chains have their own scan-in and scan-out pins and shift at the same time on the same clock. A pattern is not finished until the longest chain is fully loaded, so the shorter chains simply finish early and wait. That is why the answer depends on the 30,000-bit chain and not on the total of 123,000 flip-flops.

Why the 50% figure matters

The chip's functional clock is 1.2 GHz, but the test runs at half of that, 600 MHz. Shift clocks are often slower than the functional clock because shifting toggles a large share of the flip-flops at once, which raises power and IR drop. The question builds that in by saying the test runs at 50% of full speed.

How to answer in an interview

  • State the assumption first: all chains shift in parallel, and shift-out overlaps the next shift-in.
  • Pick the longest chain: 30,000 bits.
  • Work out the test clock: 50% of 1.2 GHz is 600 MHz.
  • Multiply and divide: 500,000 x 30,000 / 600 MHz = 25 s.
  • Then mention what you left out (capture cycles, the final unload, tester overhead) and how you would cut the time (balance the chains, add more chains, use compression).

Deep dive: the numbers and details

This part holds the equation, the full worked example and the variations an interviewer may ask next. Skip it if the overview is all you need.

The test time equation

For N patterns, a longest chain of L flip-flops and a shift clock of frequency f, with one capture cycle per pattern and the unload of each pattern overlapped with the load of the next:

Total cycles  = N x (L + 1) + L
Test time     = Total cycles / f

The trailing L is the final unload of the last pattern. When N and L are large, the formula is very close to N x L / f.

Worked example with the numbers in the question

QuantityValue
Chain lengths30,000; 20,000; 24,000; 25,000; 12,000; 12,000
Total scan flip-flops123,000
Longest chain L30,000
Patterns N500,000
Test clock f0.5 x 1.2 GHz = 600 MHz (period 1.667 ns)
Total cycles500,000 x 30,001 + 30,000 = 15,000,530,000
Test time15,000,530,000 / 600,000,000 = 25.0 s

The capture cycles and the final unload add less than a millisecond, so the answer is 25 seconds to three significant figures.

The common wrong answers and where they come from

MistakeCalculationResult
Correct (longest chain, 600 MHz)500,000 x 30,000 / 600 MHz25.0 s
Forgot the 50% speed500,000 x 30,000 / 1.2 GHz12.5 s
Used a 25,000-bit chain500,000 x 25,000 / 600 MHz20.8 s
Added all chains as if one serial chain500,000 x 123,000 / 600 MHz102.5 s
Added the chains and forgot the 50%500,000 x 123,000 / 1.2 GHz51.25 s

If an interviewer says the answer is 20.8 s, ask whether the longest chain is really 30,000 bits. Pointing that out politely is a good sign that you checked the numbers instead of matching a memorized answer.

Follow-up 1: what if the chains were balanced?

The six chains hold 123,000 flip-flops. Spread evenly, each chain would hold 20,500 bits. Test time becomes 500,000 x 20,500 / 600 MHz = 17.08 s, a saving of about 32% with no change to the patterns or the clock. This is why DFT tools try to balance chain lengths during scan insertion: the longest chain sets the cost for everyone.

Follow-up 2: what if you had more scan pins?

Each extra chain needs a scan-in and a scan-out pin (or a shared pin through muxing). With 12 balanced chains, each holds 10,250 bits and the time drops to 500,000 x 10,250 / 600 MHz = 8.54 s. Doubling the chain count halves the time, as long as the tester has channels to drive them.

Chains (balanced)Bits per chainTest time at 600 MHz
1123,000102.5 s
620,50017.08 s
1210,2508.54 s
245,1254.27 s

Follow-up 3: how scan compression changes the picture

Scan compression places a decompressor between a few scan-in pins and many short internal chains, and a compactor between the chains and the scan-out pins. The tester still drives only a few pins, but internally there may be hundreds of chains, each only a few hundred bits long. Using the same equation, 123,000 flip-flops split into 400 internal chains gives chains of about 308 bits, and 500,000 patterns then need about 500,000 x 308 / 600 MHz = 0.26 s. Real numbers depend on the compression ratio the design can tolerate and on how many extra patterns compression needs, but the principle is the same: shorter internal chains mean fewer shift cycles per pattern.

Follow-up 4: why shift slower than the functional clock?

  • Power: during shift, a random pattern toggles roughly half the scan flip-flops every cycle, far more activity than normal operation.
  • IR drop: that activity draws current spikes that can drop the supply enough to cause false failures.
  • Scan path timing: the scan connections are often routed without the care given to functional paths, and hold-time fixes on them add delay.
  • Tester limits: the tester channels driving the scan pins have their own maximum data rate.

So "50% of full speed" in this question is a convenient number. In practice the shift frequency is chosen from power and tester limits, while capture for at-speed tests may use the functional clock.

Follow-up 5: why test time matters

Every second a part spends on the tester is paid for in tester time across every unit shipped. Cutting the test from 25 s to 17 s by balancing chains, or to a fraction of a second with compression, multiplies across millions of parts. That is the business reason behind the arithmetic, and a good closing line in an interview.

Summary

  • Parallel chains: only the longest chain sets shift cycles per pattern.
  • Test time is about N x L / f, plus one capture cycle per pattern and one final unload.
  • For this question: 500,000 x 30,000 / 600 MHz = 25 s.
  • Balancing, more chains and compression all work by reducing L.
Murugavel Ganesan
About the Author
Murugavel Ganesan
Product Director | SerDes · IVN · Edge AI · Compute | Ex Intel · Infineon

A semiconductor product leader working across product architecture, definition, strategy, and silicon and software execution, from concept through volume production. He has worked with teams across Asia, Europe and the USA, including at Intel, Infineon and ArrayComm.

His work covers ASICs, SoCs, FPGAs and chiplets for wireless, wireline, automotive, IoT and AI, including PCIe, CXL and DDR interfaces alongside RF and mixed-signal design.

Share Facebook X LinkedIn WhatsApp Email

Post a Comment

0 Comments

Your comments will be moderated before it appears here.

Post a Comment (0)

#buttons=(Ok, Go it!) #days=(20)

Our website uses cookies to enhance your experience. Learn more
Ok, Go it!