diff options
author | Lioncash <mathew1800@gmail.com> | 2016-03-21 10:50:05 +0100 |
---|---|---|
committer | Lioncash <mathew1800@gmail.com> | 2016-03-21 23:56:27 +0100 |
commit | d53c9cde1a3c48b31e7f07e3f8ffb5e6c056c5ef (patch) | |
tree | 7a657f1535ec0107f141d3e5a18c2136d8f05ec6 /src/core/arm/skyeye_common/armstate.cpp | |
parent | Merge pull request #1302 from Subv/save_fix (diff) | |
download | yuzu-d53c9cde1a3c48b31e7f07e3f8ffb5e6c056c5ef.tar yuzu-d53c9cde1a3c48b31e7f07e3f8ffb5e6c056c5ef.tar.gz yuzu-d53c9cde1a3c48b31e7f07e3f8ffb5e6c056c5ef.tar.bz2 yuzu-d53c9cde1a3c48b31e7f07e3f8ffb5e6c056c5ef.tar.lz yuzu-d53c9cde1a3c48b31e7f07e3f8ffb5e6c056c5ef.tar.xz yuzu-d53c9cde1a3c48b31e7f07e3f8ffb5e6c056c5ef.tar.zst yuzu-d53c9cde1a3c48b31e7f07e3f8ffb5e6c056c5ef.zip |
Diffstat (limited to 'src/core/arm/skyeye_common/armstate.cpp')
-rw-r--r-- | src/core/arm/skyeye_common/armstate.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/core/arm/skyeye_common/armstate.cpp b/src/core/arm/skyeye_common/armstate.cpp index 2d814345a..5550c112e 100644 --- a/src/core/arm/skyeye_common/armstate.cpp +++ b/src/core/arm/skyeye_common/armstate.cpp @@ -2,6 +2,7 @@ // Licensed under GPLv2 or any later version // Refer to the license.txt file included. +#include <algorithm> #include "common/swap.h" #include "common/logging/log.h" #include "core/memory.h" @@ -48,8 +49,7 @@ void ARMul_State::ChangePrivilegeMode(u32 new_mode) Spsr[UNDEFBANK] = Spsr_copy; break; case FIQ32MODE: - Reg_firq[0] = Reg[13]; - Reg_firq[1] = Reg[14]; + std::copy(Reg.begin() + 8, Reg.end() - 1, Reg_firq.begin()); Spsr[FIQBANK] = Spsr_copy; break; } @@ -85,8 +85,7 @@ void ARMul_State::ChangePrivilegeMode(u32 new_mode) Bank = UNDEFBANK; break; case FIQ32MODE: - Reg[13] = Reg_firq[0]; - Reg[14] = Reg_firq[1]; + std::copy(Reg_firq.begin(), Reg_firq.end(), Reg.begin() + 8); Spsr_copy = Spsr[FIQBANK]; Bank = FIQBANK; break; |