mirror of
https://github.com/YosysHQ/yosys
synced 2025-08-30 15:00:26 +00:00
Progress on AppNote 011
This commit is contained in:
parent
e23a0072ec
commit
7295b25955
6 changed files with 110 additions and 16 deletions
|
@ -5,3 +5,5 @@ example_03.dot
|
|||
cmos_00.dot
|
||||
cmos_01.dot
|
||||
splice.dot
|
||||
sumprod_00.dot
|
||||
sumprod_01.dot
|
||||
|
|
8
manual/APPNOTE_011_Design_Investigation/foobaraddsub.v
Normal file
8
manual/APPNOTE_011_Design_Investigation/foobaraddsub.v
Normal file
|
@ -0,0 +1,8 @@
|
|||
module foobaraddsub(a, b, c, d, fa, fs, ba, bs);
|
||||
input [7:0] a, b, c, d;
|
||||
output [7:0] fa, fs, ba, bs;
|
||||
assign fa = a + (* foo *) b;
|
||||
assign fs = a - (* foo *) b;
|
||||
assign ba = c + (* bar *) d;
|
||||
assign bs = c - (* bar *) d;
|
||||
endmodule
|
|
@ -3,7 +3,9 @@
|
|||
../../yosys -p 'proc; opt; show -format dot -prefix splice' splice.v
|
||||
../../yosys -p 'techmap; abc -liberty ../../techlibs/cmos/cmos_cells.lib;; show -format dot -prefix cmos_00' cmos.v
|
||||
../../yosys -p 'techmap; splitnets -ports; abc -liberty ../../techlibs/cmos/cmos_cells.lib;; show -lib ../../techlibs/cmos/cmos_cells.v -format dot -prefix cmos_01' cmos.v
|
||||
sed -i '/^label=/ d;' example_*.dot splice.dot cmos_*.dot
|
||||
../../yosys -p 'opt; cd sumprod; select a:sumstuff; show -format dot -prefix sumprod_00' sumprod.v
|
||||
../../yosys -p 'opt; cd sumprod; select a:sumstuff %x; show -format dot -prefix sumprod_01' sumprod.v
|
||||
sed -i '/^label=/ d;' example_*.dot splice.dot cmos_*.dot sumprod_*.dot
|
||||
dot -Tpdf -o example_00.pdf example_00.dot
|
||||
dot -Tpdf -o example_01.pdf example_01.dot
|
||||
dot -Tpdf -o example_02.pdf example_02.dot
|
||||
|
@ -11,3 +13,5 @@ dot -Tpdf -o example_03.pdf example_03.dot
|
|||
dot -Tpdf -o splice.pdf splice.dot
|
||||
dot -Tpdf -o cmos_00.pdf cmos_00.dot
|
||||
dot -Tpdf -o cmos_01.pdf cmos_01.dot
|
||||
dot -Tpdf -o sumprod_00.pdf sumprod_00.dot
|
||||
dot -Tpdf -o sumprod_01.pdf sumprod_01.dot
|
||||
|
|
12
manual/APPNOTE_011_Design_Investigation/sumprod.v
Normal file
12
manual/APPNOTE_011_Design_Investigation/sumprod.v
Normal file
|
@ -0,0 +1,12 @@
|
|||
module sumprod(a, b, c, sum, prod);
|
||||
|
||||
input [7:0] a, b, c;
|
||||
output [7:0] sum, prod;
|
||||
|
||||
{* sumstuff *}
|
||||
assign sum = a + b + c;
|
||||
{* *}
|
||||
|
||||
assign prod = a * b * c;
|
||||
|
||||
endmodule
|
Loading…
Add table
Add a link
Reference in a new issue