pico-ice-video/ice/mandelbrot/source/impl_1/multiplier.sv

22 lines
339 B
Systemverilog
Raw Normal View History

2024-10-06 04:18:41 +00:00
module multiplier
(
input wire clk,
input wire signed [7:0] a,
input wire signed [7:0] b,
output reg signed [15:0] product
);
reg signed [7:0] a_reg;
reg signed [7:0] b_reg;
wire [15:0] product_out;
always_ff @(posedge clk) begin
a_reg <= a;
b_reg <= b;
product <= product_out;
end
assign product_out = a_reg * b_reg;
endmodule