Skip to content

Commit

Permalink
fix timing
Browse files Browse the repository at this point in the history
  • Loading branch information
myrfy001 committed Mar 28, 2024
1 parent ac28cc7 commit 2eebbe2
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/includes/EthUtils.bsv
Original file line number Diff line number Diff line change
Expand Up @@ -363,11 +363,17 @@ module mkSizedBramFifoToFifoOut#(
)(FifoOut#(dType)) provisos(Bits#(dType, dSize), Add#(1, a__, dSize), FShow#(dType));

FIFOF#(dType) fifo <- mkSizedBRAMFIFOF(depth);
// to fix timing, BRAM fifo is complex at it's output port.
FIFOF#(dType) outBuffer <- mkFIFOF;
rule doEnq;
fifo.enq(pipe.first);
pipe.deq;
endrule
return convertFifoToFifoOut(fifo);
rule doDeq;
outBuffer.enq(fifo.first);
fifo.deq;
endrule
return convertFifoToFifoOut(outBuffer);
endmodule

module mkSizedFifoToFifoOut#(
Expand Down

0 comments on commit 2eebbe2

Please sign in to comment.