yosys/techlibs/rapidflex/alkaidL/cell_sim_arith.v

16 lines
317 B
Verilog
Raw Normal View History

2026-05-15 02:33:24 +02:00
//---------------------------------------
// 1-bit adder
//---------------------------------------
(* abc9_box, lib_whitebox *)
module _fpga_adder(
output sumout,
output cout,
input a,
input b,
input cin
);
assign sumout = a ^ b ^ cin;
assign cout = (a & b) | ((a | b) & cin);
endmodule