You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I expect an undriven wire to have the same semantics as one driven by anyseq, to be left free to take any value at any time, but that all references to that wire should see the same value.
Actual Behavior
With the BTOR backend, part selects of an undriven wire get lowered as inputs multiple times, meaning that different uses of the wire can see different values. Looking at the generated btor
we see that node 2 defines a 1 bit input (a[0]), and node 6 separately defines a 2 bit input (a), so these are not consistent.
Instead, when emitting for an undriven wire it should be emitted as an input once and then part selects referenced from that input with slice. Partially driven wires can be modelled with bit masks to select between the driver and an input variable.
The text was updated successfully, but these errors were encountered:
Version
Yosys 0.45+153 (git sha1 ab378f8, g++ 14.2.1 -fPIC -O3)
On which OS did this happen?
Linux
Reproduction Steps
Expected Behavior
I expect an undriven wire to have the same semantics as one driven by
anyseq
, to be left free to take any value at any time, but that all references to that wire should see the same value.Actual Behavior
With the BTOR backend, part selects of an undriven wire get lowered as inputs multiple times, meaning that different uses of the wire can see different values. Looking at the generated btor
we see that node
2
defines a 1 bit input (a[0]), and node6
separately defines a 2 bit input (a), so these are not consistent.Instead, when emitting for an undriven wire it should be emitted as an input once and then part selects referenced from that input with
slice
. Partially driven wires can be modelled with bit masks to select between the driver and an input variable.The text was updated successfully, but these errors were encountered: