[Project64] rename tofix to legacycode

This commit is contained in:
zilmar 2015-12-15 17:01:06 +11:00
parent 9256356081
commit 5c27d6d1e8
9 changed files with 31 additions and 31 deletions

View File

@ -69,7 +69,7 @@ C7zip::~C7zip (void)
delete m_db;
m_db = NULL;
}
#ifdef tofix
#ifdef legacycode
SetNotificationCallback(NULL,NULL);
SzArDbExFree(&m_db, m_allocImp.Free);
@ -90,7 +90,7 @@ void C7zip::SetNotificationCallback (LP7ZNOTIFICATION NotfyFnc, void * CBInfo)
m_NotfyCallbackInfo = CBInfo;
}
#ifdef tofix
#ifdef legacycode
void C7zip::StatusUpdate(_7Z_STATUS status, int Value1, int Value2, C7zip * _this )
{
CFileItem * File = _this->m_CurrentFile >= 0 ? _this->FileItem(_this->m_CurrentFile) : NULL;
@ -239,4 +239,4 @@ std::wstring C7zip::FileNameIndex (int index)
filename.resize(namelen);
SzArEx_GetFileNameUtf16(m_db, index, (UInt16 *)filename.c_str());
return filename;
}
}

View File

@ -64,7 +64,7 @@ const int32_t R4300iOp::LWR_SHIFT[4] = { 24, 16, 8, 0 };
m_NextInstruction = JUMP;\
m_JumpToLocation = (*_PROGRAM_COUNTER);\
return;\
}
}
#define TLB_READ_EXCEPTION(Address) \
g_Reg->DoTLBReadMiss(m_NextInstruction == JUMP,Address);\
@ -2836,7 +2836,7 @@ void R4300iOp::UnknownOpcode()
g_System->m_EndEmulation = true;
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (HaveDebugger && !inFullScreen)
{
int32_t response;

View File

@ -41,7 +41,7 @@ void CDMA::OnFirstDMA()
default:
g_Notify->DisplayError(
stdstr_f("Unhandled CicChip(%d) in first DMA", g_Rom->CicChipID()).ToUTF16().c_str()
);
);
return;
}
g_MMU->SW_PAddr(base + offset, rt);
@ -220,7 +220,7 @@ void CDMA::PI_DMA_WRITE()
{
uint32_t i;
#ifdef tofix
#ifdef legacycode
#ifdef ROM_IN_MAPSPACE
if (WrittenToRom)
{

View File

@ -2399,7 +2399,7 @@ bool CMipsMemoryVM::LB_NonMemory(uint32_t PAddr, uint32_t* Value, bool /*SignExt
if (PAddr >= 0x10000000 && PAddr < 0x16000000)
{
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (WrittenToRom)
{
return false;
@ -3085,7 +3085,7 @@ bool CMipsMemoryVM::SW_NonMemory(uint32_t PAddr, uint32_t Value)
}
}
}
#ifdef tofix
#ifdef legacycode
if (ShowUnhandledMemory)
{
//if ( ( Value & DPC_CLR_TMEM_CTR ) != 0)

View File

@ -327,7 +327,7 @@ void CCodeSection::CompileExit(uint32_t JumpPC, uint32_t TargetPC, CRegInfo &Exi
break;
case CExitInfo::ExitResetRecompCode:
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (m_NextInstruction == JUMP || m_NextInstruction == DELAY_SLOT)
{
X86BreakPoint(__FILEW__,__LINE__);
@ -400,7 +400,7 @@ void CCodeSection::GenerateSectionLinkage()
if ((CompilePC() & 0xFFC) == 0xFFC)
{
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
//Handle Fall througth
uint8_t * Jump = NULL;
for (i = 0; i < 2; i ++)

View File

@ -239,7 +239,7 @@ bool LoopAnalysis::CheckLoopRegisterUsage(CCodeSection * Section)
case R4300i_SPECIAL_DSRA32: SPECIAL_DSRA32(); break;
default:
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (m_Command.Hex == 0x00000001) { break; }
g_Notify->DisplayError(L"Unhandled R4300i OpCode in FillSectionInfo 5\n%s",
R4300iOpcodeName(m_Command.Hex,m_PC));
@ -308,7 +308,7 @@ bool LoopAnalysis::CheckLoopRegisterUsage(CCodeSection * Section)
break;
case R4300i_REGIMM_BLTZAL:
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
m_Reg.GetMipsRegLo(31) = m_PC + 8;
m_Reg.SetMipsRegState(31,CRegInfo::STATE_CONST_32_SIGN);
Section->m_Cont.TargetPC = m_PC + 8;
@ -324,7 +324,7 @@ bool LoopAnalysis::CheckLoopRegisterUsage(CCodeSection * Section)
break;
case R4300i_REGIMM_BGEZAL:
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
m_NextInstruction = DELAY_SLOT;
if (m_Reg.IsConst(m_Command.rs))
{
@ -366,7 +366,7 @@ bool LoopAnalysis::CheckLoopRegisterUsage(CCodeSection * Section)
break;
default:
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (m_Command.Hex == 0x0407000D) { break; }
g_Notify->DisplayError(L"Unhandled R4300i OpCode in FillSectionInfo 4\n%s",
R4300iOpcodeName(m_Command.Hex,m_PC));
@ -377,7 +377,7 @@ bool LoopAnalysis::CheckLoopRegisterUsage(CCodeSection * Section)
break;
case R4300i_JAL:
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
m_NextInstruction = DELAY_SLOT;
m_Reg.GetMipsRegLo(31) = m_PC + 8;
m_Reg.SetMipsRegState(31,CRegInfo::STATE_CONST_32_SIGN);
@ -582,7 +582,7 @@ bool LoopAnalysis::CheckLoopRegisterUsage(CCodeSection * Section)
if (m_PC == m_PC + ((int16_t)m_Command.offset << 2) + 4)
{
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (!DelaySlotEffectsCompare(m_PC,m_Command.rs,m_Command.rt))
{
if (!Section->m_Jump.PermLoop)
@ -611,7 +611,7 @@ bool LoopAnalysis::CheckLoopRegisterUsage(CCodeSection * Section)
if (m_PC == Section->m_Jump.TargetPC)
{
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (!DelaySlotEffectsCompare(m_PC,m_Command.rs,m_Command.rt)) {
Section->m_Jump.PermLoop = true;
}
@ -933,7 +933,7 @@ void LoopAnalysis::SPECIAL_SRAV()
void LoopAnalysis::SPECIAL_JR()
{
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (m_Reg.IsConst(m_Command.rs))
{
Section->m_Jump.TargetPC = m_Reg.GetMipsRegLo(m_Command.rs);
@ -949,7 +949,7 @@ void LoopAnalysis::SPECIAL_JR()
void LoopAnalysis::SPECIAL_JALR()
{
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
m_Reg.GetMipsRegLo(m_Command.rd) = m_PC + 8;
m_Reg.SetMipsRegState(m_Command.rd,CRegInfo::STATE_CONST_32_SIGN);
if (m_Reg.IsConst(m_Command.rs)) {
@ -1324,4 +1324,4 @@ void LoopAnalysis::SPECIAL_DSRA32()
{
m_Reg.SetMipsRegState(m_Command.rd, CRegInfo::STATE_MODIFIED);
}
}
}

View File

@ -53,7 +53,7 @@ void CRecompiler::Run()
}
m_EndEmulation = false;
#ifdef tofix
#ifdef legacycode
*g_MemoryStack = (uint32_t)(RDRAM+(_GPR[29].W[0] & 0x1FFFFFFF));
#endif
__try
@ -175,7 +175,7 @@ void CRecompiler::RecompilerMain_VirtualTable_validate()
if (Info == NULL)
{
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (!g_TLB->ValidVaddr(PROGRAM_COUNTER))
{
DoTLBMiss(NextInstruction == DELAY_SLOT,PROGRAM_COUNTER);
@ -235,7 +235,7 @@ void CRecompiler::RecompilerMain_VirtualTable_validate()
}
}
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (!g_TLB->ValidVaddr(PROGRAM_COUNTER))
{
DoTLBMiss(NextInstruction == DELAY_SLOT,PROGRAM_COUNTER);
@ -384,7 +384,7 @@ void CRecompiler::RecompilerMain_Lookup()
/*if (bUseTlb())
{
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (!g_TLB->TranslateVaddr(PROGRAM_COUNTER, Addr))
{
DoTLBMiss(NextInstruction == DELAY_SLOT,PROGRAM_COUNTER);
@ -497,7 +497,7 @@ void CRecompiler::RecompilerMain_Lookup()
}
}
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
if (Profiling && IndvidualBlock) {
static uint32_t ProfAddress = 0;
@ -736,7 +736,7 @@ void CRecompiler::ResetRecompCode(bool bAllocate)
void CRecompiler::RecompilerMain_ChangeMemory()
{
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
uint32_t Value, Addr;
uint8_t * Block;

View File

@ -25,7 +25,7 @@ CJumpInfo::CJumpInfo()
ExitReason = CExitInfo::Normal;
}
#ifdef tofix
#ifdef legacycode
bool CCodeSection::IsAllParentLoops(CCodeSection * Parent, bool IgnoreIfCompiled, uint32_t Test)
{
@ -170,4 +170,4 @@ void CRegInfo::Initialize()
RoundingModel = RoundUnknown;
}
#endif
#endif

View File

@ -138,7 +138,7 @@ bool CDumpMemory::DumpMemory(LPCSTR FileName, DumpFormat Format, DWORD StartPC,
LogFile.SetFlush(false);
LogFile.SetTruncateFile(false);
g_Notify->BreakPoint(__FILE__, __LINE__);
#ifdef tofix
#ifdef legacycode
char Command[200];
for (COpcode OpCode(StartPC); OpCode.PC() < EndPC; OpCode.Next())
{
@ -154,4 +154,4 @@ bool CDumpMemory::DumpMemory(LPCSTR FileName, DumpFormat Format, DWORD StartPC,
break;
}
return false;
}
}