VLSI DV Interview Puzzles · All levels
Duplicate Expected Entries from Predictor Retry Path
Scoreboard reports 'unexpected actual' and duplicate expected IDs under retry traffic. Find predictor-side overcounting.
Puzzle
Difficulty: Medium · Puzzle 6 of 6 · Topic: Scoreboard Puzzles: Mismatch or Ordering Bug?
Scoreboard reports 'unexpected actual' and duplicate expected IDs under retry traffic. Find predictor-side overcounting.
Code
function void predictor::write_req(req_t r);
exp_ap.write(model_rsp(r));
if (r.retry) begin
exp_ap.write(model_rsp(r)); // bug: duplicate expectation
end
endfunctionHint
Retry metadata does not always mean a second architectural completion.
Step-by-step solution
1) Compare expected-id histogram against actual-id histogram.
2) Observe duplicate expected entries only for retry-marked requests.
3) Review protocol: retry indicates deferred completion, not duplicate completion.
4) Emit one expected response per architectural completion key.
5) Add protocol-aware predictor test covering retries and replays.Answer
Answer: Bug: predictor enqueues two expected responses for one retried operation. Fix: model retry as delay/reissue semantics and generate only one expected completion per transaction id.
Why candidates get it wrong
It looks like DUT dropped data, but predictor created phantom expectations.
Interviewer follow-up
How would you key expected entries when request id can be reused after retry windows?