Index: source/Plugins/Instruction/MIPS/EmulateInstructionMIPS.cpp =================================================================== --- source/Plugins/Instruction/MIPS/EmulateInstructionMIPS.cpp +++ source/Plugins/Instruction/MIPS/EmulateInstructionMIPS.cpp @@ -1482,56 +1482,56 @@ if (!strcasecmp (op_name, "BEQC")) { if (rs_val == rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BNEC")) { if (rs_val != rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BLTC")) { if (rs_val < rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BGEC")) { if (rs_val >= rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BLTUC")) { if (rs_val < rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BGEUC")) { if ((uint32_t)rs_val >= (uint32_t)rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BOVC")) { if (IsAdd64bitOverflow (rs_val, rt_val)) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BNVC")) { if (!IsAdd64bitOverflow (rs_val, rt_val)) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } @@ -1773,42 +1773,42 @@ if (!strcasecmp (op_name, "BLTZC")) { if (rs_val < 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BLEZC")) { if (rs_val <= 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BGEZC")) { if (rs_val >= 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BGTZC")) { if (rs_val > 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BEQZC")) { if (rs_val == 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BNEZC")) { if (rs_val != 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } @@ -2129,7 +2129,7 @@ if (!success) return false; - target = pc + 4 + offset; + target = pc + offset; Context context; @@ -2159,7 +2159,7 @@ if (!success) return false; - target = pc + 4 + offset; + target = pc + offset; Context context; Index: source/Plugins/Instruction/MIPS64/EmulateInstructionMIPS64.cpp =================================================================== --- source/Plugins/Instruction/MIPS64/EmulateInstructionMIPS64.cpp +++ source/Plugins/Instruction/MIPS64/EmulateInstructionMIPS64.cpp @@ -483,6 +483,7 @@ // Prologue/Epilogue instructions //---------------------------------------------------------------------- { "DADDiu", &EmulateInstructionMIPS64::Emulate_DADDiu, "DADDIU rt,rs,immediate" }, + { "ADDiu", &EmulateInstructionMIPS64::Emulate_DADDiu, "ADDIU rt,rs,immediate" }, { "SD", &EmulateInstructionMIPS64::Emulate_SD, "SD rt,offset(rs)" }, { "LD", &EmulateInstructionMIPS64::Emulate_LD, "LD rt,offset(base)" }, @@ -1066,7 +1067,7 @@ if (!success) return false; - target = pc + 4 + offset; + target = pc + offset; Context context; @@ -1240,7 +1241,7 @@ if (!success) return false; - target = pc + 4 + offset; + target = pc + offset; Context context; @@ -1289,56 +1290,56 @@ if (!strcasecmp (op_name, "BEQC")) { if (rs_val == rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BNEC")) { if (rs_val != rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BLTC")) { if (rs_val < rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BGEC")) { if (rs_val >= rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BLTUC")) { if (rs_val < rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BGEUC")) { if ((uint32_t)rs_val >= (uint32_t)rt_val) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BOVC")) { if (IsAdd64bitOverflow (rs_val, rt_val)) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BNVC")) { if (!IsAdd64bitOverflow (rs_val, rt_val)) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } @@ -1381,42 +1382,42 @@ if (!strcasecmp (op_name, "BLTZC")) { if (rs_val < 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BLEZC")) { if (rs_val <= 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BGEZC")) { if (rs_val >= 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BGTZC")) { if (rs_val > 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BEQZC")) { if (rs_val == 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; } else if (!strcasecmp (op_name, "BNEZC")) { if (rs_val != 0) - target = pc + 4 + offset; + target = pc + offset; else target = pc + 4; }