diff options
| author | 2018-09-30 15:32:27 -0400 | |
|---|---|---|
| committer | 2018-09-30 15:32:27 -0400 | |
| commit | 5e2f23e2b185475c3ce7ae1750ec14daefcd3e08 (patch) | |
| tree | ac2c341c94976552acd507359e8853105193d288 /src/core/gdbstub/gdbstub.cpp | |
| parent | Merge pull request #1418 from FearlessTobi/port-4269 (diff) | |
| parent | kernel/svc: Implement svcGetThreadContext() (diff) | |
| download | yuzu-5e2f23e2b185475c3ce7ae1750ec14daefcd3e08.tar.gz yuzu-5e2f23e2b185475c3ce7ae1750ec14daefcd3e08.tar.xz yuzu-5e2f23e2b185475c3ce7ae1750ec14daefcd3e08.zip | |
Merge pull request #1417 from lioncash/context
svc: Implement svcGetThreadContext
Diffstat (limited to 'src/core/gdbstub/gdbstub.cpp')
| -rw-r--r-- | src/core/gdbstub/gdbstub.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/core/gdbstub/gdbstub.cpp b/src/core/gdbstub/gdbstub.cpp index d8c7b3492..5bc947010 100644 --- a/src/core/gdbstub/gdbstub.cpp +++ b/src/core/gdbstub/gdbstub.cpp | |||
| @@ -250,7 +250,7 @@ static void RegWrite(std::size_t id, u64 val, Kernel::Thread* thread = nullptr) | |||
| 250 | } else if (id == PC_REGISTER) { | 250 | } else if (id == PC_REGISTER) { |
| 251 | thread->context.pc = val; | 251 | thread->context.pc = val; |
| 252 | } else if (id == PSTATE_REGISTER) { | 252 | } else if (id == PSTATE_REGISTER) { |
| 253 | thread->context.pstate = val; | 253 | thread->context.pstate = static_cast<u32>(val); |
| 254 | } else if (id > PSTATE_REGISTER && id < FPCR_REGISTER) { | 254 | } else if (id > PSTATE_REGISTER && id < FPCR_REGISTER) { |
| 255 | thread->context.vector_registers[id - (PSTATE_REGISTER + 1)][0] = val; | 255 | thread->context.vector_registers[id - (PSTATE_REGISTER + 1)][0] = val; |
| 256 | } | 256 | } |
| @@ -587,7 +587,7 @@ static void HandleQuery() { | |||
| 587 | strlen("Xfer:features:read:target.xml:")) == 0) { | 587 | strlen("Xfer:features:read:target.xml:")) == 0) { |
| 588 | SendReply(target_xml); | 588 | SendReply(target_xml); |
| 589 | } else if (strncmp(query, "Offsets", strlen("Offsets")) == 0) { | 589 | } else if (strncmp(query, "Offsets", strlen("Offsets")) == 0) { |
| 590 | const VAddr base_address = Core::CurrentProcess()->vm_manager.GetCodeRegionBaseAddress(); | 590 | const VAddr base_address = Core::CurrentProcess()->VMManager().GetCodeRegionBaseAddress(); |
| 591 | std::string buffer = fmt::format("TextSeg={:0x}", base_address); | 591 | std::string buffer = fmt::format("TextSeg={:0x}", base_address); |
| 592 | SendReply(buffer.c_str()); | 592 | SendReply(buffer.c_str()); |
| 593 | } else if (strncmp(query, "fThreadInfo", strlen("fThreadInfo")) == 0) { | 593 | } else if (strncmp(query, "fThreadInfo", strlen("fThreadInfo")) == 0) { |
| @@ -909,7 +909,7 @@ static void ReadMemory() { | |||
| 909 | SendReply("E01"); | 909 | SendReply("E01"); |
| 910 | } | 910 | } |
| 911 | 911 | ||
| 912 | const auto& vm_manager = Core::CurrentProcess()->vm_manager; | 912 | const auto& vm_manager = Core::CurrentProcess()->VMManager(); |
| 913 | if (addr < vm_manager.GetCodeRegionBaseAddress() || | 913 | if (addr < vm_manager.GetCodeRegionBaseAddress() || |
| 914 | addr >= vm_manager.GetMapRegionEndAddress()) { | 914 | addr >= vm_manager.GetMapRegionEndAddress()) { |
| 915 | return SendReply("E00"); | 915 | return SendReply("E00"); |