summaryrefslogtreecommitdiffstats
path: root/src/core/arm/arm_interface.h
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2016-12-22 06:08:09 +0100
committerbunnei <bunneidev@gmail.com>2016-12-22 06:27:49 +0100
commit8b1e269e5898ad0b6aadabee41fea777f0e62fdc (patch)
tree74040972517faa02fa84a819c5a39fcad12a8953 /src/core/arm/arm_interface.h
parentcore: Replace "AppCore" nomenclature with just "CPU". (diff)
downloadyuzu-8b1e269e5898ad0b6aadabee41fea777f0e62fdc.tar
yuzu-8b1e269e5898ad0b6aadabee41fea777f0e62fdc.tar.gz
yuzu-8b1e269e5898ad0b6aadabee41fea777f0e62fdc.tar.bz2
yuzu-8b1e269e5898ad0b6aadabee41fea777f0e62fdc.tar.lz
yuzu-8b1e269e5898ad0b6aadabee41fea777f0e62fdc.tar.xz
yuzu-8b1e269e5898ad0b6aadabee41fea777f0e62fdc.tar.zst
yuzu-8b1e269e5898ad0b6aadabee41fea777f0e62fdc.zip
Diffstat (limited to 'src/core/arm/arm_interface.h')
-rw-r--r--src/core/arm/arm_interface.h19
1 files changed, 13 insertions, 6 deletions
diff --git a/src/core/arm/arm_interface.h b/src/core/arm/arm_interface.h
index e466b21b2..ccd43f431 100644
--- a/src/core/arm/arm_interface.h
+++ b/src/core/arm/arm_interface.h
@@ -8,15 +8,22 @@
#include "core/arm/skyeye_common/arm_regformat.h"
#include "core/arm/skyeye_common/vfp/asm_vfp.h"
-namespace Core {
-struct ThreadContext;
-}
-
/// Generic ARM11 CPU interface
class ARM_Interface : NonCopyable {
public:
virtual ~ARM_Interface() {}
+ struct ThreadContext {
+ u32 cpu_registers[13];
+ u32 sp;
+ u32 lr;
+ u32 pc;
+ u32 cpsr;
+ u32 fpu_registers[64];
+ u32 fpscr;
+ u32 fpexc;
+ };
+
/**
* Runs the CPU for the given number of instructions
* @param num_instructions Number of instructions to run
@@ -124,13 +131,13 @@ public:
* Saves the current CPU context
* @param ctx Thread context to save
*/
- virtual void SaveContext(Core::ThreadContext& ctx) = 0;
+ virtual void SaveContext(ThreadContext& ctx) = 0;
/**
* Loads a CPU context
* @param ctx Thread context to load
*/
- virtual void LoadContext(const Core::ThreadContext& ctx) = 0;
+ virtual void LoadContext(const ThreadContext& ctx) = 0;
/// Prepare core for thread reschedule (if needed to correctly handle state)
virtual void PrepareReschedule() = 0;