project64/Source/Project64-core/N64System/Recompiler/Arm/ArmRegInfo.cpp

70 lines
1.9 KiB
C++
Raw Normal View History

2016-08-11 11:09:21 +00:00
/****************************************************************************
* *
* Project64 - A Nintendo 64 emulator. *
* http://www.pj64-emu.com/ *
* Copyright (C) 2012 Project64. All rights reserved. *
* *
* License: *
* GNU/GPLv2 http://www.gnu.org/licenses/gpl-2.0.html *
* *
****************************************************************************/
#include "stdafx.h"
#if defined(__arm__) || defined(_M_ARM)
#include <Project64-core/N64System/Recompiler/RecompilerCodeLog.h>
2016-08-11 11:09:21 +00:00
#include <Project64-core/N64System/Recompiler/Arm/ArmRegInfo.h>
2016-09-29 12:17:54 +00:00
CArmRegInfo::CArmRegInfo() :
m_InCallDirect(false)
2016-08-11 11:09:21 +00:00
{
}
CArmRegInfo::CArmRegInfo(const CArmRegInfo& rhs)
{
*this = rhs;
}
CArmRegInfo::~CArmRegInfo()
{
}
CArmRegInfo& CArmRegInfo::operator=(const CArmRegInfo& right)
{
CRegBase::operator=(right);
2016-09-29 12:17:54 +00:00
m_InCallDirect = right.m_InCallDirect;
2016-08-11 11:09:21 +00:00
#ifdef _DEBUG
if (*this != right)
{
g_Notify->BreakPoint(__FILE__, __LINE__);
}
#endif
return *this;
}
void CArmRegInfo::BeforeCallDirect(void)
{
2016-09-29 12:17:54 +00:00
if (m_InCallDirect)
{
CPU_Message("%s: in CallDirect",__FUNCTION__);
g_Notify->BreakPoint(__FILE__, __LINE__);
return;
}
m_InCallDirect = true;
2016-08-11 11:09:21 +00:00
}
void CArmRegInfo::AfterCallDirect(void)
{
2016-09-29 12:17:54 +00:00
if (!m_InCallDirect)
{
CPU_Message("%s: Not in CallDirect",__FUNCTION__);
g_Notify->BreakPoint(__FILE__, __LINE__);
return;
}
m_InCallDirect = false;
2016-08-11 11:09:21 +00:00
}
void CArmRegInfo::WriteBackRegisters()
{
}
#endif