summaryrefslogtreecommitdiff
path: root/src/core/gdbstub/gdbstub.cpp
diff options
context:
space:
mode:
authorGravatar polaris-2015-10-21 07:19:03 -0400
committerGravatar polaris-2015-10-21 07:19:03 -0400
commit8a0d848646661c28a03c4659caf64e38fc92c127 (patch)
tree9720b7baf7b26fa907e0f00410b9dc85f486278b /src/core/gdbstub/gdbstub.cpp
parentTry to add support for VFP registers (diff)
downloadyuzu-8a0d848646661c28a03c4659caf64e38fc92c127.tar.gz
yuzu-8a0d848646661c28a03c4659caf64e38fc92c127.tar.xz
yuzu-8a0d848646661c28a03c4659caf64e38fc92c127.zip
Pad responses to gdb for VFP registers
Diffstat (limited to 'src/core/gdbstub/gdbstub.cpp')
-rw-r--r--src/core/gdbstub/gdbstub.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/core/gdbstub/gdbstub.cpp b/src/core/gdbstub/gdbstub.cpp
index a6977302c..7d8e9e3fb 100644
--- a/src/core/gdbstub/gdbstub.cpp
+++ b/src/core/gdbstub/gdbstub.cpp
@@ -473,6 +473,7 @@ static void ReadRegister() {
473 IntToHex(reply, Core::g_app_core->GetVFPReg(id - CSPR_REGISTER - 1)); // VFP registers should start at 26, so one after CSPR_REGISTER 473 IntToHex(reply, Core::g_app_core->GetVFPReg(id - CSPR_REGISTER - 1)); // VFP registers should start at 26, so one after CSPR_REGISTER
474 } else if (id == FPSCR_REGISTER) { 474 } else if (id == FPSCR_REGISTER) {
475 IntToHex(reply, Core::g_app_core->GetVFPSystemReg(VFP_FPSCR)); // Get FPSCR 475 IntToHex(reply, Core::g_app_core->GetVFPSystemReg(VFP_FPSCR)); // Get FPSCR
476 IntToHex(reply + 8, 0);
476 } else { 477 } else {
477 return SendReply("E01"); 478 return SendReply("E01");
478 } 479 }
@@ -497,6 +498,8 @@ static void ReadRegisters() {
497 i++; // These registers seem to be all 64bit instead of 32bit, so skip two instead of one 498 i++; // These registers seem to be all 64bit instead of 32bit, so skip two instead of one
498 } else if (i > CSPR_REGISTER && i < FPSCR_REGISTER) { 499 } else if (i > CSPR_REGISTER && i < FPSCR_REGISTER) {
499 IntToHex(bufptr + i * 8, Core::g_app_core->GetVFPReg(i - CSPR_REGISTER - 1)); 500 IntToHex(bufptr + i * 8, Core::g_app_core->GetVFPReg(i - CSPR_REGISTER - 1));
501 IntToHex(bufptr + (i + 1) * 8, 0);
502 i++;
500 } else if (i == FPSCR_REGISTER) { 503 } else if (i == FPSCR_REGISTER) {
501 IntToHex(bufptr + i * 8, Core::g_app_core->GetVFPSystemReg(VFP_FPSCR)); 504 IntToHex(bufptr + i * 8, Core::g_app_core->GetVFPSystemReg(VFP_FPSCR));
502 } 505 }