Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

axi_stream_slave with check function requires TREADY #477

Closed
eschmidscs opened this issue Apr 16, 2019 · 3 comments · Fixed by #483
Closed

axi_stream_slave with check function requires TREADY #477

eschmidscs opened this issue Apr 16, 2019 · 3 comments · Fixed by #483

Comments

@eschmidscs
Copy link
Contributor

eschmidscs commented Apr 16, 2019

Hi

Change 3e098f5 modifies the behaviour of the check_stream/check_axi_stream function.
The check functions call the pop function one by one. The command queue to the VC thus always runs empty, causing TREADY going low with the current implementation. This results in max 50% duty cycle of the checked stream.
However, TREADY is optional by the AXIS spec.

I don't grasp the full background of the change above. Is the only reason to have it implemented the same way?

Best regards,
emanuel

@kraigher
Copy link
Collaborator

A check operation is currently a blocking operation just like a read since the check is done in the client code. A blocking operation will limit the throughput as you notice. To solve the situation you need to queue up many reads using non blocking calls and do the checks afterwards. You can already do this using the non blocking read calls today.

The situation could be improved in two ways:

  • Keep check a client side operation but make a procedure which will work on an entire array such that reads can be queued up internally.
  • Move the check into the VC. The client code must add a wait_until_idle call to ensure the check has happened.

@eschmidscs
Copy link
Contributor Author

eschmidscs commented Apr 17, 2019

The problem was solved before the mentioned commit, so it is not impossible to implement. However, if you want to have the message handler implemented as it is now, it probably does not work (even though being an "artifact" of how the simulator works).

I hope I find time to look at your second option. I think non-blocking checks would be nice anyway.

Sidenote: I find the naming confusing here. It is obviously blocking, as it waits for the actual transfer. That it causes the next cycle to be idle is something more than blocking.

@kraigher
Copy link
Collaborator

As you mention blocking is only a problem if there is latency from request to response. Maybe the way the AXI stream VC is implemented adds a latency such that the next clock edge is missed. Maybe for AXI stream the latency could be zero and a blocking operation have full throughput. However for a memory mapped AXI port such as AXI4 lite there will typically be a latency and a blocking operation will never have full throughput.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants