Skip to question and answer

Hardware interview practice

How to Connect a UVM Sequencer and Driver

EasyUVM ComponentsMultiple choice

Which connection enables a uvm_driver to pull sequence items from its sequencer?

Answer choices

  1. A. sequencer.seq_item_port.connect(driver.seq_item_export)
  2. B. driver.seq_item_port.connect(sequencer.seq_item_export)
  3. C. driver.analysis_port.connect(sequencer.analysis_imp)
  4. D. sequencer.req_port.connect(driver.rsp_export)

Concise answer

The answer and the key reason

Connect `driver.seq_item_port` to `sequencer.seq_item_export`. The driver initiates the pull operations through its port, while the sequencer exposes the implementation that arbitrates and supplies items. This connection normally belongs in the active agent’s `connect_phase`.

Deeper explanation

Work through the implementation and tradeoffs

The driver-side `seq_item_port` is the calling endpoint for methods such as `get_next_item`, `item_done`, and related request-response operations. The sequencer-side `seq_item_export` presents the implementation of that protocol. UVM TLM connections are written from the port that makes calls toward the export that serves them.

Both components should already have been created before this binding occurs, making `connect_phase` the natural location. An active agent builds and connects the driver and sequencer because it generates stimulus. A passive agent generally contains only observation infrastructure, so creating or wiring this pull path there would serve no purpose.

What to remember

  • Driver port is initiator
  • Sequencer export provides items
  • Connect in connect_phase

Practice the complete prompt

Explain it first, then compare the reviewed solution.

Open this exact question in the practice bank to attempt it, check your reasoning, and access the full member solution.Practice this question

Keep practicing

UVM ComponentsUVM get_next_item and item_done HandshakeUVM ComponentsHow a UVM Analysis Port WorksReference ModelsHow to Build an Out-of-Order UVM Scoreboard