Debugger: Fixed CPU read/write breakpoints breaking on PPU memory read/writes (e.g vram, cgram, oam)
This commit is contained in:
parent
7afc52dc4b
commit
c433b3fe33
2 changed files with 14 additions and 1 deletions
|
@ -5,7 +5,7 @@
|
||||||
|
|
||||||
bool Breakpoint::Matches(uint32_t memoryAddr, AddressInfo &info)
|
bool Breakpoint::Matches(uint32_t memoryAddr, AddressInfo &info)
|
||||||
{
|
{
|
||||||
if(_memoryType <= DebugUtilities::GetLastCpuMemoryType()) {
|
if(_memoryType <= DebugUtilities::GetLastCpuMemoryType() && !DebugUtilities::IsPpuMemory(info.Type)) {
|
||||||
if(_startAddr == -1) {
|
if(_startAddr == -1) {
|
||||||
return true;
|
return true;
|
||||||
} else if(_endAddr == -1) {
|
} else if(_endAddr == -1) {
|
||||||
|
|
|
@ -25,6 +25,19 @@ public:
|
||||||
return SnesMemoryType::GsuMemory;
|
return SnesMemoryType::GsuMemory;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static bool IsPpuMemory(SnesMemoryType memType)
|
||||||
|
{
|
||||||
|
switch(memType) {
|
||||||
|
case SnesMemoryType::VideoRam:
|
||||||
|
case SnesMemoryType::SpriteRam:
|
||||||
|
case SnesMemoryType::CGRam:
|
||||||
|
return true;
|
||||||
|
|
||||||
|
default:
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
static constexpr CpuType GetLastCpuType()
|
static constexpr CpuType GetLastCpuType()
|
||||||
{
|
{
|
||||||
return CpuType::Cx4;
|
return CpuType::Cx4;
|
||||||
|
|
Loading…
Add table
Reference in a new issue