
Memories LRAMFIFO
Speedster22i Macro Cell Library
AchronixSemiconductorProprietary PAGE 167
Forexample,the emptyflagiscomputedfromtheSynchronizedWritePointerandtheRead
Pointer.The write pointer incurs an additional delay of two to five rdclk cyles (set by the
wrptr_sync_stages parameter) before it is used to calculate the empty flag.Therefore, the
emptyflagwillnottransitionfromtheemptytonon‐emptystateforami
nimumoftwordclk
cyclesafterthefirstwritetotheFIFOoccurs.Asimilardelayoccursforthealmost_emptyflag
aswell.Likewise,forthefullandalmost_fullflags,therearetwotofivewrclkcyclesofdelay
intheactual FIFOstatusduetothesynchronizedreadpo
inter.ForanasyncronousFIFO,the
calculationoftheflagsdoesnotimmediatelyreflectthestateoftheFIFO.Whilethisbehavior
isnormalforasynchronousFIFOs,itshouldbenoted.Table6‐60
: EmptyandAlmostEmpty
FlagLatencyinTermsofReadClockCycles(ptr_sync_
mode=1’b0)andTable6‐61: Fulland
AlmostFullFlagLatencyinTer
msofWriteClockCycles(ptr_syn c_mode=1’b0)showthe
latencyfortheFIFOfl
agcalculations.
Table 6-60: Empty and Almost Empty Flag Latency in Terms of Read Clock Cycles
FIFO Status Flag Read Clock Cycle Latency (rdclk cycles)
Flag Assertion Flag Deassertion
empty flag 0 3 + rdptr_sync_stages
almost empty flag 0 3
(ptr_sync_mode =1’b0)
Table 6-61: Full and Almost Full Flag Latency in T
erms of Write Clock Cycles
FIFO Status Flag Write Clock Cycle Latency (wrclk cycles)
Flag Assertion Flag Deassertion
full flag 0 3 + wrptr_sync_stages
almost full flag 0 3
(ptr_sync_mode = 1’b0)
Flag Latency in Synchronous Mode (ptr_sync_mode = 1’b1)
AsynchronousFIFOhasonlyasingleclock,sothereisnoclockdomaincrossingrequired.A
synchronousFIFOhastheadvantagethattheflagcalculationsareimmediateandprecise.
FIFO Operational Modes
TheFIFOmacrosupportsbothsingleclocksynchronous(sameclockconnectedtowrclkand
rdclkinputswithout anyphaseoffset betweenthetwoclocks)anddualclock asynchronous
(twounrelatedclocksortworelatedclocks)modesofoperation.Forsynchronousoperation,
both the wrclk and rdclk inputs must be connected to the same clock net.Phase offsets
betw
een the two clocks in synchronous mode is not allowed.For asynchronous mode, the
usermayconnectthewrclkandrdclkinputstotwodifferentclocks.TheFIFOwilltreatthe
twoclocksasiftheyareunrelated.
Asychronous FIFO Mode (ptr_sync_mode = 1’b0)
Afteraresetoperation,orafterthelastwordhasbeenreadfromtheFIFO,theFIFOwillbein
an empty state as indicated by a high level on the empty flag.When the FIFO is set to
asynchronousmode(ptr_sync_mode=1’b0),theoutputoftheFIFOremainsun changed af
ter
thefirstwritetoaFIFOintheemptystate.Afterthefirstwriteoperationtheempty flagwill
bedeassertedindicatingtha tthereisdataintheFIFOthatmayberead.Theusermustread
theFIFO bysettingtherden highat whichtimethe first wordwri
tteninto theFIFO willbe
availableattheFIFOoutputsatthenextrisingedgeoftherdclkinput.Eachsubsequent read
operationupdates the FIFOoutputswiththenext stored data word if itisavailable(empty
flag=false).
Komentarze do niniejszej Instrukcji