diff --git a/src/debugger/DiStella.cxx b/src/debugger/DiStella.cxx index 9177ae1f3..d8e740abd 100644 --- a/src/debugger/DiStella.cxx +++ b/src/debugger/DiStella.cxx @@ -919,13 +919,12 @@ DONE_WITH_ADD: // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - void DiStella::processDirectives(const CartDebug::DirectiveList& directives) { - for(CartDebug::DirectiveList::const_iterator i = directives.begin(); i != directives.end(); ++i) { const CartDebug::DirectiveTag tag = *i; if(check_range(tag.start, tag.end)) - for(uInt16 k = tag.start; k <= tag.end; ++k) + for(uInt32 k = tag.start; k <= tag.end; ++k) mark(k, tag.type); } } diff --git a/src/emucore/M6502.ins b/src/emucore/M6502.ins index 6a6eddf6a..1391b3c61 100644 --- a/src/emucore/M6502.ins +++ b/src/emucore/M6502.ins @@ -14,7 +14,7 @@ // See the file "License.txt" for information on usage and redistribution of // this file, and for a DISCLAIMER OF ALL WARRANTIES. // -// $Id: M6502.m4 2150 2010-10-11 14:51:48Z stephena $ +// $Id: M6502.m4 2151 2010-10-11 15:11:10Z stephena $ //============================================================================ /** @@ -24,7 +24,7 @@ 'm4 M6502.m4 > M6502.ins' @author Bradford W. Mott - @version $Id: M6502.m4 2150 2010-10-11 14:51:48Z stephena $ + @version $Id: M6502.m4 2151 2010-10-11 15:11:10Z stephena $ */ #ifndef NOTSAMEPAGE @@ -32,17 +32,29 @@ #endif #ifndef SET_LAST_PEEK - #define SET_LAST_PEEK(_addr) _addr = intermediateAddress; + #ifdef DEBUGGER_SUPPORT + #define SET_LAST_PEEK(_addr) _addr = intermediateAddress; + #else + #define SET_LAST_PEEK(_addr) + #endif #endif #ifndef CLEAR_LAST_PEEK - #define CLEAR_LAST_PEEK(_addr) _addr = 0; + #ifdef DEBUGGER_SUPPORT + #define CLEAR_LAST_PEEK(_addr) _addr = 0; + #else + #define CLEAR_LAST_PEEK(_addr) + #endif #endif #ifndef CHECK_GFX_WRITE - #define CHECK_GFX_WRITE(_addr) \ - if((operandAddress == 0x1B || operandAddress == 0x1C) && _addr) \ - mySystem->setAddressDisasmType(_addr, DISASM_GFX); + #ifdef DEBUGGER_SUPPORT + #define CHECK_GFX_WRITE(_addr) \ + if((operandAddress == 0x1B || operandAddress == 0x1C) && _addr) \ + mySystem->setAddressDisasmType(_addr, DISASM_GFX); + #else + #define CHECK_GFX_WRITE(_addr) + #endif #endif diff --git a/src/emucore/M6502.m4 b/src/emucore/M6502.m4 index 50b7582d7..57202b8ee 100644 --- a/src/emucore/M6502.m4 +++ b/src/emucore/M6502.m4 @@ -32,17 +32,29 @@ #endif #ifndef SET_LAST_PEEK - #define SET_LAST_PEEK(_addr) _addr = intermediateAddress; + #ifdef DEBUGGER_SUPPORT + #define SET_LAST_PEEK(_addr) _addr = intermediateAddress; + #else + #define SET_LAST_PEEK(_addr) + #endif #endif #ifndef CLEAR_LAST_PEEK - #define CLEAR_LAST_PEEK(_addr) _addr = 0; + #ifdef DEBUGGER_SUPPORT + #define CLEAR_LAST_PEEK(_addr) _addr = 0; + #else + #define CLEAR_LAST_PEEK(_addr) + #endif #endif #ifndef CHECK_GFX_WRITE - #define CHECK_GFX_WRITE(_addr) \ - if((operandAddress == 0x1B || operandAddress == 0x1C) && _addr) \ - mySystem->setAddressDisasmType(_addr, DISASM_GFX); + #ifdef DEBUGGER_SUPPORT + #define CHECK_GFX_WRITE(_addr) \ + if((operandAddress == 0x1B || operandAddress == 0x1C) && _addr) \ + mySystem->setAddressDisasmType(_addr, DISASM_GFX); + #else + #define CHECK_GFX_WRITE(_addr) + #endif #endif diff --git a/src/emucore/System.cxx b/src/emucore/System.cxx index 494cacfce..d82216183 100644 --- a/src/emucore/System.cxx +++ b/src/emucore/System.cxx @@ -19,7 +19,7 @@ #include #include -#include "Debugger.hxx" + #include "Device.hxx" #include "M6502.hxx" #include "M6532.hxx" @@ -216,9 +216,11 @@ uInt8 System::peek(uInt16 addr, uInt8 flags) { PageAccess& access = myPageAccessTable[(addr & myAddressMask) >> myPageShift]; +#ifdef DEBUGGER_SUPPORT // Set access type if(access.codeAccessBase) *(access.codeAccessBase + (addr & myPageMask)) |= flags; +#endif // See if this page uses direct accessing or not uInt8 result;