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 Puzzle Bank
  • SystemVerilog Language Puzzles25
  • Difficulty Guide
  • Full Topic Map
  • Interview-Day Tips
  • OOP & Testbench Puzzles25
  • Concurrency & Timing Puzzles25
  • Randomization & Constraint Puzzles25
  • SVA Assertion Puzzles25
  • Functional Coverage Puzzles25
  • Logic & Aptitude Puzzles25
  • Scenario & Debug Puzzles25
    • Testbench Debug Puzzles: Why Did the Test Hang?
    • Deadlock Scenario Puzzles: Objection and Phase Stalls
    • Scoreboard Puzzles: Mismatch or Ordering Bug?
      • Out-of-Order Responses Miscompared as Corruption
      • Missing First Transaction After Reset
      • Duplicate Transactions from Handle Reuse
      • Mismatch Cascade from Incorrect Pop Policy
      • End-of-Test Draining Missing
      • Duplicate Expected Entries from Predictor Retry Path
    • Real Interview Rounds: End-to-End Debug Walkthrough
    • Scenario & Debug Puzzles: Tricky Q&A
  • Interview Prep: Puzzle Rounds5
  • DV Puzzle Cheatsheet
Loading lesson

‹Scoreboard Puzzles: Mismatch or Ordering Bug?
  1. Topics
  2. DV Interview Puzzles
  3. Scenario & Debug Puzzles
  4. Scoreboard Puzzles: Mismatch or Ordering Bug?
  5. Duplicate Transactions from Handle Reuse

VLSI DV Interview Puzzles · All levels

Duplicate Transactions from Handle Reuse

Scoreboard sees duplicate packets with changing fields, and old entries mutate in logs. Find why data appears to rewrite history.

On this page

    Puzzle

    Difficulty: Easy · Puzzle 3 of 6 · Topic: Scoreboard Puzzles: Mismatch or Ordering Bug?

    Scoreboard sees duplicate packets with changing fields, and old entries mutate in logs. Find why data appears to rewrite history.

    Code

    design.sv
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    class rsp_monitor extends uvm_component;
      uvm_analysis_port #(txn) ap;
      txn t;
      virtual task run_phase(uvm_phase phase);
        t = txn::type_id::create("t");
        forever begin
          sample_bus_into(t);
          ap.write(t); // same handle every time
        end
      endtask
    endclass

    Hint

    Analysis ports pass object handles, not value copies.

    Step-by-step solution

    Diagram
    1) Print object handles/ids in scoreboard to confirm same pointer repeats.
    2) Observe later sampling mutates previously queued entries.
    3) Clone transaction before ap.write or allocate a new object each sample.
    4) In scoreboard, optionally clone on receipt for defensive isolation.
    5) Add checker that flags repeated handle reuse across writes.

    Answer

    Answer: Bug: monitor publishes the same transaction handle repeatedly; subscribers see mutated duplicates. Fix: clone/new transaction per write boundary.

    Why candidates get it wrong

    Compare logic can look broken even though ingestion semantics are wrong.

    Interviewer follow-up

    Which side should own defensive cloning: producer, consumer, or both?

    Related topics

    • Back to Scoreboard Puzzles: Mismatch or Ordering Bug?

    • Scenario & Debug Puzzles section

    Previous

    194 / 210

    Next: Mismatch Cascade from Incorrect Pop Policy

    Up next

    Up nextMismatch Cascade from Incorrect Pop Policy

    Sign in to save progress

    Practice this lessonReport an error

    See also

    • Out-of-Order Responses Miscompared as Corruption
    • End-of-Test Draining Missing
    • Duplicate Expected Entries from Predictor Retry Path