RTL Design #7 · 2026-09-30 · Handshakes · Hard · about 20 min

A skid buffer that drops a beat

skid_buf sits between a producer and a consumer on a valid/ready interface, to break long timing paths. A beat moves when valid and ready are both 1 at a rising edge.

  • Every beat that goes in comes out exactly once, in order.
  • in_ready, out_valid and out_data come from flops: no combinational path from any input to them.
  • While out_valid is 1 and out_ready is 0, out_valid and out_data hold.
  • With in_valid and out_ready both held at 1, one beat goes through every cycle.
  • After reset nothing is held and in_ready is 1.

At full speed the current design works. When the consumer stalls, a beat goes missing. Fix skid_buf.sv.

Write and run your answer in the browser. The hidden tests check it, and it’s free.