mirror of
https://github.com/YosysHQ/yosys.git
synced 2026-08-22 14:17:27 +02:00
opt_lut: eliminate LUTs evaluating to constants or inputs.
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
module \test
|
||||
wire input 1 \i
|
||||
|
||||
wire output 2 \o1
|
||||
cell $lut $1
|
||||
parameter \LUT 16'0110100110010110
|
||||
parameter \WIDTH 4
|
||||
connect \A { \i 3'000 }
|
||||
connect \Y \o1
|
||||
end
|
||||
|
||||
wire output 2 \o2
|
||||
cell $lut $2
|
||||
parameter \LUT 16'0110100010010110
|
||||
parameter \WIDTH 4
|
||||
connect \A { \i 3'000 }
|
||||
connect \Y \o2
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,3 @@
|
||||
read_ilang opt_lut_elim.il
|
||||
opt_lut
|
||||
select -assert-count 0 t:$lut
|
||||
@@ -1,2 +1,3 @@
|
||||
read_ilang opt_lut_port.il
|
||||
opt_lut
|
||||
select -assert-count 2 t:$lut
|
||||
|
||||
Reference in New Issue
Block a user