~ruther/verilog-riscv-semestral-project

ref: a6f4c7fc1c66f05cd78d52e8e3b9229ae58ef2f7 verilog-riscv-semestral-project/src/stages/writeback.sv -rw-r--r-- 379 bytes
a6f4c7fc — Rutherther chore: add new files to compilation list 1 year, 5 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
module writeback(
  input         clk,

  output [4:0]  reg_a_write,
  output        reg_we,
  output [31:0] reg_write,

  input         stage_status_t stage_in
);
  assign reg_a_write = stage_in.data.address;
  assign reg_we = stage_in.valid && stage_in.data.valid && stage_in.instruction.reg_we; // stage_in.data.address != 0
  assign reg_write = stage_in.data.data;
endmodule
Do not follow this link