aboutsummaryrefslogtreecommitdiffstats
path: root/backends/cxxrtl/cxxrtl_capi.h
diff options
context:
space:
mode:
authorwhitequark <whitequark@whitequark.org>2020-06-08 17:29:08 +0000
committerwhitequark <whitequark@whitequark.org>2020-06-08 17:29:08 +0000
commitf2d7a18756088f4167b91c5ec4735bb694f36567 (patch)
treec06ce266bf04244616d1aa7c9abd1b39e7cf1d86 /backends/cxxrtl/cxxrtl_capi.h
parentd5c07e5b6f5c91666867751233f5c537068a7136 (diff)
downloadyosys-f2d7a18756088f4167b91c5ec4735bb694f36567.tar.gz
yosys-f2d7a18756088f4167b91c5ec4735bb694f36567.tar.bz2
yosys-f2d7a18756088f4167b91c5ec4735bb694f36567.zip
cxxrtl: emit debug information for constant wires.
Constant wires can represent a significant chunk of the design in generic designs or after optimization. Emitting them in VCD files significantly improves usability because gtkwave removes all traces that are not present in the VCD file after reload, and iterative development suffers if switching a varying signal to a constant disrupts the workflow.
Diffstat (limited to 'backends/cxxrtl/cxxrtl_capi.h')
-rw-r--r--backends/cxxrtl/cxxrtl_capi.h11
1 files changed, 6 insertions, 5 deletions
diff --git a/backends/cxxrtl/cxxrtl_capi.h b/backends/cxxrtl/cxxrtl_capi.h
index bee5a94c7..46aa662b2 100644
--- a/backends/cxxrtl/cxxrtl_capi.h
+++ b/backends/cxxrtl/cxxrtl_capi.h
@@ -64,9 +64,10 @@ enum cxxrtl_type {
// Values correspond to singly buffered netlist nodes, i.e. nodes driven exclusively by
// combinatorial cells, or toplevel input nodes.
//
- // Values can be inspected via the `curr` pointer and modified via the `next` pointer (which are
- // equal for values); however, note that changes to the bits driven by combinatorial cells will
- // be ignored.
+ // Values can be inspected via the `curr` pointer. If the `next` pointer is NULL, the value is
+ // driven by a constant and can never be modified. Otherwise, the value can be modified through
+ // the `next` pointer (which is equal to `curr` if not NULL). Note that changes to the bits
+ // driven by combinatorial cells will be ignored.
//
// Values always have depth 1.
CXXRTL_VALUE = 0,
@@ -75,8 +76,8 @@ enum cxxrtl_type {
// storage cells, or by combinatorial cells that are a part of a feedback path.
//
// Wires can be inspected via the `curr` pointer and modified via the `next` pointer (which are
- // distinct for wires); however, note that changes to the bits driven by combinatorial cells will
- // be ignored.
+ // distinct for wires). Note that changes to the bits driven by combinatorial cells will be
+ // ignored.
//
// Wires always have depth 1.
CXXRTL_WIRE = 1,