[Benchmark] Add a micro benchmark: 8-bit multiply and accumulate

This commit is contained in:
tangxifan 2021-03-23 15:33:37 -06:00
parent 8c970a792a
commit be03eafd66
1 changed files with 22 additions and 0 deletions

View File

@ -0,0 +1,22 @@
//-------------------------------------------------------
// Functionality: A 8-bit multiply-acculumate circuit
// Author: Xifan Tang
//-------------------------------------------------------
module mac_8(a, b, c, out);
parameter DATA_WIDTH = 8; /* declare a parameter. default required */
input [DATA_WIDTH - 1 : 0] a, b, c;
output [DATA_WIDTH - 1 : 0] out;
assign out = a * b + c;
endmodule