Skip to content

Commit

Permalink
Debugger: Added single step debugging
Browse files Browse the repository at this point in the history
  • Loading branch information
vertver committed Apr 4, 2024
1 parent 8d42e2a commit 03ddc0b
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions pcsx2/DebugTools/GDBServer.h
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,28 @@ class GDBServer final : public DebugServerInterface
bool processReadMemoryPacket(const std::string_view& data);
bool processWriteMemoryPacket(const std::string_view& data, bool binary);

private:
u32 getRegisterSize(int id);
bool readRegister(int threadId, int id, u32& value);
bool writeRegister(int threadId, int id, u32 value);

private:
bool writePacketBegin();
bool writePacketEnd();
bool writePacketData(const char* data, std::size_t size);

bool writeBaseResponse(std::string_view data);
bool writeThreadId(int threadId, int processId = 1);
bool writeRegisterValue(int threadId, int registerNumber);
bool writeAllRegisterValues(int threadId);

private:
bool processXferPacket(std::string_view data);
bool processQueryPacket(std::string_view data);
bool processGeneralQueryPacket(std::string_view data);
bool processMultiletterPacket(std::string_view data);
bool processThreadPacket(std::string_view data);

private:
int m_stateThreadCounter = -1;
std::vector<std::unique_ptr<BiosThread>> m_stateThreads;
Expand Down

0 comments on commit 03ddc0b

Please sign in to comment.