The Team, the Cost and the Schedule

Chip verification is a team sport with a budget. Learn who owns what and when each mode enters the project. Then work out what a regression costs from a measured speed.

You Will Be Able To

  • Name the teams of chip verification and what each owns.
  • Place the three modes on a project timeline.
  • Work out regression time from cycles and a measured simulator speed.
Lesson
V1.6
Time
20 min
Runs on
Your browser
Check
5 questions

The nightly regression finished at 9:40 in the morning, and the team waited two hours for results. Somebody proposes cutting half the tests. Before you agree, can you say where the time actually goes?

A Chip Project and Its Three ModesStep through the project from first RTL to tape-out. Each phase uses the modes that suit it, and each team has its part.
  • Test
  • Manager
  • Processor
  • Model
  • Result
  • Step
  • Data
A Chip Project and Its Three ModesStep through the project from first RTL to tape-out. Each phase uses the modes that suit it, and each team has its part. test Block benches block teams, from dayone manager Without CPU first integration,week one processor With CPU once the core andboot code run model Fast platforms once the RTL isstable result Nightlyregression every test, everynight step Tape-out plan closed, sign-off blocks deliveredcore integratedRTL stabletests joinrows close
  1. test Block benchesblock teams, from day one
    • blocks delivered → Without CPU
  2. manager Without CPUfirst integration, week one
    • core integrated → With CPU
    • tests join → Nightly regression
  3. processor With CPUonce the core and boot code run
    • RTL stable → Fast platforms
  4. model Fast platformsonce the RTL is stable
  5. result Nightly regressionevery test, every night
    • rows close → Tape-out
  6. step Tape-outplan closed, sign-off
  1. Block level first

    Block teams prove their blocks while the chip is still being joined.

  2. Without CPU early

    The first chip tests drive the bus without the core, often before boot code exists.

  3. With CPU next

    When the core and boot code run, firmware tests begin and continue to tape-out.

  4. Fast platforms later

    Long software moves to fast platforms once the RTL changes slowly.

  5. The regression closes the plan

    Every test runs every night, and plan rows close until sign-off.

Read the diagram as text
  • Block benches: block teams, from day one
  • Without CPU: first integration, week one
  • With CPU: once the core and boot code run
  • Fast platforms: once the RTL is stable
  • Nightly regression: every test, every night
  • Tape-out: plan closed, sign-off
  • Block benches → Without CPU: blocks delivered
  • Without CPU → With CPU: core integrated
  • With CPU → Fast platforms: RTL stable
  • Without CPU → Nightly regression: tests join
  • Nightly regression → Tape-out: rows close

A typical order, not a law. Real projects overlap the phases.

Before You Start

Read Three Ways to Drive a Chip and The Chip-Level Verification Plan first. The SoC Design Flow and Who Owns What shows the design flow and who owns each step.

The labs of this module are small slices. They use the real addresses and interrupt numbers of ap_soc v1.5, and each page says so. The whole chip runs from module V2 on, and in the guided run of the fundamentals module.

Five questions this page answers
Question
1Which teams take part in chip verification, and what does each own?
2When does each mode enter a project?
3Why do bugs found late cost more?
4How do you work out what a regression costs?
5Why does boot time matter in every with-CPU test?

The Idea: Time Is the Budget

A chip project has a fixed date and a growing pile of tests. Every with-CPU test pays for a boot before it does anything useful. Every test runs at the speed of the simulator, which you can measure. So the cost of a regression is not a mystery: it is cycles divided by speed, times the number of tests.

The other budget is people. Block teams, the chip team, the firmware team and the design team each own a part. Mehta notes that verification takes a large share of a whole project's effort. He argues that it should drive how the design is done.

New Words

New words on this page
WordMeaning
Chip verification teamThe engineers who own the chip-level plan, its bench and its regression.
Firmware teamThe engineers who write boot code and drivers; chip tests reuse their code.
Simulator speedCycles simulated per second of real time, measured on a given machine.
Boot costThe cycles a with-CPU test spends before main, before it tests anything.
Tape-outThe day the design is sent to be made. After it, a fix needs new silicon.

Who Owns What, and When

The teams of chip verification
TeamOwnsHands to the chip team
Block teamsEach block's bench and its rare casesPassed results, monitors and checkers for reuse
Chip verification teamThe plan, the chip bench, the regression, sign-offBug reports with a class and an owner
Firmware teamBoot code, drivers, the headerCode that chip tests run
Design teamThe RTL and its fixesNew releases of the chip

Why do late bugs cost more? Each later stage adds work to undo. A block fix needs one rerun. A chip fix needs a new release and a full regression, and a fix after tape-out needs new silicon. This page gives no multiplier, because no number in our library fits every project. The direction is certain; the size is not.

