mirror of
https://github.com/YosysHQ/yosys
synced 2025-04-28 19:35:53 +00:00
some refactoring
This commit is contained in:
parent
7a8efe9f1b
commit
f7dc93c652
6 changed files with 66 additions and 48 deletions
|
@ -2,7 +2,7 @@
|
|||
`define LCELL cycloneiv_lcell_comb
|
||||
`define M9K cycloneiv_ram_block
|
||||
`endif
|
||||
`ifdef cycloneive
|
||||
`ifdef cycloneive
|
||||
`define LCELL cycloneive_lcell_comb
|
||||
`define M9K cycloneive_ram_block
|
||||
`endif
|
||||
|
@ -33,24 +33,24 @@ endmodule
|
|||
|
||||
module MISTRAL_ALUT4(input A, B, C, D, output Q);
|
||||
parameter [15:0] LUT = 16'h0000;
|
||||
parameter sum_lutc_input = "datac";
|
||||
`LCELL #(.lut_mask(LUT),.sum_lutc_input(sum_lutc_input)) _TECHMAP_REPLACE_ (.dataa(A), .datab(B), .datac(C), .datad(D), .combout(Q));
|
||||
|
||||
`LCELL #(.lut_mask(LUT),.sum_lutc_input("datac")) _TECHMAP_REPLACE_ (.dataa(A), .datab(B), .datac(C), .datad(D), .combout(Q));
|
||||
|
||||
endmodule
|
||||
|
||||
|
||||
module MISTRAL_ALUT3(input A, B, C, output Q);
|
||||
parameter [7:0] LUT = 8'h00;
|
||||
parameter sum_lutc_input = "datac";
|
||||
`LCELL #(.lut_mask({2{LUT}}),.sum_lutc_input(sum_lutc_input)) _TECHMAP_REPLACE_ (.dataa(A), .datab(B), .datac(C), .combout(Q));
|
||||
|
||||
`LCELL #(.lut_mask({2{LUT}}),.sum_lutc_input("datac")) _TECHMAP_REPLACE_ (.dataa(A), .datab(B), .datac(C), .combout(Q));
|
||||
|
||||
endmodule
|
||||
|
||||
|
||||
module MISTRAL_ALUT2(input A, B, output Q);
|
||||
parameter [3:0] LUT = 4'h0;
|
||||
parameter sum_lutc_input = "datac";
|
||||
`LCELL #(.lut_mask({4{LUT}}),.sum_lutc_input(sum_lutc_input)) _TECHMAP_REPLACE_ (.dataa(A), .datab(B), .combout(Q));
|
||||
|
||||
`LCELL #(.lut_mask({4{LUT}}),.sum_lutc_input("datac")) _TECHMAP_REPLACE_ (.dataa(A), .datab(B), .combout(Q));
|
||||
|
||||
endmodule
|
||||
|
||||
|
@ -64,8 +64,8 @@ endmodule
|
|||
|
||||
module MISTRAL_ALUT_ARITH(input A, B, C, D, CI, output SO, CO);
|
||||
parameter LUT = 16'h0000;
|
||||
parameter sum_lutc_input = "datac";
|
||||
`LCELL #(.lut_mask({LUT}),.sum_lutc_input(sum_lutc_input)) _TECHMAP_REPLACE_ (.dataa(A), .datab(B), .datac(C), .datad(D), .cin(CI), .combout(SO), .cout(CO));
|
||||
|
||||
`LCELL #(.lut_mask({LUT}),.sum_lutc_input("cin")) _TECHMAP_REPLACE_ (.dataa(A), .datab(B), .datac(C), .datad(D), .cin(CI), .combout(SO), .cout(CO));
|
||||
|
||||
endmodule
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue