From 2c967a910b74206e9bf65463a2027a198d779396 Mon Sep 17 00:00:00 2001 From: Aadi Desai <21363892+supleed2@users.noreply.github.com> Date: Wed, 2 Dec 2020 14:24:17 +0000 Subject: [PATCH] Update mips_cpu_harvard.v Fix typo + immediate already fed in via alu_in2 --- rtl/mips_cpu_harvard.v | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/rtl/mips_cpu_harvard.v b/rtl/mips_cpu_harvard.v index 713b70d..15649b1 100644 --- a/rtl/mips_cpu_harvard.v +++ b/rtl/mips_cpu_harvard.v @@ -46,7 +46,7 @@ logic[4:0] shamt = instr_readdata[10:6]; // Shamt needed for the sll instruction //ALU Data logic[31:0] alu_in1 = read_data1; -logic[31:0] alu_in2 = ALUSrc ? {{16{in[15]}},immediate} : read_data2; +logic[31:0] alu_in2 = ALUSrc ? {{16{immediate[15]}},immediate} : read_data2; logic[31:0] ALUOut; //Data MEM @@ -99,7 +99,6 @@ alu alu( .B(alu_in2), //operand 2 .ALUzero(ALUZero), //is the result zero, used for checks .ALUOut(ALUOut), //output/result of operation -.immediate(immediate), .shamt(shamt) ); endmodule : mips_cpu_harvard