Skip to question and answer

Hardware interview practice

How to Build an Out-of-Order UVM Scoreboard

HardReference ModelsMultiple choice

A DUT can return responses out of order and may reuse transaction IDs after reset. Which scoreboard design is most robust?

Answer choices

  1. A. Compare expected and actual queues strictly by arrival position
  2. B. Disable the monitor during reset but retain all pre-reset expectations indefinitely
  3. C. Sort all responses by payload value before comparing
  4. D. Match associative entries by a key that includes transaction ID and reset epoch, and define an explicit reset flush/cancel policy

Concise answer

The answer and the key reason

Use identity-based matching keyed by transaction ID plus a reset generation, and define what reset does to outstanding expectations. This supports out-of-order completion while preventing a post-reset response from matching stale pre-reset state that happened to use the same ID.

Deeper explanation

Work through the implementation and tradeoffs

Arrival-order queues assume responses return in request order, which the DUT explicitly does not guarantee. Instead, the scoreboard should index expected results by protocol identity and retrieve the corresponding entry when an actual response arrives. If a key can have multiple simultaneous requests, its value can hold a queue or another unique sequence field.

Reset makes the ID alone insufficient because the same numeric value may describe traffic from two different lifetimes. Incrementing an epoch on reset separates those lifetimes. The scoreboard must also document whether reset flushes, cancels, or later permits outstanding operations, then report unmatched, duplicate, missing, and late responses according to that policy.

What to remember

  • Match by transaction identity
  • Include a reset epoch
  • Define reset disposition

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 ComponentsHow to Connect a UVM Sequencer and DriverUVM ComponentsUVM get_next_item and item_done HandshakeUVM ComponentsHow a UVM Analysis Port Works