-
Notifications
You must be signed in to change notification settings - Fork 603
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
Documentation and minor plugin changes. #1573
Conversation
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.
Some thoughts and suggestions. Some comments are more musings than actual suggestions.
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.
drive by comment :) 👍
|
||
### All this prefixing is annoying, how do I fix it? | ||
|
||
You can use the `noPrefix { ... }` to strip the prefix from all signals generated in that scope. |
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.
Note that noPrefix
only strips the 1 level of prefix, it doesn't remove all prefixes
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.
I'm not sure that's true? I think it clears all prefixes?
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.
I don't think it does:
def buzz(arg: UInt) = {
val x = c + arg
b + x
}
def fizz(arg: UInt) = {
val y = buzz(arg)
a + y
}
import chisel3.experimental.prefix
import chisel3.experimental.noPrefix
val foo = prefix("jack")(fizz(3.U))
val bar = noPrefix(fizz(128.U))
out := foo + bar
gives
wire [7:0] foo_jack_y_x = c + 8'h3;
wire [7:0] foo_jack_y = b + foo_jack_y_x;
wire [7:0] foo = a + foo_jack_y;
wire [7:0] y_x = c + 8'h80;
wire [7:0] y = b + y_x;
wire [7:0] bar = a + y;
assign out = foo + bar;
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Contributor Checklist
docs/src
?Type of Improvement
API Impact
Moves the plugin API to a separate package, rather than being in experimental. Should only affect the release candidate, but since its a new API there is no backwards compatibility issues.
Desired Merge Strategy
Release Notes
Added documentation for the new Chisel naming plugin, viewable on our website!
Reviewer Checklist (only modified by reviewer)
Please Merge
?