Skip to content

r_data is undefined after a simultaneous write to an empty AsyncFIFO #217

Description

@nmigen-issue-migration

Issue by whitequark
Friday Sep 20, 2019 at 20:02 GMT
Originally opened as m-labs/nmigen#217


The behavior of a dual port block RAM with read and write ports in different clock domains is not defined during a simultaneous read and write to the same address. (In fact it is not possible to make it defined.) However, this is exactly what is happening when an element is written into an empty AsyncFIFO[Buffered], since the produce and consume pointers are equal. If the phase of read and write clocks is just wrong, the output register of the BRAM could end in a metastable state.

It is not clear how this can be fixed. A workaround is to use AsyncFIFOBuffered instead, which resynchronizes the BRAM output.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions