-
Notifications
You must be signed in to change notification settings - Fork 860
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
Add "buffered-normalized mode", add $buf cell type, and add "bufnorm" command #3967
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Claire Xenia Wolf <claire@clairexen.net>
Signed-off-by: Claire Xenia Wolf <claire@clairexen.net>
Signed-off-by: Claire Xenia Wolf <claire@clairexen.net>
Signed-off-by: Claire Xenia Wolf <claire@clairexen.net>
Signed-off-by: Claire Xenia Wolf <claire@clairexen.net>
Signed-off-by: Claire Xenia Wolf <claire@clairexen.net>
Signed-off-by: Claire Xenia Wolf <claire@clairexen.net>
{ | ||
for (auto &it : wire->attributes) { | ||
f << stringf("%s" "attribute %s ", indent.c_str(), it.first.c_str()); | ||
dump_const(f, it.second); | ||
f << stringf("\n"); | ||
} | ||
if (flag_d && wire->driverCell) { | ||
f << stringf("%s" "driver %s %s\n", indent.c_str(), | ||
wire->driverCell->name.c_str(), wire->driverPort.c_str()); |
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.
Since it should be always possible to reconstruct this data, why not dump it as a comment in the RTLIL output? (Does RTLIL support comments?) And if we do dump it as a comment, maybe we could include it unconditionally and drop the argument to dump_wire
.
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.
...and drop the other new dump arguments and the option to the pass.
FWIW that doesn't seem to be the behavior for yosys/passes/techmap/simplemap.cc Lines 45 to 53 in 7d30f71
|
Since
|
oh hey, a new user of bugpoint :D |
This PR adds "buffered-normalized mode" to RTLIL. In that mode there's a 1:1 relationship between cell ouput ports and wires, and each wire is annotated with a reference to the cell and cell port driving it.
Once in "buffered-normalized mode" calling
design->bufNormalize()
(ormodule->bufNormalize()
) will ensure that the above condition is met, by adding additional intermediate wires and buffer cells as needed.This PR also adds a
$buf
"coarse-grain" buffer cell type, similar in behavior to$pos
, but techmap/simplemap/etc is not mapping this buffer type to an array of single-bit buffers.bufNormalize()
is adding buffers of that new$buf
type. Note thatbufNormalize()
is very efficient and only looks at the parts of the design that have been changed since the last timebufNormalize()
has been run, i.e. it does not require a complete scan over the design.This PR also adds the
bufnorm
command for getting the design into and out of "buffered-normalized mode", with more control over the exact type of network of buffers that is being created.