3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2025-07-29 07:27:58 +00:00

proc_prune: Make assign removal and promotion per-bit, remember promoted bits.

Fixes #2962.
This commit is contained in:
Marcelina Kościelnicka 2021-08-14 14:23:12 +02:00
parent 539d4ee907
commit faacc7ad89
2 changed files with 47 additions and 40 deletions

22
tests/proc/bug2962.ys Normal file
View file

@ -0,0 +1,22 @@
read_ilang << EOT
module \top
wire width 4 input 1 \a
wire width 2 input 2 \b
wire input 3 \clk
wire width 4 output 4 \q
wire input 5 \en
wire width 4 \nq
process \p
assign \nq \a
assign \nq [1:0] \b
switch \en
case 1'1
assign \nq [3] 1'0
end
sync posedge \clk
update \q \nq
end
end
EOT
proc
check -assert