Files
RISC-V_Verilog/rtl/mux4_1.v
brice.boisson 33835ec0ed Fix: reset edge
2023-10-22 22:41:39 +09:00

10 lines
258 B
Verilog

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);
assign O = S[1] ? (S[0] ? D : C)
: (S[0] ? B : A);
endmodule