Open 7FM opened 3 hours ago
Small reproducer:
read_slang <<EOF
module top;
reg x, b;
reg [2:0] a;
reg [2:0] out;
always_comb begin
out = a;
out[x] = b;
end
endmodule
EOF
write_verilog netlist.v
Just to make clear it is a write_verilog
bug, there's this part in its documentation:
-noexpr
without this option all internal cells are converted to Verilog
expressions.
Version
0.46
On which OS did this happen?
Linux
Reproduction Steps
Read in CVA6 via the yosys-slang plugin and try to write it out again into a single verilog file... Not so easy to reproduce, I guess.
Expected Behavior
write_verilog
should output code without internal cells.Actual Behavior
The exported verilog code still contains
bwmux
cells. I have to manually runbwmuxmap
beforewrite_verilog
to remove all internal cells.