mirror of
https://github.com/AppleWin/AppleWin.git
synced 2025-01-03 11:30:22 +00:00
Debugger: Format changes only (PR #1076)
This commit is contained in:
parent
b6404e7d96
commit
1bcf371309
@ -786,7 +786,6 @@ Update_t CmdProfile (int nArgs)
|
||||
// Dump to console
|
||||
if (iParam == PARAM_LIST)
|
||||
{
|
||||
|
||||
char *pText;
|
||||
char sText[ CONSOLE_WIDTH ];
|
||||
|
||||
@ -5061,11 +5060,11 @@ Update_t CmdNTSC (int nArgs)
|
||||
uint32_t* pChromaTable = NTSC_VideoGetChromaTable( false, bColorTV );
|
||||
char aStatusText[ CONSOLE_WIDTH*2 ] = "Loaded";
|
||||
|
||||
//uint8_t* pTmp = (uint8_t*) pChromaTable;
|
||||
//*pTmp++ = 0xFF; // b
|
||||
//*pTmp++ = 0x00; // g
|
||||
//*pTmp++ = 0x00; // r
|
||||
//*pTmp++ = 0xFF; // a
|
||||
//uint8_t* pTmp = (uint8_t*) pChromaTable;
|
||||
//*pTmp++ = 0xFF; // b
|
||||
//*pTmp++ = 0x00; // g
|
||||
//*pTmp++ = 0x00; // r
|
||||
//*pTmp++ = 0xFF; // a
|
||||
|
||||
if (nFound)
|
||||
{
|
||||
@ -5192,7 +5191,7 @@ Update_t CmdNTSC (int nArgs)
|
||||
uint8_t *pTemp64x256 = new uint8_t[ 64 * 256 * 4 ];
|
||||
memset( pTemp64x256, 0, g_nChromaSize );
|
||||
|
||||
//Transpose16x1::transposeFrom16x1( pSwizzled, (uint8_t*) pChromaTable );
|
||||
//Transpose16x1::transposeFrom16x1( pSwizzled, (uint8_t*) pChromaTable );
|
||||
|
||||
if (pBmp->nWidthPixels == 16)
|
||||
{
|
||||
@ -5317,7 +5316,7 @@ int _SearchMemoryFind(
|
||||
WORD nAddress2 = nAddress;
|
||||
|
||||
int nMemBlocks = vMemorySearchValues.size();
|
||||
for (int iBlock = 0; iBlock < nMemBlocks; iBlock++, nAddress2++ )
|
||||
for ( int iBlock = 0; iBlock < nMemBlocks; iBlock++, nAddress2++ )
|
||||
{
|
||||
MemorySearch_t ms = vMemorySearchValues.at( iBlock );
|
||||
ms.m_bFound = false;
|
||||
@ -7942,7 +7941,7 @@ void ProfileFormat( bool bExport, ProfileFormat_e eFormatMode )
|
||||
pColorTotal = CHC_DEFAULT; // white
|
||||
}
|
||||
|
||||
// Opcode
|
||||
// Opcode
|
||||
if (bExport) // Export = SeperateColumns
|
||||
sprintf( pText
|
||||
, "\"Percent\"" DELIM "\"Count\"" DELIM "\"Opcode\"" DELIM "\"Mnemonic\"" DELIM "\"Addressing Mode\"\n"
|
||||
@ -8659,7 +8658,7 @@ void DebugInitialize ()
|
||||
}
|
||||
|
||||
#if _DEBUG
|
||||
//g_bConsoleBufferPaused = true;
|
||||
//g_bConsoleBufferPaused = true;
|
||||
#endif
|
||||
|
||||
_Bookmark_Reset();
|
||||
|
@ -326,7 +326,7 @@ int GetDisassemblyLine(WORD nBaseAddress, DisasmLine_t& line_)
|
||||
pTarget = &strAddressBuf;
|
||||
}
|
||||
|
||||
// sprintf( sTarget, g_aOpmodes[ iOpmode ]._sFormat, pTarget );
|
||||
//sprintf( sTarget, g_aOpmodes[ iOpmode ]._sFormat, pTarget );
|
||||
if (bDisasmFormatFlags & DISASM_FORMAT_OFFSET)
|
||||
{
|
||||
int nAbsTargetOffset = (line_.nTargetOffset > 0) ? line_.nTargetOffset : -line_.nTargetOffset;
|
||||
@ -348,7 +348,7 @@ int GetDisassemblyLine(WORD nBaseAddress, DisasmLine_t& line_)
|
||||
|
||||
nTargetValue = *(mem + nTargetPointer) | (*(mem + ((nTargetPointer + 1) & 0xffff)) << 8);
|
||||
|
||||
// if (((iOpmode >= AM_A) && (iOpmode <= AM_NZ)) && (iOpmode != AM_R))
|
||||
//if (((iOpmode >= AM_A) && (iOpmode <= AM_NZ)) && (iOpmode != AM_R))
|
||||
// sprintf( sTargetValue_, "%04X", nTargetValue ); // & 0xFFFF
|
||||
|
||||
if (g_iConfigDisasmTargets & DISASM_TARGET_ADDR)
|
||||
@ -366,7 +366,7 @@ int GetDisassemblyLine(WORD nBaseAddress, DisasmLine_t& line_)
|
||||
unsigned _char = FormatCharTxtCtrl(FormatCharTxtHigh(line_.nImmediate, NULL), NULL);
|
||||
sprintf(line_.sImmediate, "%c", _char);
|
||||
|
||||
// if (ConsoleColorIsEscapeMeta( nImmediate_ ))
|
||||
//if (ConsoleColorIsEscapeMeta( nImmediate_ ))
|
||||
#if OLD_CONSOLE_COLOR
|
||||
if (ConsoleColorIsEscapeMeta(_char))
|
||||
sprintf(line_.sImmediate, "%c%c", _char, _char);
|
||||
@ -375,17 +375,18 @@ int GetDisassemblyLine(WORD nBaseAddress, DisasmLine_t& line_)
|
||||
#endif
|
||||
}
|
||||
|
||||
// if (iOpmode == AM_NA ) // Indirect Absolute
|
||||
//if (iOpmode == AM_NA ) // Indirect Absolute
|
||||
// sprintf( sTargetValue_, "%04X", nTargetPointer & 0xFFFF );
|
||||
// else
|
||||
// // sprintf( sTargetValue_, "%02X", nTargetValue & 0xFF );
|
||||
//else
|
||||
// //sprintf( sTargetValue_, "%02X", nTargetValue & 0xFF );
|
||||
// sprintf( sTargetValue_, "%04X:%02X", nTargetPointer & 0xFFFF, nTargetValue & 0xFF );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (iOpmode == AM_M)
|
||||
{
|
||||
// sprintf( sTarget, g_aOpmodes[ iOpmode ]._sFormat, (unsigned)nTarget );
|
||||
//sprintf( sTarget, g_aOpmodes[ iOpmode ]._sFormat, (unsigned)nTarget );
|
||||
sprintf(line_.sTarget , "%02X", (unsigned)nTarget);
|
||||
|
||||
if (nTarget == 0)
|
||||
@ -399,8 +400,8 @@ int GetDisassemblyLine(WORD nBaseAddress, DisasmLine_t& line_)
|
||||
|
||||
bDisasmFormatFlags |= DISASM_FORMAT_CHAR;
|
||||
line_.nImmediate = (BYTE)nTarget;
|
||||
unsigned _char = FormatCharTxtCtrl(FormatCharTxtHigh(line_.nImmediate, NULL), NULL);
|
||||
|
||||
unsigned _char = FormatCharTxtCtrl(FormatCharTxtHigh(line_.nImmediate, NULL), NULL);
|
||||
sprintf(line_.sImmediate, "%c", _char);
|
||||
#if OLD_CONSOLE_COLOR
|
||||
if (ConsoleColorIsEscapeMeta(_char))
|
||||
@ -410,6 +411,7 @@ int GetDisassemblyLine(WORD nBaseAddress, DisasmLine_t& line_)
|
||||
#endif
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
sprintf(line_.sAddress, "%04X", nBaseAddress);
|
||||
|
||||
@ -575,6 +577,8 @@ void FormatNopcodeBytes(WORD nBaseAddress, DisasmLine_t& line_)
|
||||
strncpy(pDst, (const char*)(mem + nBaseAddress), iByte);
|
||||
pDst += iByte;
|
||||
*pDst = 0;
|
||||
break;
|
||||
|
||||
case NOP_STRING_APPLE:
|
||||
iByte = line_.nOpbyte; // handle all bytes of text
|
||||
pSrc = (const char*)mem + nStartAddress;
|
||||
@ -604,10 +608,10 @@ void FormatNopcodeBytes(WORD nBaseAddress, DisasmLine_t& line_)
|
||||
break;
|
||||
|
||||
default:
|
||||
#if _DEBUG // Unhandled data disassembly!
|
||||
#if _DEBUG // Unhandled data disassembly!
|
||||
int* FATAL = 0;
|
||||
*FATAL = 0xDEADC0DE;
|
||||
#endif
|
||||
#endif
|
||||
iByte++;
|
||||
break;
|
||||
}
|
||||
@ -660,13 +664,17 @@ void FormatDisassemblyLine(const DisasmLine_t& line, char* sDisassembly, const i
|
||||
strcat( sDisassembly, ", Y" );
|
||||
}
|
||||
*/
|
||||
|
||||
char sTarget[32];
|
||||
|
||||
if (line.bTargetValue || line.bTargetRelative || line.bTargetImmediate)
|
||||
{
|
||||
if (line.bTargetRelative)
|
||||
{
|
||||
strcpy(sTarget, line.sTargetValue);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (line.bTargetImmediate)
|
||||
{
|
||||
strcat(sDisassembly, "#");
|
||||
@ -675,6 +683,7 @@ void FormatDisassemblyLine(const DisasmLine_t& line, char* sDisassembly, const i
|
||||
}
|
||||
else
|
||||
sprintf(sTarget, g_aOpmodes[line.iOpmode].m_sFormat, line.nTarget);
|
||||
}
|
||||
|
||||
strcat(sDisassembly, "$");
|
||||
strcat(sDisassembly, sTarget);
|
||||
|
Loading…
Reference in New Issue
Block a user