mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-02-22 23:22:25 +00:00
Make sure not to break when GE debugger closed.
Also, try to fix a might-be race condition.
This commit is contained in:
parent
2ad06d777b
commit
fc7b5f3141
@ -31,7 +31,7 @@ enum PauseAction {
|
||||
PAUSE_GETTEX,
|
||||
PAUSE_SETCMDVALUE,
|
||||
};
|
||||
|
||||
|
||||
static bool isStepping;
|
||||
|
||||
static recursive_mutex pauseLock;
|
||||
@ -40,7 +40,7 @@ static PauseAction pauseAction = PAUSE_CONTINUE;
|
||||
static recursive_mutex actionLock;
|
||||
static condition_variable actionWait;
|
||||
// In case of accidental wakeup.
|
||||
static bool actionComplete;
|
||||
static volatile bool actionComplete;
|
||||
|
||||
// Many things need to run on the GPU thread. For example, reading the framebuffer.
|
||||
// A message system is used to achieve this (temporarily "unpausing" the thread.)
|
||||
|
@ -271,8 +271,8 @@ void CGEDebugger::SetBreakNext(BreakNextType type) {
|
||||
attached = true;
|
||||
SetupPreviews();
|
||||
|
||||
ResumeFromStepping();
|
||||
breakNext = type;
|
||||
ResumeFromStepping();
|
||||
}
|
||||
|
||||
BOOL CGEDebugger::DlgProc(UINT message, WPARAM wParam, LPARAM lParam) {
|
||||
@ -455,7 +455,9 @@ static void DeliverMessage(UINT msg, WPARAM wParam, LPARAM lParam) {
|
||||
}
|
||||
|
||||
static void PauseWithMessage(UINT msg, WPARAM wParam = NULL, LPARAM lParam = NULL) {
|
||||
EnterStepping(std::bind(&DeliverMessage, msg, wParam, lParam));
|
||||
if (attached) {
|
||||
EnterStepping(std::bind(&DeliverMessage, msg, wParam, lParam));
|
||||
}
|
||||
}
|
||||
|
||||
void WindowsHost::GPUNotifyCommand(u32 pc) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user