yosys/tests/asicworld/code_hdl_models_mux_2to1_ga...

19 lines
456 B
Coq
Raw Normal View History

2013-01-05 04:13:26 -06:00
//-----------------------------------------------------
// Design Name : mux_2to1_gates
// File Name : mux_2to1_gates.v
// Function : 2:1 Mux using Gate Primitives
// Coder : Deepak Kumar Tala
//-----------------------------------------------------
module mux_2to1_gates(a,b,sel,y);
input a,b,sel;
output y;
wire sel,a_sel,b_sel;
not U_inv (inv_sel,sel);
and U_anda (asel,a,inv_sel),
U_andb (bsel,b,sel);
or U_or (y,asel,bsel);
endmodule