RISC CPU-累加器
module accum( accum, data, ena, clk1, rst);3 outputaccum;
4 inputdata;
5 input ena,clk1,rst;
6 regaccum;
7
8 always@(posedge clk1)
9 begin
10 if(rst)
11 accum<=8'b0000_0000; //Reset
12 else
13 if(ena) //当CPU状态控制器发出load_acc信号
14 accum<=data; //Accumulate
15 end
16 endmodule RISC CPU-累加器
页:
[1]