diff --git a/cMIPS/tests/ll_sc.expected b/cMIPS/tests/ll_sc.expected index 76864aa6f952c3f95055a55900761f1eff0db6c8..d8b37d0efeb7ab75af96700dfea7bd757a25ebd0 100644 --- a/cMIPS/tests/ll_sc.expected +++ b/cMIPS/tests/ll_sc.expected @@ -22,6 +22,9 @@ ffffffff ffffffff ok +55555555 +ok + ok ok diff --git a/cMIPS/vhdl/core.vhd b/cMIPS/vhdl/core.vhd index 0bddb10666f14b013652b062ce5d250b60d93eec..9b8ea27c37562b71e5f797cb6282fae31f3995cc 100644 --- a/cMIPS/vhdl/core.vhd +++ b/cMIPS/vhdl/core.vhd @@ -988,6 +988,9 @@ begin elsif MM_is_MFC0 then -- non-LW eq_fwd_A <= MM_cop0_val; rs_stall := FALSE; + elsif MM_is_SC then + eq_fwd_A <= x"00000000"; + rs_stall := FALSE; else eq_fwd_A <= MM_result; rs_stall := FALSE; @@ -1013,6 +1016,9 @@ begin elsif MM_is_MFC0 then -- non-LW eq_fwd_B <= MM_cop0_val; rt_stall := FALSE; + elsif MM_is_SC then + eq_fwd_B <= x"00000000"; + rs_stall := FALSE; else eq_fwd_B <= MM_result; rt_stall := FALSE;