mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-02-26 00:45:49 +00:00
Ensure only the very next instruction is skipped.
This commit is contained in:
parent
70cd8798be
commit
f3e27ad9dd
@ -15,16 +15,17 @@
|
||||
// Official git repository and contact information can be found at
|
||||
// https://github.com/hrydgard/ppsspp and http://www.ppsspp.org/.
|
||||
|
||||
#include "../Core.h"
|
||||
#include "Breakpoints.h"
|
||||
#include "SymbolMap.h"
|
||||
#include "FixedSizeUnorderedSet.h"
|
||||
#include "Core/Core.h"
|
||||
#include "Core/Debugger/Breakpoints.h"
|
||||
#include "Core/Debugger/SymbolMap.h"
|
||||
#include "Core/Host.h"
|
||||
#include "../MIPS/JitCommon/JitCommon.h"
|
||||
#include "Core/MIPS/JitCommon/JitCommon.h"
|
||||
#include "Core/CoreTiming.h"
|
||||
#include <cstdio>
|
||||
|
||||
std::vector<BreakPoint> CBreakPoints::breakPoints_;
|
||||
u32 CBreakPoints::breakSkipFirstAt_ = 0;
|
||||
u64 CBreakPoints::breakSkipFirstTicks_ = 0;
|
||||
std::vector<MemCheck> CBreakPoints::memChecks_;
|
||||
|
||||
MemCheck::MemCheck(void)
|
||||
@ -260,6 +261,20 @@ MemCheck *CBreakPoints::GetMemCheck(u32 address, int size)
|
||||
return 0;
|
||||
}
|
||||
|
||||
void CBreakPoints::SetSkipFirst(u32 pc)
|
||||
{
|
||||
breakSkipFirstAt_ = pc;
|
||||
breakSkipFirstTicks_ = CoreTiming::GetTicks();
|
||||
}
|
||||
u32 CBreakPoints::CheckSkipFirst()
|
||||
{
|
||||
u32 pc = breakSkipFirstAt_;
|
||||
breakSkipFirstAt_ = 0;
|
||||
if (breakSkipFirstTicks_ == CoreTiming::GetTicks())
|
||||
return pc;
|
||||
return 0;
|
||||
}
|
||||
|
||||
const std::vector<MemCheck> CBreakPoints::GetMemChecks()
|
||||
{
|
||||
return memChecks_;
|
||||
|
@ -114,9 +114,8 @@ public:
|
||||
|
||||
static MemCheck *GetMemCheck(u32 address, int size);
|
||||
|
||||
// TODO: MemChecks somehow too?
|
||||
static void SetSkipFirst(u32 pc) { breakSkipFirstAt_ = pc; }
|
||||
static u32 CheckSkipFirst() { u32 pc = breakSkipFirstAt_; breakSkipFirstAt_ = 0; return pc; }
|
||||
static void SetSkipFirst(u32 pc);
|
||||
static u32 CheckSkipFirst();
|
||||
|
||||
static const std::vector<MemCheck> GetMemChecks();
|
||||
static const std::vector<BreakPoint> GetBreakpoints();
|
||||
@ -130,6 +129,7 @@ private:
|
||||
|
||||
static std::vector<BreakPoint> breakPoints_;
|
||||
static u32 breakSkipFirstAt_;
|
||||
static u64 breakSkipFirstTicks_;
|
||||
|
||||
static std::vector<MemCheck> memChecks_;
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user