2023-10-21 13:57:58 +00:00
|
|
|
module mux4_1 #(parameter BUS_SIZE = 32)
|
|
|
|
(input [BUS_SIZE - 1:0] A, B, C, D,
|
|
|
|
input [1:0] S,
|
|
|
|
output [BUS_SIZE - 1:0] O);
|
2023-10-20 09:48:18 +00:00
|
|
|
|
2023-10-22 13:41:39 +00:00
|
|
|
assign O = S[1] ? (S[0] ? D : C)
|
|
|
|
: (S[0] ? B : A);
|
2023-10-20 09:48:18 +00:00
|
|
|
|
|
|
|
endmodule
|