dmnt: implement remaining basic gdbstub packets

This commit is contained in:
Michael Scire 2021-07-23 05:29:39 -07:00 committed by SciresM
parent 534c2c76f5
commit 904ab19823
4 changed files with 541 additions and 2 deletions

View file

@ -313,6 +313,15 @@ namespace ams::dmnt {
}
}
Result DebugProcess::Terminate() {
if (this->IsValid()) {
R_ABORT_UNLESS(svc::TerminateDebugProcess(m_debug_handle));
this->Detach();
}
return ResultSuccess();
}
void DebugProcess::GetBranchTarget(svc::ThreadContext &ctx, u64 thread_id, u64 &current_pc, u64 &target) {
/* Save pc, in case we modify it. */
const u64 pc = current_pc;