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
  • Part 5: Checking11
  • Part 6: Coverage10
  • Part 7: Formal and Simulation10
    • What Formal Does
    • Bounded Proofs
    • Induction and Full Proofs
    • Assumptions and Over-Constraint
    • Where Formal Wins
    • Where Simulation Wins
    • Formal Apps
    • Combining Formal and Simulation
    • Proving DCRouter
    • Drills: Formal and Simulation
  • 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 7: Formal and Simulation
  1. Topics
  2. First Principles of Verification Strategy
  3. Part 7: Formal and Simulation
  4. Where Simulation Wins

Part 7 · Formal and Simulation · Senior (S)

Where Simulation Wins

Simulation is still the right tool for wide data paths, long sequences, deep state, whole systems and software, and for every rule nobody has written as a property. DCRouter's depth-7 proofs missed 17 of the 24 Bug Zoo bugs; the reasons sort into exactly the categories where simulation wins.

On this page

    Note

    Level: Senior (S) · Answers: When should we prove instead of test?

    Before this: Where Formal Wins

    Lesson 7.9's formal run catches 7 of the 24 Bug Zoo bugs. The other 17 are not formal's failures in any simple sense: some are deeper than the proof's bound, some break rules nobody wrote as formal properties, and some are about counts accumulated over hundreds of packets. Lesson 6.9's simulation testbench catches all 24. The split is not an accident; it follows the shapes of logic each method handles.

    When is formal the wrong tool, and simulation the right one?

    The obvious answer, and why it breaks

    The obvious conclusion from lesson 7.5 is to prove everything that can be proved and simulate the rest. In practice the boundary is about cost and reach, not possibility. Formal cost grows steeply with depth and state (lesson 7.2), every property must be written, and a chip runs software for billions of cycles. Simulation's cost grows only linearly with cycles, and its checks can be end-to-end comparisons against models that would be impractical as properties.

    The idea: depth, width, scale and unwritten rules

    Where simulation wins

    Why

    DCRouter example

    Deep state and long sequences

    Formal's cost explodes with depth; simulation's grows linearly

    BUG_1 (FIFO full) needs at least 10 cycles, BUG_22 at least 13, BUG_15 hundreds

    Wide data transformations

    Arithmetic, CRCs and encodings make solvers slow

    CRC checking (BUG_12, BUG_13) is natural for a scoreboard with a reference model

    Results accumulated over many transactions

    Counts and statistics are easy to compare at the end of a run

    PKT_CNT, ERR_CNT (BUG_11, 14, 16, 19)

    Whole systems and software

    Formal does not scale to processors running code

    DCRouter inside an SoC with a driver (Part 8)

    Rules not written as properties

    Formal checks only what is stated

    Most register rules had no formal property here

    Performance and statistics

    Throughput and latency distributions need long runs

    Fairness over time (lesson 5.9)

    Why DCRouter's proofs missed 17 bugs

    Reason

    Bugs

    A property covers the rule, but the bug is deeper than the depth-7 bound (lesson 7.9's full proof by induction catches both)

    BUG_1 (FIFO full), BUG_22 (credits during sleep)

    No formal property covers the rule (packet framing, error flags, counters, registers, configuration, sleep and wake)

    BUG_3, 4, 8, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 23

    Neither reason is fixed by "more formal" alone. More properties would catch some (a reset-value property would catch BUG_17 in the first cycle after reset), deeper or inductive proofs others, but each costs effort that simulation's existing scoreboard and register checks already spent. The right question is not "can formal do it?" but "what is the cheapest strong evidence for this rule?"

    Signals that a rule belongs to simulation

    • Its states are hundreds of cycles deep and no small configuration reaches them.

    • It is about data values computed by wide arithmetic.

    • It involves software, other blocks or the whole chip.

    • It is statistical: averages, distributions, throughput.

    • An end-to-end reference model expresses it more simply than properties do.

    How real teams draw the line

    Practice

    Purpose

    Formal for control blocks, simulation for data paths and systems

    Each method where its cost is low

    Formal and simulation results merged per rule

    One evidence ledger regardless of method (lesson 7.8)

    Re-evaluating the split as tools and designs change

    Yesterday's too-deep property may be today's easy proof

    What breaks

    A team (illustrative) mandated formal for every block. The data-path blocks' proofs never converged, engineers wrote weaker and weaker properties to make them finish, and the eventual "proved" results checked almost nothing. A scoreboard against the existing C model would have given strong evidence in a week. Formal everywhere is as much a mistake as formal nowhere.

    Why this matters

    Senior lens. Assign each rule to the method that gives the strongest evidence for the least effort. Deep, wide, statistical and system-level rules go to simulation; control rules with short reach go to formal. Measure the split with something like a bug-catch matrix rather than by policy.

    Interview

    Asked: "When is formal the wrong tool?"

    Weak answer: When the design is too big.

    Strong answer: When the rule needs long sequences or deep state, wide data transformations, results accumulated over many transactions, whole-system behaviour with software, or statistics, and whenever the rule isn't written as a property at all. Formal cost grows steeply with depth while simulation grows linearly. On the course's router, depth-7 proofs caught 7 of 24 planted bugs: two others were covered by a property but deeper than the bound, and fifteen broke rules that only simulation's scoreboard, assertions and register checks covered.

    Follow-ups: (1) Could more properties have closed the gap? (2) How do you decide which method owns a rule?

    Check yourself Why is CRC checking (BUG_12, BUG_13) a better fit for the scoreboard than for formal?

    The CRC is wide data computation over a whole packet; a reference model computes it directly, while a solver must reason about it symbolically over many cycles.

    Check yourself Name one missed bug that one more formal property would catch quickly, and one that would still need simulation or a deeper proof.

    BUG_17: a property that CTRL holds 0x3F after reset fails in the first cycle after reset. BUG_15: saturation after 255 errors is far beyond a short bounded proof.

    Key takeaways

    • Simulation wins on deep state, wide data, accumulated results, whole systems, statistics and unwritten rules.

    • DCRouter's proofs missed 17 bugs: 2 deeper than the bound, 15 outside the property set.

    • Assign each rule to the cheapest strong evidence, not to a method by policy.

    Keep going

    Next: Lesson 7.7, Formal Apps. Formal tools aimed at one question each.

    Related topics

    • Part 7 overview: Formal and Simulation

    Previous

    77 / 160

    Next: Formal Apps

    Up next

    Up nextFormal Apps

    Sign in to save progress

    Practice this lessonReport an error

    See also

    • What Formal Does
    • Bounded Proofs
    • Induction and Full Proofs