Memory & FIFOs
Stream Skid Buffer 2-Deep 8-bit
A 2-deep skid buffer for 8-bit stream data that handles back-pressure and stalls.
About this block
Simulate it in the Verilog IDE
Stream Skid Buffer 2-Deep 8-bit is a Verilog reference block in the Memory & FIFOs catalog. SRAM models, FIFOs, register files, and memory-style storage. Marked Medium: more state or a wider datapath, still one workspace in the IDE.
This IP core implements a 2-deep skid buffer for 8-bit AXI-stream-like interfaces.
It decouples producer and consumer clock domains by buffering up to two data words.
It ensures data integrity by back-pressuring the producer when the buffer is full and forwarding data to the consumer as soon as it is ready.
- Choose Open in IDE. RTL Studio loads the packaged workspace for Stream Skid Buffer 2-Deep 8-bit.
- Read the Verilog module in the editor. The catalog line for this block: A 2-deep skid buffer for 8-bit stream data that handles back-pressure and stalls.
- Run the packaged testbench with the in-browser Verilator simulator, then open the VCD in the waveform viewer.
- Run Yosys in the same IDE for a generic netlist. Sky130 liberty mapping is a separate Pro library option.
RTL Studio is the Verilog simulator and IDE around this block: Slang lint, Verilator, VCD waveforms, and Yosys, in the browser. Simulation guide · Yosys guide.
Architecture
The design utilizes two internal registers to store incoming data and valid flags. It implements a simple FIFO-like logic with a depth of two. Back-pressure is asserted when both buffer slots are occupied. Data is forwarded to the output as soon as the consumer is ready and data is available.
Ports
| Port Name | Direction | Width | Description |
|---|---|---|---|
clk | Input | 1 | Clock input |
rst_n | Input | 1 | Active-low reset |
in_valid | Input | 1 | Input data valid signal |
in_ready | Output | 1 | Input ready to accept data |
in_data | Input | 8 | Input data bus |
out_valid | Output | 1 | Output data valid signal |
out_ready | Input | 1 | Output ready to accept data |
out_data | Output | 8 | Output data bus |
Verification
The testbench verifies basic back-to-back transfers and output stall scenarios. It checks that in_ready correctly reflects buffer occupancy and confirms that out_valid and out_data behave correctly during stalls.
### Test Cases
| Test Case | Description | Result |
|---|---|---|
| TC1 | Back-to-back transfer (no stall) | PASS |
| TC2 | Stall at output (back-to-back input) | PASS |
### Simulation Results
After running the simulation, the Log panel should show:
TC1 in_ready PASSTC1 out_valid PASSTC1 out_data PASSTC2 in_ready PASSTC2 out_valid PASSTC2 out_data PASS(multiple entries for buffered data)Simulation ends with INFO: PASS.
More in Memory & FIFOs
- 16-Word 16-Bit Sync RAM with Byte Enable — L2 Upgrade
- 16×8 Sync RAM (No Reset, Registered Read) — L2 Upgrade
- 32-Bit Asynchronous FIFO with Gray Pointer Encoding
- 32-Bit Register with Byte Writes
- 32x16 Synchronous Single-Port RAM
- 4x8 1W1R Register File (Comb Read)
- 4×8 Sync RAM (Async Reset, Comb Read)
- 64-bit Wide Scratchpad RAM with Dual-Port Access
- 8-Bit Valid/Ready Skid Buffer
- 8x16 Single-Port Sync RAM
- 8x32 Dual-Read Register File
- 8×8 Sync RAM (Async Reset, Comb Read, Loop Init) — L1 Upgrade
- Asymmetric RAM WR8 RD16 — L2 Upgrade
- Byte-Enable Regfile 8x32 — L2 Upgrade
- CAM 4x8 with Invalidate
- Circular Buffer 16x8