Fix LR when changing cpu modes
Former-commit-id: 0ac911ee90758b9bffaafd459f1d9bca86d5064d
This commit is contained in:
parent
6a3d4358da
commit
3541779fbf
|
@ -134,8 +134,8 @@ impl Core {
|
|||
self.gpr[13] = self.gpr_banked_r13[next_index];
|
||||
|
||||
self.gpr_banked_r14[curr_index] = self.gpr[14];
|
||||
self.gpr_banked_r14[next_index] = self.pc; // Store the return address in LR_mode
|
||||
self.gpr[14] = self.gpr_banked_r14[next_index];
|
||||
self.gpr_banked_r14[next_index] = self.get_next_pc(); // Store the return address in LR_mode
|
||||
|
||||
if new_mode == CpuMode::Fiq {
|
||||
for r in 0..5 {
|
||||
|
|
Reference in a new issue