mirror of https://github.com/PCSX2/pcsx2.git
Fix up debugger stepping
This commit is contained in:
parent
939e576df9
commit
4ce3fdfcb2
|
@ -60,7 +60,7 @@ void intBreakpoint(bool memcheck)
|
||||||
}
|
}
|
||||||
|
|
||||||
CBreakPoints::SetBreakpointTriggered(true);
|
CBreakPoints::SetBreakpointTriggered(true);
|
||||||
GetCoreThread().PauseSelf();
|
GetCoreThread().PauseSelfDebug();
|
||||||
throw Exception::ExitCpuExecute();
|
throw Exception::ExitCpuExecute();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -168,6 +168,21 @@ void SysThreadBase::PauseSelf()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void SysThreadBase::PauseSelfDebug()
|
||||||
|
{
|
||||||
|
if (!IsSelf() || !IsRunning()) return;
|
||||||
|
|
||||||
|
{
|
||||||
|
ScopedLock locker(m_ExecModeMutex);
|
||||||
|
|
||||||
|
if (m_ExecMode == ExecMode_Opened)
|
||||||
|
m_ExecMode = ExecMode_Pausing;
|
||||||
|
|
||||||
|
OnPauseDebug();
|
||||||
|
m_sem_event.Post();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// Resumes the core execution state, or does nothing is the core is already running. If
|
// Resumes the core execution state, or does nothing is the core is already running. If
|
||||||
// settings were changed, resets will be performed as needed and emulation state resumed from
|
// settings were changed, resets will be performed as needed and emulation state resumed from
|
||||||
// memory savestates.
|
// memory savestates.
|
||||||
|
|
|
@ -114,6 +114,7 @@ public:
|
||||||
virtual void Resume();
|
virtual void Resume();
|
||||||
virtual void Pause(bool debug = false);
|
virtual void Pause(bool debug = false);
|
||||||
virtual void PauseSelf();
|
virtual void PauseSelf();
|
||||||
|
virtual void PauseSelfDebug();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
virtual void OnStart();
|
virtual void OnStart();
|
||||||
|
|
|
@ -611,6 +611,7 @@ void DisassemblyDialog::setDebugMode(bool debugMode, bool switchPC)
|
||||||
|
|
||||||
if (debugMode)
|
if (debugMode)
|
||||||
{
|
{
|
||||||
|
if (!CBreakPoints::GetBreakpointTriggered())
|
||||||
{
|
{
|
||||||
wxBusyInfo wait("Please wait, Reading ELF functions");
|
wxBusyInfo wait("Please wait, Reading ELF functions");
|
||||||
reset();
|
reset();
|
||||||
|
|
|
@ -1148,7 +1148,7 @@ void dynarecCheckBreakpoint()
|
||||||
return;
|
return;
|
||||||
|
|
||||||
CBreakPoints::SetBreakpointTriggered(true);
|
CBreakPoints::SetBreakpointTriggered(true);
|
||||||
GetCoreThread().PauseSelf();
|
GetCoreThread().PauseSelfDebug();
|
||||||
recExitExecution();
|
recExitExecution();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1159,7 +1159,7 @@ void dynarecMemcheck()
|
||||||
return;
|
return;
|
||||||
|
|
||||||
CBreakPoints::SetBreakpointTriggered(true);
|
CBreakPoints::SetBreakpointTriggered(true);
|
||||||
GetCoreThread().PauseSelf();
|
GetCoreThread().PauseSelfDebug();
|
||||||
recExitExecution();
|
recExitExecution();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue