All guides
Design Verification9 min readUpdated Aug 8, 2026

UVM Testbench Architecture: A Complete Walkthrough

How a UVM testbench is built end to end — test, environment, agent, sequencer, driver, monitor, scoreboard and coverage — with a diagram, code and the questions interviewers ask.

The Universal Verification Methodology (UVM) is the industry-standard SystemVerilog library for building reusable, constrained-random verification environments. Because verification consumes roughly 70% of a modern design cycle, UVM structure is the single most-tested topic in Design Verification interviews. This guide walks the whole testbench top to bottom.

Key idea. A UVM testbench is really one idea repeated: small, reusable components that talk over standard TLM interfaces, so the same environment scales from a single block up to a full SoC.

The big picture

UVM testbench architectureA UVM test contains an environment holding an agent (sequencer, driver, monitor), a scoreboard and a coverage collector, all connected to the design under test.uvm_testuvm_envuvm_agentSequencerDriverMonitorScoreboardCoverageDUTdesign under testseq_itemdrive pinssample pinsanalysis port
A UVM test builds an environment; the agent drives and observes the DUT while the scoreboard and coverage collector check correctness and completeness.

Read it top-down. The test picks a configuration and starts a stimulus sequence. It builds an environment that contains one or more agents. Each agent bundles the three components that touch the pins — a sequencer, a driver and a monitor — while the scoreboard and coverage collector sit alongside and judge the result.

The components you must know

ComponentResponsibility
uvm_testTop-level: selects config + starts the top sequence.
uvm_envContainer that wires agents, scoreboard and coverage together.
uvm_agentReusable bundle: sequencer + driver + monitor for one interface.
uvm_sequencerArbitrates sequences and hands transactions to the driver.
uvm_driverConverts transactions into pin-level activity on the DUT.
uvm_monitorPassively samples pins and broadcasts observed transactions.
uvm_scoreboardCompares observed behaviour against a reference model.
coverage collectorSubscribes to the monitor and samples functional coverage.
The canonical UVM component hierarchy.

How a transaction flows

  1. A sequence creates a transaction (a uvm_sequence_item) and calls start_item/finish_item.
  2. The sequencer arbitrates and hands the item to the driver.
  3. The driver calls get_next_item, wiggles the DUT pins per the protocol, then calls item_done.
  4. The monitor samples those pins independently and reconstructs a transaction.
  5. The monitor broadcasts it on an analysis port; the scoreboard and coverage collector both receive it.
  6. The scoreboard compares against a reference model; coverage samples the bins that were hit.
driver.sv — the sequencer–driver handshake
task my_driver::run_phase(uvm_phase phase);
  forever begin
    seq_item_port.get_next_item(req);   // block until a transaction
    drive_transfer(req);                // wiggle the pins
    seq_item_port.item_done();          // release the sequencer
  end
endtask

Active vs passive agents

An agent's is_active field decides whether it drives. UVM_ACTIVE builds the sequencer and driver (it stimulates the interface); UVM_PASSIVE builds only the monitor. This one switch is why UVM reuses so well: a block-level agent that drove an interface becomes a passive checker when the block is dropped into an SoC and driven by real neighbours.

Phasing in one minute

Components run through ordered phases. build_phase constructs children (top-down), connect_phase wires TLM ports (bottom-up), and the time-consuming run_phase is where stimulus actually happens. A test stays alive by raising an objection at the start of run_phase and dropping it when done.

Watch out. The three classic UVM bugs interviewers probe: forgetting to register a component with the factory (the uvm_component_utils macro), passing handles by hand instead of the config_db, and never raising or dropping objections so the test ends at time 0.

Common interview questions

  • What is the difference between a driver and a monitor, and why is the monitor always passive?
  • Walk me through the sequencer–driver handshake (get_next_item vs item_done).
  • What do UVM_ACTIVE and UVM_PASSIVE change, and when would you flip an agent to passive?
  • How does a monitor get data to both the scoreboard and coverage — analysis port vs export?
  • Why use the factory and config_db instead of new() and direct handles?
  • How do objections control when the run phase ends?

Put this into practice

Drill Design Verification questions from real interview loops, then book a mock with a mentor who runs them.

Related guides