From fb4b3c127f7c390358d7f4cadd2f58de116fec48 Mon Sep 17 00:00:00 2001 From: Liam Date: Mon, 30 May 2022 19:35:01 -0400 Subject: core/debugger: Implement new GDB stub debugger --- src/core/core.h | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) (limited to 'src/core/core.h') diff --git a/src/core/core.h b/src/core/core.h index 4a0c7dc84..94477206e 100644 --- a/src/core/core.h +++ b/src/core/core.h @@ -97,6 +97,7 @@ namespace Core { class ARM_Interface; class CpuManager; +class Debugger; class DeviceMemory; class ExclusiveMonitor; class SpeedLimiter; @@ -147,12 +148,6 @@ public: */ [[nodiscard]] SystemResultStatus Pause(); - /** - * Step the CPU one instruction - * @return Result status, indicating whether or not the operation succeeded. - */ - [[nodiscard]] SystemResultStatus SingleStep(); - /** * Invalidate the CPU instruction caches * This function should only be used by GDB Stub to support breakpoints, memory updates and @@ -168,6 +163,11 @@ public: std::unique_lock StallCPU(); void UnstallCPU(); + /** + * Initialize the debugger. + */ + void InitializeDebugger(); + /** * Load an executable application. * @param emu_window Reference to the host-system window used for video output and keyboard @@ -354,6 +354,9 @@ public: [[nodiscard]] Service::Time::TimeManager& GetTimeManager(); [[nodiscard]] const Service::Time::TimeManager& GetTimeManager() const; + [[nodiscard]] Core::Debugger& GetDebugger(); + [[nodiscard]] const Core::Debugger& GetDebugger() const; + void SetExitLock(bool locked); [[nodiscard]] bool GetExitLock() const; @@ -375,6 +378,9 @@ public: /// Tells if system is running on multicore. [[nodiscard]] bool IsMulticore() const; + /// Tells if the system debugger is enabled. + [[nodiscard]] bool DebuggerEnabled() const; + /// Type used for the frontend to designate a callback for System to re-launch the application /// using a specified program index. using ExecuteProgramCallback = std::function; -- cgit v1.2.3