The Rules

  1. Rule 1: Measure speed, then do the sum.

    Seconds per test is cycles per test divided by cycles per second.

  2. Rule 2: Count boot in every with-CPU test.

    Short tests can spend a large share of their time booting.

  3. Rule 3: Find bugs as early as the mode allows.

    Without-CPU tests start before the core is ready; use them.

Sources for These Rules

Mehta, ASIC/SoC Functional Design Verification, section 2.1: verification challenges and the share of effort.

Mehta, section 15.5: verification across the product life cycle, and why it should drive the design.

Speeds measured on the laptop with the five-stage core alone in its bench (docs/soc-verification-plan.md section 6.2; facts ledger TL-095 to TL-097). The whole chip will be slower.

Now Run It: Where the Night Goes

The lab does the regression sum for two measured simulators. Icarus runs about 9,200 cycles a second and Verilator about 534,000, both with the core alone on the laptop. The test sizes are exercise values: a boot of 40,000 cycles and a body of 2,100,000. It rounds each time up to a whole second or minute, and the boot share down.

Printed by the lab (Icarus). Speeds measured; test sizes are exercise values.
Icarus    one test 233 s, 300 tests 1165 min
Verilator one test 5 s, 300 tests 25 min
boot share of each test: 18 per thousand

On Icarus one test takes 233 seconds, and 300 tests take 1,165 minutes: almost twenty hours. On Verilator the same test takes 5 seconds, and 300 tests take 25 minutes. Same tests, same chip, a factor of about fifty from the simulator alone.

The last line says boot is 18 parts in a thousand of each test here. That is small because the body is long. Shorten the body and the boot share grows: the predict question shows how far.

The Trap: Cutting Tests Before Measuring

The easy answer to a slow regression is to delete tests. But each deleted test may close a plan row, and nobody notices the row reopen. Measure first: which simulator, how many cycles per test, how much of it is boot.

Often the fix is elsewhere. A faster simulator saves more than any cut, and so does a back-door load instead of a front-door boot. Moving long software to a fast platform helps too, and the plan stays closed.

Try It

Run the lab. Check one line by hand: 2,140,000 cycles at 534,000 a second.

Make the boot as long as the body: boot = 2100000. Predict the last line.

Change the number of tests to 1,000. Predict the Verilator minutes.

RUNIcarus Verilog · in your browser
Edit the code, then run it
Expected: Icarus one test 233 s, 300 tests 1165 min Verilator one test 5 s, 300 tests 25 min boot share of each test: 18 per thousand

Check Yourself

Predict the outputThe boot grows to 2,100,000 cycles, as long as the body. What is the last line the lab prints?
// Regression time from measured simulator speeds (laptop, ap_rv32 alone in its bench,
// docs/soc-verification-plan.md §6.2): Icarus 12.0 about 9,200 cycles a second, Verilator 5.032 about
// 534,000. Test sizes are exercise values: boot 40,000 cycles, body 2,100,000 cycles.
module tb;
  int unsigned boot = 2100000, body = 2100000, tests = 300;
  int unsigned speed [2];
  string name [2];
  initial begin
    speed[0] = 9200; name[0] = "Icarus   ";
    speed[1] = 534000; name[1] = "Verilator";
    foreach (speed[i]) begin
      int unsigned per, all;
      per = (boot + body + speed[i] - 1) / speed[i];   // seconds per test, rounded up
      all = (per * tests + 59) / 60;                   // minutes, rounded up
      $display("%s one test %0d s, %0d tests %0d min", name[i], per, tests, all);
    end
    $display("boot share of each test: %0d per thousand", boot * 1000 / (boot + body));
  end
endmodule
ConceptSeconds per test equals...
ConceptWho owns the chip-level plan and its regression?
ConceptIn the lab, why is Verilator about fifty times faster than Icarus?
ConceptWhich mode can start in the first week of integration?

Common Mistakes

Wrong Guess regression time.

Speed varies by a factor of fifty between simulators.

Fix Measure cycles per second and do the sum.

Wrong Ignore boot in short tests.

A short test can spend most of its time booting.

Fix Count boot cycles in every with-CPU test, or load memory by back door.

Wrong Quote a fixed cost multiplier for late bugs.

No single number fits every project.

Fix Say the direction: each later stage adds work to undo.

Remember

  • Block teams, the chip team, the firmware team and the design team each own a part.
  • Without-CPU tests start first, with-CPU tests follow, fast platforms come once RTL is stable.
  • Regression time is cycles per test divided by measured speed, times the number of tests.
  • Boot is paid in every with-CPU test; late bugs cost more, by an amount no single number captures.

Practice

Report a problem with this page