Simple ALU (top level)
module alusim(a,b,Carryin,Result,Overflow,Operation);
input a,b,Carryin;
output Result,Overflow;
input Operation;
wire t0, t1,t2;
and g0(t0,a,b);
fullAdd1 g1( t2, t1, Overflow, a, b, Carryin);
mux2 g2(Result,Operation,t0,t1);
endmodule
Previous slide
Next slide
Back to first slide
View graphic version