summaryrefslogtreecommitdiffstats
path: root/src/core/gdbstub/gdbstub.cpp
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2018-05-03 04:36:51 +0200
committerbunnei <bunneidev@gmail.com>2018-05-11 01:34:46 +0200
commita434fdcb102e96ddf564dc0973d7073d49bf19fc (patch)
treede758b0cc5ebcb67146397a74474fb898c0be51a /src/core/gdbstub/gdbstub.cpp
parentcore: Create a thread for each CPU core, keep in lock-step with a barrier. (diff)
downloadyuzu-a434fdcb102e96ddf564dc0973d7073d49bf19fc.tar
yuzu-a434fdcb102e96ddf564dc0973d7073d49bf19fc.tar.gz
yuzu-a434fdcb102e96ddf564dc0973d7073d49bf19fc.tar.bz2
yuzu-a434fdcb102e96ddf564dc0973d7073d49bf19fc.tar.lz
yuzu-a434fdcb102e96ddf564dc0973d7073d49bf19fc.tar.xz
yuzu-a434fdcb102e96ddf564dc0973d7073d49bf19fc.tar.zst
yuzu-a434fdcb102e96ddf564dc0973d7073d49bf19fc.zip
Diffstat (limited to 'src/core/gdbstub/gdbstub.cpp')
-rw-r--r--src/core/gdbstub/gdbstub.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/core/gdbstub/gdbstub.cpp b/src/core/gdbstub/gdbstub.cpp
index 46606b992..6c5a40ba8 100644
--- a/src/core/gdbstub/gdbstub.cpp
+++ b/src/core/gdbstub/gdbstub.cpp
@@ -598,11 +598,11 @@ static void ReadRegister() {
}
if (id <= SP_REGISTER) {
- LongToGdbHex(reply, Core::CPU().GetReg(static_cast<int>(id)));
+ LongToGdbHex(reply, Core::CurrentArmInterface().GetReg(static_cast<int>(id)));
} else if (id == PC_REGISTER) {
- LongToGdbHex(reply, Core::CPU().GetPC());
+ LongToGdbHex(reply, Core::CurrentArmInterface().GetPC());
} else if (id == CPSR_REGISTER) {
- IntToGdbHex(reply, Core::CPU().GetCPSR());
+ IntToGdbHex(reply, Core::CurrentArmInterface().GetCPSR());
} else {
return SendReply("E01");
}
@@ -618,16 +618,16 @@ static void ReadRegisters() {
u8* bufptr = buffer;
for (int reg = 0; reg <= SP_REGISTER; reg++) {
- LongToGdbHex(bufptr + reg * 16, Core::CPU().GetReg(reg));
+ LongToGdbHex(bufptr + reg * 16, Core::CurrentArmInterface().GetReg(reg));
}
bufptr += (32 * 16);
- LongToGdbHex(bufptr, Core::CPU().GetPC());
+ LongToGdbHex(bufptr, Core::CurrentArmInterface().GetPC());
bufptr += 16;
- IntToGdbHex(bufptr, Core::CPU().GetCPSR());
+ IntToGdbHex(bufptr, Core::CurrentArmInterface().GetCPSR());
bufptr += 8;
@@ -646,11 +646,11 @@ static void WriteRegister() {
}
if (id <= SP_REGISTER) {
- Core::CPU().SetReg(id, GdbHexToLong(buffer_ptr));
+ Core::CurrentArmInterface().SetReg(id, GdbHexToLong(buffer_ptr));
} else if (id == PC_REGISTER) {
- Core::CPU().SetPC(GdbHexToLong(buffer_ptr));
+ Core::CurrentArmInterface().SetPC(GdbHexToLong(buffer_ptr));
} else if (id == CPSR_REGISTER) {
- Core::CPU().SetCPSR(GdbHexToInt(buffer_ptr));
+ Core::CurrentArmInterface().SetCPSR(GdbHexToInt(buffer_ptr));
} else {
return SendReply("E01");
}
@@ -667,11 +667,11 @@ static void WriteRegisters() {
for (int i = 0, reg = 0; reg <= CPSR_REGISTER; i++, reg++) {
if (reg <= SP_REGISTER) {
- Core::CPU().SetReg(reg, GdbHexToLong(buffer_ptr + i * 16));
+ Core::CurrentArmInterface().SetReg(reg, GdbHexToLong(buffer_ptr + i * 16));
} else if (reg == PC_REGISTER) {
- Core::CPU().SetPC(GdbHexToLong(buffer_ptr + i * 16));
+ Core::CurrentArmInterface().SetPC(GdbHexToLong(buffer_ptr + i * 16));
} else if (reg == CPSR_REGISTER) {
- Core::CPU().SetCPSR(GdbHexToInt(buffer_ptr + i * 16));
+ Core::CurrentArmInterface().SetCPSR(GdbHexToInt(buffer_ptr + i * 16));
} else {
UNIMPLEMENTED();
}