Skip to content
DenseChip
Learn
PracticeCode labInterview

DenseChip

Navigate

Menu

LearnPracticeCode labInterview

Tools

All toolsSV editorCode repoResume
DenseChip

Practice, courses, and chip-design tools in one focused workspace.

LearnPracticeCode labInterviewToolsLearning paths

© 2026 DenseChip

AboutContactPrivacyTerms
Skip to lesson

Course contents

  • How to Use This Course
  • Reading Paths
  • Concept Map
  • Meet DCRouter
  • Glossary
  • Part 0: What Verification Is8
  • Part 1: What Can Go Wrong11
  • Part 2: Specifications as Checkable Rules8
  • Part 3: Observability and Controllability7
  • Part 4: Stimulus11
    • Directed Tests
    • Why Random Works
    • Constrained Random
    • Distributions and Bias
    • The Long Tail
    • Scenarios and Layered Stimulus
    • Error Injection
    • Timing and Back-Pressure
    • Seeds and Regressions
    • Hunting the Zoo with Random
    • Drills: Stimulus
  • Part 5: Checking11
  • Part 6: Coverage10
  • Part 7: Formal and Simulation10
  • Part 8: Verification Levels and Reuse8
  • Part 9: Planning and Risk9
  • Part 10: Emulation and Prototyping8
  • Part 11: Post-Silicon Validation8
  • Part 12: Bug Economics8
  • Part 13: Debug7
  • Part 14: Sign-Off7
  • Part 15: Verification in Context8
  • Part 16: Case Studies5
  • Part 17: Capstones5
  • Part 18: Interview Preparation6
Loading lesson

‹Part 4: Stimulus
  1. Topics
  2. First Principles of Verification Strategy
  3. Part 4: Stimulus
  4. Drills: Stimulus

Part 4 · Stimulus · All levels

Drills: Stimulus

Interview questions, a whiteboard exercise and a ten-question checkpoint for Part 4.

On this page

    Answer each question out loud before opening it. If you miss more than three in the checkpoint, revisit the lessons linked at the end.

    Interview questions

    Check yourself What are directed tests good for?

    Bring-up, specific deep states, register and reset checks, corners random will not reach, and a permanent test for every fixed bug; each is a single point in a feature's space.

    Check yourself Why does random testing find bugs directed tests miss?

    Its choices do not share the writer's blind spots, and every random transaction exercises timing and combinations for free.

    Check yourself Why constrain random stimulus?

    To keep it inside the legal space; constraints model the environment, with explicit modes for deliberate errors.

    Check yourself How do you hit rare cases with random?

    Shape the distribution: keep most weight broad and put extra weight on boundary values, since corners multiply their probabilities.

    Check yourself How long to hit a one-in-a-million case?

    About a million trials on average, and about three million for 95% confidence.

    Check yourself How do you verify error handling?

    Inject every fault type deliberately, crossed with modes, check every response and side effect, drive the limits and check recovery.

    Check yourself What randomisation finds race bugs?

    Random timing: source gaps, sink stalls, changing profiles and independent settings per port, with an audit of hidden state at the end.

    Check yourself A test fails once in 1,000 seeds. Now what?

    Reproduce the seed on the same build, debug it, keep the seed and a directed test, and add bias or coverage for the rare trigger.

    Whiteboard exercise

    Task. You inherit a random regression for a cache controller: uniform random addresses over 4 GB, reads and writes 50/50, no idle cycles, a memory model that always answers in 2 cycles, one fixed seed per test. List what this stimulus will rarely or never exercise, and how you would change it.

    Check yourself Open a model answer

    Rarely or never: hits (uniform addresses over 4 GB almost never reuse a line, so the cache misses constantly), conflicts on one set and evictions of dirty lines, read-after-write to the same line, back-pressure and slow or out-of-order memory responses, idle periods (power or clock gating), error responses from memory, and anything that varies by seed. Changes: constrain addresses to a small working set with a mixture (most traffic in a few sets, some uniform) to create hits, conflicts and evictions; flows of accesses to the same line; a memory model with random latency, stalls and error injection; random idle gaps; layered scenarios such as fill, thrash, flush; fresh seeds nightly with many seeds per test; and coverage on hit, miss, eviction and conflict to see what was reached.

    Checkpoint: ten questions

    Check yourself 1. How many Bug Zoo bugs did the nine directed tests catch?

    10 of 24.

    Check yourself 2. Why did the directed suite miss BUG_13?

    Its one bad-CRC packet was low priority; the bug only affects high-priority packets.

    Check yourself 3. About how many uniform random packets does it take to see all 128 DCRouter header kinds?

    About 695 (n·H_n).

    Check yourself 4. What is the difference between := and :/ in a dist?

    := gives the weight to every value of a range; :/ shares it across the range.

    Check yourself 5. How many of the 128 header kinds can a corners-only length distribution reach?

    24.

    Check yourself 6. Which layer of stimulus makes priority contention (BUG_6, BUG_7) happen?

    The traffic pattern layer: a hot spot of mixed-priority inputs on one output.

    Check yourself 7. Which four bugs did error injection add over the directed suite on the error path?

    BUG_13, BUG_14, BUG_15 and BUG_19.

    Check yourself 8. Which two bugs did random stalls add over smooth delivery of the same packets?

    BUG_20 and BUG_22.

    Check yourself 9. With how many of 20 seeds did the random hunt catch BUG_21?

    16.

    Check yourself 10. Which five bugs escaped all four Part 4 tests, and why?

    BUG_5, 6, 7 (reached but no fairness or priority check) and BUG_16, 23 (never reached: no packet-counter clear, no disabled port).

    Revisit

    • 4.1 Directed Tests

    • 4.2 Why Random Works

    • 4.3 Constrained Random

    • 4.4 Distributions and Bias

    • 4.5 The Long Tail

    • 4.6 Scenarios and Layered Stimulus

    • 4.7 Error Injection

    • 4.8 Timing and Back-Pressure

    • 4.9 Seeds and Regressions

    • 4.10 Hunting the Zoo with Random

    Keep going

    Next: Part 5: Checking. How do we know the output is right?

    Previous

    50 / 160

    Next: Part 5: Checking

    Up next

    Up nextPart 5: Checking

    Sign in to save progress

    Practice this lessonReport an error

    See also

    • Directed Tests
    • Why Random Works
    • Constrained Random