[HDL] Add tech library for architecture using multi-mode 16-bit DSP blocks

This commit is contained in:
tangxifan 2021-04-24 13:30:46 -06:00
parent ddcdb35b28
commit 272d1fffb7
2 changed files with 66 additions and 0 deletions

View File

@ -0,0 +1,25 @@
//-----------------------------
// 8-bit multiplier
//-----------------------------
module mult_8(
input [0:7] A,
input [0:7] B,
output [0:15] Y
);
assign Y = A * B;
endmodule
//-----------------------------
// 16-bit multiplier
//-----------------------------
module mult_16(
input [0:15] A,
input [0:15] B,
output [0:31] Y
);
assign Y = A * B;
endmodule

View File

@ -0,0 +1,41 @@
//-----------------------------
// 8-bit multiplier
//-----------------------------
module mult_8x8 (
input [0:7] A,
input [0:7] B,
output [0:15] Y
);
parameter A_SIGNED = 0;
parameter B_SIGNED = 0;
parameter A_WIDTH = 0;
parameter B_WIDTH = 0;
parameter Y_WIDTH = 0;
mult_8 #() _TECHMAP_REPLACE_ (
.A (A),
.B (B),
.Y (Y) );
endmodule
//-----------------------------
// 16-bit multiplier
//-----------------------------
module mult_16x16 (
input [0:15] A,
input [0:15] B,
output [0:31] Y
);
parameter A_SIGNED = 0;
parameter B_SIGNED = 0;
parameter A_WIDTH = 0;
parameter B_WIDTH = 0;
parameter Y_WIDTH = 0;
mult_16 #() _TECHMAP_REPLACE_ (
.A (A),
.B (B),
.Y (Y) );
endmodule