-
Notifications
You must be signed in to change notification settings - Fork 645
Expose read-latency and write-latency parameters of FIRRTL memories #5133
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
Conversation
| Seq.fill(numReadPorts)(clock), | ||
| Seq.fill(numWritePorts)(clock), | ||
| Seq.fill(numReadwritePorts)(clock), | ||
| 1, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Summary of the changes in this file:
- Add
readLatencyandwriteLatencyto the private impl functions - For each public API
- Set the default latency of 1
- Add a copy of that method with latency parameters passed by the caller
If we expose additional parameters in the future, I think we can keep the minimal public APIs that were present before this PR, then add additional parameters to the new APIs added here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this summary. 👍
seldridge
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
| * | ||
| * @return A new `SRAMInterface` wire containing the control signals for each instantiated port | ||
| * @note This does *not* return the `SyncReadMem` itself, you must interact with it using the returned bundle | ||
| * @note Read-only memories (R >= 1, W === 0, RW === 0) and write-only memories (R === 0, W >= 1, RW === 0) are not supported by this API, and will result in an error if declared. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The more Scaladoc way of doing this is:
@throws java.lang.IllegalArgumentException if <the user does something>
mikeurbach
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, looks good to me
Contributor Checklist
docs/src?Type of Improvement
Desired Merge Strategy
Release Notes
read-latencyandwrite-latency>= 1Reviewer Checklist (only modified by reviewer)
3.6.x,5.x, or6.xdepending on impact, API modification or big change:7.0)?Enable auto-merge (squash)and clean up the commit message.Create a merge commit.